Function at 0x837af33b
Capabilities:
Encode data using xor

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x87100004]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, dword [ebp + 8]
movsx ebx, word [esi + 0xe]
mov eax, dword [esi + 0x10]
xor edx, edx
lea eax, [eax + ebx - 1]
div ebx
mov ecx, dword [esi]
push edi
mov edi, dword [ebp + 0x10]
mov dword [ebp - 0x2c], edi
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x24], eax
test eax, eax
je 0x837af73d
mov edx, dword [esi + 0x14]
test edx, edx
je 0x837af3f9
cmp eax, edx
jb 0x837af3f9
mov ecx, dword [edi]
mov edi, dword [ecx]
xor eax, eax
push eax
push edx
xor ebx, ebx
push ebx
push edi
call fcn.83781380
push ebx
push dword [ebp - 0x24]
push edx
push eax
call fcn.83781310
mov ebx, edi
sub edi, dword [ebp - 0x1c]
sub ebx, eax
xor eax, eax
push eax
push dword [esi + 0x14]
mov dword [ebp - 0x20], ebx
push eax
push edi
call fcn.83781380
xor ecx, ecx
push ecx
push dword [ebp - 0x24]
push edx
push eax
call fcn.83781310
sub edi, eax
mov eax, dword [0x87100730]
cmp edi, eax
jbe 0x837af3d0
mov edi, eax
mov eax, dword [esi + 0x2c]
test eax, eax
je 0x837af3f4
sub edi, eax
jns 0x837af3e4
neg edi
sar edi, 2
neg edi
jmp 0x837af3e7
sar edi, 2
add eax, edi
mov dword [esi + 0x2c], eax
mov ecx, dword [ebp - 0x1c]
mov edi, dword [ebp - 0x2c]
jmp 0x837af403
mov dword [esi + 0x2c], edi
jmp 0x837af3ec
and dword [ebp - 0x20], 0
mov ebx, dword [ebp - 0x20]
mov dword [esi + 0x14], eax
cmp ebx, dword [esi + 0x34]
ja 0x837af454
cmp ebx, dword [0x8710071c]
ja 0x837af43f
mov eax, dword [edi]
mov eax, dword [eax]
mov ebx, dword [ebp + 0xc]
xor edx, edx
div dword [ebx + 8]
push eax
call fcn.837ae54c
xor ecx, ecx
inc ecx
cmp eax, ecx
jb 0x837af42b
mov ecx, eax
mov dword [esi + 4], ecx
mov eax, dword [ebx + 8]
imul eax, ecx
shr eax, 3
mov dword [esi + 4], eax
cmp eax, dword [ebx + 8]
ja 0x837af445
and dword [esi + 4], 0
jmp 0x837af44b
sub eax, dword [ebx + 8]
mov dword [esi + 4], eax
mov eax, dword [edi]
mov eax, dword [eax]
add eax, dword [esi + 4]
jmp 0x837af475
and dword [esi + 4], 0
cmp ecx, ebx
jbe 0x837af466
sub ecx, ebx
mov dword [esi], ecx
mov eax, dword [edi]
sub dword [eax], ebx
jmp 0x837af471
mov eax, dword [edi]
cmp dword [eax], ecx
jbe 0x837af46e
sub dword [eax], ecx
and dword [esi], 0
mov eax, dword [edi]
mov eax, dword [eax]
mov dx, word [esi + 0x18]
movzx edi, word [esi + 8]
movzx ecx, word [esi + 0xa]
and dx, 0xf
mov dword [ebp - 0x28], eax
mov eax, dword [esi + 0x24]
mov dword [ebp - 0x30], edi
cmp dx, 1
jbe 0x837af59e
cmp di, cx
jae 0x837af505
mov ebx, 0xffe0
cmp di, 0x20
jb 0x837af4b5
movzx edx, di
shr edx, 5
mov eax, dword [eax]
add ecx, ebx
dec edx
jne 0x837af4ae
cmp cx, 0x20
jb 0x837af59e
mov eax, dword [eax]
add ecx, ebx
cmp cx, 0x20
jb 0x837af59e
movzx ebx, cx
shr ebx, 5
mov edi, dword [eax]
mov ecx, dword [eax + 4]
mov dword [ecx], edi
push eax
mov dword [edi + 4], ecx
call fcn.83773c13
movzx ecx, word [esi + 0x18]
add word [esi + 0xa], 0xffe0
lea edx, [ecx - 1]
xor edx, ecx
and edx, 0xf
xor edx, ecx
dec ebx
mov eax, edi
mov word [esi + 0x18], dx
je 0x837af59e
jmp 0x837af4d3
cmp dx, 1
jbe 0x837af59e
cmp cx, 0x20
jb 0x837af55c
movzx ecx, cx
shr ecx, 5
mov dword [ebp - 0x18], ecx
mov ebx, 0xffe0
mov edi, dword [eax]
mov ecx, dword [eax + 4]
mov dword [ecx], edi
push eax
mov dword [edi + 4], ecx
call fcn.83773c13
movzx ecx, word [esi + 0x18]
add dword [ebp - 0x30], ebx
add word [esi + 0xa], 0xffe0
add word [esi + 8], 0xffe0
lea edx, [ecx - 1]
xor edx, ecx
and edx, 0xf
xor edx, ecx
dec dword [ebp - 0x18]
mov eax, edi
mov word [esi + 0x18], dx
jne 0x837af523
mov edi, dword [ebp - 0x30]
cmp di, 0x20
jb 0x837af56d
movzx ecx, di
shr ecx, 5
dec ecx
mov eax, dword [eax]
jne 0x837af568
mov edi, dword [eax]
jmp 0x837af597
mov edx, edi
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov edi, dword [edi]
mov dword [ecx], eax
push edx
mov dword [eax + 4], ecx
call fcn.83773c13
movzx eax, word [esi + 0x18]
lea ecx, [eax - 1]
xor ecx, eax
and ecx, 0xf
xor ecx, eax
mov word [esi + 0x18], cx
lea eax, [esi + 0x24]
cmp edi, eax
jne 0x837af571
mov ecx, dword [0x8710b048]
mov eax, dword [esi + 0x14]
mov dword [ebp - 0x18], eax
test ecx, ecx
je 0x837af5b2
xor edx, edx
div ecx
push eax
push dword [ebp - 0x28]
call fcn.837ae43d
movzx eax, ax
shl eax, 4
xor ax, word [esi + 0x18]
mov ecx, 0xf0
and ax, cx
xor word [esi + 0x18], ax
movzx eax, word [esi + 0x18]
mov edx, eax
shr edx, 4
mov ecx, eax
and ecx, 0xf
and edx, 0xf
cmp dx, cx
jae 0x837af5f5
shl ecx, 4
and eax, 0xff0f
or ecx, eax
mov word [esi + 0x18], cx
movzx ecx, word [esi + 0x18]
mov eax, dword [ebp - 0x28]
shr ecx, 4
and ecx, 0xf
shl ecx, 5
xor edx, edx
div ecx
and dword [esi + 0x20], 0
mov dword [esi + 0x1c], eax
mov eax, dword [0x87107e34]
test eax, eax
je 0x837af73d
cmp eax, 1
jne 0x837af73d
mov dl, byte [0x87107e38]
mov ebx, 0x80000001
cmp dl, 5
jae 0x837af63e
test dl, dl
jne 0x837af6c6
mov eax, dword [0x87107e20]
mov ecx, dword [0x87107e24]
and eax, 0x40
and ecx, ebx
or eax, ecx
je 0x837af6c6
mov eax, dword [0x87107e28]
mov ecx, dword [0x87107e2c]
and eax, 0x40
and ecx, ebx
cmp eax, dword [0x87107e28]
jne 0x837af6c6
cmp ecx, dword [0x87107e2c]
jne 0x837af6c6
push dword [esi + 4]
mov ecx, dword [ebp - 0x2c]
push dword [ebp - 0x20]
mov ecx, dword [ecx]
xor eax, eax
lea edi, [ebp - 0x14]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [esi - 0x8c]
mov dword [ebp - 0x14], eax
push dword [ecx]
push dword [ebp - 0x24]
push dword [ebp - 0x18]
push dword [ebp - 0x1c]
push dword [esi]
push eax
lea eax, [ebp - 0x14]
push eax
push 0x870f5170
push dword [0x87107e0c]
push dword [0x87107e08]
call fcn.837ad5db
cmp dword [0x87107e34], 1
jne 0x837af73d
mov dl, byte [0x87107e38]
cmp dl, 5
jae 0x837af6cf
test dl, dl
jne 0x837af73d
mov eax, dword [0x87107e20]
mov ecx, dword [0x87107e24]
and eax, 0x40
and ecx, ebx
or eax, ecx
je 0x837af73d
mov edx, dword [0x87107e28]
mov edi, dword [0x87107e2c]
mov eax, edx
mov ecx, edi
and eax, 0x40
and ecx, ebx
cmp eax, edx
jne 0x837af73d
cmp ecx, edi
jne 0x837af73d
xor eax, eax
lea edi, [ebp - 0x14]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
lea eax, [esi - 0x8c]
mov dword [ebp - 0x14], eax
movzx eax, word [esi + 0x18]
mov ecx, eax
shr ecx, 4
and ecx, 0xf
push ecx
and eax, 0xf
push eax
lea eax, [ebp - 0x14]
push eax
push 0x870f5160
push dword [0x87107e0c]
push dword [0x87107e08]
call fcn.837a657f
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.83781dcc
leave
ret 0xc