Function at 0x64e810
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x20
mov esi, ecx
mov ecx, dword [esi + 0x2c]
mov dword [esp + 0x1c], ecx
mov eax, dword [esi + 0x74]
lea edx, [ecx - 0x106]
mov dword [esp + 0x18], edx
xor ebp, ebp
jmp 0x64e843
mov ecx, dword [esi + 0x2c]
mov ebx, dword [esi + 0x3c]
mov edx, dword [esi + 0x6c]
sub ebx, eax
sub ebx, edx
add ecx, dword [esp + 0x18]
cmp edx, ecx
jb 0x64eb1d
mov eax, dword [esi + 0x38]
mov edi, dword [esp + 0x1c]
lea ecx, [eax + edi]
mov edx, edi
sub edx, ebx
mov dword [esp + 8], edx
mov dword [esp + 4], ecx
mov dword [esp], eax
call fcn.007ce510
sub dword [esi + 0x70], edi
sub dword [esi + 0x6c], edi
sub dword [esi + 0x5c], edi
mov eax, dword [esi + 0x2c]
mov edx, dword [esi + 0x44]
mov edi, dword [esi + 0x4c]
lea ecx, [edx + edi*2]
cmp edi, 8
jae 0x64e8b0
mov edx, edi
pxor xmm6, xmm6
movdqa xmm7, xmmword [0x7e2160]
jmp 0x64e9c9
mov dword [esp + 0xc], edx
mov ebp, edi
and ebp, 0xfffffff8
mov edx, edi
and edx, 0xfffffff8
mov dword [esp + 0x14], edx
pxor xmm6, xmm6
movdqa xmm7, xmmword [0x7e2160]
je 0x64e9c5
mov dword [esp + 0x10], edi
lea edx, [ebp + ebp]
sub ecx, edx
mov edx, edi
sub edx, ebp
movd xmm0, eax
pshufd xmm0, xmm0, 0
mov edi, dword [esp + 0xc]
mov ebp, dword [esp + 0x10]
lea ebp, [edi + ebp*2 - 0x10]
mov edi, dword [esp + 0x14]
nop dword [eax + eax]
movdqu xmm1, xmmword [ebp]
pshufd xmm1, xmm1, 0x4e
pshuflw xmm1, xmm1, 0x1b
pshufhw xmm2, xmm1, 0x1b
movdqa xmm1, xmm2
punpcklwd xmm1, xmm6
punpckhwd xmm2, xmm6
movdqa xmm3, xmm0
pxor xmm3, xmm7
movdqa xmm4, xmm2
pxor xmm4, xmm7
movdqa xmm5, xmm3
pcmpgtd xmm5, xmm4
pshuflw xmm4, xmm5, 0xe8
pshufhw xmm4, xmm4, 0xe8
pshufd xmm4, xmm4, 0xe8
movdqa xmm5, xmm1
pxor xmm5, xmm7
pcmpgtd xmm3, xmm5
pshuflw xmm3, xmm3, 0xe8
pshufhw xmm3, xmm3, 0xe8
pshufd xmm3, xmm3, 0xe8
punpcklqdq xmm3, xmm4
psllw xmm3, 0xf
psraw xmm3, 0xf
psubd xmm1, xmm0
psubd xmm2, xmm0
pslld xmm2, 0x10
psrad xmm2, 0x10
pslld xmm1, 0x10
psrad xmm1, 0x10
packssdw xmm1, xmm2
pandn xmm3, xmm1
pshufd xmm1, xmm3, 0x4e
pshuflw xmm1, xmm1, 0x1b
pshufhw xmm1, xmm1, 0x1b
movdqu xmmword [ebp], xmm1
add ebp, 0xfffffff0
add edi, 0xfffffff8
jne 0x64e900
mov edi, dword [esp + 0x14]
cmp dword [esp + 0x10], edi
mov ebp, 0
je 0x64e9e2
jmp 0x64e9c9
mov edx, edi
xor ebp, ebp
add ecx, 0xfffffffe
nop dword [eax]
movzx edi, word [ecx]
sub edi, eax
cmovb di, bp
mov word [ecx], di
add ecx, 0xfffffffe
dec edx
jne 0x64e9d0
mov edi, dword [esi + 0x40]
lea ecx, [edi + eax*2]
cmp eax, 8
jae 0x64ea00
mov edx, eax
jmp 0x64eaee
mov ebp, eax
and ebp, 0xfffffff8
mov edx, eax
and edx, 0xfffffff8
je 0x64eaec
mov dword [esp + 0x14], edx
lea edx, [ebp + ebp]
sub ecx, edx
mov edx, eax
sub edx, ebp
movd xmm0, eax
pshufd xmm0, xmm0, 0
lea ebp, [edi + eax*2 - 0x10]
mov edi, dword [esp + 0x14]
nop
movdqu xmm1, xmmword [ebp]
pshufd xmm1, xmm1, 0x4e
pshuflw xmm1, xmm1, 0x1b
pshufhw xmm2, xmm1, 0x1b
movdqa xmm1, xmm2
punpcklwd xmm1, xmm6
punpckhwd xmm2, xmm6
movdqa xmm3, xmm0
pxor xmm3, xmm7
movdqa xmm4, xmm2
pxor xmm4, xmm7
movdqa xmm5, xmm3
pcmpgtd xmm5, xmm4
pshuflw xmm4, xmm5, 0xe8
pshufhw xmm4, xmm4, 0xe8
pshufd xmm4, xmm4, 0xe8
movdqa xmm5, xmm1
pxor xmm5, xmm7
pcmpgtd xmm3, xmm5
pshuflw xmm3, xmm3, 0xe8
pshufhw xmm3, xmm3, 0xe8
pshufd xmm3, xmm3, 0xe8
punpcklqdq xmm3, xmm4
psllw xmm3, 0xf
psraw xmm3, 0xf
psubd xmm1, xmm0
psubd xmm2, xmm0
pslld xmm2, 0x10
psrad xmm2, 0x10
pslld xmm1, 0x10
psrad xmm1, 0x10
packssdw xmm1, xmm2
pandn xmm3, xmm1
pshufd xmm1, xmm3, 0x4e
pshuflw xmm1, xmm1, 0x1b
pshufhw xmm1, xmm1, 0x1b
movdqu xmmword [ebp], xmm1
add ebp, 0xfffffff0
add edi, 0xfffffff8
jne 0x64ea30
cmp eax, dword [esp + 0x14]
je 0x64eb17
jmp 0x64eaee
mov edx, eax
add ecx, 0xfffffffe
nop word cs:[eax + eax]
movzx edi, word [ecx]
sub edi, eax
mov ebp, 0
cmovae bp, di
mov word [ecx], bp
add ecx, 0xfffffffe
dec edx
jne 0x64eb00
add ebx, dword [esp + 0x1c]
xor ebp, ebp
mov edi, dword [esi]
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x64ec58
mov eax, dword [esi + 0x74]
cmp ecx, ebx
cmovbe ebx, ecx
test ebx, ebx
je 0x64eb80
mov ebp, dword [esi + 0x38]
add ebp, dword [esi + 0x6c]
add ebp, eax
sub ecx, ebx
mov dword [edi + 4], ecx
mov eax, dword [edi]
mov dword [esp + 8], ebx
mov dword [esp + 4], eax
mov dword [esp], ebp
call fcn.007ce510
mov eax, dword [edi + 0x1c]
mov eax, dword [eax + 0x18]
cmp eax, 2
je 0x64eb90
cmp eax, 1
jne 0x64eba6
mov eax, dword [edi + 0x30]
mov dword [esp + 8], ebx
mov dword [esp + 4], ebp
mov dword [esp], eax
call fcn.006515d0
jmp 0x64eba3
xor ebx, ebx
jmp 0x64ebb0
mov eax, dword [edi + 0x30]
mov dword [esp + 8], ebx
mov dword [esp + 4], ebp
mov dword [esp], eax
call fcn.00652040
mov dword [edi + 0x30], eax
add dword [edi], ebx
add dword [edi + 8], ebx
mov eax, dword [esi + 0x74]
xor ebp, ebp
add eax, ebx
mov dword [esi + 0x74], eax
mov edi, dword [esi + 0x16b4]
lea ecx, [edi + eax]
cmp ecx, 3
jb 0x64ec45
mov ebx, dword [esi + 0x38]
mov edx, dword [esi + 0x6c]
sub edx, edi
movzx ebp, byte [ebx + edx]
mov dword [esi + 0x48], ebp
mov cl, byte [esi + 0x58]
shl ebp, cl
movzx ecx, byte [ebx + edx + 1]
xor ecx, ebp
xor ebp, ebp
and ecx, dword [esi + 0x54]
mov dword [esi + 0x48], ecx
nop word [eax + eax]
test edi, edi
je 0x64ec45
mov eax, dword [esi + 0x38]
mov edi, dword [esi + 0x48]
mov cl, byte [esi + 0x58]
shl edi, cl
movzx eax, byte [eax + edx + 2]
xor eax, edi
and eax, dword [esi + 0x54]
mov dword [esi + 0x48], eax
mov ecx, dword [esi + 0x40]
mov edi, dword [esi + 0x44]
mov ax, word [edi + eax*2]
mov edi, dword [esi + 0x34]
and edi, edx
mov word [ecx + edi*2], ax
mov eax, dword [esi + 0x44]
mov ecx, dword [esi + 0x48]
mov word [eax + ecx*2], dx
inc edx
mov ecx, dword [esi + 0x16b4]
lea edi, [ecx - 1]
mov dword [esi + 0x16b4], edi
mov eax, dword [esi + 0x74]
lea ecx, [eax + ecx - 1]
cmp ecx, 2
ja 0x64ebf0
cmp eax, 0x105
ja 0x64ec58
mov ecx, dword [esi]
cmp dword [ecx + 4], 0
jne 0x64e840
mov eax, dword [esi + 0x16c0]
mov edx, dword [esi + 0x3c]
mov ecx, edx
sub ecx, eax
jbe 0x64ecd0
mov edi, dword [esi + 0x74]
add edi, dword [esi + 0x6c]
cmp eax, edi
jae 0x64eca4
sub edx, edi
cmp edx, 0x102
mov ebx, 0x102
cmovbe ebx, edx
mov eax, dword [esi + 0x38]
add eax, edi
mov dword [esp + 8], ebx
mov dword [esp], eax
mov dword [esp + 4], 0
call fcn.007ce3c0
add ebx, edi
mov dword [esi + 0x16c0], ebx
jmp 0x64ecd0
add edi, 0x102
sub edi, eax
jbe 0x64ecd0
cmp edi, ecx
cmova edi, ecx
add eax, dword [esi + 0x38]
mov dword [esp + 8], edi
mov dword [esp], eax
mov dword [esp + 4], 0
call fcn.007ce3c0
add dword [esi + 0x16c0], edi
add esp, 0x20
pop esi
pop edi
pop ebx
pop ebp
ret