Function at 0x481490
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Initialize winsock library
Read .ini file
Read and send data from client to server
Receive data
Receive data on socket
Send data
Send data on socket
Send http request
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x53b240
mov eax, dword fs:[0]
push eax
mov eax, 0x2a5c
call fcn.004b0a90
mov eax, dword [0x58c758]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 4], 0
mov dword [ebp - 0x2798], 0x50
xor eax, eax
mov word [ebp - 0x814], ax
push 0x7fe
push 0
lea ecx, [ebp - 0x812]
push ecx
call fcn.004b0ac0
add esp, 0xc
push 0x540e68
lea edx, [ebp - 0x2778]
push edx
call fcn.0041acc0
add esp, 8
mov byte [ebp - 4], 1
mov dword [ebp - 0x2790], 0
movzx eax, byte [0x58fc30]
test eax, eax
jne 0x481588
mov ecx, 0x202
mov word [ebp - 0x2930], cx
lea edx, [ebp - 0x292c]
push edx
movzx eax, word [ebp - 0x2930]
push eax
call dword [sym.imp.WS2_32.dll_WSAStartup]
mov dword [ebp - 0x2934], eax
cmp dword [ebp - 0x2934], 0
je 0x481581
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x2938], eax
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2778]
call fcn.00401eb0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401eb0
mov eax, dword [ebp - 0x2938]
jmp 0x481a8e
mov byte [0x58fc30], 1
lea ecx, [ebp - 0x2778]
call fcn.0043e290
push eax
push 0
push str.port
push str.proxy
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
mov dword [ebp - 0x2798], eax
lea ecx, [ebp - 0x2778]
call fcn.0043e290
push eax
push 0x3ff
lea ecx, [ebp - 0x814]
push ecx
push 0x540868
push 0x540e40
push str.proxy
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringW]
cmp dword [ebp - 0x2798], 0
je 0x4815f5
lea edx, [ebp - 0x814]
push edx
call fcn.004b0eb7
add esp, 4
test eax, eax
jne 0x481628
mov dword [ebp - 0x293c], 1
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2778]
call fcn.00401eb0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401eb0
mov eax, dword [ebp - 0x293c]
jmp 0x481a8e
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov dword [ebp - 0x2770], eax
cmp dword [ebp - 0x2770], 0xffffffff
jne 0x481678
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x2940], eax
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2778]
call fcn.00401eb0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401eb0
mov eax, dword [ebp - 0x2940]
jmp 0x481a8e
mov eax, 2
mov word [ebp - 0x278c], ax
lea ecx, [ebp - 0x814]
push ecx
lea ecx, [ebp - 0x29c4]
call fcn.004087b0
mov dword [ebp - 0x2a60], eax
mov ecx, dword [ebp - 0x2a60]
call fcn.0043e290
push eax
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [ebp - 0x2788], eax
lea ecx, [ebp - 0x29c4]
call fcn.004087e0
movzx edx, word [ebp - 0x2798]
push edx
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x278a], ax
mov dword [ebp - 0x2774], 0x2710
push 4
lea eax, [ebp - 0x2774]
push eax
push 0x1005
push 0xffff
mov ecx, dword [ebp - 0x2770]
push ecx
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jne 0x481726
push 4
lea edx, [ebp - 0x2774]
push edx
push 0x1006
push 0xffff
mov eax, dword [ebp - 0x2770]
push eax
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
je 0x481774
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x2790], eax
mov ecx, dword [ebp - 0x2770]
push ecx
call dword [sym.imp.WS2_32.dll_closesocket]
mov edx, dword [ebp - 0x2790]
mov dword [ebp - 0x29c8], edx
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2778]
call fcn.00401eb0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401eb0
mov eax, dword [ebp - 0x29c8]
jmp 0x481a8e
push 0x10
lea eax, [ebp - 0x278c]
push eax
mov ecx, dword [ebp - 0x2770]
push ecx
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x4817dd
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x2790], eax
mov edx, dword [ebp - 0x2770]
push edx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebp - 0x2790]
mov dword [ebp - 0x29cc], eax
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2778]
call fcn.00401eb0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401eb0
mov eax, dword [ebp - 0x29cc]
jmp 0x481a8e
lea ecx, [ebp - 0x2794]
call fcn.00403840
mov byte [ebp - 4], 2
mov ecx, dword [ebp + 8]
push ecx
push str.GET__s_HTTP_1.1_r_n_r_n
lea edx, [ebp - 0x2794]
push edx
call fcn.00409170
add esp, 0xc
lea ecx, [ebp - 0x2794]
call fcn.0043e290
push eax
lea ecx, [ebp - 0x2a50]
call fcn.004087b0
mov dword [ebp - 0x2a64], eax
mov eax, dword [ebp - 0x2a64]
mov dword [ebp - 0x2a68], eax
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x2a68]
call fcn.0043e290
push eax
lea ecx, [ebp - 0x277c]
call fcn.00408660
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x2a50]
call fcn.004087e0
push 0
lea ecx, [ebp - 0x277c]
call fcn.004086e0
push eax
lea ecx, [ebp - 0x277c]
call fcn.0043e290
push eax
mov ecx, dword [ebp - 0x2770]
push ecx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
jne 0x4818ef
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x2790], eax
mov edx, dword [ebp - 0x2770]
push edx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebp - 0x2790]
mov dword [ebp - 0x2a54], eax
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x277c]
call fcn.00401eb0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2794]
call fcn.00401eb0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2778]
call fcn.00401eb0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401eb0
mov eax, dword [ebp - 0x2a54]
jmp 0x481a8e
mov byte [ebp - 0x276c], 0
push 0x1f57
push 0
lea ecx, [ebp - 0x276b]
push ecx
call fcn.004b0ac0
add esp, 0xc
push 0
push 0x1f58
lea edx, [ebp - 0x276c]
push edx
mov eax, dword [ebp - 0x2770]
push eax
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
jne 0x481998
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x2790], eax
mov ecx, dword [ebp - 0x2770]
push ecx
call dword [sym.imp.WS2_32.dll_closesocket]
mov edx, dword [ebp - 0x2790]
mov dword [ebp - 0x2a58], edx
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x277c]
call fcn.00401eb0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2794]
call fcn.00401eb0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2778]
call fcn.00401eb0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401eb0
mov eax, dword [ebp - 0x2a58]
jmp 0x481a8e
lea eax, [ebp - 0x276c]
push eax
call fcn.004b1d80
add esp, 4
test eax, eax
je 0x4819f0
cmp dword [ebp + 0xc], 0
je 0x4819f0
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x4819f0
push 0x542000
lea edx, [ebp - 0x276c]
push edx
call fcn.00408640
add esp, 8
test eax, eax
je 0x4819f0
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
lea edx, [ebp - 0x276c]
push edx
call fcn.00480760
add esp, 0xc
jmp 0x481a33
lea eax, [ebp - 0x276c]
push eax
call fcn.004b1d80
add esp, 4
test eax, eax
je 0x481a27
push 0x542000
lea ecx, [ebp - 0x276c]
push ecx
call fcn.00408640
add esp, 8
test eax, eax
jne 0x481a27
mov dword [ebp - 0x2790], 2
jmp 0x481a33
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x2790], eax
mov edx, dword [ebp - 0x2770]
push edx
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebp - 0x2790]
mov dword [ebp - 0x2a5c], eax
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x277c]
call fcn.00401eb0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2794]
call fcn.00401eb0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2778]
call fcn.00401eb0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 8]
call fcn.00401eb0
mov eax, dword [ebp - 0x2a5c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004b0a79
mov esp, ebp
pop ebp
ret