Function at 0x1001fa20
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
push esi
push edi
push 0x38
mov esi, ecx
mov dword [ebp - 0x14], edx
xor ebx, ebx
mov dword [ebp - 0x10], esi
push ebx
push esi
call fcn.100065a0
mov edx, dword [ebp - 0x14]
add esp, 0xc
xor ecx, ecx
mov eax, dword [edx + 4]
mov dword [ebp - 0x20], eax
test eax, eax
jle 0x1001ff6c
lea edi, [edx + 8]
mov esi, eax
mov dword [ebp - 0x1c], edi
mov edi, dword [edi]
nop dword [eax]
cmp byte [edi + ecx], 0
lea eax, [ebx + 1]
cmovle eax, ebx
inc ecx
mov ebx, eax
cmp ecx, esi
jl 0x1001fa60
mov esi, dword [ebp - 0x10]
lea edi, [edx + 8]
mov eax, dword [ebp - 0x20]
mov dword [esi + 8], ebx
mov dword [esi + 4], eax
lea eax, [esi + 8]
mov dword [ebp - 0xc], eax
mov eax, dword [edx]
mov dword [esi], eax
test ebx, ebx
jle 0x1001ff73
mov edx, dword [edx + 4]
mov ecx, dword [edi]
push ebx
call fcn.1001f670
mov edi, eax
add esp, 4
lea eax, [ebx*4]
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x28], eax
call fcn.10005330
mov eax, esp
mov dword [ebp - 0x24], eax
test edi, edi
jne 0x1001fb27
mov eax, dword [esi + 0x10]
test eax, eax
je 0x1001facd
push eax
call fcn.1000dff9
add esp, 4
mov eax, dword [esi + 0x14]
test eax, eax
je 0x1001fadd
push eax
call fcn.1000dff9
add esp, 4
mov eax, dword [esi + 0x18]
test eax, eax
je 0x1001faed
push eax
call fcn.1000dff9
add esp, 4
mov eax, dword [esi + 0x1c]
test eax, eax
je 0x1001fafd
push eax
call fcn.1000dff9
add esp, 4
mov eax, dword [esi + 0x20]
test eax, eax
je 0x1001fb0d
push eax
call fcn.1000dff9
add esp, 4
push 0x38
push 0
push esi
call fcn.100065a0
add esp, 0xc
or eax, 0xffffffff
lea esp, [ebp - 0x38]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
sub eax, edi
mov dword [ebp - 8], ebx
mov esi, edi
mov dword [ebp - 0x20], eax
mov ecx, dword [esi]
bswap ecx
mov edi, ecx
mov eax, ecx
shl eax, 4
shr edi, 4
xor edi, eax
shl ecx, 4
and edi, 0xf0f0f0f
xor edi, ecx
mov edx, edi
shr edx, 2
lea eax, [edi*4]
xor edx, eax
lea eax, [edi*4]
and edx, 0x33333333
xor edx, eax
mov ecx, edx
shr ecx, 1
lea eax, [edx + edx]
xor ecx, eax
lea eax, [edx + edx]
and ecx, 0x55555555
xor ecx, eax
mov eax, dword [ebp - 0x20]
mov dword [esi], ecx
mov dword [eax + esi], esi
add esi, 4
sub ebx, 1
jne 0x1001fb31
push 0x1001f1b0
push 4
push dword [ebp - 8]
push dword [ebp - 0x24]
call fcn.1001a150
mov ebx, dword [ebp - 0x28]
add esp, 0x10
mov eax, ebx
call fcn.10005330
mov edi, esp
push ebx
mov dword [ebp - 0x20], edi
call fcn.1000e58b
mov esi, dword [ebp - 0x10]
add esp, 4
mov edx, dword [ebp - 8]
xor ecx, ecx
mov dword [esi + 0x14], eax
test edx, edx
jle 0x1001fbf4
mov ebx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0xc]
mov esi, dword [ebp - 0x24]
mov dword [ebp - 8], edx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0xc], eax
nop dword [eax + eax]
mov eax, dword [esi + ecx*4]
sub eax, dword [ebp - 0x18]
sar eax, 2
mov dword [edi + eax*4], ecx
inc ecx
cmp ecx, edx
jl 0x1001fbe0
mov esi, dword [ebp - 0x10]
mov eax, dword [ebp - 0x18]
mov ebx, edx
sub eax, edi
mov dword [ebp - 0x24], edi
mov dword [ebp - 0x2c], eax
mov edx, dword [edi]
lea edi, [edi + 4]
mov ecx, dword [esi + 0x14]
mov eax, dword [eax + edi - 4]
mov dword [ecx + edx*4], eax
mov eax, dword [ebp - 0x2c]
sub ebx, 1
jne 0x1001fc01
push dword [ebp - 0x18]
call fcn.1000dff9
mov edi, dword [ebp - 0x20]
add esp, 4
mov edx, dword [ebp - 8]
push edi
mov edi, dword [ebp - 0x14]
mov ecx, edi
call fcn.1001f230
add esp, 4
mov dword [esi + 0x10], eax
push dword [ebp - 0x28]
call fcn.1000e58b
mov ebx, dword [ebp - 0x1c]
xor ecx, ecx
add esp, 4
mov dword [esi + 0x18], eax
xor edx, edx
mov dword [ebp - 0x28], ecx
cmp dword [edi + 4], ecx
jle 0x1001fc7a
mov eax, dword [ebx]
cmp byte [edx + eax], 0
jle 0x1001fc72
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax + ecx*4]
mov eax, dword [esi + 0x18]
mov dword [eax + ecx*4], edx
mov ecx, dword [ebp - 0x28]
inc ecx
mov dword [ebp - 0x28], ecx
inc edx
cmp edx, dword [edi + 4]
jl 0x1001fc57
jmp 0x1001fc80
mov eax, dword [ebp - 0xc]
mov dword [ebp - 0xc], eax
push ecx
call fcn.1000e58b
mov dword [esi + 0x1c], eax
xor edx, edx
mov eax, dword [ebp - 0x14]
add esp, 4
mov dword [esi + 0x28], 0
xor edi, edi
mov dword [ebp - 8], edx
cmp dword [eax + 4], edx
jle 0x1001fd13
mov eax, dword [ebx]
mov al, byte [edi + eax]
mov byte [ebp - 1], al
test al, al
jle 0x1001fcd2
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax + edx*4]
mov eax, dword [esi + 0x1c]
mov dl, byte [ebp - 1]
mov byte [ecx + eax], dl
mov eax, dword [ebx]
mov edx, dword [ebp - 8]
inc edx
mov dword [ebp - 8], edx
movsx eax, byte [eax + edi]
cmp eax, dword [esi + 0x28]
jle 0x1001fcd2
mov dword [esi + 0x28], eax
mov eax, dword [ebp - 0x14]
inc edi
cmp edi, dword [eax + 4]
jl 0x1001fca2
cmp edx, 1
jne 0x1001fd13
cmp dword [esi + 0x28], edx
jne 0x1001fd13
push 4
push 2
mov dword [esi + 0x24], edx
call fcn.1000e596
mov dword [esi + 0x20], eax
add esp, 8
mov dword [eax + 4], 1
mov eax, dword [esi + 0x20]
mov dword [eax], 1
xor eax, eax
lea esp, [ebp - 0x38]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0xc]
xor ecx, ecx
mov eax, dword [eax]
test eax, eax
je 0x1001fd25
nop
inc ecx
shr eax, 1
jne 0x1001fd20
add ecx, 0xfffffffc
mov dword [esi + 0x24], ecx
cmp ecx, 5
jge 0x1001fd3e
mov dword [esi + 0x24], 5
mov ecx, 5
jmp 0x1001fd4f
cmp ecx, 8
jle 0x1001fd4f
mov dword [esi + 0x24], 8
mov ecx, 8
mov eax, 1
shl eax, cl
push 4
push eax
mov dword [ebp - 0x18], eax
call fcn.1000e596
mov dword [esi + 0x20], eax
add esp, 8
mov eax, dword [ebp - 8]
xor ebx, ebx
test eax, eax
jle 0x1001fe2e
mov ecx, dword [esi + 0x1c]
movsx edx, byte [ecx + ebx]
mov dword [ebp - 0x24], edx
cmp edx, dword [esi + 0x24]
jg 0x1001fe25
mov eax, dword [esi + 0x14]
mov ecx, dword [eax + ebx*4]
bswap ecx
mov edi, ecx
mov eax, ecx
shl eax, 4
shl ecx, 4
shr edi, 4
xor edi, eax
and edi, 0xf0f0f0f
xor edi, ecx
mov edx, edi
shr edx, 2
lea eax, [edi*4]
xor edx, eax
lea eax, [edi*4]
and edx, 0x33333333
xor edx, eax
mov ecx, edx
shr ecx, 1
lea eax, [edx + edx]
xor ecx, eax
lea eax, [edx + edx]
and ecx, 0x55555555
xor edx, edx
xor ecx, eax
mov dword [ebp - 0x28], edx
mov dword [ebp - 0x20], ecx
mov eax, 1
mov ecx, dword [esi + 0x24]
sub ecx, dword [ebp - 0x24]
shl eax, cl
test eax, eax
jle 0x1001fe22
mov eax, dword [esi + 0x1c]
lea edi, [ebx + 1]
mov cl, byte [eax + ebx]
mov eax, dword [esi + 0x20]
shl edx, cl
or edx, dword [ebp - 0x20]
mov dword [eax + edx*4], edi
mov eax, dword [esi + 0x1c]
mov ecx, dword [esi + 0x24]
mov edx, dword [ebp - 0x28]
inc edx
movsx eax, byte [eax + ebx]
sub ecx, eax
mov dword [ebp - 0x28], edx
mov eax, 1
shl eax, cl
cmp edx, eax
jl 0x1001fdf0
mov eax, dword [ebp - 8]
inc ebx
cmp ebx, eax
jl 0x1001fd74
mov edx, dword [esi + 0x24]
mov ecx, 0x1f
sub ecx, edx
mov dword [ebp - 0x20], edx
mov eax, 0xfffffffe
mov dword [ebp - 0x28], 0
shl eax, cl
xor ebx, ebx
mov dword [ebp - 0x2c], eax
xor eax, eax
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x18], eax
jle 0x1001ff73
nop dword [eax]
mov ecx, 0x20
sub ecx, edx
shl eax, cl
mov ecx, eax
mov dword [ebp - 0x24], eax
bswap ecx
mov edi, ecx
mov eax, ecx
shl eax, 4
shr edi, 4
xor edi, eax
shl ecx, 4
and edi, 0xf0f0f0f
xor edi, ecx
mov edx, edi
shr edx, 2
lea eax, [edi*4]
xor edx, eax
lea eax, [edi*4]
and edx, 0x33333333
xor edx, eax
mov ecx, edx
shr ecx, 1
lea eax, [edx + edx]
xor ecx, eax
lea eax, [edx + edx]
mov edx, dword [ebp - 0x20]
and ecx, 0x55555555
xor ecx, eax
mov dword [ebp - 0x20], edx
mov eax, dword [esi + 0x20]
cmp dword [eax + ecx*4], 0
lea eax, [eax + ecx*4]
mov dword [ebp - 0x14], eax
jne 0x1001ff50
mov edi, dword [ebp - 0x28]
mov ecx, dword [ebp - 8]
lea edx, [edi + 1]
cmp edx, ecx
jge 0x1001ff03
mov eax, dword [esi + 0x14]
mov esi, dword [ebp - 0x24]
lea eax, [eax + edi*4]
add eax, 4
nop word [eax + eax]
cmp dword [eax], esi
ja 0x1001fefd
inc edx
inc edi
add eax, 4
cmp edx, ecx
jl 0x1001fef0
mov esi, dword [ebp - 0x10]
mov dword [ebp - 0x28], edi
cmp ebx, ecx
jge 0x1001ff24
mov eax, dword [esi + 0x14]
mov esi, dword [ebp - 0x2c]
lea edx, [eax + ebx*4]
mov eax, esi
and eax, dword [edx]
cmp dword [ebp - 0x24], eax
jb 0x1001ff21
inc ebx
add edx, 4
cmp ebx, ecx
jl 0x1001ff10
mov esi, dword [ebp - 0x10]
sub ecx, ebx
mov edx, 0x7fff
cmp edi, 0x7fff
mov eax, edi
cmova eax, edx
cmp ecx, edx
cmova ecx, edx
or eax, 0xffff0000
shl eax, 0xf
or eax, ecx
mov ecx, dword [ebp - 0x14]
mov dword [ecx], eax
mov edx, dword [esi + 0x24]
mov dword [ebp - 0x20], edx
mov eax, dword [ebp - 0x1c]
inc eax
mov dword [ebp - 0x1c], eax
cmp eax, dword [ebp - 0x18]
jl 0x1001fe60
xor eax, eax
lea esp, [ebp - 0x38]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov dword [esi + 4], eax
mov eax, dword [edx]
mov dword [esi], eax
xor eax, eax
lea esp, [ebp - 0x38]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret