Function at 0x5139c0
Capabilities:
Send data
Send data on socket

Disassembly:
sub esp, 8
push ebx
push ebp
mov ebx, ecx
push esi
push edi
xor edi, edi
mov eax, dword [ebx + 0xd4]
mov dword [ebx + 0x20], edi
cmp dword [eax + 0x140], 4
jne 0x513b74
mov eax, dword [ebx + 0xa4]
mov dword [esp + 0x14], edi
cmp eax, edi
je 0x5139f7
mov esi, dword [eax]
mov dword [esp + 0x10], esi
jmp 0x513a05
mov eax, dword [ebx + 0xa0]
mov ecx, dword [eax]
mov dword [esp + 0x10], ecx
mov esi, ecx
cmp dword [esp + 0x20], edi
je 0x513a18
mov edx, dword [esp + 0x24]
mov dword [ebx + 0x30], edi
mov dword [esp + 0x14], edx
jmp 0x513a29
lea eax, [esp + 0x14]
push edi
push eax
push esi
mov ecx, ebx
call fcn.00513530
mov dword [ebx + 0x30], eax
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
add ecx, 9
push ecx
call fcn.005a9fe9
mov ebp, eax
add esp, 4
test ebp, ebp
jne 0x513a55
pop edi
pop esi
pop ebp
mov eax, 0x753b
pop ebx
add esp, 8
ret 0x14
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
add ecx, 9
mov edi, ebp
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
mov edx, dword [esp + 0x2c]
and ecx, 3
test edx, edx
rep stosb byte es:[edi], al
setne al
inc eax
mov edi, 9
mov byte [ebp + 1], al
mov eax, dword [esp + 0x20]
test eax, eax
mov byte [ebp], 4
je 0x513a97
mov eax, dword [esp + 0x28]
jmp 0x513ab5
mov eax, dword [ebx + 0xa4]
test eax, eax
je 0x513aa6
mov eax, dword [eax + 0xc]
jmp 0x513aaf
mov ecx, dword [ebx + 0xa0]
mov eax, dword [ecx + 0x14]
push eax
call sub.WSOCK32.dll_htons
mov word [ebp + 2], ax
mov eax, dword [ebx + 0x30]
test eax, eax
je 0x513b07
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
mov byte [ebp + 4], 0
mov byte [ebp + 5], 0
mov byte [ebp + 6], 0
mov byte [ebp + 7], 1
lea edx, [ebp + 9]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x10]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov edi, ecx
add edi, 0xa
jmp 0x513b0e
mov ecx, dword [esp + 0x14]
mov dword [ebp + 4], ecx
mov edx, dword [esp + 0x1c]
push str.sending_socks_CONNECT
push 0
push edi
push ebp
push edx
call sub.WSOCK32.dll_send
push eax
mov ecx, ebx
call fcn.00513450
push str.socks4:_sending_connect_n
mov ecx, ebx
mov edi, eax
call fcn.005133a0
push ebp
call fcn.005aa012
add esp, 4
cmp edi, 0x2733
jne 0x513b5d
xor edi, edi
mov dword [ebx + 0x7c], 0x1d
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret 0x14
test edi, edi
jne 0x513b68
mov dword [ebx + 0x7c], 0x1d
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret 0x14
mov dword [esp + 0x20], edi
mov byte [esp + 0x20], 5
mov cl, byte [eax + 0x145]
push str.sending_socks_INIT
test cl, cl
setne cl
inc ecx
push edi
mov byte [esp + 0x29], cl
mov dl, byte [eax + 0x145]
neg dl
sbb dl, dl
xor ecx, ecx
and edx, 2
mov byte [esp + 0x2a], dl
mov dl, byte [eax + 0x145]
test dl, dl
setne cl
add ecx, 3
lea edx, [esp + 0x28]
mov eax, ecx
push eax
mov eax, dword [esp + 0x28]
push edx
push eax
call sub.WSOCK32.dll_send
push eax
mov ecx, ebx
call fcn.00513450
push str.socks5:_sending_init_n
mov ecx, ebx
mov esi, eax
call fcn.005133a0
cmp esi, edi
je 0x513be8
cmp esi, 0x2733
jne 0x513bef
mov dword [ebx + 0x7c], 0x1e
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret 0x14