Function at 0x54cdd0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x58
mov edx, dword [ebp + 8]
xor ecx, ecx
push ebx
push esi
push edi
mov eax, dword [edx]
xor ebx, ebx
mov dword [ebp - 0x28], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x10], 0
mov esi, dword [eax]
mov ecx, dword [eax + 4]
inc esi
mov edi, dword [eax + 0x10]
push esi
push dword [edx + 0xc]
mov dword [ebp + 0xc], ecx
mov ecx, dword [eax + 0x14]
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x58], edi
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x54], ecx
call fcn.00521960
mov ecx, dword [ebp + 8]
add esp, 8
mov dword [ebp - 8], eax
mov ecx, dword [ecx + 0xc]
push esi
push ecx
test eax, eax
jne 0x54ce41
call fcn.00522220
add esp, 8
sub eax, 5
neg eax
sbb eax, eax
pop edi
pop esi
and eax, 7
pop ebx
mov esp, ebp
pop ebp
ret
call fcn.00521b20
mov ecx, dword [ebp - 0x28]
mov edx, eax
mov dword [ebp - 0x38], edx
mov ecx, dword [ecx + 0x24]
mov eax, dword [ecx]
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x2c]
push eax
mov eax, dword [ebp + 8]
push edx
push dword [ebp - 8]
push dword [eax + 0x14]
push ecx
call fcn.0057afc0
add esp, 0x1c
test eax, eax
jne 0x54d1dc
lea eax, [ebp - 0x10]
mov dword [ebp - 0x34], 0xffffffff
push eax
lea eax, [ebp - 0x20]
mov dword [ebp - 0x14], 0
push eax
lea eax, [ebp - 0x14]
mov dword [ebp - 0x20], 0
push eax
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x4c]
push eax
mov eax, dword [ebp - 0x30]
push dword [ebp - 0x2c]
mov eax, dword [eax + 0x14]
call eax
mov esi, eax
add esp, 0x18
test esi, esi
jne 0x54d1b1
mov ecx, dword [ebp + 0xc]
cmp dword [ebp - 0x10], ecx
jl 0x54ce75
test ebx, ebx
jne 0x54d0e2
mov eax, dword [ebp - 0x38]
sub eax, dword [ebp - 0x14]
mov ebx, dword [ebp - 0xc]
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 8]
add eax, dword [ebp - 0x14]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x14]
mov dword [ebp - 0x44], eax
mov eax, edi
or eax, ebx
je 0x54d091
mov eax, edi
mov dword [ebp - 0x1c], esi
and eax, 1
or eax, esi
jne 0x54cf23
nop word [eax + eax]
inc esi
xor edx, edx
xor ecx, ecx
mov eax, esi
bts edx, eax
cmp eax, 0x20
cmovae ecx, edx
xor edx, ecx
cmp eax, 0x40
cmovae ecx, edx
and edx, edi
and ecx, ebx
or edx, ecx
je 0x54cf00
mov dword [ebp - 0x1c], esi
mov edi, dword [ebp + 0x18]
xor edx, edx
dec edi
xor ecx, ecx
mov eax, edi
xor ebx, ebx
bts edx, eax
cmp eax, 0x20
cmovae ecx, edx
xor edx, ecx
cmp eax, 0x40
cmovae ecx, edx
and edx, dword [ebp - 0x18]
and ecx, dword [ebp - 0xc]
or edx, ecx
jne 0x54cf75
mov esi, dword [ebp - 0x18]
nop dword [eax]
dec edi
xor edx, edx
xor ecx, ecx
mov eax, edi
bts edx, eax
inc ebx
cmp eax, 0x20
cmovae ecx, edx
xor edx, ecx
cmp eax, 0x40
cmovae ecx, edx
and edx, esi
and ecx, dword [ebp - 0xc]
or edx, ecx
je 0x54cf50
mov esi, dword [ebp - 0x1c]
sub esi, ebx
mov eax, esi
cdq
sub eax, edx
sar eax, 1
mov dword [ebp - 0x48], eax
test eax, eax
jle 0x54d091
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x1c], 0
mov dword [ebp - 4], 0
mov ebx, dword [eax + 0x24]
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x3c]
mov edi, dword [ebx]
push dword [ebp - 0x40]
push ebx
mov eax, dword [edi + 0xc]
call eax
mov esi, eax
add esp, 0x10
test esi, esi
jne 0x54cfe8
mov eax, dword [ebp - 4]
mov dword [eax], ebx
cmp dword [edi], 1
jl 0x54cfe8
push dword [ebp - 0x44]
mov eax, dword [edi + 0x18]
push dword [ebp - 4]
call eax
mov esi, eax
add esp, 8
test esi, esi
je 0x54cfe8
push dword [ebp - 4]
mov eax, dword [edi + 0x10]
call eax
add esp, 4
xor ebx, ebx
mov dword [ebp - 4], ebx
jmp 0x54cfeb
mov ebx, dword [ebp - 4]
test esi, esi
je 0x54cff7
mov ecx, dword [ebp + 0xc]
jmp 0x54d096
mov eax, dword [ebp - 0x48]
add eax, dword [ebp + 0x18]
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x1c], eax
jge 0x54d040
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x40], 0
push eax
lea eax, [ebp - 0x48]
mov dword [ebp - 0x44], 0
push eax
lea eax, [ebp - 0x44]
mov dword [ebp - 0x48], 0
push eax
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x50]
push eax
mov eax, dword [edi + 0x14]
push ebx
call eax
mov esi, eax
add esp, 0x18
mov eax, dword [ebp - 0x3c]
test esi, esi
je 0x54d000
mov eax, dword [edi + 0x10]
push ebx
call eax
add esp, 4
test esi, esi
je 0x54d057
cmp esi, 0x65
je 0x54d057
mov ecx, dword [ebp + 0xc]
jmp 0x54d096
mov ecx, dword [ebp + 0xc]
xor eax, eax
cmp esi, 0x65
sete al
sub eax, dword [ebp + 0x18]
add eax, dword [ebp - 0x1c]
test eax, eax
jle 0x54d094
movq xmm1, qword [ebp - 0x58]
add ecx, eax
movd xmm0, eax
psrlq xmm1, xmm0
mov dword [ebp + 0xc], ecx
movq qword [ebp - 0x58], xmm1
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x58]
mov dword [ebp - 0x18], eax
jmp 0x54d094
mov ecx, dword [ebp + 0xc]
xor esi, esi
mov ebx, 1
test esi, esi
jne 0x54d1cc
test ecx, ecx
jg 0x54d0b9
cmp dword [ebp + 0x10], esi
jg 0x54d0b9
mov ecx, dword [ebp - 0x14]
test ecx, ecx
je 0x54d0d3
push ecx
push dword [ebp - 8]
jmp 0x54d0be
push 0xffffffffffffffff
push dword [ebp + 0x24]
push dword [ebp + 0x28]
call fcn.0054da10
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x54d1cc
mov ecx, dword [ebp + 0xc]
mov edi, dword [ebp - 0x18]
cmp dword [ebp - 0x10], ecx
jl 0x54ce75
mov eax, dword [ebp + 0x18]
mov edx, dword [ebp - 0x10]
add eax, ecx
cmp edx, eax
jge 0x54d1a4
sub edx, ecx
xor eax, eax
xor ecx, ecx
bts ecx, edx
cmp edx, 0x20
cmovae eax, ecx
xor ecx, eax
cmp edx, 0x40
cmovae eax, ecx
and ecx, edi
and eax, dword [ebp - 0xc]
or ecx, eax
je 0x54d119
mov edi, 1
jmp 0x54d11b
xor edi, edi
mov ecx, dword [ebp + 0xc]
cmp dword [ebp - 0x10], ecx
jle 0x54d142
mov eax, dword [ebp - 0x14]
sub eax, dword [ebp - 0x24]
push eax
mov eax, dword [ebp - 8]
add eax, dword [ebp - 0x24]
push eax
push dword [ebp + 0x28]
call fcn.0054da10
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x54d191
test edi, edi
je 0x54d15c
push 0xffffffffffffffff
push dword [ebp + 0x1c]
push dword [ebp + 0x28]
call fcn.0054da10
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x54d191
mov eax, dword [ebp - 0x20]
sub eax, dword [ebp - 0x14]
push eax
mov eax, dword [ebp - 8]
add eax, dword [ebp - 0x14]
push eax
push dword [ebp + 0x28]
call fcn.0054da10
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x54d191
test edi, edi
je 0x54d191
push 0xffffffffffffffff
push dword [ebp + 0x20]
push dword [ebp + 0x28]
call fcn.0054da10
add esp, 0xc
mov esi, eax
mov eax, dword [ebp - 0x20]
mov edi, dword [ebp - 0x18]
mov dword [ebp - 0x24], eax
test esi, esi
je 0x54ce75
jmp 0x54d1cc
cmp dword [ebp + 0x14], 0
je 0x54d1cc
push 0xffffffffffffffff
push dword [ebp + 0x24]
jmp 0x54d1bf
cmp esi, 0x65
jne 0x54d1cc
mov eax, dword [ebp - 8]
add eax, dword [ebp - 0x24]
push 0xffffffffffffffff
push eax
push dword [ebp + 0x28]
call fcn.0054da10
mov esi, eax
add esp, 0xc
mov eax, dword [ebp - 0x30]
push dword [ebp - 0x2c]
mov eax, dword [eax + 0x10]
call eax
add esp, 4
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret