Function at 0x5a9550
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x68
mov eax, dword [0x6ce488]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp + 0x14]
push edi
push eax
mov dword [ebp - 0x5c], ebx
mov dword [ebp - 0x60], eax
mov dword [ebp - 0x64], 0
call fcn.00520ec0
mov edi, dword [ebp - 0x60]
push edi
call fcn.00520d20
add esp, 8
mov dword [ebp - 0x40], eax
test eax, eax
je 0x5a9a1f
push edi
call fcn.00520d20
add esp, 4
mov dword [ebp - 0x38], eax
test eax, eax
je 0x5a9a1f
push edi
call fcn.00520d20
add esp, 4
mov dword [ebp - 0x48], eax
test eax, eax
je 0x5a9a1f
push edi
call fcn.00520d20
mov edi, eax
add esp, 4
mov dword [ebp - 0x50], edi
test edi, edi
je 0x5a9a1f
push 6
lea eax, [ebp - 0x1c]
push eax
push ebx
call fcn.005aa210
add esp, 0xc
test eax, eax
je 0x5a9a04
cmp eax, 6
jg 0x5a9a04
lea eax, [ebp - 0x1c]
push eax
push esi
mov esi, dword [ebp - 0x48]
push esi
call fcn.005a9130
add esp, 0xc
test eax, eax
je 0x5a9a1f
cmp dword [esi + 4], 0
je 0x5a9a1f
push ebx
push edi
call fcn.004f12f0
add esp, 8
test eax, eax
je 0x5a9a1f
push esi
call fcn.004f1650
push edi
mov dword [ebp - 0x34], eax
call fcn.004f1650
mov edi, dword [ebx + 4]
add esp, 8
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x20], edi
cmp edi, dword [esi + 8]
jg 0x5a9653
mov eax, esi
jmp 0x5a965d
push edi
push esi
call fcn.004f19a0
add esp, 8
test eax, eax
je 0x5a9a1f
mov edx, dword [ebp - 0x48]
mov esi, dword [esi]
mov dword [ebp - 0x3c], esi
mov eax, dword [edx + 4]
cmp eax, edi
jge 0x5a9683
mov ecx, dword [ebp - 0x20]
lea edi, [esi + eax*4]
sub ecx, eax
xor eax, eax
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 0x20]
mov dword [edx + 4], edi
mov edx, dword [ebp - 0x40]
cmp edi, dword [edx + 8]
jg 0x5a9692
mov eax, edx
jmp 0x5a969f
push edi
push edx
call fcn.004f19a0
mov edx, dword [ebp - 0x40]
add esp, 8
test eax, eax
je 0x5a9a1f
mov ebx, dword [edx]
mov dword [ebp - 0x28], ebx
mov dword [ebx], 1
cmp edi, 1
jle 0x5a96c4
lea ecx, [edi - 1]
xor eax, eax
lea edi, [ebx + 4]
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x38]
mov dword [edx + 4], edi
cmp edi, dword [ecx + 8]
jg 0x5a96d3
mov eax, ecx
jmp 0x5a96e0
push edi
push ecx
call fcn.004f19a0
mov ecx, dword [ebp - 0x38]
add esp, 8
test eax, eax
je 0x5a9a1f
mov edx, dword [ecx]
mov dword [ebp - 0x2c], edx
test edi, edi
jle 0x5a96ff
mov ecx, edi
xor eax, eax
mov edi, edx
rep stosd dword es:[edi], eax
mov edi, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x38]
mov eax, dword [ebp - 0x50]
mov dword [ecx + 4], edi
mov ecx, dword [ebp - 0x34]
mov eax, dword [eax]
mov dword [ebp - 0x24], eax
nop dword [eax]
test ecx, ecx
je 0x5a97e2
nop dword [eax + eax]
mov ebx, dword [esi]
test bl, 1
jne 0x5a97dc
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x5c]
mov eax, dword [eax]
mov edx, eax
mov ecx, dword [ecx]
and edx, 1
neg edx
mov dword [ebp - 0x58], edx
mov ecx, dword [ecx]
and ecx, edx
lea edx, [edi - 1]
xor eax, ecx
xor ecx, ecx
mov dword [ebp - 0x30], ecx
test edx, edx
jle 0x5a97be
mov ecx, dword [ebp - 0x28]
mov edx, esi
sub edx, ecx
mov dword [ebp - 0x44], edx
lea edi, [ecx + 4]
mov ecx, 0xfffffffc
sub ecx, dword [ebp - 0x28]
mov dword [ebp - 0x54], ecx
nop dword [eax]
mov edx, dword [edx + edi]
lea edi, [edi + 4]
mov ecx, edx
shr ebx, 1
shl ecx, 0x1f
or ecx, ebx
shr eax, 1
mov ebx, dword [ebp - 0x30]
mov dword [esi + ebx*4], ecx
mov ebx, edx
mov ecx, dword [ebp - 0x5c]
mov esi, dword [ebp - 0x3c]
mov ecx, dword [ecx]
add ecx, dword [ebp - 0x54]
mov edx, dword [ecx + edi]
and edx, dword [ebp - 0x58]
xor edx, dword [edi - 4]
mov ecx, edx
shl ecx, 0x1f
or ecx, eax
mov eax, edx
mov edx, dword [ebp - 0x20]
mov dword [edi - 8], ecx
dec edx
mov ecx, dword [ebp - 0x30]
inc ecx
cmp ecx, edx
mov dword [ebp - 0x30], ecx
mov edx, dword [ebp - 0x44]
jl 0x5a9770
mov edi, dword [ebp - 0x20]
shr ebx, 1
mov dword [esi + ecx*4], ebx
mov ebx, dword [ebp - 0x28]
shr eax, 1
mov dword [ebx + ecx*4], eax
mov ecx, dword [ebp - 0x34]
sub ecx, 1
mov dword [ebp - 0x34], ecx
jne 0x5a9720
jmp 0x5a97df
mov ebx, dword [ebp - 0x28]
mov edx, dword [ebp - 0x2c]
cmp ecx, 0x20
jg 0x5a97fa
mov eax, dword [esi]
test eax, eax
je 0x5a9a1f
cmp eax, 1
je 0x5a99c4
cmp ecx, dword [ebp - 0x4c]
jge 0x5a9837
mov ebx, dword [ebp - 0x48]
mov eax, ecx
mov esi, dword [ebp - 0x50]
mov ecx, dword [ebp - 0x4c]
mov dword [ebp - 0x48], esi
mov esi, dword [ebp - 0x38]
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x50], ebx
mov ebx, dword [ebx]
mov dword [ebp - 0x40], esi
mov esi, dword [ebp - 0x24]
mov dword [ebp - 0x24], ebx
mov ebx, edx
mov edx, dword [eax]
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x3c], esi
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x2c], edx
xor edx, edx
test edi, edi
jle 0x5a9972
cmp edi, 4
jb 0x5a9927
mov ecx, dword [ebp - 0x2c]
lea eax, [edi - 1]
lea eax, [ebx + eax*4]
lea ecx, [ecx + edi*4]
add ecx, 0xfffffffc
cmp ebx, ecx
ja 0x5a9866
cmp eax, dword [ebp - 0x2c]
jae 0x5a9927
lea ecx, [edi - 1]
lea ecx, [esi + ecx*4]
mov dword [ebp - 0x30], ecx
cmp ebx, ecx
ja 0x5a987b
cmp eax, esi
jae 0x5a9927
mov ecx, dword [ebp - 0x24]
sub ecx, 4
lea edi, [ecx + edi*4]
cmp ebx, edi
ja 0x5a9891
cmp eax, dword [ebp - 0x24]
jae 0x5a9924
mov ebx, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x2c]
dec ebx
lea eax, [ecx + ebx*4]
mov ebx, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x30]
cmp esi, eax
ja 0x5a98ae
cmp ecx, dword [ebp - 0x2c]
jae 0x5a9924
cmp esi, edi
ja 0x5a98bd
mov eax, dword [ebp - 0x24]
cmp ecx, eax
jae 0x5a99bc
mov ecx, dword [ebp - 0x20]
mov eax, ecx
and eax, reloc.WS2_32.dll_closesocket
jns 0x5a98ce
dec eax
or eax, 0xfffffffc
inc eax
mov ebx, dword [ebp - 0x2c]
sub ecx, eax
mov edi, dword [ebp - 0x24]
sub ebx, esi
mov dword [ebp - 0x44], ebx
sub edi, esi
mov ebx, dword [ebp - 0x28]
mov eax, esi
mov esi, dword [ebp - 0x3c]
mov dword [ebp - 0x30], ebx
sub dword [ebp - 0x30], esi
mov ebx, dword [ebp - 0x44]
mov esi, dword [ebp - 0x30]
movups xmm0, xmmword [eax]
add edx, 4
lea eax, [eax + 0x10]
movups xmm1, xmmword [edi + eax - 0x10]
pxor xmm1, xmm0
movups xmm0, xmmword [esi + eax - 0x10]
movups xmmword [eax - 0x10], xmm1
movups xmm1, xmmword [ebx + eax - 0x10]
pxor xmm1, xmm0
movups xmmword [esi + eax - 0x10], xmm1
cmp edx, ecx
jl 0x5a98f1
mov esi, dword [ebp - 0x3c]
mov ebx, dword [ebp - 0x28]
mov edi, dword [ebp - 0x20]
mov eax, dword [ebp - 0x24]
cmp edx, edi
jge 0x5a996f
sub eax, esi
lea ecx, [esi + edx*4]
mov dword [ebp - 0x44], eax
sub ebx, esi
mov eax, dword [ebp - 0x2c]
sub eax, esi
mov dword [ebp - 0x54], ebx
mov ebx, dword [ebp - 0x44]
sub edi, edx
mov esi, dword [ebp - 0x54]
mov edx, eax
mov dword [ebp - 0x58], eax
nop dword [eax]
mov eax, dword [ecx + ebx]
lea ecx, [ecx + 4]
xor dword [ecx - 4], eax
mov eax, dword [ecx + edx - 4]
xor dword [ecx + esi - 4], eax
sub edi, 1
jne 0x5a9950
mov esi, dword [ebp - 0x3c]
mov ebx, dword [ebp - 0x28]
mov edi, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x34]
mov edx, dword [ebp - 0x2c]
cmp ecx, dword [ebp - 0x4c]
jne 0x5a9710
lea eax, [ecx - 1]
cdq
and edx, 0x1f
lea edi, [edx + eax]
sar edi, 5
mov eax, dword [esi + edi*4]
test eax, eax
jne 0x5a999f
test edi, edi
je 0x5a999f
mov eax, dword [esi + edi*4 - 4]
dec edi
test eax, eax
je 0x5a9992
push eax
call fcn.004f16d0
mov edx, dword [ebp - 0x2c]
add esp, 4
shl edi, 5
lea ecx, [edi + eax]
mov edi, dword [ebp - 0x20]
mov dword [ebp - 0x34], ecx
jmp 0x5a9710
mov edi, dword [ebp - 0x20]
jmp 0x5a992a
mov ebx, dword [ebp - 0x40]
mov ecx, dword [ebx + 4]
test ecx, ecx
jle 0x5a99e7
mov eax, dword [ebx]
lea edx, [ecx - 1]
lea edx, [eax + edx*4]
mov eax, dword [edx]
lea edx, [edx - 4]
test eax, eax
jne 0x5a99e4
dec ecx
test ecx, ecx
jg 0x5a99d6
mov dword [ebx + 4], ecx
push ebx
push dword [ebp - 0x68]
call fcn.004f12f0
xor ecx, ecx
add esp, 8
test eax, eax
mov edx, 1
cmovne ecx, edx
mov dword [ebp - 0x64], ecx
jmp 0x5a9a1f
push 0x1dd
push 0x685a08
push 0x6a
push 0x83
push 3
call fcn.0050ab50
add esp, 0x14
push dword [ebp - 0x60]
call fcn.00520c30
mov ecx, dword [ebp - 4]
add esp, 4
mov eax, dword [ebp - 0x64]
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.005c358e
mov esp, ebp
pop ebp
ret