Function at 0xa594cd5
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
cmp dword [ebp + 8], 0
push ebx
push esi
push edi
je 0xa594f3b
cmp dword [ebp + 0x28], 0
je 0xa594f3b
cmp dword [ebp + 0x2c], 0
je 0xa594f3b
mov ebx, dword [ebp + 0x24]
push ebx
call fcn.0a5937eb
pop ecx
test eax, eax
jne 0xa594f3e
push dword [ebp + 0x20]
call fcn.0a5949b8
pop ecx
test eax, eax
jne 0xa594f3e
imul eax, ebx, 0x68
push 0
pop ebx
mov esi, dword [eax + 0xa456a80]
mov eax, dword [ebp + 0x18]
test al, 7
mov dword [ebp - 0x10], esi
setne bl
shr eax, 3
add ebx, eax
lea edx, [esi + esi]
lea eax, [ebx - 2]
cmp edx, eax
jae 0xa594f37
mov ecx, ebx
sub ecx, edx
mov dword [ebp - 0x14], ecx
lea eax, [ecx - 2]
cmp dword [ebp + 0xc], eax
ja 0xa594f37
push ebx
call fcn.0a62391c
push ebx
mov edi, eax
call fcn.0a62391c
push esi
mov dword [ebp - 8], eax
call fcn.0a62391c
add esp, 0xc
mov esi, eax
mov dword [ebp - 0xc], esi
test edi, edi
je 0xa594f1a
cmp dword [ebp - 8], 0
je 0xa594f13
test esi, esi
je 0xa594f13
cmp dword [ebp + 0x10], 0
lea eax, [ebp - 4]
push eax
mov dword [ebp - 4], ebx
push edi
je 0xa594dab
push dword [ebp + 0x14]
push dword [ebp + 0x10]
jmp 0xa594dae
push 0
push edi
push dword [ebp + 0x24]
call fcn.0a5972e4
mov esi, eax
add esp, 0x14
test esi, esi
jne 0xa594ef6
mov eax, dword [ebp - 0x14]
sub eax, dword [ebp + 0xc]
mov esi, dword [ebp - 0x10]
sub eax, 2
push eax
mov dword [ebp - 0x14], eax
push 0
lea eax, [edi + esi]
mov dword [ebp - 4], esi
push eax
call fcn.0a613410
mov eax, dword [ebp - 4]
add eax, dword [ebp - 0x14]
push dword [ebp + 0xc]
mov dword [ebp - 4], eax
push dword [ebp + 8]
mov byte [eax + edi], 1
mov eax, dword [ebp - 4]
inc eax
mov dword [ebp - 4], eax
add eax, edi
push eax
call fcn.0a612e90
mov eax, dword [ebp + 0xc]
add dword [ebp - 4], eax
imul eax, dword [ebp + 0x20], 0x28
push dword [ebp + 0x1c]
push esi
push dword [ebp - 0xc]
call dword [eax + 0xa45785c]
add esp, 0x24
cmp eax, esi
je 0xa594e29
push 9
pop esi
jmp 0xa594ef6
mov eax, ebx
sub eax, esi
dec eax
push eax
push dword [ebp - 8]
mov dword [ebp + 8], eax
push esi
push dword [ebp - 0xc]
push dword [ebp + 0x24]
call fcn.0a597399
mov esi, eax
add esp, 0x14
test esi, esi
jne 0xa594ef6
mov edx, dword [ebp + 8]
test edx, edx
je 0xa594e6a
mov esi, dword [ebp - 8]
mov ecx, edi
sub esi, edi
mov al, byte [esi + ecx]
xor byte [ecx], al
inc ecx
sub edx, 1
jne 0xa594e5c
mov edx, dword [ebp + 8]
mov esi, dword [ebp - 0x10]
push esi
push dword [ebp - 8]
push edx
push edi
push dword [ebp + 0x24]
call fcn.0a597399
mov esi, eax
add esp, 0x14
test esi, esi
jne 0xa594ef6
mov esi, dword [ebp - 0x10]
test esi, esi
je 0xa594ea3
mov eax, dword [ebp - 8]
mov edx, dword [ebp - 0xc]
sub eax, edx
mov ecx, eax
mov al, byte [ecx + edx]
xor byte [edx], al
inc edx
sub esi, 1
jne 0xa594e95
mov esi, dword [ebp - 0x10]
mov eax, dword [ebp + 0x2c]
mov ecx, dword [ebp - 0xc]
cmp dword [eax], ebx
jae 0xa594eb6
mov dword [eax], ebx
push 6
jmp 0xa594e23
mov eax, dword [ebp + 0x28]
push esi
push ecx
mov byte [eax], 0
inc eax
push eax
mov dword [ebp - 4], 1
call fcn.0a612e90
mov eax, dword [ebp - 4]
push dword [ebp + 8]
add eax, esi
mov dword [ebp - 4], eax
add eax, dword [ebp + 0x28]
push edi
push eax
call fcn.0a612e90
mov eax, dword [ebp - 4]
sub ebx, esi
mov ecx, dword [ebp + 0x2c]
dec eax
add eax, ebx
add esp, 0x18
mov dword [ebp - 4], eax
xor esi, esi
mov dword [ecx], eax
push dword [ebp - 0xc]
call fcn.0a61be5a
push dword [ebp - 8]
call fcn.0a61be5a
push edi
call fcn.0a61be5a
add esp, 0xc
mov eax, esi
jmp 0xa594f3e
push edi
call fcn.0a61be5a
pop ecx
mov eax, dword [ebp - 8]
test eax, eax
je 0xa594f28
push eax
call fcn.0a61be5a
pop ecx
test esi, esi
je 0xa594f33
push esi
call fcn.0a61be5a
pop ecx
push 0xd
jmp 0xa594f3d
push 0x16
jmp 0xa594f3d
push 0x10
pop eax
pop edi
pop esi
pop ebx
leave
ret