Function at 0x406790
Capabilities:
Get local ipv4 addresses
Get socket information
Receive data
Receive data on socket
Receive http request
Send data
Send data on socket
Send http request
Send http request with host header
Send http response

Disassembly:
push edi
mov eax, 0x12e8
lea edi, [esp + 8]
and esp, 0xfffffff8
push dword [edi - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
call fcn.0040f5e0
mov ecx, 0x48
sub esp, eax
lea edi, [ebp - 0x1130]
lea ebx, [ebp - 0x1010]
xor eax, eax
rep stosd dword es:[edi], eax
mov dword [esp + 0xc], 0
mov edi, ebx
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 0
call dword [sym.imp.kernel32.dll_CreateEventA]
mov ecx, 0x200
mov esi, dword [0x413108]
mov dword [ebp - 0x1260], eax
mov eax, 0xcccccccc
sub esp, 0x10
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x1298]
mov dword [esp], esi
mov dword [esp + 8], 0
mov dword [esp + 4], eax
call dword [0x42501c]
sub esp, 0xc
mov edi, eax
mov eax, 0x63f
call fcn.00401190
xor eax, eax
test edi, edi
mov dword [esp + 8], edi
sete al
mov dword [esp + 4], str.Failed_to_create_session__error__u._n
mov dword [esp], eax
call fcn.00401af0
lea eax, [ebp - 0x1290]
mov dword [esp + 0xc], 0
mov dword [esp + 8], eax
mov edx, dword [ebp - 0x1294]
mov eax, dword [ebp - 0x1298]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425014]
sub esp, 0x10
mov edi, eax
mov eax, 0x641
call fcn.00401190
xor eax, eax
test edi, edi
mov dword [esp + 8], edi
sete al
mov dword [esp + 4], str.Failed_to_create_URL_group__error__u._n
mov dword [esp], eax
call fcn.00401af0
lea eax, [ebp - 0x12a0]
mov dword [esp], esi
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
call dword [0x425018]
sub esp, 0x14
mov esi, eax
mov eax, 0x643
call fcn.00401190
xor eax, eax
test esi, esi
mov dword [esp + 8], esi
sete al
mov dword [esp + 4], str.Failed_to_create_request_queue__error__u._n
mov dword [esp], eax
call fcn.00401af0
mov eax, dword [ebp - 0x12a0]
or byte [ebp - 0x1288], 1
mov dword [ebp - 0x1284], eax
lea eax, [ebp - 0x1288]
mov dword [esp + 0x10], 8
mov dword [esp + 0xc], eax
mov dword [esp + 8], 7
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425000]
sub esp, 0x14
mov esi, eax
mov eax, 0x647
call fcn.00401190
xor eax, eax
test esi, esi
mov dword [esp + 8], esi
sete al
mov dword [esp + 4], str.Failed_to_bind_request_queue__error__u._n
mov dword [esp], eax
call fcn.00401af0
mov edi, dword [sym.imp.httpapi.dll_HttpReceiveHttpRequest]
lea eax, [ebp - 0x1270]
mov dword [esp + 0x18], 0
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], 0x800
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0
mov dword [esp + 8], 0
mov dword [esp], 0
mov dword [ebp - 0x12c4], edi
call edi
sub esp, 0x20
mov esi, eax
mov eax, 0x64a
call fcn.00401190
xor eax, eax
cmp esi, 6
mov dword [esp + 8], esi
sete al
mov dword [esp + 4], str.Got_error__u._n
mov dword [esp], eax
call fcn.00401af0
lea eax, [ebp - 0x1270]
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x800
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0xdeadbeef
mov dword [esp + 8], 0
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
call edi
sub esp, 0x20
mov esi, eax
mov eax, 0x64c
call fcn.00401190
xor eax, eax
cmp esi, 0x4cd
mov dword [esp + 8], esi
sete al
mov dword [esp + 4], str.Got_error__u._n
mov dword [esp], eax
call fcn.00401af0
lea eax, [ebp - 0x1270]
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x800
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0
mov dword [esp + 8], 0
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
call edi
sub esp, 0x20
mov esi, eax
mov eax, 0x64e
call fcn.00401190
xor eax, eax
cmp esi, 0x3e5
mov dword [esp + 8], esi
sete al
mov dword [esp + 4], str.Got_error__u._n
mov dword [esp], eax
mov esi, dword fs:[0x18]
call fcn.00401af0
lea eax, [ebp - 0x12a4]
mov dword [esi + 0x34], 0xdeadbeef
mov dword [esp + 8], eax
lea eax, [ebp - 0x1270]
mov dword [esp + 0xc], 0
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
mov eax, dword [sym.imp.kernel32.dll_GetOverlappedResult]
mov dword [ebp - 0x12bc], eax
call eax
sub esp, 0x10
mov edi, eax
mov eax, 0x652
call fcn.00401190
xor eax, eax
test edi, edi
mov dword [esp + 4], str.Expected_failure._n
sete al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x653
call fcn.00401190
mov eax, dword [esi + 0x34]
mov dword [esp + 4], str.Got_error__lu._n
mov dword [esp + 8], eax
xor eax, eax
cmp dword [esi + 0x34], 0x3e4
sete al
mov dword [esp], eax
call fcn.00401af0
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
call fcn.004065f0
mov word [ebp - 0x12b0], ax
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], 0xdeadbeef
mov dword [esp + 0x10], 0
mov dword [esp + 8], str.http:__localhost:50000
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425020]
mov edi, dword [0x425070]
sub esp, 0x18
mov esi, eax
call fcn.0040ded0
mov ecx, dword [eax + 0x10]
mov dword [eax + 0x14], 1
lea edx, [ecx + ecx]
xor ecx, ecx
test edi, edi
setne cl
or edx, ecx
mov dword [eax + 0x10], edx
jmp 0x406c06
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x658
xor eax, eax
cmp esi, 0x57
sete al
mov dword [esp + 8], esi
mov dword [esp], eax
mov dword [esp + 4], str.Got_error__u._n
call fcn.00401af0
call fcn.0040ded0
shr dword [eax + 0x10], 1
call fcn.0040ded0
mov edx, dword [eax + 0x14]
mov dword [eax + 0x14], 0
test edx, edx
jne 0x406bd0
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], 0xdeadbeef
mov dword [esp + 0x10], 0
mov dword [esp + 8], str.localhost:50000
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425020]
mov edi, dword [0x425070]
sub esp, 0x18
mov esi, eax
call fcn.0040ded0
mov ecx, dword [eax + 0x10]
mov dword [eax + 0x14], 1
lea edx, [ecx + ecx]
xor ecx, ecx
test edi, edi
setne cl
or edx, ecx
mov dword [eax + 0x10], edx
jmp 0x406cb6
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x65a
xor eax, eax
cmp esi, 0x57
sete al
mov dword [esp + 8], esi
mov dword [esp], eax
mov dword [esp + 4], str.Got_error__u._n
call fcn.00401af0
call fcn.0040ded0
shr dword [eax + 0x10], 1
call fcn.0040ded0
mov edx, dword [eax + 0x14]
mov dword [eax + 0x14], 0
test edx, edx
jne 0x406c80
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], 0xdeadbeef
mov dword [esp + 0x10], 0
mov dword [esp + 8], str.localhost:50000_
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425020]
mov edi, dword [0x425070]
sub esp, 0x18
mov esi, eax
call fcn.0040ded0
mov ecx, dword [eax + 0x10]
mov dword [eax + 0x14], 1
lea edx, [ecx + ecx]
xor ecx, ecx
test edi, edi
setne cl
or edx, ecx
mov dword [eax + 0x10], edx
jmp 0x406d66
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x65c
xor eax, eax
cmp esi, 0x57
sete al
mov dword [esp + 8], esi
mov dword [esp], eax
mov dword [esp + 4], str.Got_error__u._n
call fcn.00401af0
call fcn.0040ded0
shr dword [eax + 0x10], 1
call fcn.0040ded0
mov edx, dword [eax + 0x14]
mov dword [eax + 0x14], 0
test edx, edx
jne 0x406d30
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], 0xdeadbeef
mov dword [esp + 0x10], 0
mov dword [esp + 8], str.http:__localhost_
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425020]
mov edi, dword [0x425070]
sub esp, 0x18
mov esi, eax
call fcn.0040ded0
mov ecx, dword [eax + 0x10]
mov dword [eax + 0x14], 1
lea edx, [ecx + ecx]
xor ecx, ecx
test edi, edi
setne cl
or edx, ecx
mov dword [eax + 0x10], edx
jmp 0x406e16
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x65e
xor eax, eax
cmp esi, 0x57
sete al
mov dword [esp + 8], esi
mov dword [esp], eax
mov dword [esp + 4], str.Got_error__u._n
call fcn.00401af0
call fcn.0040ded0
shr dword [eax + 0x10], 1
call fcn.0040ded0
mov edx, dword [eax + 0x14]
mov dword [eax + 0x14], 0
test edx, edx
jne 0x406de0
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], 0xdeadbeef
mov dword [esp + 0x10], 0
mov dword [esp + 8], str.http:__localhost:_
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425020]
mov edi, dword [0x425070]
sub esp, 0x18
mov esi, eax
call fcn.0040ded0
mov ecx, dword [eax + 0x10]
mov dword [eax + 0x14], 1
lea edx, [ecx + ecx]
xor ecx, ecx
test edi, edi
setne cl
or edx, ecx
mov dword [eax + 0x10], edx
jmp 0x406ec6
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x660
xor eax, eax
cmp esi, 0x57
sete al
mov dword [esp + 8], esi
mov dword [esp], eax
mov dword [esp + 4], str.Got_error__u._n
call fcn.00401af0
call fcn.0040ded0
shr dword [eax + 0x10], 1
call fcn.0040ded0
mov edx, dword [eax + 0x14]
mov dword [eax + 0x14], 0
test edx, edx
jne 0x406e90
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], 0xdeadbeef
mov dword [esp + 0x10], 0
mov dword [esp + 8], str.http:__localhost:0_
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425020]
mov edi, dword [0x425070]
sub esp, 0x18
mov esi, eax
call fcn.0040ded0
mov ecx, dword [eax + 0x10]
mov dword [eax + 0x14], 1
lea edx, [ecx + ecx]
xor ecx, ecx
test edi, edi
setne cl
or edx, ecx
mov dword [eax + 0x10], edx
jmp 0x406f76
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x662
xor eax, eax
cmp esi, 0x57
sete al
mov dword [esp + 8], esi
mov dword [esp], eax
mov dword [esp + 4], str.Got_error__u._n
call fcn.00401af0
call fcn.0040ded0
shr dword [eax + 0x10], 1
call fcn.0040ded0
mov edx, dword [eax + 0x14]
mov dword [eax + 0x14], 0
test edx, edx
jne 0x406f40
movzx eax, word [ebp - 0x12b0]
lea edi, [ebp - 0x125c]
mov dword [ebp - 0x12ac], eax
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0x4121d4
mov dword [esp + 4], 0x32
mov dword [esp], edi
call fcn.00401400
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], 0xdeadbeef
mov dword [esp + 0x10], 0
mov dword [esp + 8], edi
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425020]
mov ecx, dword [0x425070]
sub esp, 0x18
mov esi, eax
mov dword [ebp - 0x12a8], ecx
call fcn.0040ded0
mov ecx, dword [eax + 0x10]
mov dword [eax + 0x14], 1
lea edx, [ecx + ecx]
mov ecx, dword [ebp - 0x12a8]
test ecx, ecx
setne cl
movzx ecx, cl
or edx, ecx
mov dword [eax + 0x10], edx
jmp 0x407061
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x665
xor eax, eax
cmp esi, 0xb7
sete al
mov dword [esp + 8], esi
mov dword [esp], eax
mov dword [esp + 4], str.Got_error__u._n
call fcn.00401af0
call fcn.0040ded0
shr dword [eax + 0x10], 1
call fcn.0040ded0
mov edx, dword [eax + 0x14]
mov dword [eax + 0x14], 0
test edx, edx
jne 0x407028
mov eax, dword [ebp - 0x12ac]
lea esi, [ebp - 0x1280]
call fcn.00401b10
mov dword [ebp - 0x129c], 0x10
mov ecx, eax
lea eax, [ebp - 0x129c]
mov dword [esp + 4], esi
mov dword [esp + 8], eax
mov dword [ebp - 0x12b8], ecx
mov dword [esp], ecx
call dword [sym.imp.ws2_32.dll_getsockname]
sub esp, 0xc
mov esi, eax
mov eax, 0x66a
call fcn.00401190
call dword [sym.imp.ws2_32.dll_WSAGetLastError]
mov dword [esp + 4], str.getsockname___failed__error__u._n
mov dword [esp + 8], eax
xor eax, eax
test esi, esi
sete al
mov dword [esp], eax
mov esi, dword fs:[0x18]
call fcn.00401af0
lea edx, [ebp - 0x12a4]
mov dword [esi + 0x34], 0xdeadbeef
mov dword [esp + 8], edx
lea edx, [ebp - 0x1270]
mov dword [esp + 0xc], 0
mov dword [esp + 4], edx
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
mov edx, dword [ebp - 0x12bc]
call edx
sub esp, 0x10
mov dword [ebp - 0x12a8], eax
mov eax, 0x66e
call fcn.00401190
mov dword [esp + 4], str.Expected_failure._n
xor eax, eax
mov edx, dword [ebp - 0x12a8]
test edx, edx
sete al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x66f
call fcn.00401190
mov eax, dword [esi + 0x34]
mov dword [esp + 4], str.Got_error__lu._n
mov dword [esp + 8], eax
xor eax, eax
cmp dword [esi + 0x34], 0x3e4
sete al
mov dword [esp], eax
call fcn.00401af0
mov eax, dword [ebp - 0x12ac]
mov dword [esp + 4], str.GET__foobar_HTTP_1.1_r_nHost:_localhost:_u_r_nConnection:_keep_alive_r_nUser_Agent:_WINE_r_n_r_n
mov dword [esp + 8], eax
lea eax, [ebp - 0x1194]
mov dword [esp], eax
call fcn.00401040
lea eax, [ebp - 0x1194]
mov dword [esp], eax
mov eax, dword [sym.imp.msvcrt.dll_strlen]
mov dword [ebp - 0x12b4], eax
call eax
lea edx, [ebp - 0x1194]
mov dword [esp + 0xc], 0
mov dword [esp + 4], edx
mov dword [esp + 8], eax
mov ecx, dword [ebp - 0x12b8]
mov dword [esp], ecx
call dword [sym.imp.ws2_32.dll_send]
sub esp, 0x10
mov dword [ebp - 0x12a8], eax
mov eax, 0x673
call fcn.00401190
lea ecx, [ebp - 0x1194]
mov dword [esp], ecx
mov eax, dword [ebp - 0x12b4]
call eax
mov edx, dword [ebp - 0x12a8]
mov dword [esp + 4], str.send___returned__d._n
cmp edx, eax
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov dword [esp + 4], 0x64
mov eax, dword [ebp - 0x1260]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_WaitForSingleObject]
sub esp, 8
mov dword [ebp - 0x12a8], eax
mov eax, 0x676
call fcn.00401190
mov edx, dword [ebp - 0x12a8]
xor eax, eax
mov dword [esp + 4], str.Got__u._n
test edx, edx
mov dword [esp + 8], edx
sete al
mov dword [esp], eax
call fcn.00401af0
mov dword [esp], 0x64
call dword [sym.imp.kernel32.dll_Sleep]
lea eax, [ebp - 0x12a4]
sub esp, 4
mov dword [esp + 8], eax
lea eax, [ebp - 0x1270]
mov dword [esp + 0xc], 1
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
mov edx, dword [ebp - 0x12bc]
call edx
sub esp, 0x10
mov dword [ebp - 0x12a8], eax
mov eax, 0x67b
call fcn.00401190
mov eax, dword [esi + 0x34]
mov dword [esp + 4], str.Got_error__lu._n
mov dword [esp + 8], eax
mov edx, dword [ebp - 0x12a8]
mov dword [esp], edx
call fcn.00401af0
mov eax, 0x67c
call fcn.00401190
mov eax, dword [ebp - 0x12a4]
mov dword [esp + 4], str.Got_size__lu._n
cmp eax, 0x1d0
mov dword [esp + 8], eax
seta al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x67e
call fcn.00401190
mov eax, dword [ebp - 0x1010]
mov dword [esp + 4], str.Got_flags__lx._n
test eax, eax
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x67f
call fcn.00401190
mov dword [esp + 4], str.Expected_nonzero_connection_ID._n
mov eax, dword [ebp - 0x1008]
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x680
call fcn.00401190
mov dword [esp + 4], str.Expected_nonzero_connection_ID._n
mov eax, dword [ebp - 0x1000]
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x681
call fcn.00401190
mov eax, dword [ebp - 0xff4]
mov edx, dword [ebp - 0xff8]
test eax, eax
je 0x4080e0
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], str._lx_08lx
call fcn.00401000
mov dword [esp + 8], eax
mov dword [esp + 4], str.Got_URL_context__s._n
mov eax, dword [ebp - 0xff8]
mov edx, dword [ebp - 0xff4]
xor eax, 0xdeadbeef
or eax, edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x682
call fcn.00401190
movzx edx, word [ebp - 0xff0]
mov dword [esp + 4], str.Got_major_version__u._n
cmp dx, 1
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x683
call fcn.00401190
movzx edx, word [ebp - 0xfee]
mov dword [esp + 4], str.Got_major_version__u._n
cmp dx, 1
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x684
call fcn.00401190
mov eax, dword [ebp - 0xfec]
mov dword [esp + 4], str.Got_verb__u._n
cmp eax, 4
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x685
call fcn.00401190
movzx edx, word [ebp - 0xfe8]
mov dword [esp + 4], str.Got_unknown_verb_length__u._n
test dx, dx
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x686
call fcn.00401190
movzx edx, word [ebp - 0xfe6]
mov dword [esp + 4], str.Got_raw_URL_length__u._n
cmp dx, 7
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x687
call fcn.00401190
mov eax, dword [ebp - 0xfe4]
mov dword [esp + 4], str.Got_unknown_verb__s._n
test eax, eax
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x688
call fcn.00401190
mov esi, dword [ebp - 0xfe0]
mov eax, dword [sym.imp.msvcrt.dll_strcmp]
mov dword [esp + 4], str._foobar
mov dword [esp], esi
mov dword [ebp - 0x12a8], eax
call eax
mov dword [esp + 8], esi
test eax, eax
mov dword [esp + 4], str.Got_raw_URL__s._n
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x689
call fcn.00401190
movzx edx, word [ebp - 0xfdc]
mov dword [esp + 4], str.Got_full_URL_length__u._n
cmp dx, 0x3a
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x68a
call fcn.00401190
movzx edx, word [ebp - 0xfda]
mov dword [esp + 4], str.Got_host_length__u._n
cmp dx, 0x1e
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x68b
call fcn.00401190
movzx edx, word [ebp - 0xfd8]
mov dword [esp + 4], str.Got_absolute_path_length__u._n
cmp dx, 0xe
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x68c
call fcn.00401190
movzx edx, word [ebp - 0xfd6]
mov dword [esp + 4], str.Got_query_string_length__u._n
test dx, dx
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, dword [ebp - 0x12ac]
mov dword [esp], edi
mov dword [esp + 8], str.http:__localhost:_u_foobar
mov dword [esp + 0xc], eax
mov dword [esp + 4], 0x32
call fcn.00401400
mov eax, 0x68e
call fcn.00401190
mov eax, dword [ebp - 0xfd4]
call fcn.00401390
mov esi, eax
mov eax, edi
shr eax, 0x10
je 0x40810f
mov dword [esp + 4], 0xffffffff
mov dword [esp], edi
call dword [sym.imp.kernel32.dll_IsBadStringPtrW]
mov edx, str._invalid_
sub esp, 8
test eax, eax
jne 0x407646
mov eax, edi
call fcn.004011b0
mov edx, eax
mov dword [ebp - 0x12c0], edx
mov dword [esp + 4], edi
mov eax, dword [ebp - 0xfd4]
mov dword [esp], eax
call dword [sym.imp.msvcrt.dll_wcscmp]
mov dword [esp + 0xc], esi
mov edx, dword [ebp - 0x12c0]
test eax, eax
mov dword [esp + 4], str.Expected_full_URL__s__got__s._n
sete al
mov dword [esp + 8], edx
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x690
call fcn.00401190
mov eax, dword [ebp - 0xfd0]
call fcn.00401390
mov dword [esp + 4], str.Got_host__s._n
mov dword [esp + 8], eax
mov eax, dword [ebp - 0xfd4]
add eax, 0xe
cmp dword [ebp - 0xfd0], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x691
call fcn.00401190
mov eax, dword [ebp - 0xfcc]
call fcn.00401390
mov dword [esp + 4], str.Got_absolute_path__s._n
mov dword [esp + 8], eax
mov eax, dword [ebp - 0xfd4]
add eax, 0x2c
cmp dword [ebp - 0xfcc], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x693
call fcn.00401190
mov eax, dword [ebp - 0xfc8]
call fcn.00401390
mov dword [esp + 4], str.Got_query_string__s._n
mov dword [esp + 8], eax
mov edx, dword [ebp - 0xfc8]
xor eax, eax
test edx, edx
sete al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x694
call fcn.00401190
mov eax, dword [ebp - 0x129c]
mov dword [esp + 8], eax
lea eax, [ebp - 0x1280]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0xfc4]
mov dword [esp], eax
call sub.msvcrt.dll_memcmp
mov dword [esp + 4], str.Client_addresses_didnt_match._n
test eax, eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov edi, dword [ebp - 0xfc0]
mov eax, 0x696
call fcn.00401190
movsx edx, word [edi]
mov dword [esp + 4], str.Got_family__u._n
cmp dx, 2
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x697
call fcn.00401190
movzx eax, word [edi + 2]
mov esi, dword [sym.imp.ws2_32.dll_ntohs]
mov dword [esp], eax
call esi
mov word [ebp - 0x12c0], ax
movzx eax, word [edi + 2]
sub esp, 4
mov dword [esp], eax
call esi
movzx esi, word [ebp - 0x12c0]
sub esp, 4
mov dword [esp + 8], esi
mov dword [esp + 4], str.Got_wrong_port__u._n
cmp ax, word [ebp - 0x12b0]
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x698
call fcn.00401190
mov esi, dword [edi + 4]
mov dword [esp], str.127.0.0.1
call dword [sym.imp.ws2_32.dll_inet_addr]
sub esp, 4
cmp esi, eax
sete al
mov dword [esp + 8], esi
lea esi, [ebp - 0x810]
movzx eax, al
mov dword [esp + 4], str.Got_address__08lx._n
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x699
call fcn.00401190
movzx edx, word [ebp - 0xfbc]
mov dword [esp + 4], str.Got__u_unknown_headers._n
test dx, dx
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x69a
call fcn.00401190
mov eax, dword [ebp - 0xfb8]
mov dword [esp + 4], str.Got_unknown_headers__p._n
test eax, eax
mov dword [esp + 8], eax
sete al
xor edi, edi
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
nop
cmp edi, 1
je 0x407935
cmp edi, 0x1c
je 0x408060
cmp edi, 0x28
je 0x4079d0
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x6b6
movzx edx, word [ebx + edi*8 + 0x64]
mov dword [esp + 8], edi
test dx, dx
mov dword [esp + 0xc], edx
sete al
mov dword [esp + 4], str.Header__x:_got_length__u._n
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x6b8
mov eax, dword [ebx + edi*8 + 0x68]
mov dword [esp + 8], edi
test eax, eax
mov dword [esp + 0xc], eax
sete al
mov dword [esp + 4], str.Header__x:_got_value__s._n
add edi, 1
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
cmp edi, 1
jne 0x4078a9
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x69f
movzx edx, word [ebp - 0xfa4]
mov dword [esp + 4], str.Got_length__u._n
cmp dx, 0xa
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x6a1
mov edx, dword [ebp - 0xfa0]
mov dword [esp + 4], str.keep_alive
mov dword [esp], edx
mov eax, dword [ebp - 0x12a8]
mov dword [ebp - 0x12b0], edx
call eax
mov edx, dword [ebp - 0x12b0]
mov dword [esp + 4], str.Got_connection__s._n
test eax, eax
sete al
mov dword [esp + 8], edx
add edi, 1
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
jmp 0x4078a0
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x6af
movzx edx, word [ebp - 0xe6c]
mov dword [esp + 4], str.Got_length__u._n
cmp dx, 4
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x6b1
mov edi, dword [ebp - 0xe68]
mov dword [esp + 4], str.WINE
mov dword [esp], edi
mov eax, dword [ebp - 0x12a8]
call eax
mov dword [esp + 8], edi
test eax, eax
mov dword [esp + 4], str.Got_connection__s._n
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x6bc
call fcn.00401190
mov eax, dword [ebp - 0xe5c]
mov edx, dword [ebp - 0xe60]
test eax, eax
je 0x4080f8
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov dword [esp], str._lx_08lx
call fcn.00401000
mov edi, eax
lea eax, [ebp - 0x1194]
mov dword [esp], eax
mov eax, dword [ebp - 0x12b4]
call eax
mov dword [esp + 8], edi
xor edx, edx
mov dword [esp + 4], str.Got__s_bytes._n
xor edx, dword [ebp - 0xe5c]
xor eax, dword [ebp - 0xe60]
or eax, edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x6bd
call fcn.00401190
movzx edx, word [ebp - 0xe58]
mov dword [esp + 4], str.Got__u_entity_chunks._n
test dx, dx
mov dword [esp + 8], edx
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x6be
call fcn.00401190
mov eax, dword [ebp - 0xe54]
mov dword [esp + 4], str.Got_entity_chunks__p._n
test eax, eax
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x6c0
call fcn.00401190
mov eax, dword [ebp - 0xe48]
mov dword [esp + 4], str.Got_SSL_info__p._n
test eax, eax
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 3
mov dword [ebp - 0x1124], str.Im_a_teapot
mov edi, dword [sym.imp.httpapi.dll_HttpSendHttpResponse]
mov word [ebp - 0x1048], ax
lea eax, [ebp - 0x1270]
mov dword [ebp - 0x1128], 0xc01a2
mov dword [ebp - 0x1044], 0x412775
mov dword [esp + 0x24], eax
lea eax, [ebp - 0x1130]
mov dword [esp + 0x28], 0
mov dword [esp + 0x20], 0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0xdeadbeef
mov dword [esp + 8], 0
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
call edi
sub esp, 0x2c
mov dword [ebp - 0x12a8], eax
mov eax, 0x6c9
call fcn.00401190
mov edx, dword [ebp - 0x12a8]
xor eax, eax
mov dword [esp + 4], str.Got_error__u._n
cmp edx, 0x4cd
mov dword [esp + 8], edx
sete al
mov dword [esp], eax
call fcn.00401af0
lea eax, [ebp - 0x1270]
mov dword [esp + 0x28], 0
mov dword [esp + 0x24], eax
lea eax, [ebp - 0x1130]
mov dword [esp + 0x20], 0
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0
mov edx, dword [ebp - 0xffc]
mov eax, dword [ebp - 0x1000]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
call edi
sub esp, 0x2c
mov edi, eax
mov eax, 0x6cb
call fcn.00401190
xor eax, eax
test edi, edi
mov dword [esp + 8], edi
sete al
mov dword [esp + 4], str.Got_error__u._n
mov dword [esp], eax
call fcn.00401af0
lea eax, [ebp - 0x12a4]
mov dword [esp + 0xc], 0
mov dword [esp + 8], eax
lea eax, [ebp - 0x1270]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
mov eax, dword [ebp - 0x12bc]
call eax
sub esp, 0x10
mov edi, eax
mov eax, 0x6cd
call fcn.00401190
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x34]
mov dword [esp], edi
mov dword [esp + 4], str.Got_error__lu._n
mov dword [esp + 8], eax
call fcn.00401af0
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0x800
mov dword [esp + 4], esi
mov eax, dword [ebp - 0x12b8]
mov dword [esp], eax
call dword [sym.imp.ws2_32.dll_recv]
sub esp, 0x10
mov edi, eax
mov eax, 0x6d0
call fcn.00401190
mov eax, dword [ebp - 0x12a4]
mov dword [esp + 0xc], edi
mov dword [esp + 4], str.Expected_size__lu__got__u._n
cmp eax, edi
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
cmp dword [0x410008], 1
jle 0x407d6f
mov eax, 0x6d3
call fcn.00401190
mov dword [esp + 8], esi
mov dword [esp + 4], edi
mov dword [esp], str._.s_n
call fcn.00401550
mov eax, 0x6d5
call fcn.00401190
mov dword [esp], esi
mov dword [esp + 8], 0x1b
mov dword [esp + 4], str.HTTP_1.1_418_Im_a_teapot_r_n
call sub.msvcrt.dll_strncmp
mov dword [esp + 4], str.Got_incorrect_status_line._n
test eax, eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x6d6
call fcn.00401190
mov edi, dword [sym.imp.msvcrt.dll_strstr]
mov dword [esp], esi
mov dword [esp + 4], str._r_nRetry_After:_120_r_n
call edi
mov dword [esp + 4], str.Missing_or_malformed_Retry_After_header._n
test eax, eax
setne al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
mov eax, 0x6d7
call fcn.00401190
mov dword [esp], esi
mov dword [esp + 4], str._r_nDate:
call edi
mov dword [esp + 4], str.Missing_Date_header._n
test eax, eax
setne al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
lea eax, [ebp - 0x1270]
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0x800
mov dword [esp + 0xc], 0
mov edx, dword [ebp - 0xffc]
mov eax, dword [ebp - 0x1000]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x12a0]
mov dword [esp], eax
mov eax, dword [ebp - 0x12c4]
call eax
sub esp, 0x20
mov ebx, eax
mov eax, 0x6da
call fcn.00401190
xor eax, eax
cmp ebx, 0x4cd
mov dword [esp + 8], ebx
sete al
mov dword [esp + 4], str.Got_error__u._n
lea ebx, [ebp - 0x11f8]
mov dword [esp], eax
call fcn.00401af0
mov eax, dword [ebp - 0x12ac]
mov esi, dword [ebp - 0x1290]
mov edi, dword [ebp - 0x128c]
mov dword [esp], ebx
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0x4121d4
mov dword [esp + 4], 0x32
call fcn.00401400
mov dword [esp + 8], ebx
mov dword [esp], esi
mov dword [esp + 4], edi
mov dword [esp + 0xc], 0
call dword [0x425004]
sub esp, 0x10
mov esi, eax
mov eax, 0x6dd
call fcn.00401190
xor eax, eax
test esi, esi
mov dword [esp + 8], esi
sete al
mov dword [esp + 4], str.Got_error__u._n
mov dword [esp], eax
call fcn.00401af0
mov eax, dword [ebp - 0x12ac]
mov esi, dword [ebp - 0x1290]
mov edi, dword [ebp - 0x128c]
mov dword [esp], ebx
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0x4121d4
mov dword [esp + 4], 0x32
call fcn.00401400
mov dword [esp + 8], ebx
mov dword [esp], esi
mov dword [esp + 4], edi
mov dword [esp + 0xc], 0
call dword [0x425004]
sub esp, 0x10
mov ebx, eax
mov eax, 0x6df
call fcn.00401190
xor eax, eax
cmp ebx, 2
mov dword [esp + 8], ebx
sete al
mov dword [esp + 4], str.Got_error__u._n
mov dword [esp], eax
call fcn.00401af0
mov eax, dword [ebp - 0x12b8]
mov dword [esp], eax
call dword [sym.imp.ws2_32.dll_closesocket]
mov eax, dword [ebp - 0x1260]
sub esp, 4
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CloseHandle]
mov eax, dword [ebp - 0x12a0]
sub esp, 4
mov dword [esp], eax
call dword [0x425010]
sub esp, 4
mov ebx, eax
mov eax, 0x6e4
call fcn.00401190
xor eax, eax
test ebx, ebx
mov dword [esp + 8], ebx
sete al
mov dword [esp + 4], str.Failed_to_close_queue_handle__error__u._n
mov dword [esp], eax
call fcn.00401af0
mov edx, dword [ebp - 0x128c]
mov eax, dword [ebp - 0x1290]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x425008]
sub esp, 8
mov ebx, eax
mov eax, 0x6e6
call fcn.00401190
xor eax, eax
test ebx, ebx
mov dword [esp + 8], ebx
sete al
mov dword [esp + 4], str.Failed_to_close_group__error__u._n
mov dword [esp], eax
call fcn.00401af0
mov edx, dword [ebp - 0x1294]
mov eax, dword [ebp - 0x1298]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [0x42500c]
sub esp, 8
mov ebx, eax
mov eax, 0x6e8
call fcn.00401190
xor eax, eax
test ebx, ebx
mov dword [esp + 8], ebx
sete al
mov dword [esp + 4], str.Failed_to_close_group__error__u._n
mov dword [esp], eax
call fcn.00401af0
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
lea esp, [edi - 8]
pop edi
ret
mov eax, dword [ebp - 0x12ac]
mov dword [esp + 4], str.localhost:_u
mov dword [esp], esi
mov dword [esp + 8], eax
call fcn.00401040
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x6a8
mov dword [esp], esi
mov eax, dword [ebp - 0x12b4]
call eax
mov edx, eax
movzx eax, word [ebp - 0xecc]
mov dword [esp + 4], str.Got_length__u._n
cmp eax, edx
mov dword [esp + 8], eax
sete al
movzx eax, al
mov dword [esp], eax
call fcn.00401af0
call fcn.0040ded0
mov dword [eax], 0x412056
mov dword [eax + 4], 0x6aa
mov edx, dword [ebp - 0xec8]
mov dword [esp + 4], esi
jmp 0x40798c
mov dword [esp + 4], edx
mov dword [esp], 0x41248e
call fcn.00401000
jmp 0x40739c
mov dword [esp + 4], edx
mov dword [esp], 0x41248e
call fcn.00401000
mov edi, eax
jmp 0x407a82
movzx eax, di
mov dword [esp], str._04x
mov dword [esp + 4], eax
call fcn.00401000
mov edx, eax
jmp 0x407646