Function at 0x4cade0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1e90
call fcn.004ebe60
mov eax, dword [0x515040]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0x14]
mov dword [ebp - 0x1e38], eax
mov eax, dword [ecx + 0x28]
push esi
mov esi, edx
mov dword [ebp - 0x1e40], ebx
mov ebx, dword [ebp + 0x18]
lea edx, [eax + eax*4]
mov dword [ebp - 0x1e34], ecx
push edi
mov eax, dword [esi + 0x800]
add dword [ebx + edx*4 + 0x24], eax
mov ecx, dword [esi + 0x800]
mov eax, dword [ebx + edx*4 + 0x28]
cmp eax, ecx
mov dword [ebp - 0x1e3c], ebx
cmovbe eax, ecx
mov dword [ebp - 0x1e4c], 0x800
mov dword [ebx + edx*4 + 0x28], eax
lea eax, [ebp - 0x1e2c]
push dword [esi + 0x800]
lea edx, [ebp - 0x1e4c]
mov dword [ebp - 0x1e50], eax
push esi
mov ecx, eax
call fcn.004ad330
add esp, 8
test eax, eax
je 0x4cae8a
xorps xmm0, xmm0
movlpd qword [ebp - 0x1e54], xmm0
mov eax, dword [ebp - 0x1e50]
mov ecx, dword [ebp - 0x1e54]
jmp 0x4cae96
mov ecx, dword [ebp - 0x1e50]
mov eax, dword [ebp - 0x1e4c]
mov dword [ebp - 0x1e30], ecx
mov dword [ebp - 0x162c], ecx
mov dword [ebp - 0x1628], eax
cmp eax, 0x47d
je 0x4caec3
inc dword [ebx + 0xc]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004cf01b
mov esp, ebp
pop ebp
ret
cmp dword [ecx], 0x36696873
je 0x4caedf
inc dword [ebx + 0x14]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004cf01b
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 0x1e34]
mov eax, dword [ebp + 8]
cmp eax, dword [edx + 0x20]
jne 0x4cb1e1
mov eax, dword [ebp + 0xc]
cmp eax, dword [edx + 0x24]
jne 0x4cb1e1
mov eax, dword [ecx + 4]
cmp eax, dword [ebx + 0x2c]
ja 0x4caf19
inc dword [ebx + 0x10]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004cf01b
mov esp, ebp
pop ebp
ret
mov dword [ebx + 0x2c], eax
lea edi, [ebx + 0x70]
xor esi, esi
lea ebx, [ecx + 0x40d]
cmp esi, dword [edx + 0x28]
je 0x4caf3a
mov eax, dword [edi]
mov ecx, edi
push ebx
call dword [eax + 4]
mov edx, dword [ebp - 0x1e34]
inc esi
add ebx, 0x1c
add edi, 0x4640
cmp esi, 4
jb 0x4caf27
imul eax, dword [edx + 0x28], 0x4640
lea edi, [ebp - 0x40c]
mov esi, dword [ebp - 0x1e30]
mov ecx, 0x100
mov ebx, dword [ebp - 0x1e3c]
add esi, 8
rep movsd dword es:[edi], dword [esi]
mov esi, dword [ebp - 0x1e30]
lea edx, [ebx + 0x78]
add edx, eax
mov dword [ebp - 0x1e3c], edx
mov edi, dword [ebp - 0x1e3c]
movzx eax, byte [esi + 0x40c]
shl eax, 0xa
add edx, eax
lea ecx, [edi + 0x4288]
lea eax, [edx + 0x400]
cmp eax, ecx
jae 0x4cafa5
lea ecx, [edx + 0x400]
sub ecx, edx
lea eax, [ebp - 0x40c]
and ecx, 0xfffffffc
push ecx
push eax
push edx
call fcn.004d21c0
add esp, 0xc
cmp byte [esi + 0x40c], 0x10
jne 0x4cb1e4
lea edx, [edi + 2]
xor ecx, ecx
mov edi, 0x10a2
movzx eax, byte [edx - 2]
lea edx, [edx + 4]
add eax, ecx
imul eax, eax, 0x401
mov ecx, eax
shr ecx, 6
xor ecx, eax
movzx eax, byte [edx - 5]
add ecx, eax
imul eax, ecx, 0x401
mov ecx, eax
shr ecx, 6
xor ecx, eax
movzx eax, byte [edx - 4]
add ecx, eax
imul eax, ecx, 0x401
mov ecx, eax
shr ecx, 6
xor ecx, eax
movzx eax, byte [edx - 3]
add ecx, eax
imul ecx, ecx, 0x401
mov eax, ecx
shr eax, 6
xor ecx, eax
sub edi, 1
jne 0x4cafd2
lea ecx, [ecx + ecx*8]
mov eax, ecx
shr eax, 0xb
xor eax, ecx
imul eax, eax, 0x8001
cmp eax, dword [esi + 0x408]
jne 0x4cb1e4
mov ecx, dword [ebp - 0x1e34]
xorps xmm0, xmm0
movlpd qword [ebp - 0x1e70], xmm0
xorps xmm1, xmm1
movlpd qword [ebp - 0x1e68], xmm0
movlpd qword [ebp - 0x1e60], xmm0
mov edx, dword [ecx + 0x28]
mov ecx, dword [ebp - 0x1e40]
imul eax, edx, 0x70
lea edi, [ecx + 0x3880]
add edi, eax
movss xmm2, dword [edi + 4]
movss xmm0, dword [edi]
movss dword [ebp - 0x1e4c], xmm2
mov eax, dword [ebp - 0x1e4c]
mov dword [ebp - 0x1e74], eax
mov eax, dword [edi + 0x68]
movss dword [ebp - 0x1e34], xmm0
mov dword [ebp - 0x1e58], eax
mov dword [ebp - 0x1e70], eax
mov eax, dword [edi + 0x64]
unpcklps xmm0, xmm1
movss dword [ebp - 0x1e30], xmm2
movq qword [ebp - 0x1e7c], xmm0
mov dword [ebp - 0x1e4c], eax
mov dword [ebp - 0x1e6c], eax
call fcn.004cde50
mov byte [ebp - 0x1e5c], al
test al, al
je 0x4cb112
lea eax, [ebp - 0x1e8c]
mov edx, ecx
mov ecx, dword [ebp - 0x1e38]
push edi
push eax
call fcn.004cded0
mov ecx, dword [ebp - 0x1e40]
add esp, 8
movq xmm0, qword [eax]
mov eax, dword [eax + 8]
movq qword [ebp - 0x1e68], xmm0
mov dword [ebp - 0x1e60], eax
mov esi, dword [ecx + 0x426c]
push 0x4288
push dword [ebp - 0x1e3c]
push ecx
call fcn.004d21c0
add esp, 0xc
lea eax, [ebp - 0x10c]
push 0x100
push 0
push eax
call fcn.004d0d20
mov edx, dword [ebp - 0x1e38]
lea eax, [ebp - 0x1624]
add esp, 0xc
mov ecx, esi
push ebx
mov ebx, dword [ebp - 0x1e40]
push eax
lea eax, [ebp - 0x10c]
push eax
push ebx
call fcn.004cac90
add esp, 0x10
lea ecx, [ebp - 0x1e7c]
call fcn.004b9a40
mov ecx, dword [ebp - 0x1e38]
cmp eax, 0x441
jae 0x4cb1a3
test byte [ecx + eax + 0x4684], 1
je 0x4cb1a3
movss xmm0, dword [ebp - 0x1e34]
movss dword [edi], xmm0
movss xmm0, dword [ebp - 0x1e30]
movss dword [edi + 4], xmm0
cmp byte [ebp - 0x1e5c], 0
mov eax, dword [ebp - 0x1e58]
mov dword [edi + 0x68], eax
mov eax, dword [ebp - 0x1e4c]
mov dword [edi + 0x64], eax
je 0x4cb1e4
lea eax, [ebp - 0x1e68]
mov edx, ebx
push eax
push edi
call fcn.004cdfe0
add esp, 8
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004cf01b
mov esp, ebp
pop ebp
ret
inc dword [ebx + 8]
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004cf01b
mov esp, ebp
pop ebp
ret