Function at 0x1010c510
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
push edi
push ebp
sub esp, 8
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x2c]
mov edx, dword [esp + 0x4c]
mov ecx, dword [esp + 0x3c]
dec ecx
pxor mm6, mm6
movd mm5, edx
mov dword [esp], ecx
inc dword [esp + 0x5c]
pcmpeqd mm7, mm7
jmp 0x1010c540
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
movdqu xmm1, xmmword [edx + edi]
movzx eax, byte [edx + edi]
movzx ebx, byte [edx + edi + 1]
movzx ebp, byte [edx + edi + 2]
movzx eax, word [esi + eax*2]
movzx ebx, word [esi + ebx*2 + 0x200]
movzx ebp, word [esi + ebp*2 + 0x400]
xor eax, ebx
mov ebx, dword [esp]
xor eax, ebp
mov esi, dword [esp + 0x38]
and eax, dword [esp + 0x40]
and ebx, edx
mov ebp, dword [ecx + eax*4]
mov dword [esi + ebx*4], ebp
mov dword [ecx + eax*4], edx
mov ebx, ebp
mov eax, 2
movd mm2, dword [esp + 0x5c]
cmp edi, dword [esp + 0x2c]
jne 0x1010c5e7
jmp 0x1010c6fd
cmp ebx, dword [esp + 0x4c]
mov dword [esp + 4], ebx
jl 0x1010c6be
movdqu xmm2, xmmword [ebx + edi]
and ebx, dword [esp]
pcmpeqb xmm2, xmm1
pmovmskb ecx, xmm2
mov ebx, dword [esi + ebx*4]
not ecx
bsf ecx, ecx
cmp ecx, 0x10
je 0x1010c604
cmp ecx, eax
cmovg eax, ecx
mov ecx, dword [esp + 4]
cmovg ebp, ecx
mov ecx, dword [esp + 0x3c]
paddd mm2, mm7
add ecx, ebx
cmp edx, ecx
movd ecx, mm2
jge 0x1010c7d1
and ecx, ecx
jne 0x1010c5b0
jmp 0x1010c7d1
mov esi, dword [esp + 4]
add edx, edi
add edi, esi
movzx esi, word [eax + edx - 1]
movzx ecx, word [eax + edi - 1]
cmp esi, ecx
jne 0x1010c6ad
mov esi, 0x10
jmp 0x1010c630
movdqu xmm3, xmmword [esi + edx]
movdqu xmm2, xmmword [esi + edi]
pcmpeqb xmm2, xmm3
pmovmskb ecx, xmm2
cmp ecx, 0xffff
je 0x1010c651
not ecx
bsf ecx, ecx
jmp 0x1010c69a
add esi, 0x10
cmp esi, 0x100
jl 0x1010c630
movd xmm3, dword [edx + 0xfe]
movd xmm2, dword [edi + 0xfe]
pcmpeqb xmm2, xmm3
pmovmskb ecx, xmm2
and ecx, 0xf
not ecx
bsf ecx, ecx
sub ecx, 2
cmp ecx, 2
jl 0x1010c69a
mov ebp, dword [esp + 4]
mov eax, 0x102
sub edi, ebp
mov esi, dword [esp + 0x38]
sub edx, edi
jmp 0x1010c7d1
add ecx, esi
mov esi, dword [esp + 4]
sub edi, esi
mov esi, dword [esp + 0x38]
sub edx, edi
jmp 0x1010c5db
mov esi, dword [esp + 4]
sub edi, esi
mov esi, dword [esp + 0x38]
sub edx, edi
jmp 0x1010c5e7
mov edi, dword [esp + 0x2c]
jmp 0x1010c6d0
mov dword [esp + 4], ebx
movdqu xmm2, xmmword [ebx + edi]
and ebx, dword [esp]
pcmpeqb xmm2, xmm1
pmovmskb ecx, xmm2
mov ebx, dword [esi + ebx*4]
not ecx
bsf ecx, ecx
cmp ecx, 0x10
je 0x1010c71a
cmp ecx, eax
cmovg eax, ecx
mov ecx, dword [esp + 4]
cmovg ebp, ecx
mov ecx, dword [esp + 0x3c]
paddd mm2, mm7
add ecx, ebx
cmp edx, ecx
movd ecx, mm2
jge 0x1010c7d1
and ecx, ecx
jne 0x1010c6d0
jmp 0x1010c7d1
mov esi, dword [esp + 4]
add edx, dword [esp + 0x1c]
add edi, esi
movzx esi, word [eax + edx - 1]
movzx ecx, word [eax + edi - 1]
cmp esi, ecx
jne 0x1010c7be
mov esi, 0x10
jmp 0x1010c740
movdqu xmm3, xmmword [esi + edx]
movdqu xmm2, xmmword [esi + edi]
pcmpeqb xmm2, xmm3
pmovmskb ecx, xmm2
cmp ecx, 0xffff
je 0x1010c761
not ecx
bsf ecx, ecx
jmp 0x1010c7a9
add esi, 0x10
cmp esi, 0x100
jl 0x1010c740
movd xmm3, dword [edx + 0xfe]
movd xmm2, dword [edi + 0xfe]
pcmpeqb xmm2, xmm3
pmovmskb ecx, xmm2
and ecx, 0xf
not ecx
bsf ecx, ecx
sub ecx, 2
cmp ecx, 2
jl 0x1010c7a9
mov ebp, dword [esp + 4]
mov eax, 0x102
sub edi, ebp
mov esi, dword [esp + 0x38]
sub edx, dword [esp + 0x1c]
jmp 0x1010c7d1
add ecx, esi
mov esi, dword [esp + 4]
sub edi, esi
mov esi, dword [esp + 0x38]
sub edx, dword [esp + 0x1c]
jmp 0x1010c6f1
mov esi, dword [esp + 4]
sub edi, esi
mov esi, dword [esp + 0x38]
sub edx, dword [esp + 0x1c]
jmp 0x1010c6fd
mov ebx, edx
sub ebx, ebp
cmp eax, 3
jl 0x1010ca07
je 0x1010c7e2
jmp 0x1010c7ee
cmp ebx, 0x1000
jg 0x1010ca07
movd mm1, eax
mov ecx, eax
movd mm2, edx
add edx, ecx
psubd mm2, mm7
sub edx, 1
cmp ecx, ebx
jg 0x1010c810
jmp 0x1010c942
movd eax, mm2
add eax, 2
cmp eax, edx
jge 0x1010c942
lea eax, [ebx + ebp]
mov dword [esp + 4], eax
lea eax, [ebp + 1]
mov edi, dword [esp]
and edi, ebp
add edi, 0x204
cmp edi, dword [esp]
jg 0x1010c910
lea edi, [edi - 0x203]
jmp 0x1010c85b
cmp ebp, dword [esi + edi*4]
jle 0x1010c942
inc eax
inc edi
cmp eax, dword [esp + 4]
jl 0x1010c850
movd edi, mm2
mov ecx, edi
mov eax, edi
sub edx, 2
sub edi, ebx
and eax, dword [esp]
jmp 0x1010c880
mov dword [esi + eax*4], edi
inc ecx
inc eax
inc edi
and eax, dword [esp]
cmp ecx, edx
jle 0x1010c880
movd mm0, ebx
sub ecx, ebx
movd mm5, edx
movd mm2, ecx
movd mm3, ebp
mov edi, dword [esp + 0x1c]
mov edx, dword [esp + 0x30]
mov ebp, dword [esp + 0x34]
jmp 0x1010c8b0
movzx eax, byte [ecx + edi]
movzx ebx, byte [ecx + edi + 1]
movzx ecx, byte [ecx + edi + 2]
movzx eax, word [edx + eax*2]
movzx ebx, word [edx + ebx*2 + 0x200]
movzx ecx, word [edx + ecx*2 + 0x400]
xor eax, ebx
xor eax, ecx
movd ecx, mm2
and eax, dword [esp + 0x40]
mov dword [ebp + eax*4], ecx
inc ecx
movd eax, mm5
psubd mm2, mm7
cmp ecx, eax
jle 0x1010c8b0
psubd mm5, mm7
psubd mm5, mm7
jmp 0x1010c94b
movd mm3, edi
and edi, dword [esp]
cmp ebp, dword [esi + edi*4]
movd edi, mm3
jle 0x1010c942
inc eax
inc edi
cmp eax, dword [esp + 4]
jl 0x1010c900
movd edi, mm2
mov ecx, edi
mov eax, edi
sub edx, 2
sub edi, ebx
and eax, dword [esp]
jmp 0x1010c930
mov dword [esi + eax*4], edi
inc ecx
inc eax
inc edi
and eax, dword [esp]
cmp ecx, edx
jle 0x1010c930
jmp 0x1010c88d
movd mm0, ebx
movd mm3, ebp
movd mm5, edx
mov edi, dword [esp + 0x1c]
mov edx, dword [esp + 0x30]
mov ebp, dword [esp + 0x34]
movd ecx, mm2
jmp 0x1010c960
movzx eax, byte [ecx + edi]
movzx ebx, byte [ecx + edi + 1]
movzx ecx, byte [ecx + edi + 2]
movzx eax, word [edx + eax*2]
movzx ebx, word [edx + ebx*2 + 0x200]
movzx ecx, word [edx + ecx*2 + 0x400]
xor eax, ebx
movd ebx, mm2
xor eax, ecx
and ebx, dword [esp]
and eax, dword [esp + 0x40]
mov ecx, dword [ebp + eax*4]
mov dword [esi + ebx*4], ecx
movd ecx, mm2
mov dword [ebp + eax*4], ecx
movd eax, mm5
inc ecx
cmp ecx, eax
psubd mm2, mm7
jle 0x1010c960
movd edx, mm6
movd eax, mm0
movd ecx, mm1
mov esi, dword [esp + 0x54]
mov ebp, dword [esp + 0x50]
sub ecx, 3
mov word [esi + edx*2], ax
dec eax
mov byte [edx + ebp], cl
psubd mm6, mm7
mov esi, dword [esp + 0x28]
mov ebx, eax
mov ebp, dword [esp + 0x24]
shr eax, 7
add eax, 0x100
mov edi, dword [esp + 0x20]
cmp ebx, 0x100
cmovge ebx, eax
movzx eax, byte [ebx + edi + 0x100]
movzx ecx, byte [ecx + edi]
add ecx, 0x101
inc word [esi + eax*4]
inc word [ebp + ecx*4]
movd edx, mm5
jmp 0x1010ca2e
mov ecx, dword [esp + 0x1c]
movd edi, mm6
movzx ecx, byte [edx + ecx]
mov esi, dword [esp + 0x54]
mov ebp, dword [esp + 0x50]
mov word [esi + edi*2], 0
mov byte [edi + ebp], cl
mov esi, dword [esp + 0x24]
psubd mm6, mm7
inc word [esi + ecx*4]
mov edi, dword [esp + 0x1c]
inc edx
cmp edx, dword [esp + 0x44]
jge 0x1010ca46
movd ecx, mm6
cmp ecx, dword [esp + 0x48]
jl 0x1010c540
mov esi, dword [esp + 0x58]
mov dword [esi], edx
movd eax, mm6
add esp, 8
emms
pop ebp
pop edi
pop esi
pop ebx
ret