Function at 0xd2beb0
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
mov eax, 0x15a8
call fcn.00d2c9f0
mov ebx, edx
mov edi, ecx
mov esi, dword [esp + 0x15bc]
lea eax, [esp + 0x24]
push 0x84
push 0
push eax
call fcn.00d2cb10
add esp, 0xc
cmp dword [esp + 0x15c4], 0
je 0xd2bf68
test esi, esi
mov ecx, esi
jle 0xd2c7be
xor eax, eax
cmp ecx, 1
je 0xd2bf38
mov ecx, dword [esp + 0x15bc]
and ecx, 0x7ffffffe
lea eax, [ebx + ebx*8]
shl eax, 5
lea edx, [eax + edi]
add edx, 0x8f13
xor eax, eax
nop
nop
nop
nop
nop
nop
movzx esi, byte [edx + eax - 1]
inc dword [esp + esi*4 + 0x24]
movzx esi, byte [edx + eax]
inc dword [esp + esi*4 + 0x24]
add eax, 2
cmp ecx, eax
jne 0xd2bf20
mov ecx, dword [esp + 0x15bc]
test cl, 1
je 0xd2c7be
lea ecx, [ebx + ebx*8]
shl ecx, 5
add ecx, edi
movzx eax, byte [eax + ecx + 0x8f12]
mov ecx, dword [esp + 0x15bc]
inc dword [esp + eax*4 + 0x24]
jmp 0xd2c7be
lea eax, [ebx + ebx*8]
mov dword [esp + 0x1c], eax
shl eax, 6
test esi, esi
mov dword [esp + 0x10], edi
mov dword [esp + 0x20], ebx
mov dword [esp + 0x18], eax
jle 0xd2c06d
cmp esi, 1
jne 0xd2c34b
xor eax, eax
xor ebx, ebx
mov ecx, dword [esp + 0x15bc]
test cl, 1
je 0xd2bfc5
mov ecx, dword [esp + 0x18]
add ecx, edi
add ecx, 0x8192
movzx ecx, word [ecx + eax*2]
test cx, cx
je 0xd2bfc5
mov word [esp + ebx*4 + 0xa8], cx
mov word [esp + ebx*4 + 0xaa], ax
inc ebx
lea eax, [esp + 0x928]
push 0x800
push 0
push eax
call fcn.00d2cb10
add esp, 0xc
test ebx, ebx
sete byte [esp]
je 0xd2c084
xor eax, eax
cmp ebx, 1
je 0xd2c03f
mov edx, ebx
and edx, 0xfffffffe
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx ecx, word [esp + eax*4 + 0xa8]
movzx esi, cl
inc dword [esp + esi*4 + 0x928]
shr ecx, 8
inc dword [esp + ecx*4 + 0xd28]
movzx ecx, word [esp + eax*4 + 0xac]
movzx esi, cl
inc dword [esp + esi*4 + 0x928]
shr ecx, 8
inc dword [esp + ecx*4 + 0xd28]
add eax, 2
cmp edx, eax
jne 0xd2c000
test bl, 1
je 0xd2c060
movzx eax, word [esp + eax*4 + 0xa8]
movzx ecx, al
inc dword [esp + ecx*4 + 0x928]
shr eax, 8
inc dword [esp + eax*4 + 0xd28]
mov eax, dword [esp + 0xd28]
mov dword [esp + 4], eax
jmp 0xd2c092
lea eax, [esp + 0x928]
push 0x800
push 0
push eax
call fcn.00d2cb10
add esp, 0xc
xor ebx, ebx
mov byte [esp], 1
mov dword [esp + 4], 0
lea eax, [ebx - 1]
mov dword [esp + 8], eax
xor ecx, ecx
mov edx, 1
mov dword [esp + edx*4 + 0x524], ecx
mov esi, dword [esp + edx*4 + 0x924]
mov edi, dword [esp + edx*4 + 0x928]
mov ebp, esi
and ebp, ecx
xor esi, ecx
lea ecx, [esi + ebp*2]
mov dword [esp + edx*4 + 0x528], ecx
mov esi, edi
and esi, ecx
xor edi, ecx
lea ecx, [edi + esi*2]
add edx, 2
cmp edx, 0x101
jne 0xd2c0a0
cmp byte [esp], 0
jne 0xd2c181
cmp dword [esp + 8], 0
je 0xd2c3b5
mov ecx, ebx
and ecx, 0xfffffffe
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx esi, byte [esp + edx*4 + 0xa8]
mov edi, dword [esp + esi*4 + 0x528]
lea ebp, [edi + 1]
mov dword [esp + esi*4 + 0x528], ebp
mov esi, dword [esp + edx*4 + 0xa8]
mov ebp, dword [esp + edx*4 + 0xac]
mov dword [esp + edi*4 + 0x1128], esi
movzx esi, byte [esp + edx*4 + 0xac]
mov edi, dword [esp + esi*4 + 0x528]
lea eax, [edi + 1]
mov dword [esp + esi*4 + 0x528], eax
mov dword [esp + edi*4 + 0x1128], ebp
add edx, 2
cmp ecx, edx
jne 0xd2c100
test bl, 1
je 0xd2c181
movzx eax, byte [esp + edx*4 + 0xa8]
mov ecx, dword [esp + eax*4 + 0x528]
lea esi, [ecx + 1]
mov dword [esp + eax*4 + 0x528], esi
mov eax, dword [esp + edx*4 + 0xa8]
mov dword [esp + ecx*4 + 0x1128], eax
cmp dword [esp + 4], ebx
jne 0xd2c19b
lea edi, [esp + 0x1128]
test ebx, ebx
jne 0xd2c299
jmp 0xd2c695
xor ecx, ecx
xor eax, eax
nop
mov dword [esp + eax*4 + 0x528], ecx
mov edx, dword [esp + eax*4 + 0xd28]
mov esi, dword [esp + eax*4 + 0xd2c]
mov edi, edx
and edi, ecx
xor edx, ecx
lea ecx, [edx + edi*2]
mov dword [esp + eax*4 + 0x52c], ecx
mov edx, esi
and edx, ecx
xor esi, ecx
lea ecx, [esi + edx*2]
add eax, 2
cmp eax, 0x100
jne 0xd2c1a0
cmp byte [esp], 0
jne 0xd2c28a
cmp dword [esp + 8], 0
je 0xd2c90d
mov ecx, ebx
and ecx, 0xfffffffe
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx edx, word [esp + eax*4 + 0x1128]
movzx edx, dh
mov esi, dword [esp + edx*4 + 0x528]
lea edi, [esi + 1]
mov dword [esp + edx*4 + 0x528], edi
mov edx, dword [esp + eax*4 + 0x1128]
mov edi, dword [esp + eax*4 + 0x112c]
mov dword [esp + esi*4 + 0xa8], edx
movzx edx, word [esp + eax*4 + 0x112c]
movzx edx, dh
mov esi, dword [esp + edx*4 + 0x528]
lea ebp, [esi + 1]
mov dword [esp + edx*4 + 0x528], ebp
mov dword [esp + esi*4 + 0xa8], edi
add eax, 2
cmp ecx, eax
jne 0xd2c200
test bl, 1
je 0xd2c28a
movzx ecx, word [esp + eax*4 + 0x1128]
movzx ecx, ch
mov edx, dword [esp + ecx*4 + 0x528]
lea esi, [edx + 1]
mov dword [esp + ecx*4 + 0x528], esi
mov eax, dword [esp + eax*4 + 0x1128]
mov dword [esp + edx*4 + 0xa8], eax
lea edi, [esp + 0xa8]
test ebx, ebx
je 0xd2c695
cmp ebx, 1
jne 0xd2c2a8
mov word [edi], 1
jmp 0xd2c578
movzx eax, word [edi + 4]
add word [edi], ax
cmp dword [esp + 8], 2
jl 0xd2c3c5
mov eax, 2
mov ecx, 2
sub ecx, ebx
mov dword [esp + 4], ecx
xor edx, edx
mov esi, 1
jmp 0xd2c2fe
movzx ecx, word [edi + edx*4]
add word [edi + esi*4], cx
mov word [edi + edx*4], si
inc edx
mov ecx, dword [esp + 4]
add ecx, esi
inc ecx
inc esi
cmp ecx, 1
je 0xd2c3d4
movzx ecx, word [edi + edx*4]
cmp eax, ebx
jge 0xd2c30f
movzx ebp, word [edi + eax*4]
cmp cx, bp
jae 0xd2c320
mov word [edi + esi*4], cx
mov word [edi + edx*4], si
inc edx
cmp eax, ebx
jge 0xd2c2e0
jmp 0xd2c329
mov word [edi + esi*4], bp
inc eax
cmp eax, ebx
jge 0xd2c2e0
cmp edx, esi
jge 0xd2c340
movzx ecx, word [edi + edx*4]
movzx ebp, word [edi + eax*4]
cmp cx, bp
jb 0xd2c2e4
jmp 0xd2c344
movzx ebp, word [edi + eax*4]
inc eax
add word [edi + esi*4], bp
jmp 0xd2c2ed
mov ecx, esi
and ecx, 0x7ffffffe
lea edx, [eax + edi]
add edx, 0x8194
xor eax, eax
xor ebx, ebx
jmp 0xd2c37b
add eax, 2
cmp ecx, eax
je 0xd2bf93
movzx esi, word [edx + eax*2 - 2]
test si, si
je 0xd2c396
mov word [esp + ebx*4 + 0xa8], si
mov word [esp + ebx*4 + 0xaa], ax
inc ebx
movzx esi, word [edx + eax*2]
test si, si
je 0xd2c370
mov word [esp + ebx*4 + 0xa8], si
lea esi, [eax + 1]
mov word [esp + ebx*4 + 0xaa], si
inc ebx
jmp 0xd2c370
xor edx, edx
test bl, 1
jne 0xd2c15a
jmp 0xd2c181
lea ecx, [ebx - 2]
mov word [edi + ebx*4 - 8], 0
jmp 0xd2c461
lea ecx, [ebx - 2]
mov word [edi + ebx*4 - 8], 0
cmp ebx, 3
jl 0xd2c461
lea edx, [ebx - 3]
mov esi, ebx
and esi, 3
xor esi, 2
mov eax, edx
je 0xd2c411
mov eax, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx ebp, word [edi + eax*4]
movzx ebp, word [edi + ebp*4]
inc ebp
mov word [edi + eax*4], bp
dec eax
dec esi
jne 0xd2c400
cmp edx, 3
jb 0xd2c461
inc eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx edx, word [edi + eax*4 - 4]
movzx edx, word [edi + edx*4]
inc edx
mov word [edi + eax*4 - 4], dx
movzx edx, word [edi + eax*4 - 8]
movzx edx, word [edi + edx*4]
inc edx
mov word [edi + eax*4 - 8], dx
movzx edx, word [edi + eax*4 - 0xc]
movzx edx, word [edi + edx*4]
inc edx
mov word [edi + eax*4 - 0xc], dx
movzx edx, word [edi + eax*4 - 0x10]
movzx edx, word [edi + edx*4]
inc edx
mov word [edi + eax*4 - 0x10], dx
add eax, 0xfffffffc
jne 0xd2c420
mov esi, edi
mov edi, 1
xor edx, edx
mov eax, dword [esp + 8]
mov dword [esp], esi
jmp 0xd2c490
lea edi, [ebp*2]
inc edx
test ebp, ebp
jle 0xd2c56d
test ecx, ecx
mov dword [esp + 0xc], edi
js 0xd2c4c0
lea ebp, [ecx + 1]
xor esi, esi
nop
nop
nop
mov edi, ebp
mov ebp, dword [esp]
movzx ebp, word [ebp + ecx*4]
cmp edx, ebp
jne 0xd2c4d0
inc esi
dec ecx
mov ebp, edi
cmp edi, esi
jne 0xd2c4a0
mov ecx, 0xffffffff
jmp 0xd2c4d2
xor ebp, ebp
jmp 0xd2c4d6
mov ebp, esi
mov edi, dword [esp + 0xc]
mov esi, edi
sub esi, ebp
jle 0xd2c480
and esi, 3
mov dword [esp + 0x14], ebp
je 0xd2c51c
mov edi, esi
lea esi, [eax + eax]
xor ebp, ebp
mov dword [esp + 4], edi
mov edi, dword [esp]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov word [edi + esi*2], dx
inc ebp
add esi, 0xfffffffe
cmp dword [esp + 4], ebp
jne 0xd2c500
mov esi, dword [esp + 0xc]
sub esi, ebp
sub eax, ebp
mov ebp, dword [esp + 0x14]
jmp 0xd2c51e
mov esi, edi
mov edi, ebp
sub ebp, dword [esp + 0xc]
cmp ebp, 0xfffffffc
mov ebp, edi
ja 0xd2c480
mov edi, dword [esp]
lea ebp, [eax*2 - 2]
neg eax
nop
nop
nop
nop
nop
mov word [edi + ebp*2 + 4], dx
mov word [edi + ebp*2], dx
mov word [edi + ebp*2 - 4], dx
mov word [edi + ebp*2 - 8], dx
add esi, 0xfffffffc
add eax, 4
add ebp, 0xfffffff8
cmp esi, dword [esp + 0x14]
jg 0xd2c540
neg eax
mov ebp, dword [esp + 0x14]
jmp 0xd2c480
test ebx, ebx
mov edi, dword [esp]
jle 0xd2c695
mov eax, ebx
and eax, 3
xor ecx, ecx
cmp dword [esp + 8], 3
jb 0xd2c5ba
mov edx, ebx
and edx, 0xfffffffc
xor ecx, ecx
nop
nop
nop
movzx esi, word [edi + ecx*4]
inc dword [esp + esi*4 + 0x24]
movzx esi, word [edi + ecx*4 + 4]
inc dword [esp + esi*4 + 0x24]
movzx esi, word [edi + ecx*4 + 8]
inc dword [esp + esi*4 + 0x24]
movzx esi, word [edi + ecx*4 + 0xc]
inc dword [esp + esi*4 + 0x24]
add ecx, 4
cmp edx, ecx
jne 0xd2c590
test eax, eax
je 0xd2c5dd
lea ecx, [edi + ecx*4]
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx esi, word [ecx + edx*4]
inc dword [esp + esi*4 + 0x24]
inc edx
cmp eax, edx
jne 0xd2c5d0
cmp ebx, 2
jl 0xd2c695
mov edx, dword [esp + 0x15c0]
cmp edx, 0x20
jge 0xd2c660
mov eax, dword [esp + edx*4 + 0x24]
mov esi, edx
neg edx
mov ecx, esi
and edx, 3
je 0xd2c61c
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
add eax, dword [esp + ecx*4 + 0x28]
inc ecx
mov dword [esp + esi*4 + 0x24], eax
dec edx
jne 0xd2c610
lea edx, [esi - 0x1d]
cmp edx, 3
mov edx, esi
jb 0xd2c658
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
add eax, dword [esp + ecx*4 + 0x28]
mov dword [esp + edx*4 + 0x24], eax
add eax, dword [esp + ecx*4 + 0x2c]
mov dword [esp + edx*4 + 0x24], eax
add eax, dword [esp + ecx*4 + 0x30]
mov dword [esp + edx*4 + 0x24], eax
add eax, dword [esp + ecx*4 + 0x34]
add ecx, 4
mov dword [esp + edx*4 + 0x24], eax
cmp ecx, 0x20
jne 0xd2c630
test edx, edx
jle 0xd2c91d
inc edx
xor ecx, ecx
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, dword [esp + edx*4 + 0x20]
shl esi, cl
add eax, esi
dec edx
inc ecx
cmp edx, 1
ja 0xd2c670
mov edx, 1
mov ecx, dword [esp + 0x15c0]
shl edx, cl
cmp eax, edx
jne 0xd2c928
mov ebp, edi
mov edi, dword [esp + 0x1c]
shl edi, 5
mov esi, dword [esp + 0x10]
lea eax, [esi + edi]
add eax, 0x8f12
push 0x120
push 0
push eax
call fcn.00d2cb10
add esp, 0xc
mov eax, dword [esp + 0x18]
add eax, esi
add eax, 0x8852
mov esi, edi
mov edi, ebp
push 0x240
push 0
push eax
call fcn.00d2cb10
add esp, 0xc
cmp dword [esp + 0x15c0], 0
jle 0xd2c7af
add edi, 0xfffffffe
mov eax, 1
add esi, dword [esp + 0x10]
mov dword [esp], edi
jmp 0xd2c712
lea ecx, [eax + 1]
cmp eax, dword [esp + 0x15c0]
mov eax, ecx
je 0xd2c7af
mov ecx, dword [esp + eax*4 + 0x24]
test ecx, ecx
jle 0xd2c700
mov edx, ecx
and edx, 3
je 0xd2c760
mov dword [esp + 4], ecx
lea ebp, [edi + ebx*4]
mov edi, esi
xor esi, esi
nop
nop
nop
nop
movzx ecx, word [ebp]
mov byte [ecx + edi + 0x8f12], al
inc esi
add ebp, 0xfffffffc
cmp edx, esi
jne 0xd2c730
sub ebx, esi
mov ecx, dword [esp + 4]
mov edx, ecx
sub edx, esi
mov esi, edi
mov edi, dword [esp]
cmp ecx, 4
jb 0xd2c700
jmp 0xd2c767
mov edx, ecx
cmp ecx, 4
jb 0xd2c700
dec edx
nop
nop
nop
nop
nop
nop
nop
nop
movzx ecx, word [edi + ebx*4]
mov byte [ecx + esi + 0x8f12], al
movzx ecx, word [edi + ebx*4 - 4]
mov byte [ecx + esi + 0x8f12], al
movzx ecx, word [edi + ebx*4 - 8]
mov byte [ecx + esi + 0x8f12], al
movzx ecx, word [edi + ebx*4 - 0xc]
add ebx, 0xfffffffc
mov byte [ecx + esi + 0x8f12], al
add edx, 0xfffffffc
cmp edx, 0xfffffffe
jb 0xd2c770
jmp 0xd2c700
mov ecx, dword [esp + 0x15bc]
mov edi, dword [esp + 0x10]
mov ebx, dword [esp + 0x20]
mov dword [esp + 0x92c], 0
mov eax, dword [esp + 0x15c0]
cmp eax, 2
jl 0xd2c83f
lea ecx, [eax - 1]
cmp eax, 2
jne 0xd2c7e6
xor eax, eax
mov edx, 2
jmp 0xd2c826
mov esi, ebx
mov ebx, ecx
and ebx, 0xfffffffe
xor eax, eax
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
add eax, dword [esp + edx*4 + 0x28]
add eax, eax
mov dword [esp + edx*4 + 0x930], eax
add eax, dword [esp + edx*4 + 0x2c]
add eax, eax
mov dword [esp + edx*4 + 0x934], eax
add edx, 2
cmp ebx, edx
jne 0xd2c800
add edx, 2
mov ebx, esi
test cl, 1
mov ecx, dword [esp + 0x15bc]
je 0xd2c83f
add eax, dword [esp + edx*4 + 0x20]
add eax, eax
mov dword [esp + edx*4 + 0x928], eax
test ecx, ecx
jle 0xd2c902
xor eax, eax
lea esi, [ebx + ebx*8]
mov edx, esi
shl edx, 5
add edx, edi
shl esi, 6
add esi, edi
mov dword [esp], esi
jmp 0xd2c87b
mov ecx, dword [esp]
mov word [ecx + eax*2 + 0x8852], di
mov ecx, dword [esp + 0x15bc]
inc eax
cmp eax, ecx
je 0xd2c902
movzx ebx, byte [eax + edx + 0x8f12]
test ebx, ebx
je 0xd2c872
mov ecx, dword [esp + ebx*4 + 0x928]
lea edi, [ecx + 1]
mov dword [esp + ebx*4 + 0x928], edi
xor edi, edi
cmp bl, 4
jb 0xd2c8df
mov ebp, ebx
and ebp, 0xfffffffc
xor edi, edi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, ecx
and esi, 1
shl esi, 2
lea esi, [esi + edi*8]
mov edi, ecx
and edi, 2
or edi, esi
mov esi, ecx
shr esi, 2
and esi, 1
or esi, edi
mov edi, ecx
shr edi, 3
and edi, 1
lea edi, [edi + esi*2]
shr ecx, 4
add ebp, 0xfffffffc
jne 0xd2c8b0
and ebx, 3
je 0xd2c860
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, ecx
and esi, 1
lea edi, [esi + edi*2]
shr ecx, 1
dec ebx
jne 0xd2c8f0
jmp 0xd2c860
add esp, 0x15a8
pop esi
pop edi
pop ebx
pop ebp
ret
xor eax, eax
test bl, 1
jne 0xd2c260
jmp 0xd2c28a
mov ecx, edx
mov edx, 1
shl edx, cl
xor eax, eax
mov ecx, dword [esp + 0x15c0]
mov esi, ecx
xor esi, 1
and ecx, 0xfffffffe
add ecx, ecx
sub ecx, esi
lea esi, [ecx + 1]
mov dword [esp + 4], esi
jmp 0xd2c963
dec esi
mov dword [esp + ebp*4 + 0x20], esi
add dword [esp + ebp*4 + 0x24], 2
dec eax
cmp eax, edx
je 0xd2c695
mov esi, dword [esp + 0x15c0]
dec dword [esp + esi*4 + 0x24]
test ecx, ecx
jle 0xd2c95a
mov ebp, dword [esp + 4]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, dword [esp + ebp*4 + 0x20]
test esi, esi
jne 0xd2c950
dec ebp
cmp ebp, 1
jg 0xd2c980
jmp 0xd2c95a