Function at 0x1009fc20
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
mov ebx, dword [ebp + 0x14]
xor ecx, ecx
push esi
mov esi, dword [ebp + 8]
mov eax, dword [esi + 0x174]
mov dword [ebp - 0xc], eax
mov eax, ebx
add eax, dword [esi + 0x38]
adc ecx, dword [esi + 0x3c]
cmp ecx, 0xf
ja 0x1009fe1e
jb 0x1009fc55
cmp eax, 0xffffffe0
ja 0x1009fe1e
cmp dword [esi + 0x16c], 0
mov dword [esi + 0x38], eax
mov dword [esi + 0x3c], ecx
je 0x1009fc7e
lea eax, [esi + 0x60]
push eax
lea eax, [esi + 0x40]
push eax
call fcn.100a07b0
add esp, 8
mov dword [esi + 0x16c], 0
mov eax, dword [esi + 0xc]
push edi
mov edi, dword [esi + 0x168]
mov dword [ebp - 0x14], edi
bswap eax
mov dword [ebp - 8], eax
test edi, edi
je 0x1009fce5
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp + 0xc]
mov dword [ebp - 4], edx
mov dword [ebp + 0x14], eax
test ebx, ebx
je 0x1009fccb
mov cl, byte [eax]
dec ebx
inc eax
mov dword [ebp + 0x14], eax
mov al, byte [edi + esi + 0x10]
xor al, cl
mov byte [edx], al
lea eax, [edi + esi]
xor byte [eax + 0x40], cl
inc edx
mov eax, dword [ebp + 0x14]
inc edi
and edi, 0xf
mov dword [ebp - 4], edx
mov dword [ebp - 0x14], edi
jne 0x1009fca0
jmp 0x1009fcd3
test edi, edi
jne 0x1009fe0f
lea eax, [esi + 0x60]
push eax
lea eax, [esi + 0x40]
push eax
call fcn.100a07b0
add esp, 8
jmp 0x1009fcf1
mov eax, dword [ebp + 0x10]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp + 0x14], eax
cmp ebx, 0xc00
jb 0x1009fd65
mov edi, dword [ebp + 0x14]
lea ecx, [esi + 0x60]
mov eax, 0xaaaaaaab
mul ebx
shr edx, 0xb
mov dword [ebp - 0x10], edx
lea esp, [esp]
push 0xc00
push edi
push ecx
lea eax, [esi + 0x40]
push eax
call fcn.100a05f0
push esi
push dword [ebp - 0xc]
push 0xc0
push dword [ebp - 4]
push edi
call dword [ebp + 0x18]
mov ecx, dword [ebp - 8]
add esp, 0x24
add dword [ebp - 4], 0xc00
add ecx, 0xc0
mov dword [ebp - 8], ecx
add edi, 0xc00
bswap ecx
sub ebx, 0xc00
mov dword [esi + 0xc], ecx
dec dword [ebp - 0x10]
lea ecx, [esi + 0x60]
jne 0x1009fd10
mov dword [ebp + 0x14], edi
mov edi, dword [ebp - 0x14]
mov eax, ebx
and eax, 0xfffffff0
mov dword [ebp - 0x14], eax
je 0x1009fdb6
mov ecx, dword [ebp + 8]
mov esi, eax
push eax
push dword [ebp + 0x14]
shr esi, 4
lea eax, [ecx + 0x60]
push eax
lea eax, [ecx + 0x40]
push eax
call fcn.100a05f0
push dword [ebp + 8]
push dword [ebp - 0xc]
push esi
push dword [ebp - 4]
push dword [ebp + 0x14]
call dword [ebp + 0x18]
mov eax, dword [ebp - 8]
add esp, 0x24
add eax, esi
mov esi, dword [ebp + 8]
mov dword [ebp - 8], eax
bswap eax
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 0x14]
add dword [ebp - 4], eax
add dword [ebp + 0x14], eax
sub ebx, eax
test ebx, ebx
je 0x1009fe0f
push dword [ebp - 0xc]
lea eax, [esi + 0x10]
push eax
mov eax, dword [esi + 0x170]
push esi
call eax
mov eax, dword [ebp - 8]
add esp, 0xc
inc eax
bswap eax
mov dword [esi + 0xc], eax
mov eax, dword [ebp - 4]
sub dword [ebp + 0x14], eax
lea edx, [edi + eax]
lea eax, [esi + 0x40]
mov esi, dword [ebp + 0x14]
mov dword [ebp - 0x14], eax
jmp 0x1009fdf0
mov cl, byte [esi + edx]
lea edx, [edx + 1]
xor byte [eax + edi], cl
mov eax, dword [ebp - 0x14]
mov al, byte [eax + edi - 0x30]
inc edi
xor al, cl
mov byte [edx - 1], al
mov eax, dword [ebp - 0x14]
dec ebx
jne 0x1009fdf0
mov esi, dword [ebp + 8]
mov dword [esi + 0x168], edi
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret