Function at 0x1009ce60
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0x18]
sub esp, 0x18
cmp dword [ebp + 0x1c], 0
movzx eax, byte [ecx]
push ebx
push esi
push edi
je 0x1009d052
movzx ebx, byte [ecx + 1]
movzx edx, byte [ecx + 4]
shl ebx, 8
or ebx, eax
mov edi, dword [ebp + 0xc]
movzx eax, byte [ecx + 2]
shl eax, 0x10
or ebx, eax
mov esi, dword [ebp + 8]
movzx eax, byte [ecx + 3]
shl eax, 0x18
or ebx, eax
movzx eax, byte [ecx + 5]
movzx ecx, byte [ecx + 7]
shl eax, 8
or edx, eax
shl ecx, 8
mov eax, dword [ebp + 0x18]
movzx eax, byte [eax + 6]
or ecx, eax
mov eax, dword [ebp + 0x10]
shl ecx, 0x10
or edx, ecx
mov dword [ebp - 8], eax
mov dword [ebp + 0x1c], edx
cmp eax, 8
jb 0x1009cf84
shr eax, 3
mov dword [ebp - 4], eax
movzx eax, byte [esi + 1]
movzx edx, byte [esi]
movzx ecx, byte [esi + 4]
shl eax, 8
or edx, eax
movzx eax, byte [esi + 2]
shl eax, 0x10
or edx, eax
movzx eax, byte [esi + 3]
shl eax, 0x18
or edx, eax
movzx eax, byte [esi + 5]
shl eax, 8
xor edx, ebx
or ecx, eax
mov dword [ebp - 0x18], edx
movzx eax, byte [esi + 6]
shl eax, 0x10
or ecx, eax
movzx eax, byte [esi + 7]
shl eax, 0x18
add esi, 8
push 1
push dword [ebp + 0x14]
or ecx, eax
lea eax, [ebp - 0x18]
xor ecx, dword [ebp + 0x1c]
push eax
mov dword [ebp - 0x14], ecx
call fcn.1009acf0
mov ebx, dword [ebp - 0x18]
add esp, 0xc
mov edx, dword [ebp - 0x14]
mov eax, ebx
shr eax, 8
mov byte [edi], bl
mov byte [edi + 1], al
mov eax, ebx
shr eax, 0x10
mov byte [edi + 2], al
mov eax, ebx
shr eax, 0x18
mov byte [edi + 3], al
mov eax, edx
shr eax, 8
mov byte [edi + 5], al
mov eax, edx
shr eax, 0x10
mov byte [edi + 6], al
mov eax, edx
shr eax, 0x18
mov byte [edi + 7], al
mov eax, dword [ebp - 8]
mov byte [edi + 4], dl
sub eax, 8
add edi, 8
mov dword [ebp + 0x1c], edx
sub dword [ebp - 4], 1
mov dword [ebp - 8], eax
jne 0x1009ced4
test eax, eax
je 0x1009d232
mov edx, dword [ebp - 8]
add esi, eax
dec edx
xor eax, eax
xor ecx, ecx
mov dword [ebp - 4], eax
mov dword [ebp - 0x10], edx
cmp edx, 7
ja case.default.0x1009cfa1
jmp dword [edx*4 + 0x1009d290]
movzx ecx, byte [esi - 1]
dec esi
shl ecx, 0x18
movzx eax, byte [esi - 1]
dec esi
shl eax, 0x10
or ecx, eax
movzx eax, byte [esi - 1]
dec esi
shl eax, 8
or ecx, eax
movzx eax, byte [esi - 1]
dec esi
or ecx, eax
movzx eax, byte [esi - 1]
dec esi
shl eax, 0x18
mov dword [ebp - 4], eax
movzx eax, byte [esi - 1]
dec esi
shl eax, 0x10
or dword [ebp - 4], eax
movzx eax, byte [esi - 1]
dec esi
shl eax, 8
or dword [ebp - 4], eax
movzx eax, byte [esi - 1]
or dword [ebp - 4], eax
mov eax, dword [ebp - 4]
xor ecx, dword [ebp + 0x1c]
xor eax, ebx
push 1
push dword [ebp + 0x14]
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x18]
push eax
mov dword [ebp - 0x14], ecx
call fcn.1009acf0
mov ebx, dword [ebp - 0x18]
add esp, 0xc
mov edx, dword [ebp - 0x14]
mov eax, ebx
shr eax, 8
mov byte [edi], bl
mov byte [edi + 1], al
mov eax, ebx
shr eax, 0x10
mov byte [edi + 2], al
mov eax, ebx
shr eax, 0x18
mov byte [edi + 3], al
mov eax, edx
shr eax, 8
mov byte [edi + 5], al
mov eax, edx
shr eax, 0x10
mov byte [edi + 6], al
mov eax, edx
shr eax, 0x18
mov byte [edi + 4], dl
mov byte [edi + 7], al
jmp 0x1009d232
movzx edi, byte [ecx + 1]
movzx esi, byte [ecx + 4]
shl edi, 8
or edi, eax
mov ebx, dword [ebp + 0xc]
movzx eax, byte [ecx + 2]
shl eax, 0x10
or edi, eax
movzx eax, byte [ecx + 3]
shl eax, 0x18
or edi, eax
movzx eax, byte [ecx + 5]
movzx ecx, byte [ecx + 7]
shl eax, 8
or esi, eax
shl ecx, 8
mov eax, dword [ebp + 0x18]
mov dword [ebp - 4], edi
movzx eax, byte [eax + 6]
or ecx, eax
mov eax, dword [ebp + 0x10]
shl ecx, 0x10
or esi, ecx
mov dword [ebp - 8], eax
mov dword [ebp + 0x1c], esi
cmp eax, 8
jb 0x1009d16a
mov ecx, dword [ebp + 8]
shr eax, 3
mov dword [ebp - 0xc], eax
movzx eax, byte [ecx + 1]
movzx edi, byte [ecx]
movzx esi, byte [ecx + 4]
shl eax, 8
or edi, eax
movzx eax, byte [ecx + 2]
shl eax, 0x10
or edi, eax
movzx eax, byte [ecx + 3]
shl eax, 0x18
or edi, eax
movzx eax, byte [ecx + 5]
shl eax, 8
or esi, eax
mov dword [ebp - 0x18], edi
movzx eax, byte [ecx + 6]
shl eax, 0x10
or esi, eax
movzx eax, byte [ecx + 7]
shl eax, 0x18
add ecx, 8
push 0
push dword [ebp + 0x14]
or esi, eax
mov dword [ebp - 0x10], ecx
lea eax, [ebp - 0x18]
mov dword [ebp - 0x14], esi
push eax
call fcn.1009acf0
mov ecx, dword [ebp - 0x18]
add esp, 0xc
xor ecx, dword [ebp - 4]
mov edx, dword [ebp - 0x14]
mov eax, ecx
xor edx, dword [ebp + 0x1c]
shr eax, 8
mov byte [ebx], cl
mov byte [ebx + 1], al
mov eax, ecx
shr eax, 0x10
mov byte [ebx + 2], al
mov eax, edx
shr eax, 8
mov byte [ebx + 5], al
mov eax, edx
shr eax, 0x10
shr ecx, 0x18
mov byte [ebx + 4], dl
mov byte [ebx + 6], al
mov eax, dword [ebp - 8]
shr edx, 0x18
sub eax, 8
mov byte [ebx + 3], cl
mov ecx, dword [ebp - 0x10]
mov byte [ebx + 7], dl
add ebx, 8
sub dword [ebp - 0xc], 1
mov dword [ebp - 4], edi
mov dword [ebp + 0x1c], esi
mov dword [ebp - 8], eax
jne 0x1009d0b0
mov edx, ecx
jmp 0x1009d16d
mov edx, dword [ebp + 8]
test eax, eax
je 0x1009d22c
movzx eax, byte [edx + 1]
movzx ecx, byte [edx]
shl eax, 8
or ecx, eax
movzx eax, byte [edx + 2]
shl eax, 0x10
or ecx, eax
movzx eax, byte [edx + 3]
shl eax, 0x18
or ecx, eax
movzx eax, byte [edx + 5]
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0x18], ecx
movzx ecx, byte [edx + 4]
shl eax, 8
or ecx, eax
movzx eax, byte [edx + 6]
mov dword [ebp + 0x1c], ecx
movzx ecx, byte [edx + 7]
shl ecx, 8
or ecx, eax
mov eax, dword [ebp + 0x1c]
shl ecx, 0x10
or eax, ecx
push 0
push dword [ebp + 0x14]
mov dword [ebp + 0x1c], eax
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x18]
push eax
call fcn.1009acf0
mov eax, dword [ebp - 8]
add esp, 0xc
mov edx, dword [ebp - 0x18]
add ebx, eax
mov ecx, dword [ebp - 0x14]
dec eax
xor edx, edi
xor ecx, esi
cmp eax, 7
ja case.default.0x1009d1ea
jmp dword [eax*4 + 0x1009d2b0]
dec ebx
mov eax, ecx
shr eax, 0x18
mov byte [ebx], al
dec ebx
mov eax, ecx
shr eax, 0x10
mov byte [ebx], al
dec ebx
mov eax, ecx
shr eax, 8
mov byte [ebx], al
dec ebx
mov byte [ebx], cl
dec ebx
mov eax, edx
shr eax, 0x18
mov byte [ebx], al
dec ebx
mov eax, edx
shr eax, 0x10
mov byte [ebx], al
dec ebx
mov eax, edx
shr eax, 8
mov byte [ebx], al
mov byte [ebx - 1], dl
mov ebx, dword [ebp - 0x10]
jmp 0x1009d22f
mov ebx, dword [ebp - 4]
mov edx, dword [ebp + 0x1c]
mov eax, edx
mov ecx, edx
shr eax, 0x10
mov dword [ebp - 4], eax
mov eax, edx
shr eax, 8
mov dword [ebp - 8], eax
mov eax, ebx
shr eax, 0x18
mov dword [ebp - 0xc], eax
mov eax, ebx
shr eax, 0x10
mov dword [ebp - 0x10], eax
mov eax, ebx
shr ecx, 0x18
shr eax, 8
mov dword [ebp + 0x1c], eax
mov eax, dword [ebp + 0x18]
pop edi
pop esi
mov byte [eax], bl
mov ebx, dword [ebp + 0x1c]
mov byte [eax + 1], bl
mov ebx, dword [ebp - 0x10]
mov byte [eax + 2], bl
mov ebx, dword [ebp - 0xc]
mov byte [eax + 3], bl
mov byte [eax + 4], dl
mov edx, dword [ebp - 8]
mov byte [eax + 5], dl
mov edx, dword [ebp - 4]
mov byte [eax + 6], dl
mov byte [eax + 7], cl
pop ebx
mov esp, ebp
pop ebp
ret