Function at 0x1005a890
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x314
push ebx
push esi
push edi
mov edi, edx
mov esi, ecx
mov dword [ebp - 0xc], edi
xor ebx, ebx
mov edx, 1
lea ebx, [ebx]
mov eax, edx
mov byte [ebp + ebx - 0x314], dl
and al, 0x80
mov byte [ebp + ebx - 0x215], dl
mov byte [ebp + edx - 0x114], bl
inc ebx
movzx ecx, al
lea eax, [edx + edx]
neg ecx
sbb ecx, ecx
and ecx, 0x11b
xor ecx, eax
xor edx, ecx
cmp edx, 1
jne 0x1005a8b0
cmp dword [esi + 0x108], 0
jne 0x1005a8f8
mov eax, dword [edi + 0x1f564]
mov dword [esi + 0x108], eax
mov ecx, 1
xor edx, edx
nop
mov eax, dword [edi + 0x1f564]
mov dword [edx + eax], ecx
test ecx, ecx
je 0x1005a91f
movzx eax, byte [ebp + ecx - 0x114]
movzx ecx, byte [ebp + eax - 0x2fb]
jmp 0x1005a921
xor ecx, ecx
add edx, 4
cmp edx, 0x28
jb 0x1005a900
xor eax, eax
mov ebx, 0x428
mov dword [ebp - 0x10], eax
mov dword [ebp - 8], ebx
test al, al
je 0x1005a955
movzx edx, al
lea ecx, [ebp - 0x215]
mov dword [ebp - 4], edx
movzx eax, byte [ebp + edx - 0x114]
sub ecx, eax
movzx ecx, byte [ecx]
jmp 0x1005a95a
xor ecx, ecx
mov dword [ebp - 4], ecx
lea eax, [ecx + ecx]
xor eax, ecx
add eax, eax
xor eax, ecx
add eax, eax
xor eax, ecx
add eax, eax
xor eax, ecx
mov ecx, eax
shr ecx, 8
xor cl, al
xor cl, 0x63
je 0x1005a99c
movzx esi, cl
movzx eax, byte [ebp + esi - 0x114]
movzx ecx, byte [ebp + eax - 0x2fb]
movzx eax, byte [ebp + esi - 0x114]
movzx eax, byte [ebp + eax - 0x313]
jmp 0x1005a9a2
xor esi, esi
xor ecx, ecx
xor eax, eax
shl eax, 8
or eax, esi
shl eax, 8
or eax, esi
shl eax, 8
or eax, ecx
mov ecx, dword [edi + 0x1f564]
mov edx, eax
ror edx, 0x18
mov dword [ebx + ecx - 0x400], eax
mov ecx, dword [edi + 0x1f564]
mov dword [ebx + ecx], edx
mov edx, eax
mov ecx, dword [edi + 0x1f564]
ror eax, 8
ror edx, 0x10
mov dword [ebx + ecx + 0x400], edx
mov ecx, dword [edi + 0x1f564]
mov dword [ebx + ecx + 0x800], eax
mov ecx, esi
mov eax, dword [edi + 0x1f564]
ror ecx, 0x18
mov dword [ebx + eax + 0xc00], esi
mov eax, dword [edi + 0x1f564]
mov dword [ebx + eax + 0x1000], ecx
mov ecx, esi
mov eax, dword [edi + 0x1f564]
ror ecx, 0x10
ror esi, 8
mov dword [ebx + eax + 0x1400], ecx
mov ecx, dword [ebp - 4]
mov eax, dword [edi + 0x1f564]
mov dword [ebx + eax + 0x1800], esi
lea eax, [ecx*8]
xor eax, ecx
shl eax, 2
xor eax, ecx
lea edx, [eax + eax]
mov ecx, edx
mov al, dl
shr ecx, 8
xor al, cl
cmp al, 5
je 0x1005aaa9
xor ecx, edx
xor ecx, 5
movzx eax, cl
lea ecx, [ebp - 0x215]
movzx eax, byte [ebp + eax - 0x114]
sub ecx, eax
mov al, byte [ecx]
test al, al
je 0x1005aaa9
movzx ecx, al
movzx eax, byte [ebp + ecx - 0x114]
movzx edx, byte [ebp + eax - 0x226]
movzx esi, byte [ebp + eax - 0x24d]
movzx eax, byte [ebp + eax - 0x235]
mov dword [ebp - 0x14], eax
movzx eax, byte [ebp + ecx - 0x114]
movzx ebx, byte [ebp + eax - 0x2ac]
mov eax, dword [ebp - 0x14]
jmp 0x1005aab3
xor ecx, ecx
xor edx, edx
xor esi, esi
xor eax, eax
xor ebx, ebx
shl ebx, 8
or ebx, edx
mov dword [ebp - 4], ecx
shl ebx, 8
or ebx, esi
shl ebx, 8
or ebx, eax
mov eax, dword [edi + 0x1f564]
mov esi, ebx
mov edx, ebx
shr esi, 0x18
shr edx, 0x10
mov dword [eax + ecx*4 + 0x4028], ebx
mov eax, ebx
shl eax, 8
or esi, eax
mov eax, dword [edi + 0x1f564]
mov dword [eax + ecx*4 + 0x4428], esi
mov eax, ebx
shl eax, 0x10
or edx, eax
mov eax, dword [edi + 0x1f564]
mov dword [eax + ecx*4 + 0x4828], edx
mov ecx, ebx
shl ecx, 0x18
mov eax, ebx
shr eax, 8
or ecx, eax
mov eax, dword [edi + 0x1f564]
mov edi, dword [ebp - 4]
mov dword [eax + edi*4 + 0x4c28], ecx
mov edi, dword [ebp - 0xc]
mov eax, dword [edi + 0x1f564]
mov edi, dword [ebp - 8]
mov dword [edi + eax + 0x1c00], ebx
mov edi, dword [ebp - 0xc]
mov ebx, dword [ebp - 8]
mov eax, dword [edi + 0x1f564]
mov dword [ebx + eax + 0x2000], esi
mov eax, dword [edi + 0x1f564]
mov dword [ebx + eax + 0x2400], edx
mov eax, dword [edi + 0x1f564]
mov edx, dword [ebp - 4]
mov dword [ebx + eax + 0x2800], ecx
mov ecx, edx
mov eax, dword [edi + 0x1f564]
ror ecx, 0x18
mov dword [ebx + eax + 0x2c00], edx
mov eax, dword [edi + 0x1f564]
mov dword [ebx + eax + 0x3000], ecx
mov ecx, edx
mov eax, dword [edi + 0x1f564]
ror ecx, 0x10
ror edx, 8
mov dword [ebx + eax + 0x3400], ecx
mov eax, dword [edi + 0x1f564]
mov dword [ebx + eax + 0x3800], edx
add ebx, 4
mov eax, dword [ebp - 0x10]
inc eax
mov dword [ebp - 8], ebx
mov dword [ebp - 0x10], eax
cmp ebx, 0x828
jb 0x1005a936
mov eax, dword [edi + 0x1f564]
pop edi
pop esi
pop ebx
mov byte [eax + 0x5028], 1
mov esp, ebp
pop ebp
ret