Function at 0x41783d
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Initialize winsock library
Receive data
Receive data on socket
Resolve dns
Send data
Send data on socket
Send http request
Set socket configuration

Disassembly:
push ebp
sub esp, 0x5a4
lea ebp, [esp - 4]
mov eax, dword [0x4a4b60]
xor eax, ebp
mov dword [ebp + 0x5a4], eax
push 0x18
mov eax, 0x47ebf5
call fcn.00462bd7
mov eax, dword [ebp + 0x5b8]
mov ebx, dword [ebp + 0x5b0]
mov edi, dword [ebp + 0x5b4]
and dword [ebp - 0x20], 0
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x1c], eax
call fcn.004459aa
push eax
lea ecx, [ebp - 0x10]
call fcn.00402668
and dword [ebp - 4], 0
call fcn.004459aa
push eax
lea ecx, [ebp - 0x18]
call fcn.00402668
lea eax, [ebp]
push eax
mov esi, 0x101
push esi
mov byte [ebp - 4], 1
call dword [sym.imp.WSOCK32.dll_WSAStartup]
test eax, eax
je 0x4178e3
call dword [sym.imp.WSOCK32.dll_WSACleanup]
lea eax, [ebp - 0x10]
push eax
mov ecx, ebx
call fcn.004027d8
mov ecx, dword [ebp - 0x18]
add ecx, 0xfffffff0
call fcn.0040112d
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
call fcn.0040112d
mov eax, ebx
jmp 0x417a86
cmp word [ebp], si
jne 0x4178b5
push edi
call dword [sym.imp.WSOCK32.dll_inet_addr]
mov dword [ebp - 0x20], eax
cmp eax, 0xffffffff
jne 0x417901
push edi
call dword [sym.imp.WSOCK32.dll_gethostbyname]
jmp 0x41790f
push 2
push 4
lea eax, [ebp - 0x20]
push eax
call dword [sym.imp.WSOCK32.dll_gethostbyaddr]
mov esi, eax
test esi, esi
je 0x4178b5
push 6
push 1
push 2
call dword [sym.imp.WSOCK32.dll_socket]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x417a5b
push 0x485068
push str.http
call dword [sym.imp.WSOCK32.dll_getservbyname]
test eax, eax
jne 0x41794a
push 0x50
call dword [sym.imp.WSOCK32.dll_htons]
jmp 0x41794e
mov ax, word [eax + 8]
cmp dword [0x4a8c78], 0
mov word [ebp + 0x192], ax
je 0x41796b
mov ax, word [0x4a8bec]
mov word [ebp + 0x192], ax
push 2
pop eax
mov word [ebp + 0x190], ax
mov eax, dword [esi + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
mov dword [ebp + 0x194], eax
push 0x10
lea eax, [ebp + 0x190]
push eax
push ebx
call dword [sym.imp.WSOCK32.dll_connect]
cmp eax, 0xffffffff
je 0x417a54
push ecx
mov ecx, esp
mov dword [ebp - 0x24], esp
push dword [ebp - 0x1c]
call fcn.00403303
push ecx
mov ecx, esp
mov dword [ebp - 0x1c], esp
push edi
mov byte [ebp - 4], 2
call fcn.00403303
lea eax, [ebp - 0x18]
push eax
mov byte [ebp - 4], 1
call fcn.004176d7
mov esi, dword [ebp - 0x18]
lea eax, [ebp + 0x1a0]
push esi
push eax
call fcn.00461a10
add esp, 0x14
lea eax, [ebp + 0x1a0]
push 0
push eax
call fcn.00461980
pop ecx
push eax
lea eax, [ebp + 0x1a0]
push eax
push ebx
call dword [sym.imp.WSOCK32.dll_send]
cmp eax, 0xffffffff
jne 0x417a1a
push ebx
call dword [sym.imp.WSOCK32.dll_closesocket]
call dword [sym.imp.WSOCK32.dll_WSACleanup]
mov ecx, dword [ebp - 0x14]
lea eax, [ebp - 0x10]
push eax
call fcn.004027d8
lea ecx, [esi - 0x10]
jmp 0x417a73
mov esi, dword [sym.imp.WSOCK32.dll_recv]
mov edi, 0x400
jmp 0x417a42
test eax, eax
je 0x417a54
mov byte [ebp + eax + 0x1a0], 0
lea eax, [ebp + 0x1a0]
push eax
lea ecx, [ebp - 0x10]
call fcn.00402e72
push 0
push edi
lea eax, [ebp + 0x1a0]
push eax
push ebx
call esi
cmp eax, 0xffffffff
jne 0x417a27
push ebx
call dword [sym.imp.WSOCK32.dll_closesocket]
call dword [sym.imp.WSOCK32.dll_WSACleanup]
mov ecx, dword [ebp - 0x14]
lea eax, [ebp - 0x10]
push eax
call fcn.004027d8
mov ecx, dword [ebp - 0x18]
add ecx, 0xfffffff0
call fcn.0040112d
mov ecx, dword [ebp - 0x10]
add ecx, 0xfffffff0
call fcn.0040112d
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x5a4]
xor ecx, ebp
call fcn.00461b8a
add ebp, 0x5a8
leave
ret