Function at 0x4096cf
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Receive data
Receive data on socket
Reference http user-agent string
Resolve dns
Send data
Send data on socket
Send http request
Send http request with host header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x93c
mov eax, dword [0x439030]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x934], eax
push edi
test esi, esi
je 0x409ad4
xor ebx, ebx
mov dword [ebp - 0x930], ebx
push 0x7f
lea eax, [ebp - 0x117]
mov byte [ebp - 0x118], bl
push ebx
push eax
call fcn.0041ba00
push 0x50
pop ebx
push 0x433380
push esi
call fcn.00419900
mov edi, eax
add esp, 0x14
test edi, edi
je 0x409ace
sub eax, esi
push eax
push esi
lea eax, [ebp - 0x118]
push 0x80
push eax
call fcn.0041a3cc
lea eax, [ebp - 0x118]
push str.http
push eax
call fcn.00419f8e
add esp, 0x18
test eax, eax
jne 0x409ace
add edi, 3
push 0x2f
push edi
call fcn.0041a070
push 0x80
mov dword [ebp - 0x938], eax
lea eax, [ebp - 0x118]
push 0
push eax
call fcn.0041ba00
mov eax, dword [ebp - 0x938]
sub eax, edi
push eax
push edi
lea eax, [ebp - 0x118]
push 0x80
push eax
call fcn.0041a3cc
lea eax, [ebp - 0x118]
push 0x3a
push eax
call fcn.0041a070
mov ecx, eax
mov byte [ebp - 0x2c], 0
xor eax, eax
lea edi, [ebp - 0x2b]
stosd dword es:[edi], eax
add esp, 0x2c
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
test ecx, ecx
je 0x409802
mov eax, ecx
lea edx, [ebp - 0x118]
sub eax, edx
cmp eax, 0x80
jae 0x409aec
mov byte [ebp + eax - 0x118], 0
lea eax, [ecx + 1]
push eax
lea eax, [ebp - 0x2c]
push 0x14
push eax
call fcn.004198a4
lea eax, [ebp - 0x2c]
push eax
call fcn.0041a3af
add esp, 0x10
mov ebx, eax
xor eax, eax
mov byte [ebp - 0x18], 0
lea edi, [ebp - 0x17]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
cmp ebx, 0x50
je 0x409833
lea eax, [ebx - 1]
cmp eax, 0xfffe
ja 0x409833
push ebx
lea eax, [ebp - 0x18]
push 0x43338c
push eax
call fcn.0040a4b8
add esp, 0xc
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
push 2
mov edi, eax
pop eax
push ebx
mov dword [ebp - 0x92c], edi
mov word [ebp - 0x928], ax
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x926], ax
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov ecx, eax
test ecx, ecx
jne 0x409881
lea eax, [ebp - 0x118]
push eax
call dword [sym.imp.WS2_32.dll_inet_addr]
jmp 0x4098a0
movsx eax, word [ecx + 0xa]
push eax
mov eax, dword [ecx + 0xc]
push dword [eax]
lea eax, [ebp - 0x93c]
push eax
call fcn.0041a850
mov eax, dword [ebp - 0x93c]
add esp, 0xc
mov dword [ebp - 0x924], eax
lea eax, [ebp - 0x928]
push 0x10
push eax
push edi
call dword [sym.imp.WS2_32.dll_connect]
xor ebx, ebx
lea eax, [ebp - 0x917]
push 0x3ff
push ebx
push eax
mov byte [ebp - 0x918], bl
call fcn.0041ba00
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x118]
push eax
push dword [ebp - 0x938]
lea eax, [ebp - 0x918]
push str.GET__s_HTTP_1.1_r_nHost:__s_s_r_nAccept:__r_nUser_Agent:_Mozilla_5.0__compatible__MSIE_9.0__Windows_NT_6.1__WOW64__Trident_5.0__r_nConnection:close_r_nCache_Control:_no_cache_r_n_r_n
push eax
call fcn.0040a4d1
lea ecx, [ebp - 0x918]
add esp, 0x20
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4098fe
push ebx
sub ecx, edx
lea eax, [ebp - 0x918]
push ecx
push eax
push edi
call dword [sym.imp.WS2_32.dll_send]
push 0x3ff
lea eax, [ebp - 0x517]
mov byte [ebp - 0x518], bl
push ebx
push eax
call fcn.0041ba00
add esp, 0xc
lea eax, [ebp - 0x518]
push ebx
push 0x400
push eax
push edi
call dword [sym.imp.WS2_32.dll_recv]
push ecx
mov edi, eax
lea eax, [ebp - 0x518]
push esi
push eax
call fcn.00409af2
cmp eax, 0xffffffff
je 0x409ab9
cmp eax, 0xfffffffe
je 0x409701
push 0x63
lea eax, [ebp - 0x97]
mov byte [ebp - 0x98], bl
push ebx
push eax
call fcn.0041ba00
lea eax, [ebp - 0x518]
push str.Content_Length:
push eax
call fcn.00419900
add esp, 0x14
test eax, eax
je 0x409a07
add eax, 0xf
mov cl, byte [eax]
test cl, cl
je 0x409a1d
cmp cl, 0xd
je 0x4099b4
lea edx, [ebp - 0x98]
mov byte [edx], cl
inc edx
inc eax
mov cl, byte [eax]
cmp cl, 0xd
jne 0x4099a9
cmp byte [ebp - 0x98], 0x20
lea ecx, [ebp - 0x98]
jne 0x4099c9
inc ecx
cmp byte [ecx], 0x20
je 0x4099c3
lea edx, [ebp - 0x98]
sub edx, ecx
mov al, byte [ecx]
mov byte [edx + ecx], al
inc ecx
test al, al
jne 0x4099d1
lea ecx, [ebp - 0x98]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4099e4
sub ecx, edx
jmp 0x4099f3
test ecx, ecx
js 0x4099fe
dec ecx
cmp byte [ebp + ecx - 0x98], 0x20
je 0x4099ef
mov byte [ebp + ecx - 0x97], bl
jmp 0x409a1d
push str.102400
lea eax, [ebp - 0x98]
push 0x64
push eax
call fcn.004198a4
add esp, 0xc
lea eax, [ebp - 0x98]
push eax
call fcn.0041a3af
mov ebx, eax
pop ecx
cmp ebx, 1
jb 0x409ab9
lea eax, [ebx + 1]
push eax
call fcn.00417e2e
mov esi, eax
pop ecx
test esi, esi
je 0x409ab9
mov eax, dword [ebp - 0x934]
push str._r_n_r_n
mov dword [eax], esi
lea eax, [ebp - 0x518]
push eax
call fcn.00419900
pop ecx
pop ecx
mov ecx, eax
test ecx, ecx
je 0x409ab9
add ecx, 4
lea eax, [ebp - 0x518]
sub eax, ecx
add edi, eax
push edi
push ecx
push esi
call fcn.0041a850
add esi, edi
mov dword [ebp - 0x930], edi
add esp, 0xc
cmp edi, ebx
mov edi, dword [ebp - 0x92c]
jae 0x409abf
push 0
push 0x400
push esi
push edi
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
jle 0x409abf
mov ecx, dword [ebp - 0x930]
add esi, eax
add ecx, eax
mov dword [ebp - 0x930], ecx
cmp ecx, ebx
jb 0x409a90
jmp 0x409abf
mov edi, dword [ebp - 0x92c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebp - 0x930]
jmp 0x409ad9
mov eax, dword [ebp - 0x934]
and dword [eax], 0
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0041813f
mov esp, ebp
pop ebp
ret 8
call fcn.0041a2d3
int3