Function at 0x437820
Capabilities:
Check for time delay via gettickcount
Check http status code

Disassembly:
sub esp, 0x38
push ebx
mov ebx, dword [esp + 0x40]
push ebp
mov ebp, dword [ebx]
push esi
push edi
xor edi, edi
mov dword [esp + 0x3c], edi
mov eax, dword [ebp + 0x170]
mov dword [esp + 0x18], ebp
mov dword [esp + 0x30], eax
cmp eax, edi
jne 0x43784d
mov dword [esp + 0x30], 0x36ee80
mov eax, dword [esp + 0x50]
mov ecx, dword [ebx + eax*4 + 0xa0]
mov dword [esp + 0x34], ecx
mov dword [esp + 0x40], edi
mov dword [esp + 0x44], edi
mov byte [esp + 0x12], 0
mov byte [esp + 0x13], 0
mov dword [esp + 0x2c], edi
mov byte [ebx + 0x121], 0
cmp byte [ebx + 0x119], 0
mov ecx, dword [esp + 0x54]
mov ax, word [esp + 0x58]
jne 0x437a88
cmp byte [ebx + 0x118], 0
movzx esi, ax
push esi
push ecx
je 0x4378a4
push str.Establish_HTTP_proxy_tunnel_to__s:_d_n
jmp 0x4378a9
push str.Establish_HTTP_proxy_to__s:_d_n
push ebp
call fcn.00425c10
mov eax, dword [ebp + 0xcc]
add esp, 0x10
cmp eax, edi
je 0x4378cc
push eax
call dword [0x50c148]
add esp, 4
mov dword [ebp + 0xcc], edi
push 0xc
call dword [0x50c144]
mov edi, eax
add esp, 4
test edi, edi
je 0x438016
mov edx, dword [esp + 0x54]
xor eax, eax
push esi
mov dword [edi], eax
push edx
mov dword [edi + 4], eax
push str._s:_d
mov dword [edi + 8], eax
call fcn.00428450
add esp, 0xc
mov dword [esp + 0x24], eax
test eax, eax
je 0x43800c
push 1
push eax
push str.CONNECT
mov esi, ebx
call fcn.004356f0
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x437a59
mov eax, dword [esp + 0x18]
mov esi, 0x4fe730
push eax
mov ebx, str.Host:
mov ebp, esi
mov dword [esp + 0x2c], esi
call fcn.00435430
add esp, 4
test eax, eax
jne 0x437963
mov ebx, dword [esp + 0x24]
push ebx
push str.Host:__s_r_n
call fcn.00428450
mov ebp, eax
add esp, 8
test ebp, ebp
je 0x438023
mov ecx, dword [esp + 0x18]
push ecx
mov ebx, str.Proxy_Connection:
call fcn.00435430
add esp, 4
test eax, eax
jne 0x437981
mov dword [esp + 0x28], str.Proxy_Connection:_Keep_Alive_r_n
mov edx, dword [esp + 0x18]
push edx
mov ebx, str.User_Agent:
call fcn.00435430
add esp, 4
test eax, eax
jne 0x4379ae
mov eax, dword [esp + 0x18]
cmp dword [eax + 0x2fc], 0
je 0x4379ae
mov ecx, dword [esp + 0x4c]
mov esi, dword [ecx + 0x134]
mov edx, dword [esp + 0x4c]
mov eax, dword [edx + 0x130]
test eax, eax
jne 0x4379c1
mov eax, 0x4fe730
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x54]
push ecx
push esi
push eax
movzx eax, word [esp + 0x64]
push ebp
push eax
push edx
push str.CONNECT__s:_d_HTTP_1.0_r_n_s_s_s_s
mov eax, edi
call fcn.004362b0
add esp, 0x1c
mov esi, eax
test ebp, ebp
je 0x4379f9
cmp byte [ebp], 0
je 0x4379f9
push ebp
call dword [0x50c148]
add esp, 4
test esi, esi
jne 0x437a41
mov ebx, dword [esp + 0x4c]
push edi
call fcn.00436370
mov esi, eax
add esp, 4
test esi, esi
jne 0x437a41
push 0x4de1d8
mov eax, edi
call fcn.004362b0
mov esi, eax
add esp, 4
test esi, esi
jne 0x437a41
mov ecx, dword [esp + 0x50]
push eax
mov eax, dword [esp + 0x1c]
add eax, 0x853c
push eax
push edi
mov edi, ebx
call fcn.00435c30
add esp, 0xc
mov esi, eax
xor edi, edi
test esi, esi
je 0x437a59
mov ecx, dword [esp + 0x18]
push str.Failed_sending_CONNECT_to_proxy
push ecx
call fcn.00425ca0
add esp, 8
mov edx, dword [esp + 0x24]
push edx
call dword [0x50c148]
push edi
call fcn.00429570
add esp, 8
test esi, esi
jne 0x438041
mov eax, dword [esp + 0x4c]
mov ebp, dword [esp + 0x18]
mov byte [eax + 0x119], 1
mov ebx, eax
xor edi, edi
mov ecx, dword [ebx + 0x94]
mov edx, dword [ebx + 0x90]
push ecx
push edx
call fcn.004343a0
push edx
push eax
call fcn.004343d0
mov ecx, dword [esp + 0x40]
sub ecx, eax
add esp, 0x10
test ecx, ecx
jle 0x43804b
cmp dword [ebp + 0x418], 2
jne 0x437ad4
mov edx, dword [esp + 0x34]
push edi
push 0xffffffffffffffff
push edx
call fcn.0043d9d0
add esp, 0xc
test eax, eax
je 0x4380f7
xor edi, edi
lea esi, [ebp + 0x434]
mov byte [ebx + 0x119], 0
mov dword [esp + 0x24], esi
mov dword [esp + 0x28], edi
mov dword [esp + 0x1c], edi
mov dword [esp + 0x14], 1
jmp 0x437b00
cmp dword [esp + 0x14], 0
je 0x437f92
cmp dword [esp + 0x2c], 0
jne 0x4380b8
mov eax, dword [ebx + 0x94]
mov ecx, dword [ebx + 0x90]
push eax
push ecx
call fcn.004343a0
push edx
push eax
call fcn.004343d0
mov ecx, dword [esp + 0x40]
sub ecx, eax
add esp, 0x10
test ecx, ecx
jle 0x437ff1
cmp ecx, 0x3e8
jl 0x437b4e
mov ecx, 0x3e8
mov edx, dword [esp + 0x34]
push ecx
push 0xffffffffffffffff
push edx
call fcn.0043d9d0
add esp, 0xc
cmp eax, 0xffffffff
je 0x437f5b
test eax, eax
je 0x437f71
mov edx, dword [esp + 0x24]
lea eax, [esp + 0x20]
push eax
mov eax, dword [esp + 0x38]
mov ecx, 0x4000
sub ecx, edi
push ecx
push edx
push eax
push ebx
call fcn.00425910
add esp, 0x14
test eax, eax
jl 0x437f86
xor ecx, ecx
cmp eax, ecx
je 0x437ba6
mov dword [esp + 0x14], ecx
jmp 0x437f71
mov eax, dword [esp + 0x20]
cmp eax, ecx
jg 0x437bd8
mov dword [esp + 0x14], ecx
cmp dword [ebp + 0x104], ecx
je 0x437bce
cmp dword [ebp + 0x84cc], ecx
je 0x437bce
mov byte [ebx + 0x121], 1
jmp 0x437f71
push str.Proxy_CONNECT_aborted
jmp 0x437f60
add edi, eax
cmp dword [esp + 0x14], 1
mov dword [esp + 0x28], edi
jle 0x437c72
mov edi, dword [esp + 0x44]
mov dword [esp + 0x28], ecx
mov ecx, dword [esp + 0x40]
mov edx, ecx
or edx, edi
je 0x437c27
cdq
sub ecx, eax
sbb edi, edx
mov dword [esp + 0x40], ecx
mov dword [esp + 0x44], edi
test edi, edi
jg 0x437f71
jl 0x437c1a
test ecx, ecx
ja 0x437f71
mov dword [esp + 0x14], 0
jmp 0x437f71
mov edx, dword [esp + 0x24]
lea ecx, [esp + 0x38]
push ecx
push eax
push edx
xor edi, edi
push ebx
mov dword [esp + 0x48], edi
call fcn.004401e0
add esp, 0x10
cmp eax, 0xffffffff
jne 0x437c5a
push str.chunk_reading_DONE_n
push ebp
call fcn.00425c10
mov dword [esp + 0x1c], edi
jmp 0x437f6e
mov eax, dword [esp + 0x38]
push eax
push str.Read__d_bytes_of_chunk__continue_n
push ebp
call fcn.00425c10
add esp, 0xc
jmp 0x437f71
xor edi, edi
mov dword [esp + 0x38], edi
test eax, eax
jle 0x437f71
mov ecx, 1
mov edx, dword [esp + 0x24]
add dword [esp + 0x1c], ecx
cmp byte [edx], 0xa
jne 0x437e48
cmp byte [ebp + 0x25c], 0
je 0x437cb1
mov eax, dword [esp + 0x1c]
push ebx
push eax
push esi
push 1
push ebp
call fcn.00425a80
add esp, 0x14
cmp byte [ebp + 0x250], 0
mov eax, 2
je 0x437cc4
mov eax, 3
mov ecx, dword [esp + 0x1c]
push ecx
push esi
push eax
push ebx
call fcn.00425e00
add esp, 0x10
test eax, eax
jne 0x4380f9
mov al, byte [esi]
cmp al, 0xd
je 0x437e5f
cmp al, 0xa
je 0x437e5f
mov eax, dword [esp + 0x1c]
mov bl, byte [eax + esi]
push 0x11
push esi
push str.WWW_Authenticate:
mov byte [eax + esi], 0
call fcn.00432140
add esp, 0xc
test eax, eax
je 0x437d1a
mov eax, dword [ebp + 0x90]
cmp eax, 0x191
je 0x437d3b
push 0x13
push esi
push str.Proxy_authenticate:
call fcn.00432140
add esp, 0xc
test eax, eax
je 0x437d57
mov eax, dword [ebp + 0x90]
cmp eax, 0x197
jne 0x437d57
mov edx, dword [esp + 0x4c]
push esi
push eax
push edx
call fcn.00435980
add esp, 0xc
test eax, eax
jne 0x4380f9
jmp 0x437e21
push 0xf
push esi
push str.Content_Length:
call fcn.00432140
add esp, 0xc
test eax, eax
je 0x437d88
push 0xa
lea eax, [esi + 0xf]
push 0
push eax
call fcn.0049db1e
add esp, 0xc
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], edx
jmp 0x437e21
push str.close
push str.Connection:
push esi
call fcn.00435e90
add esp, 0xc
test al, al
je 0x437da6
mov byte [esp + 0x12], 1
jmp 0x437e21
push str.chunked
push str.Transfer_Encoding:
push esi
call fcn.00435e90
add esp, 0xc
test al, al
je 0x437ddc
push str.CONNECT_responded_chunked_n
push ebp
call fcn.00425c10
mov ecx, dword [esp + 0x54]
push ecx
mov byte [esp + 0x1f], 1
call fcn.004401c0
add esp, 0xc
jmp 0x437e21
push str.close
push str.Proxy_Connection:
push esi
call fcn.00435e90
add esp, 0xc
test al, al
je 0x437dfa
mov byte [esp + 0x12], 1
jmp 0x437e21
lea edi, [ebp + 0x90]
push edi
lea edx, [esp + 0x40]
push edx
push str.HTTP_1._d__d
push esi
call fcn.0049b84a
add esp, 0x10
cmp eax, 2
jne 0x437e21
mov eax, dword [edi]
mov dword [ebp + 0x852c], eax
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x24]
mov eax, dword [esp + 0x20]
mov edi, dword [esp + 0x38]
mov byte [ecx + esi], bl
mov ebx, dword [esp + 0x4c]
mov dword [esp + 0x1c], 0
lea esi, [edx + 1]
mov ecx, 1
add dword [esp + 0x24], ecx
add edi, ecx
cmp edi, eax
mov dword [esp + 0x38], edi
jl 0x437c85
jmp 0x437f71
xor eax, eax
cmp dword [ebp + 0x90], 0x197
mov dword [esp + 0x28], eax
jne 0x437f55
cmp byte [ebp + 0x84d4], al
jne 0x437f55
mov ecx, dword [esp + 0x40]
or ecx, dword [esp + 0x44]
mov dword [esp + 0x14], 2
je 0x437ee2
mov edx, dword [esp + 0x44]
mov eax, dword [esp + 0x40]
push edx
push eax
push str.Ignore__lld_bytes_of_response_body_n
push ebp
call fcn.00425c10
mov eax, dword [esp + 0x30]
sub eax, edi
cdq
add esp, 0x10
sub dword [esp + 0x40], eax
mov eax, dword [esp + 0x44]
sbb eax, edx
mov dword [esp + 0x44], eax
test eax, eax
jg 0x437f71
jl 0x437ed5
cmp dword [esp + 0x40], 0
ja 0x437f71
mov dword [esp + 0x14], 0
jmp 0x437f71
cmp byte [esp + 0x13], 0
je 0x437f55
mov ecx, dword [esp + 0x20]
sub ecx, edi
push ecx
push str._d_bytes_of_chunk_left_n
push ebp
mov byte [ebp + 0xc5], 1
call fcn.00425c10
add esp, 0xc
cmp byte [esi + 1], 0xa
jne 0x437f0d
inc esi
inc edi
mov eax, dword [esp + 0x20]
lea edx, [esp + 0x20]
push edx
sub eax, edi
push eax
lea ecx, [esi + 1]
push ecx
push ebx
call fcn.004401e0
add esp, 0x10
cmp eax, 0xffffffff
jne 0x437f40
push str.chunk_reading_DONE_n
push ebp
call fcn.00425c10
mov dword [esp + 0x1c], 0
jmp 0x437f6e
mov edx, dword [esp + 0x20]
push edx
push str.Read__d_bytes_of_chunk__continue_n
push ebp
call fcn.00425c10
add esp, 0xc
jmp 0x437f71
mov dword [esp + 0x14], eax
jmp 0x437f71
push str.Proxy_CONNECT_aborted_due_to_select_poll_error
push ebp
mov dword [esp + 0x34], 1
call fcn.00425ca0
add esp, 8
push ebx
call fcn.00434c10
add esp, 4
test eax, eax
jne 0x43805b
mov edi, dword [esp + 0x28]
cmp edi, 0x4000
jb 0x437b00
cmp dword [esp + 0x2c], 0
jne 0x4380b8
cmp dword [ebp + 0x852c], 0xc8
je 0x437fc9
push ebx
call fcn.00436110
add esp, 4
test eax, eax
jne 0x4380f9
cmp byte [ebx + 0x10c], al
je 0x437fc9
mov byte [esp + 0x12], 1
jmp 0x437fd0
cmp byte [esp + 0x12], 0
je 0x437fdd
cmp dword [ebp + 0xcc], 0
jne 0x438068
cmp dword [ebp + 0xcc], 0
je 0x438085
xor edi, edi
jmp 0x437879
push str.Proxy_CONNECT_aborted_due_to_timeout
push ebp
call fcn.00425ca0
add esp, 8
pop edi
pop esi
pop ebp
mov eax, 0x38
pop ebx
add esp, 0x38
ret
push edi
call dword [0x50c148]
add esp, 4
pop edi
pop esi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x38
ret
push edi
call dword [0x50c148]
push ebx
call dword [0x50c148]
add esp, 8
pop edi
pop esi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x38
ret
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x38
ret
push str.Proxy_CONNECT_aborted_due_to_timeout
push ebp
call fcn.00425ca0
add esp, 8
jmp 0x438085
pop edi
pop esi
pop ebp
mov eax, 0x2a
pop ebx
add esp, 0x38
ret
mov esi, dword [esp + 0x50]
mov eax, dword [ebx + esi*4 + 0xa0]
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [ebx + esi*4 + 0xa0], 0xffffffff
mov eax, dword [ebp + 0x90]
cmp eax, 0xc8
je 0x4380c5
push eax
push str.Received_HTTP_code__d_from_proxy_after_CONNECT
push ebp
call fcn.00425ca0
add esp, 0xc
cmp byte [esp + 0x12], 0
je 0x4380b8
cmp dword [ebp + 0xcc], 0
je 0x4380b8
mov byte [ebx + 0x121], 1
pop edi
pop esi
pop ebp
mov eax, 0x38
pop ebx
add esp, 0x38
ret
mov ecx, dword [ebx + 0x130]
push ecx
call fcn.00429570
push str.Proxy_replied_OK_to_CONNECT_request_n
mov dword [ebx + 0x130], 0
push ebp
mov byte [ebp + 0x84d0], 1
call fcn.00425c10
add esp, 0xc
mov byte [ebp + 0xc5], 0
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x38
ret