Function at 0x1000ff12
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0xc
mov eax, dword [esp + 0x10]
push ebx
mov ebx, dword [esp + 0x1c]
push ebp
mov ebp, dword [eax + 4]
inc ebp
imul ebp, dword [eax]
mov dword [esp + 0x10], ebp
cmp ebx, 7
jne 0x1000fdb3
pop ebp
pop ebx
add esp, 0xc
mov dword [esp + 0xc], 7
mov dword [esp + 4], eax
jmp 0x10010080
push esi
push edi
lea esi, [ebx*4]
add eax, 0x2c
push esi
push dword [esp + 0x28]
mov dword [esp + 0x28], eax
push eax
call fcn.1003cf40
mov edx, dword [esp + 0x2c]
mov eax, ebp
sub eax, ebx
add esp, 0xc
mov edi, ebx
mov dword [esp + 0x14], eax
lea ecx, [edx - 4]
add ecx, esi
cmp ebx, eax
jae 0x1000ff33
mov ebx, edx
mov ebp, edi
mov edx, dword [ecx]
ror edx, 8
mov eax, edx
shr eax, 0x10
and eax, 0xff
movzx esi, byte [eax*4 + 0x1004bee0]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax*4 + 0x1004bee0]
shl eax, 8
or esi, eax
mov eax, edx
shr eax, 8
and eax, 0xff
shl esi, 8
movzx eax, byte [eax*4 + 0x1004bee0]
or esi, eax
movzx eax, dl
shl esi, 8
xor edx, edx
movzx eax, byte [eax*4 + 0x1004bee0]
or esi, eax
mov eax, edi
div ebp
add edi, 4
xor esi, dword [eax*4 + 0x1004e2dc]
xor esi, dword [ebx]
mov dword [ecx + 4], esi
mov edx, esi
mov eax, dword [ebx + 4]
xor eax, edx
mov dword [ecx + 8], eax
mov edx, eax
mov eax, dword [ebx + 8]
xor eax, edx
mov dword [ecx + 0xc], eax
mov edx, eax
mov eax, dword [ebx + 0xc]
add ecx, 0x10
xor eax, edx
add ebx, 0x10
mov dword [esp + 0x10], ebx
mov dword [ecx], eax
cmp ebp, 4
je case.default.0x1000fe91
lea eax, [ebp - 5]
cmp eax, 3
ja case.default.0x1000fe91
jmp dword [eax*4 + 0x1001006c]
mov ebx, dword [ecx]
inc edi
mov eax, ebx
add ecx, 4
shr eax, 0x10
and eax, 0xff
movzx edx, byte [eax*4 + 0x1004bee0]
mov eax, ebx
shr eax, 0x18
movzx eax, byte [eax*4 + 0x1004bee0]
shl eax, 8
or edx, eax
mov eax, ebx
shr eax, 8
and eax, 0xff
shl edx, 8
movzx eax, byte [eax*4 + 0x1004bee0]
or edx, eax
movzx eax, bl
mov ebx, dword [esp + 0x10]
shl edx, 8
movzx eax, byte [eax*4 + 0x1004bee0]
or edx, eax
xor edx, dword [ebx]
add ebx, 4
mov dword [ecx], edx
mov edx, dword [ecx]
inc edi
mov eax, dword [ebx]
add ecx, 4
xor eax, edx
add ebx, 4
mov dword [ecx], eax
mov edx, dword [ecx]
inc edi
mov eax, dword [ebx]
add ecx, 4
xor eax, edx
add ebx, 4
mov dword [ecx], eax
mov edx, dword [ecx]
inc edi
mov eax, dword [ebx]
add ecx, 4
xor eax, edx
add ebx, 4
mov dword [ecx], eax
cmp edi, dword [esp + 0x14]
jb 0x1000fdf0
mov ebp, dword [esp + 0x18]
mov ebx, dword [esp + 0x28]
mov edx, dword [ecx]
add ecx, 4
ror edx, 8
mov eax, edx
shr eax, 0x10
and eax, 0xff
movzx esi, byte [eax*4 + 0x1004bee0]
mov eax, edx
shr eax, 0x18
movzx eax, byte [eax*4 + 0x1004bee0]
shl eax, 8
or esi, eax
mov eax, edx
shr eax, 8
and eax, 0xff
shl esi, 8
movzx eax, byte [eax*4 + 0x1004bee0]
or esi, eax
movzx eax, dl
shl esi, 8
xor edx, edx
movzx eax, byte [eax*4 + 0x1004bee0]
or esi, eax
mov eax, edi
div ebx
mov edx, dword [esp + 0x20]
xor esi, dword [eax*4 + 0x1004e2dc]
mov eax, edi
sub eax, ebx
inc edi
xor esi, dword [edx + eax*4]
mov dword [ecx], esi
cmp ebx, 8
jae 0x1000ffd3
cmp edi, ebp
jae 0x10010061
mov eax, edi
sub eax, ebx
sub ebp, edi
lea esi, [edx + eax*4]
mov eax, dword [esi]
lea ecx, [ecx + 4]
mov edx, dword [ecx - 4]
lea esi, [esi + 4]
xor eax, edx
mov dword [ecx], eax
dec ebp
jne 0x1000ffb7
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xc
ret
cmp edi, ebp
jae 0x10010061
mov esi, dword [esp + 0x28]
mov eax, edi
sub eax, ebx
lea eax, [edx + eax*4]
mov dword [esp + 0x20], eax
lea ebx, [ebx]
xor edx, edx
mov ebx, dword [ecx]
mov eax, edi
lea ecx, [ecx + 4]
div esi
cmp edx, 4
jne 0x1001004b
mov eax, ebx
shr eax, 0x10
and eax, 0xff
movzx edx, byte [eax*4 + 0x1004bee0]
mov eax, ebx
shr eax, 0x18
movzx eax, byte [eax*4 + 0x1004bee0]
shl eax, 8
or edx, eax
mov eax, ebx
shr eax, 8
and eax, 0xff
shl edx, 8
movzx eax, byte [eax*4 + 0x1004bee0]
or edx, eax
movzx eax, bl
shl edx, 8
movzx ebx, byte [eax*4 + 0x1004bee0]
or ebx, edx
mov edx, dword [esp + 0x20]
inc edi
mov eax, dword [edx]
add edx, 4
xor eax, ebx
mov dword [esp + 0x20], edx
mov dword [ecx], eax
cmp edi, ebp
jb 0x1000fff0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xc
ret
mov eax, dword [esp + 0xc]
push ebx
push ebp
mov ebp, dword [esp + 0xc]
push esi
push edi
lea esi, [eax*4]
push esi
push dword [esp + 0x1c]
lea ebx, [ebp + 0x2c]
push ebx
call fcn.1003cf40
mov eax, dword [ebp + 4]
add esi, 0xfffffffc
mov edi, dword [esp + 0x28]
inc eax
imul eax, dword [ebp]
add esp, 0xc
add esi, ebx
cmp edi, eax
jae 0x1001019b
lea ecx, [ecx]
xor edx, edx
mov ecx, dword [esi]
mov eax, edi
lea esi, [esi + 4]
div dword [esp + 0x1c]
mov dword [esp + 0x14], eax
test edx, edx
jne 0x10010131
ror ecx, 8
mov edx, ecx
shr ecx, 0x10
and ecx, 0xff
mov eax, edx
shr eax, 0x18
movzx ecx, byte [ecx*4 + 0x1004bee0]
movzx eax, byte [eax*4 + 0x1004bee0]
shl eax, 8
or ecx, eax
mov eax, edx
shr eax, 8
and eax, 0xff
shl ecx, 8
movzx eax, byte [eax*4 + 0x1004bee0]
or ecx, eax
movzx eax, dl
shl ecx, 8
movzx eax, byte [eax*4 + 0x1004bee0]
or ecx, eax
mov eax, dword [esp + 0x14]
xor ecx, dword [eax*4 + 0x1004e2dc]
jmp 0x10010181
cmp edx, 4
jne 0x10010181
mov eax, ecx
shr eax, 0x10
and eax, 0xff
movzx edx, byte [eax*4 + 0x1004bee0]
mov eax, ecx
shr eax, 0x18
movzx eax, byte [eax*4 + 0x1004bee0]
shl eax, 8
or edx, eax
mov eax, ecx
shr eax, 8
and eax, 0xff
shl edx, 8
movzx eax, byte [eax*4 + 0x1004bee0]
or edx, eax
movzx eax, cl
shl edx, 8
movzx ecx, byte [eax*4 + 0x1004bee0]
or ecx, edx
mov eax, dword [ebx]
inc edi
xor eax, ecx
add ebx, 4
mov dword [esi], eax
mov eax, dword [ebp + 4]
inc eax
imul eax, dword [ebp]
cmp edi, eax
jb 0x100100c0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret