Function at 0x59cbf0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0x24]
sub esp, 0x20
test ecx, ecx
je 0x59ce76
mov eax, dword [ebp + 0x20]
mov edx, dword [ebp + 0x10]
add eax, 0xfffffffc
push esi
push edi
mov edi, dword [ebp + 8]
mov dword [ebp - 0x10], eax
dec ecx
xor eax, eax
cmp byte [0x708fa1], al
mov esi, dword [ebp + 0x20]
mov dword [ebp + 0x24], ecx
mov dword [ebp - 4], esi
je 0x59ccfd
lea ecx, [esi - 0x20]
test ecx, ecx
js 0x59ccad
mov eax, dword [ebp + 0x18]
lea ecx, [edx + 0x10]
mov dword [ebp - 0x14], edi
sub edi, edx
mov dword [ebp - 0x18], edi
mov edi, eax
sub eax, dword [ebp + 8]
sub edi, edx
mov edx, dword [ebp - 0x14]
mov dword [ebp - 0x20], eax
mov eax, esi
shr eax, 5
mov dword [ebp - 8], eax
shl eax, 5
mov dword [ebp - 0x1c], edi
mov edi, dword [ebp - 0x18]
mov esi, dword [ebp - 0x1c]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x20]
jmp 0x59cc70
dec dword [ebp - 8]
lea ecx, [ecx + 0x20]
movdqu xmm0, xmmword [ecx - 0x20]
lea edx, [edx + 0x20]
movdqu xmm2, xmmword [edi + ecx - 0x20]
movdqu xmm1, xmmword [ecx - 0x30]
pxor xmm2, xmm0
movdqu xmm0, xmmword [edx - 0x20]
pxor xmm1, xmm0
movdqu xmmword [eax + edx - 0x20], xmm1
movdqu xmmword [esi + ecx - 0x20], xmm2
jne 0x59cc70
mov eax, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
mov edi, dword [ebp + 8]
lea edx, [esi - 8]
cmp eax, edx
jg 0x59ccfd
mov esi, dword [ebp + 0x18]
lea ecx, [eax + edi]
mov dword [ebp - 8], esi
sub edx, eax
mov esi, dword [ebp + 0x10]
sub dword [ebp - 8], edi
sub esi, edi
mov edi, dword [ebp - 8]
shr edx, 3
inc edx
mov dword [ebp - 0x20], esi
mov esi, dword [ebp - 4]
lea eax, [eax + edx*8]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0x20]
lea ecx, [ecx]
movq xmm1, qword [eax + ecx]
lea ecx, [ecx + 8]
movq xmm0, qword [ecx - 8]
pxor xmm1, xmm0
movq qword [ecx + edi - 8], xmm1
dec edx
jne 0x59cce0
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp - 0x10]
jg 0x59cd78
mov edx, dword [ebp + 0x10]
mov ecx, dword [ebp + 8]
mov esi, dword [ebp + 0x18]
mov dword [ebp - 0xc], ecx
add esi, eax
mov ecx, dword [ebp + 0x18]
lea edi, [edx + 1]
sub dword [ebp - 0xc], edx
sub ecx, edx
mov dword [ebp - 0x1c], ecx
add edi, eax
mov ecx, dword [ebp + 8]
sub ecx, dword [ebp + 0x18]
mov dword [ebp - 0x20], ecx
lea esp, [esp]
mov ecx, dword [ebp - 0xc]
lea edi, [edi + 4]
lea esi, [esi + 4]
mov dl, byte [edi + ecx - 4]
mov ecx, dword [ebp - 0x20]
xor dl, byte [edi - 4]
movzx ecx, byte [ecx + esi - 4]
xor cl, byte [edi - 5]
mov byte [esi - 4], cl
mov ecx, dword [ebp - 0x1c]
mov byte [edi + ecx - 4], dl
mov ecx, dword [ebp + 8]
mov dl, byte [ecx + eax + 3]
movzx ecx, byte [ecx + eax + 2]
add eax, 4
xor dl, byte [edi - 2]
xor cl, byte [edi - 3]
mov byte [esi - 2], cl
mov byte [esi - 1], dl
cmp eax, dword [ebp - 0x10]
jle 0x59cd30
mov esi, dword [ebp - 4]
mov ecx, esi
sub ecx, eax
mov dword [ebp - 0x1c], ecx
cmp eax, esi
jge 0x59ce51
cmp ecx, 0x10
jb 0x59ce21
mov ecx, dword [ebp + 0x18]
lea edx, [eax + ecx]
mov dword [ebp - 0xc], edx
lea edi, [ecx - 1]
mov edx, dword [ebp + 0x10]
add edi, esi
mov dword [ebp - 0x20], edi
lea ecx, [edx - 1]
add ecx, esi
cmp dword [ebp - 0xc], ecx
ja 0x59cdb9
lea ecx, [eax + edx]
cmp edi, ecx
jae 0x59ce7a
mov edi, dword [ebp + 8]
lea ecx, [edi - 1]
add ecx, esi
lea edx, [eax + edi]
cmp dword [ebp - 0xc], ecx
ja 0x59cdce
cmp dword [ebp - 0x20], edx
jae 0x59ce24
mov ecx, dword [ebp - 0x1c]
and ecx, reloc.WS2_32.dll_ntohs
jns 0x59cdde
dec ecx
or ecx, 0xfffffff0
inc ecx
mov dword [ebp - 0xc], esi
sub dword [ebp - 0xc], ecx
mov ecx, dword [ebp + 0x18]
sub ecx, edi
mov dword [ebp - 0x20], ecx
mov ecx, dword [ebp + 0x10]
sub ecx, edi
mov edi, dword [ebp - 0x20]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp - 0xc]
mov esi, dword [ebp - 0x1c]
lea ecx, [ecx]
movdqu xmm1, xmmword [esi + edx]
add eax, 0x10
lea edx, [edx + 0x10]
movdqu xmm0, xmmword [edx - 0x10]
pxor xmm1, xmm0
movdqu xmmword [edi + edx - 0x10], xmm1
cmp eax, ecx
jl 0x59ce00
mov esi, dword [ebp - 4]
mov edi, dword [ebp + 8]
mov edx, dword [ebp + 0x10]
cmp eax, esi
jge 0x59ce51
sub edi, edx
lea ecx, [eax + edx]
mov edx, dword [ebp + 0x18]
mov dword [ebp - 0xc], edx
mov edx, dword [ebp + 0x10]
sub dword [ebp - 0xc], edx
sub esi, eax
mov edx, dword [ebp - 0xc]
mov al, byte [edi + ecx]
lea ecx, [ecx + 1]
xor al, byte [ecx - 1]
mov byte [edx + ecx - 1], al
dec esi
jne 0x59ce41
mov edi, dword [ebp + 8]
mov edx, dword [ebp + 0x10]
add edi, dword [ebp + 0xc]
add edx, dword [ebp + 0x14]
mov eax, dword [ebp + 0x1c]
add dword [ebp + 0x18], eax
mov ecx, dword [ebp + 0x24]
mov dword [ebp + 8], edi
mov dword [ebp + 0x10], edx
test ecx, ecx
jne 0x59cc12
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov edi, dword [ebp + 8]
jmp 0x59ce27