Function at 0x405160
Capabilities:
Receive data
Receive data on socket
Send data
Send data on socket
Send http request

Disassembly:
push 0xffffffffffffffff
push 0x431b8e
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x410
mov eax, dword [0x441304]
push ebx
push ebp
push esi
mov dword [esp + 0x418], eax
push edi
mov esi, ecx
mov dword [esp + 0x428], 0
call fcn.00422ef8
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x18], eax
mov ebx, dword [esp + 0x434]
mov eax, dword [esp + 0x430]
push ebx
push ecx
add eax, 0xfffffff0
mov dword [esp + 0x1c], esp
mov edi, esp
push eax
mov byte [esp + 0x434], 1
mov dword [esp + 0x1c], eax
call fcn.00401a00
add eax, 0x10
add esp, 4
mov ecx, esi
mov dword [edi], eax
call fcn.00403dd0
mov ebp, eax
or esi, 0xffffffff
cmp ebp, esi
jne 0x40523f
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
mov byte [esp + 0x428], 0
lea ecx, [eax + 0xc]
mov edx, esi
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405213
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x428], esi
lea ecx, [eax + 0xc]
mov edx, esi
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4052b9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, esi
jmp 0x40546c
mov eax, dword [esp + 0x430]
push ebx
push eax
lea ecx, [esp + 0x20]
push str.CONNECT__s:_d_HTTP_1.0_r_nUser_Agent:_t_t___________MyApp_0.1_r_n_r_n
push ecx
call fcn.004021f0
mov ebx, dword [esp + 0x28]
mov eax, dword [ebx - 0xc]
add esp, 0x10
push 0
push eax
push ebx
push ebp
call dword [sym.imp.WS2_32.dll_send]
cmp eax, esi
jne 0x4052c0
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
lea eax, [ebx - 0x10]
mov byte [esp + 0x428], 0
lea edx, [eax + 0xc]
mov ecx, esi
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x405298
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x428], esi
lea ecx, [eax + 0xc]
mov edx, esi
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4052b9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, esi
jmp 0x40546c
mov byte [esp + 0x1c], 0
xor eax, eax
mov ecx, 0xff
lea edi, [esp + 0x1d]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
call fcn.00422ef8
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0xc]
add eax, 0x10
mov dword [esp + 0x14], eax
mov edi, dword [sym.imp.WS2_32.dll_recv]
mov byte [esp + 0x428], 2
jmp 0x405300
push 0
push 0x3ff
lea eax, [esp + 0x24]
push eax
push ebp
call edi
mov esi, eax
test esi, esi
jl 0x4053db
lea eax, [esp + 0x1c]
mov byte [esp + esi + 0x1c], 0
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x405325
sub eax, edx
push eax
lea ecx, [esp + 0x20]
push ecx
lea ecx, [esp + 0x1c]
call fcn.00404220
test esi, esi
jg 0x405300
mov esi, dword [esp + 0x14]
mov eax, dword [esi - 0xc]
test eax, eax
jl 0x405369
push str.HTTP_1.0_200_Connection_established
push esi
call fcn.00414289
add esp, 8
test eax, eax
je 0x405369
sub eax, esi
cmp eax, 0xffffffff
jne 0x405400
lea eax, [esi - 0x10]
mov byte [esp + 0x428], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40538b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebx - 0x10]
mov byte [esp + 0x428], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4053ad
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x428], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4053d3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
or eax, 0xffffffff
jmp 0x40546c
push ebp
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
mov byte [esp + 0x428], 1
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jmp 0x405381
lea eax, [esi - 0x10]
mov byte [esp + 0x428], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405422
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea eax, [ebx - 0x10]
mov byte [esp + 0x428], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405444
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x428], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40546a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, ebp
mov ecx, dword [esp + 0x420]
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x41c]
call fcn.00413d31
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x41c
ret 8