Function at 0x4ca69b
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
and dword [ebp - 0x48], 0
push ebx
push edi
mov edi, dword [ebp + 0x14]
push edi
call fcn.00460c34
push edi
call fcn.00460b77
push edi
mov dword [ebp - 0x14], eax
call fcn.00460b77
push edi
mov dword [ebp - 0x18], eax
call fcn.00460b77
push dword [ebp + 0x14]
mov edi, eax
mov dword [ebp - 0x28], edi
call fcn.00460b77
mov ebx, eax
add esp, 0x14
mov dword [ebp - 0x10], ebx
test ebx, ebx
je 0x4ca9ab
push esi
mov esi, dword [ebp + 0x10]
push esi
push dword [ebp + 0xc]
push edi
call fcn.004ca245
add esp, 0xc
test eax, eax
je 0x4ca9aa
push edi
call fcn.0045fbe9
pop ecx
test eax, eax
jne 0x4ca9aa
push esi
push ebx
call fcn.0045fa49
pop ecx
pop ecx
test eax, eax
je 0x4ca9aa
push edi
call fcn.0045fc8e
push ebx
mov dword [ebp - 8], eax
call fcn.0045fc8e
mov esi, dword [esi + 4]
push esi
push edi
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x40], esi
call fcn.0046032b
add esp, 0x10
test eax, eax
je 0x4ca9aa
mov eax, dword [edi + 4]
mov ebx, dword [edi]
mov dword [ebp - 0x44], ebx
cmp eax, esi
jge 0x4ca762
mov ecx, esi
lea edi, [ebx + eax*4]
sub ecx, eax
xor eax, eax
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 0x28]
mov dword [edi + 4], esi
mov edi, dword [ebp - 0x14]
push esi
push edi
call fcn.0046032b
pop ecx
pop ecx
test eax, eax
je 0x4ca9aa
mov edx, dword [edi]
xor eax, eax
inc eax
mov dword [ebp - 0x1c], edx
mov dword [edx], eax
cmp esi, eax
jle 0x4ca794
lea ecx, [esi - 1]
xor eax, eax
lea edi, [edx + 4]
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 0x14]
mov dword [edi + 4], esi
mov edi, dword [ebp - 0x18]
push esi
push edi
call fcn.0046032b
pop ecx
pop ecx
test eax, eax
je 0x4ca9aa
mov edx, edi
mov edi, dword [edx]
mov dword [ebp - 0x30], edi
test esi, esi
jle 0x4ca7bc
mov ecx, esi
xor eax, eax
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 0x10]
mov dword [edx + 4], esi
mov edx, dword [ebp - 8]
mov eax, dword [edi]
mov dword [ebp - 0x2c], eax
test edx, edx
je 0x4ca8b8
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebx]
mov dword [ebp - 0x24], eax
test al, 1
jne 0x4ca8b5
mov ecx, dword [edi]
mov eax, ecx
and dword [ebp - 0xc], 0
and eax, 1
neg eax
mov dword [ebp - 0x38], eax
mov eax, dword [ebp + 0x10]
mov eax, dword [eax]
mov eax, dword [eax]
and eax, dword [ebp - 0x38]
xor ecx, eax
lea eax, [esi - 1]
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x50], eax
test eax, eax
jle 0x4ca894
mov esi, dword [ebp - 0x24]
lea eax, [edi + 4]
mov edx, dword [ebp - 0x38]
mov dword [ebp - 4], eax
mov eax, ebx
push 0xfffffffffffffffc
sub eax, edi
pop ecx
sub ecx, edi
mov dword [ebp - 0x3c], eax
mov edi, dword [ebp - 0x20]
mov dword [ebp - 0x4c], ecx
mov ecx, dword [ebp - 4]
mov eax, dword [eax + ecx]
mov ecx, dword [ebp - 0xc]
shl eax, 0x1f
shr esi, 1
or eax, esi
shr edi, 1
mov esi, dword [ebp - 0x3c]
mov dword [ebx + ecx*4], eax
mov ecx, dword [ebp - 4]
mov eax, dword [ebp + 0x10]
mov esi, dword [esi + ecx]
mov eax, dword [eax]
add ecx, dword [ebp - 0x4c]
mov ecx, dword [ecx + eax + 4]
mov eax, dword [ebp - 4]
and ecx, edx
xor ecx, dword [eax]
mov eax, ecx
shl eax, 0x1f
or eax, edi
mov edi, dword [ebp - 4]
mov dword [edi - 4], eax
mov edi, ecx
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 4]
inc eax
add ecx, 4
mov dword [ebp - 0xc], eax
cmp eax, dword [ebp - 0x50]
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 4], ecx
jl 0x4ca830
mov edx, dword [ebp - 8]
mov dword [ebp - 0x20], edi
mov edi, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x20]
mov dword [ebp - 0x24], esi
mov esi, dword [ebp - 0xc]
mov eax, dword [ebp - 0x24]
shr eax, 1
shr ecx, 1
sub edx, 1
mov dword [ebx + esi*4], eax
mov eax, esi
mov esi, dword [ebp - 0x40]
mov dword [ebp - 8], edx
mov dword [edi + eax*4], ecx
jne 0x4ca7d5
mov edi, dword [ebp - 0x10]
cmp edx, 0x20
jg 0x4ca8cf
cmp dword [ebx], 0
je 0x4ca9aa
cmp dword [ebx], 1
je 0x4ca988
mov ecx, dword [ebp - 0x34]
cmp edx, ecx
jge 0x4ca90b
mov eax, dword [ebp - 0x14]
mov ebx, dword [ebp - 0x2c]
mov dword [ebp - 0x34], edx
mov edx, ecx
mov ecx, dword [ebp - 0x28]
mov dword [ebp - 0x28], edi
mov edi, dword [ebp - 0x18]
mov dword [ebp - 0x10], ecx
mov ecx, dword [ecx]
mov dword [ebp - 0x14], edi
mov edi, dword [ebp - 0x30]
mov dword [ebp - 0x18], eax
mov eax, dword [eax]
mov dword [ebp - 8], edx
mov dword [ebp - 0x44], ebx
mov dword [ebp - 0x2c], ecx
mov dword [ebp - 0x1c], edi
mov dword [ebp - 0x30], eax
jmp 0x4ca90e
mov edi, dword [ebp - 0x1c]
test esi, esi
jle 0x4ca949
mov eax, dword [ebp - 0x2c]
mov ecx, ebx
sub eax, ebx
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x30]
sub eax, ebx
sub edi, ebx
mov ebx, esi
mov dword [ebp - 0x4c], eax
mov esi, dword [ebp - 0x50]
mov edx, eax
mov eax, dword [esi + ecx]
xor dword [ecx], eax
mov eax, dword [edx + ecx]
xor dword [edi + ecx], eax
lea ecx, [ecx + 4]
sub ebx, 1
jne 0x4ca92d
mov esi, dword [ebp - 0x40]
mov ebx, dword [ebp - 0x44]
mov edx, dword [ebp - 8]
mov edi, dword [ebp - 0x10]
cmp edx, dword [ebp - 0x34]
jne 0x4ca7ca
lea eax, [edx - 1]
cdq
and edx, 0x1f
lea edi, [edx + eax]
sar edi, 5
jmp 0x4ca969
test edi, edi
je 0x4ca970
dec edi
mov eax, dword [ebx + edi*4]
test eax, eax
je 0x4ca964
push eax
call fcn.0045fcc4
shl edi, 5
pop ecx
lea edx, [edi + eax]
mov edi, dword [ebp - 0x10]
mov dword [ebp - 8], edx
jmp 0x4ca7ca
mov ebx, dword [ebp - 0x14]
push ebx
call fcn.0046010f
push ebx
push dword [ebp + 8]
call fcn.0045fa49
add esp, 0xc
xor ecx, ecx
test eax, eax
push 1
pop eax
cmovne ecx, eax
mov dword [ebp - 0x48], ecx
pop esi
push dword [ebp + 0x14]
call fcn.00460ad7
mov eax, dword [ebp - 0x48]
pop ecx
pop edi
pop ebx
leave
ret