Function at 0x1005c690
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x34
mov eax, dword [0x1010d170]
xor eax, esp
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x38]
push ebx
push ebp
mov ebp, dword [esi + 0x28]
mov dword [esp + 0x18], eax
mov al, byte [esi]
mov ebx, ecx
mov ecx, dword [esi + 0x2c]
push edi
mov edi, edx
mov byte [esp + 0x13], al
mov dword [esp + 0x14], ebp
mov dword [esp + 0x18], ecx
test al, 0x40
jne 0x1005c6dc
push ecx
lea ecx, [esi + 0x10]
push ecx
push esi
call ebp
mov al, byte [esp + 0x1f]
add esp, 0xc
add dword [esi + 0x20], 1
adc dword [esi + 0x24], 0
movzx eax, al
and eax, 7
mov edx, 0xf
sub edx, eax
mov byte [esi], al
mov eax, edx
xor ecx, ecx
mov dword [esp + 0x20], edx
cmp eax, 0xf
jae 0x1005c717
jmp 0x1005c700
movzx ebp, byte [esi + eax]
or ecx, ebp
mov byte [esi + eax], 0
inc eax
shl ecx, 8
cmp eax, 0xf
jb 0x1005c700
mov ebp, dword [esp + 0x14]
movzx eax, byte [esi + 0xf]
or ecx, eax
mov byte [esi + 0xf], 1
cmp ecx, ebx
je 0x1005c73a
or eax, 0xffffffff
pop edi
pop ebp
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.100ae60d
add esp, 0x34
ret
lea ecx, [ebx + 0xf]
or ecx, 8
shr ecx, 3
add dword [esi + 0x20], ecx
adc dword [esi + 0x24], 0
cmp dword [esi + 0x24], 0x20000000
jb 0x1005c772
ja 0x1005c75b
cmp dword [esi + 0x20], 0
jbe 0x1005c772
mov eax, 0xfffffffe
pop edi
pop ebp
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.100ae60d
add esp, 0x34
ret
cmp ebx, 0x10
jb 0x1005c81c
mov eax, ebx
shr eax, 4
lea ebp, [esi + 0x10]
mov dword [esp + 0x24], eax
mov edx, dword [edi]
xor dword [ebp], edx
mov eax, dword [edi + 4]
xor dword [ebp + 4], eax
mov eax, dword [esp + 0x18]
mov ecx, dword [edi + 8]
xor dword [esi + 0x18], ecx
mov edx, dword [edi + 0xc]
xor dword [esi + 0x1c], edx
push eax
push ebp
push ebp
call dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
push ecx
lea edx, [esp + 0x38]
push edx
push esi
call dword [esp + 0x2c]
add esp, 0x18
mov eax, 8
mov cl, byte [eax + esi + 7]
dec eax
add cl, 1
mov byte [eax + esi + 8], cl
jne 0x1005c7d2
test eax, eax
jne 0x1005c7c0
mov ecx, dword [edi]
mov edx, dword [edi + 4]
mov eax, dword [esp + 0x1c]
xor ecx, dword [esp + 0x28]
xor edx, dword [esp + 0x2c]
mov dword [eax], ecx
mov ecx, dword [esp + 0x30]
mov dword [eax + 4], edx
xor ecx, dword [edi + 8]
mov edx, dword [esp + 0x34]
xor edx, dword [edi + 0xc]
mov dword [eax + 8], ecx
mov dword [eax + 0xc], edx
add eax, 0x10
add edi, 0x10
sub ebx, 0x10
sub dword [esp + 0x24], 1
mov dword [esp + 0x1c], eax
jne 0x1005c787
mov edx, dword [esp + 0x20]
mov ebp, dword [esp + 0x14]
test ebx, ebx
je 0x1005c87b
xor eax, eax
test ebx, ebx
jbe 0x1005c832
mov cl, byte [eax + edi]
xor byte [esi + eax + 0x10], cl
inc eax
cmp eax, ebx
jb 0x1005c826
mov edx, dword [esp + 0x18]
lea eax, [esi + 0x10]
push edx
push eax
push eax
call ebp
mov eax, dword [esp + 0x24]
push eax
lea ecx, [esp + 0x38]
push ecx
push esi
call ebp
add esp, 0x18
xor ecx, ecx
test ebx, ebx
jbe 0x1005c877
mov ebp, dword [esp + 0x1c]
lea edx, [esp + 0x28]
mov eax, edx
sub edi, edx
sub ebp, eax
lea eax, [esp + ecx + 0x28]
mov dl, byte [edi + eax]
xor dl, byte [eax]
inc ecx
mov byte [eax + ebp], dl
cmp ecx, ebx
jb 0x1005c862
mov ebp, dword [esp + 0x14]
mov edx, dword [esp + 0x20]
cmp edx, 0x10
jae 0x1005c896
mov ecx, 0x10
sub ecx, edx
push ecx
lea eax, [esi + edx]
push 0
push eax
call fcn.100b34b0
add esp, 0xc
mov edx, dword [esp + 0x18]
push edx
lea eax, [esp + 0x2c]
push eax
push esi
call ebp
mov ecx, dword [esp + 0x34]
xor dword [esi + 0x10], ecx
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x38]
xor dword [esi + 0x1c], ecx
xor dword [esi + 0x14], edx
mov eax, dword [esp + 0x3c]
mov ecx, dword [esp + 0x48]
xor dword [esi + 0x18], eax
mov dl, byte [esp + 0x1f]
add esp, 0xc
pop edi
pop ebp
pop ebx
xor ecx, esp
mov byte [esi], dl
xor eax, eax
call fcn.100ae60d
add esp, 0x34
ret