Function at 0x5a6870
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
push esi
mov esi, ecx
xor edx, edx
push edi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 4], edx
lea ecx, [esi + 4]
mov dword [ebp - 8], edx
call fcn.00402f10
cdq
lea ecx, [esi + 0x20]
and edx, 3
lea ebx, [edx + eax]
sar ebx, 2
mov dword [ebp - 0x18], ebx
call fcn.00402f10
cdq
lea ecx, [esi + 4]
and edx, 3
add eax, edx
sar eax, 2
mov dword [ebp - 0x20], eax
call fcn.00438b90
lea ecx, [esi + 0x20]
mov dword [ebp - 0x14], eax
call fcn.00438b90
test ebx, ebx
mov dword [ebp - 0x24], eax
mov ebx, dword [ebp + 0xc]
mov dword [ebp - 0xc], 0
jle 0x5a6a04
mov ebx, dword [ebp + 0x14]
xor edx, edx
mov ecx, dword [ebp + 0x10]
nop
movzx esi, byte [edx + ecx]
lea eax, [edx + 1]
cdq
idiv ebx
shl esi, 8
movzx edi, byte [edx + ecx]
lea eax, [edx + 1]
cdq
or edi, esi
idiv ebx
shl edi, 8
movzx ebx, byte [edx + ecx]
lea eax, [edx + 1]
cdq
or ebx, edi
idiv dword [ebp + 0x14]
mov edi, dword [ebp - 0x14]
shl ebx, 8
movzx esi, byte [edx + ecx]
lea eax, [edx + 1]
or esi, ebx
cdq
mov ebx, dword [ebp + 0x14]
idiv ebx
mov eax, dword [ebp - 0xc]
xor dword [edi + eax*4], esi
inc eax
mov dword [ebp - 0xc], eax
cmp eax, dword [ebp - 0x18]
jl 0x5a68e0
mov ebx, dword [ebp + 0xc]
xor edi, edi
mov esi, dword [ebp + 8]
mov dword [ebp + 0x14], 0
nop dword [eax]
lea eax, [edi + 1]
movzx ecx, byte [edi + esi]
cdq
idiv ebx
shl ecx, 8
push 0
movzx esi, byte [edx + esi]
lea eax, [edx + 1]
cdq
or esi, ecx
idiv ebx
mov eax, dword [ebp + 8]
shl esi, 8
movzx edi, byte [edx + eax]
lea eax, [edx + 1]
cdq
or edi, esi
idiv ebx
mov esi, dword [ebp + 8]
shl edi, 8
movzx ecx, byte [edx + esi]
lea eax, [edx + 1]
cdq
or ecx, edi
idiv ebx
mov eax, dword [ebp - 4]
xor eax, ecx
mov dword [ebp - 0x10], eax
movzx ecx, byte [edx + esi]
lea eax, [edx + 1]
cdq
idiv ebx
shl ecx, 8
movzx esi, byte [edx + esi]
lea eax, [edx + 1]
cdq
or esi, ecx
idiv ebx
mov eax, dword [ebp + 8]
shl esi, 8
movzx edi, byte [edx + eax]
lea eax, [edx + 1]
cdq
or edi, esi
idiv ebx
mov esi, dword [ebp + 8]
shl edi, 8
movzx ecx, byte [edx + esi]
lea eax, [edx + 1]
cdq
or ecx, edi
idiv ebx
mov eax, dword [ebp - 8]
xor eax, ecx
mov edi, edx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x10]
push eax
call fcn.005a6770
mov ecx, dword [ebp + 0x14]
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp - 0x10]
mov dword [ebp - 4], edx
mov dword [eax + ecx*4], edx
mov edx, dword [ebp - 0xc]
mov dword [eax + ecx*4 + 4], edx
add ecx, 2
mov dword [ebp - 8], edx
mov dword [ebp + 0x14], ecx
cmp ecx, dword [ebp - 0x18]
jl 0x5a6940
jmp 0x5a6a09
mov esi, dword [ebp + 8]
xor edi, edi
cmp dword [ebp - 0x20], 0
mov dword [ebp + 0x14], 0
jle 0x5a6ae2
nop word [eax + eax]
lea eax, [edi + 1]
movzx ecx, byte [edi + esi]
cdq
idiv ebx
shl ecx, 8
push 0
movzx esi, byte [edx + esi]
lea eax, [edx + 1]
cdq
or esi, ecx
idiv ebx
mov eax, dword [ebp + 8]
shl esi, 8
movzx edi, byte [edx + eax]
lea eax, [edx + 1]
cdq
or edi, esi
idiv ebx
mov esi, dword [ebp + 8]
shl edi, 8
movzx ecx, byte [edx + esi]
lea eax, [edx + 1]
cdq
or ecx, edi
idiv ebx
mov eax, dword [ebp - 4]
xor eax, ecx
mov dword [ebp - 0x10], eax
movzx ecx, byte [edx + esi]
lea eax, [edx + 1]
cdq
idiv ebx
shl ecx, 8
movzx esi, byte [edx + esi]
lea eax, [edx + 1]
cdq
or esi, ecx
idiv ebx
mov eax, dword [ebp + 8]
shl esi, 8
movzx edi, byte [edx + eax]
lea eax, [edx + 1]
cdq
or edi, esi
idiv ebx
mov esi, dword [ebp + 8]
shl edi, 8
movzx ecx, byte [edx + esi]
lea eax, [edx + 1]
cdq
or ecx, edi
idiv ebx
mov eax, dword [ebp - 8]
xor eax, ecx
mov edi, edx
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 0x10]
push eax
call fcn.005a6770
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x24]
mov edx, dword [ebp - 0x10]
mov dword [ebp - 4], edx
mov dword [ecx + eax*4], edx
mov edx, dword [ebp - 0xc]
mov dword [ecx + eax*4 + 4], edx
add eax, 2
mov dword [ebp - 8], edx
mov dword [ebp + 0x14], eax
cmp eax, dword [ebp - 0x20]
jl 0x5a6a20
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10