Function at 0x1001d151
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
mov dword [ebp - 8], 0
mov dword [ebp - 4], 0
mov eax, dword [ebp + 8]
mov dword [eax + 0x6af78], 2
mov ecx, dword [ebp + 8]
cmp dword [ecx + 0x6af88], 0
je 0x1001d506
mov edx, dword [ebp + 8]
cmp dword [edx + 0x6af88], 3
jb 0x1001d20e
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af74]
shl ecx, 5
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af7c]
mov edx, dword [ebp + 8]
xor ebx, ebx
mov bl, byte [edx + eax + 0x1af6a]
xor ecx, ebx
and ecx, 0x7fff
mov eax, dword [ebp + 8]
mov dword [eax + 0x6af74], ecx
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x6af74]
mov eax, dword [ebp + 8]
mov ecx, dword [eax + edx*4 + 0x4af68]
mov dword [ebp - 8], ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af7c]
and eax, 0x7fff
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 8]
mov dword [ecx + eax*4 + 0x2af68], edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af74]
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x6af7c]
mov dword [edx + ecx*4 + 0x4af68], eax
cmp dword [ebp - 8], 0
je 0x1001d27b
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x6af7c]
sub edx, dword [ebp - 8]
cmp edx, 0x7efa
ja 0x1001d27b
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 8]
mov edx, dword [eax + 0x6af98]
cmp edx, dword [ecx + 0x6af88]
jbe 0x1001d24e
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x6af88]
mov dword [eax + 0x6af98], edx
mov eax, dword [ebp - 8]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.1001cb90
add esp, 8
mov dword [ebp - 4], eax
mov edx, dword [ebp + 8]
mov eax, dword [ebp - 4]
cmp eax, dword [edx + 0x6af88]
jbe 0x1001d27b
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x6af88]
mov dword [ebp - 4], edx
cmp dword [ebp - 4], 3
jb 0x1001d42d
mov eax, dword [ebp - 4]
sub eax, 3
push eax
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov eax, dword [ecx + 0x6af7c]
sub eax, dword [edx + 0x6af80]
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.1001bd56
add esp, 0xc
mov dword [ebp - 0xc], eax
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af88]
sub eax, dword [ebp - 4]
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x6af88], eax
mov edx, dword [ebp + 8]
mov eax, dword [ebp - 4]
cmp eax, dword [edx + 0x6af90]
ja 0x1001d3ac
mov ecx, dword [ebp + 8]
cmp dword [ecx + 0x6af88], 3
jb 0x1001d3ac
mov edx, dword [ebp - 4]
sub edx, 1
mov dword [ebp - 4], edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af7c]
add ecx, 1
mov edx, dword [ebp + 8]
mov dword [edx + 0x6af7c], ecx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af74]
shl ecx, 5
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af7c]
mov edx, dword [ebp + 8]
xor ebx, ebx
mov bl, byte [edx + eax + 0x1af6a]
xor ecx, ebx
and ecx, 0x7fff
mov eax, dword [ebp + 8]
mov dword [eax + 0x6af74], ecx
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x6af74]
mov eax, dword [ebp + 8]
mov ecx, dword [eax + edx*4 + 0x4af68]
mov dword [ebp - 8], ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af7c]
and eax, 0x7fff
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 8]
mov dword [ecx + eax*4 + 0x2af68], edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af74]
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x6af7c]
mov dword [edx + ecx*4 + 0x4af68], eax
mov ecx, dword [ebp - 4]
sub ecx, 1
mov dword [ebp - 4], ecx
cmp dword [ebp - 4], 0
jne 0x1001d2ee
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af7c]
add eax, 1
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x6af7c], eax
jmp 0x1001d42b
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af7c]
add eax, dword [ebp - 4]
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x6af7c], eax
mov dword [ebp - 4], 0
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af7c]
mov ecx, dword [ebp + 8]
xor edx, edx
mov dl, byte [ecx + eax + 0x1af68]
mov eax, dword [ebp + 8]
mov dword [eax + 0x6af74], edx
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x6af74]
shl edx, 5
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af7c]
mov eax, dword [ebp + 8]
xor ebx, ebx
mov bl, byte [eax + ecx + 0x1af69]
xor edx, ebx
and edx, 0x7fff
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x6af74], edx
push 0x58aaf4c
push 1
mov edx, dword [ebp + 8]
push edx
call fcn.1001a4e9
add esp, 0xc
jmp 0x1001d47e
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af7c]
mov edx, dword [ebp + 8]
xor eax, eax
mov al, byte [edx + ecx + 0x1af68]
push eax
push 0
mov ecx, dword [ebp + 8]
push ecx
call fcn.1001bd56
add esp, 0xc
mov dword [ebp - 0xc], eax
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af88]
sub eax, 1
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x6af88], eax
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x6af7c]
add eax, 1
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x6af7c], eax
cmp dword [ebp - 0xc], 0
je 0x1001d4e6
mov edx, dword [ebp + 8]
cmp dword [edx + 0x6af6c], 0
jl 0x1001d4a8
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af6c]
mov edx, dword [ebp + 8]
lea eax, [edx + ecx + 0x1af68]
mov dword [ebp - 0x10], eax
jmp 0x1001d4af
mov dword [ebp - 0x10], 0
push 0
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov eax, dword [ecx + 0x6af7c]
sub eax, dword [edx + 0x6af6c]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.1001b9bf
add esp, 0x10
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x6af7c]
mov dword [eax + 0x6af6c], edx
mov eax, dword [ebp + 8]
cmp dword [eax + 0x6af88], 0x106
jae 0x1001d501
mov ecx, dword [ebp + 8]
push ecx
call fcn.1001cf1e
add esp, 4
jmp 0x1001d173
mov edx, dword [ebp + 8]
cmp dword [edx + 0x6af6c], 0
jl 0x1001d52a
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x6af6c]
mov edx, dword [ebp + 8]
lea eax, [edx + ecx + 0x1af68]
mov dword [ebp - 0x14], eax
jmp 0x1001d531
mov dword [ebp - 0x14], 0
push 1
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 8]
mov eax, dword [ecx + 0x6af7c]
sub eax, dword [edx + 0x6af6c]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.1001b9bf
add esp, 0x10
pop ebx
mov esp, ebp
pop ebp
ret