Function at 0x4c28ac
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff004
push eax
add esp, 0xffffffd8
push ebx
push esi
xor ecx, ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x18], ecx
mov ebx, edx
lea esi, [ebp - 0x10]
xor eax, eax
push ebp
push 0x4c2b20
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 1], 0
mov eax, ebx
call fcn.00404988
cmp eax, 3
jl 0x4c2b05
lea eax, [ebp - 0x1028]
xor ecx, ecx
mov edx, 0x1000
call fcn.00403114
call fcn.004b7338
mov ecx, ebx
mov dl, 1
mov eax, dword [0x47c1a0]
call fcn.0047c254
mov dword [ebp - 8], eax
xor eax, eax
push ebp
push 0x4c2afe
push dword fs:[eax]
mov dword fs:[eax], esp
push 6
push 1
push 2
call sub.wsock32.dll_socket
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0xffffffff
jne 0x4c293e
call fcn.0040412c
jmp 0x4c2b05
mov word [ebp - 0x28], 2
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x18]
call fcn.004b7358
test al, al
je 0x4c2963
lea eax, [ebp - 0x14]
mov edx, dword [ebp - 8]
mov edx, dword [edx + 0x18]
call fcn.00404760
jmp 0x4c297f
lea edx, [ebp - 0x14]
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x18]
call fcn.004b74f4
test al, al
jne 0x4c297f
call fcn.0040412c
jmp 0x4c2b05
mov eax, dword [ebp - 0x14]
call fcn.00404b88
push eax
call sub.wsock32.dll_inet_addr
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x10]
mov edx, 0x50
call fcn.00409344
push eax
call sub.wsock32.dll_ntohs
mov word [ebp - 0x26], ax
push 0x10
lea eax, [ebp - 0x28]
push eax
mov eax, dword [ebp - 0xc]
push eax
call sub.wsock32.dll_connect
inc eax
jne 0x4c29c6
call fcn.0040412c
jmp 0x4c2b05
push 0x4c2b38
mov eax, dword [ebp - 8]
push dword [eax + 0x14]
mov eax, dword [ebp - 8]
push dword [eax + 4]
mov eax, dword [ebp - 8]
push dword [eax + 0x28]
push 0x4c2b48
lea eax, [ebp - 0x14]
mov edx, 5
call fcn.00404a48
lea eax, [ebp - 0x14]
mov edx, 0x4c2b5c
call fcn.00404990
lea eax, [ebp - 0x14]
mov edx, 0x4c2b74
call fcn.00404990
lea eax, [ebp - 0x14]
mov edx, 0x4c2b98
call fcn.00404990
push dword [ebp - 0x14]
push 0x4c2bbc
mov eax, dword [ebp - 8]
push dword [eax + 0x18]
push 0x4c2bcc
lea eax, [ebp - 0x14]
mov edx, 4
call fcn.00404a48
lea eax, [ebp - 0x14]
mov edx, 0x4c2bcc
call fcn.00404990
lea eax, [ebp - 0xc]
mov edx, dword [ebp - 0x14]
call fcn.004b7658
test al, al
jne 0x4c2a5c
call fcn.0040412c
jmp 0x4c2b05
mov dword [esi], 0x1000
lea eax, [ebp - 0x18]
call fcn.004046c8
jmp 0x4c2ab9
mov dword [esi], 0x1000
mov ecx, esi
lea edx, [ebp - 0x1028]
lea eax, [ebp - 0xc]
call fcn.004b7794
test al, al
jne 0x4c2a8d
call fcn.0040412c
jmp 0x4c2b05
lea eax, [ebp - 0x14]
mov edx, dword [esi]
call fcn.00404d14
lea eax, [ebp - 0x14]
call fcn.00404be0
mov edx, eax
lea eax, [ebp - 0x1028]
mov ecx, dword [esi]
call fcn.004029e0
lea eax, [ebp - 0x18]
mov edx, dword [ebp - 0x14]
call fcn.00404990
mov edx, dword [ebp - 0x18]
mov eax, 0x4c2bd8
call fcn.00404ccc
test eax, eax
jle 0x4c2a6c
cmp dword [ebp - 0x18], 0
je 0x4c2ad4
mov byte [ebp - 1], 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4c2b05
cmp dword [ebp - 0xc], 0xffffffff
je 0x4c2af0
mov eax, dword [ebp - 0xc]
push eax
call sub.wsock32.dll_closesocket
lea eax, [ebp - 8]
call fcn.0040eabc
call fcn.004b7350
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4c2b27
lea eax, [ebp - 0x18]
mov edx, 2
call fcn.004046ec
ret