Function at 0x4e6570
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Resolve dns
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5dda1d
mov eax, dword fs:[0]
push eax
push ecx
sub esp, 0x7c
mov eax, dword [0x65a640]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x6c], ecx
mov byte [ebp - 0x65], 0
mov dword [ebp - 4], 0
mov ecx, dword [ebp + 8]
call fcn.004076a1
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov dword [ebp - 0x70], eax
cmp dword [ebp - 0x70], 0
jne 0x4e65da
mov dword [ebp - 0x74], 9
push 0x649658
lea eax, [ebp - 0x74]
push eax
call fcn.005458a4
xor ecx, ecx
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x18], ecx
mov edx, 1
imul eax, edx, 3
mov ecx, 4
imul edx, ecx, 0
mov ecx, dword [ebp - 0x70]
mov ecx, dword [ecx + 0xc]
mov edx, dword [ecx + edx]
movsx eax, byte [edx + eax]
and eax, 0xff
push eax
mov ecx, 1
shl ecx, 1
mov edx, 4
imul eax, edx, 0
mov edx, dword [ebp - 0x70]
mov edx, dword [edx + 0xc]
mov eax, dword [edx + eax]
movsx ecx, byte [eax + ecx]
and ecx, 0xff
push ecx
mov edx, 1
shl edx, 0
mov eax, 4
imul ecx, eax, 0
mov eax, dword [ebp - 0x70]
mov eax, dword [eax + 0xc]
mov ecx, dword [eax + ecx]
movsx edx, byte [ecx + edx]
and edx, 0xff
push edx
mov eax, 1
imul ecx, eax, 0
mov edx, 4
imul eax, edx, 0
mov edx, dword [ebp - 0x70]
mov edx, dword [edx + 0xc]
mov eax, dword [edx + eax]
movsx ecx, byte [eax + ecx]
and ecx, 0xff
push ecx
push 0x5f8094
lea edx, [ebp - 0x24]
push edx
call fcn.004e4d20
add esp, 0x18
lea eax, [ebp - 0x24]
push eax
lea ecx, [ebp - 0x4c]
call fcn.004077a2
mov dword [ebp - 0x88], eax
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x4c]
push ecx
lea edx, [ebp - 0x64]
push edx
call fcn.004e4e90
add esp, 8
mov dword [ebp - 0x78], eax
mov eax, dword [ebp - 0x78]
push eax
mov ecx, dword [ebp - 0x6c]
add ecx, 0xc
call fcn.0040302c
lea ecx, [ebp - 0x64]
call fcn.00403027
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x4c]
call fcn.0040772f
mov ecx, dword [ebp - 0x6c]
cmp dword [ecx + 8], 0xffffffff
je 0x4e66e9
mov edx, dword [ebp - 0x6c]
mov eax, dword [edx + 8]
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov ecx, dword [ebp - 0x6c]
mov dword [ecx + 8], eax
mov edx, dword [ebp - 0x6c]
cmp dword [edx + 8], 0xffffffff
jne 0x4e6719
mov dword [ebp - 0x7c], 0xa
push 0x649658
lea eax, [ebp - 0x7c]
push eax
call fcn.005458a4
mov dword [ebp - 0x80], 0x2710
push 4
lea ecx, [ebp - 0x80]
push ecx
push 0x1006
push 0xffff
mov edx, dword [ebp - 0x6c]
mov eax, dword [edx + 8]
push eax
call dword [sym.imp.WS2_32.dll_setsockopt]
mov ecx, 2
mov word [ebp - 0x34], cx
movzx edx, word [ebp + 0xc]
push edx
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x32], ax
lea eax, [ebp - 0x24]
push eax
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [ebp - 0x30], eax
push 0x10
lea ecx, [ebp - 0x34]
push ecx
mov edx, dword [ebp - 0x6c]
mov eax, dword [edx + 8]
push eax
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x4e6795
mov dword [ebp - 0x84], 2
push 0x649658
lea ecx, [ebp - 0x84]
push ecx
call fcn.005458a4
mov byte [ebp - 0x65], 1
jmp 0x4e67b6
mov dword [ebp - 4], 0xffffffff
jmp 0x4e67c8
jmp 0x4e67d1
mov al, byte [ebp - 0x65]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0052ef51
mov esp, ebp
pop ebp
ret 8