Function at 0x10085210
Capabilities:
Encode data using xor

Disassembly:
mov edx, dword [esp + 4]
sub esp, 0xc
push ebp
mov ebp, dword [esp + 0x18]
test edx, edx
je 0x10085442
mov eax, dword [esp + 0x24]
push ebx
push esi
push edi
cmp eax, 5
jne 0x1008530e
mov ecx, dword [esp + 0x2c]
mov ebx, ebp
mov edi, dword [esp + 0x28]
mov dword [esp + 0x10], ecx
cmp edx, 2
jne 0x100852b0
test ecx, ecx
je 0x1008543f
mov eax, ecx
lea ecx, [edi*4]
mov dword [esp + 0x20], eax
nop dword [eax]
mov esi, 2
cmp edi, esi
jbe 0x1008529f
nop dword [eax]
mov eax, dword [ebx + esi*4 - 4]
mov ecx, dword [ebx + esi*4]
and eax, 0xff800000
add eax, ecx
add ecx, dword [ebx + esi*4 - 4]
xor ecx, eax
and ecx, 0x7fffff
xor ecx, eax
mov dword [ebx + esi*4], ecx
inc esi
cmp esi, edi
jb 0x10085270
mov eax, dword [esp + 0x20]
lea ecx, [edi*4]
add ebx, ecx
sub eax, 1
mov dword [esp + 0x20], eax
jne 0x10085260
mov ecx, dword [esp + 0x2c]
jmp 0x100852c0
test edx, edx
jle 0x1008543f
test ecx, ecx
je 0x1008543f
lea ebx, [edi*4]
mov eax, 1
cmp edi, eax
jbe 0x100852fb
mov ecx, dword [ebp + eax*4 - 4]
mov edx, dword [ebp + eax*4]
and ecx, 0xff800000
add ecx, edx
add edx, dword [ebp + eax*4 - 4]
xor edx, ecx
and edx, 0x7fffff
xor edx, ecx
mov dword [ebp + eax*4], edx
inc eax
cmp eax, edi
jb 0x100852d0
mov ecx, dword [esp + 0x10]
add ebp, ebx
sub ecx, 1
mov dword [esp + 0x10], ecx
jne 0x100852c7
pop edi
pop esi
pop ebx
pop ebp
add esp, 0xc
ret
cmp eax, 6
jne 0x1008543f
mov ecx, dword [esp + 0x2c]
mov eax, ebp
mov dword [esp + 0x20], eax
mov dword [esp + 0x18], ecx
cmp edx, 2
jne 0x100853bd
test ecx, ecx
je 0x1008543f
mov ebp, dword [esp + 0x28]
mov dword [esp + 0x14], ecx
nop
mov edx, 2
mov dword [esp + 0x10], edx
cmp ebp, edx
jbe 0x1008539d
nop dword [eax]
mov ecx, dword [eax + edx*8]
mov edi, ecx
mov ebx, dword [eax + edx*8 - 4]
mov esi, dword [eax + edx*8 + 4]
add edi, dword [eax + edx*8 - 8]
mov edx, esi
adc edx, ebx
xor eax, eax
and ebx, 0xfff00000
add eax, ecx
mov ecx, dword [esp + 0x20]
adc ebx, esi
xor eax, eax
xor ebx, edx
xor eax, edi
and ebx, 0xfff00000
xor ebx, edx
mov edx, dword [esp + 0x10]
mov dword [ecx + edx*8], eax
mov eax, ecx
mov dword [eax + edx*8 + 4], ebx
inc edx
mov dword [esp + 0x10], edx
cmp edx, ebp
jb 0x10085350
mov ecx, dword [esp + 0x14]
lea edx, [ebp*8]
add eax, edx
sub ecx, 1
mov dword [esp + 0x20], eax
mov dword [esp + 0x14], ecx
jne 0x10085340
mov ebp, dword [esp + 0x24]
mov ecx, dword [esp + 0x2c]
jmp 0x100853c5
test edx, edx
jle 0x1008543f
test ecx, ecx
je 0x1008543f
mov eax, dword [esp + 0x28]
nop dword [eax]
mov edx, 1
mov dword [esp + 0x20], edx
cmp eax, edx
jbe 0x1008542d
nop dword [eax]
mov ecx, dword [ebp + edx*8]
mov edi, ecx
add edi, dword [ebp + edx*8 - 8]
mov ebx, dword [ebp + edx*8 - 4]
mov esi, dword [ebp + edx*8 + 4]
mov edx, esi
adc edx, ebx
xor eax, eax
and ebx, 0xfff00000
add eax, ecx
adc ebx, esi
xor eax, eax
xor ebx, edx
xor eax, edi
and ebx, 0xfff00000
xor ebx, edx
mov edx, dword [esp + 0x20]
mov dword [ebp + edx*8], eax
mov eax, dword [esp + 0x28]
mov dword [ebp + edx*8 + 4], ebx
inc edx
mov dword [esp + 0x20], edx
cmp edx, eax
jb 0x100853e0
mov ecx, dword [esp + 0x18]
lea edx, [eax*8]
add ebp, edx
sub ecx, 1
mov dword [esp + 0x18], ecx
jne 0x100853d0
pop edi
pop esi
pop ebx
pop ebp
add esp, 0xc
ret