Function at 0x421100
Capabilities:
Check http status code

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov ecx, dword [ebp + 8]
mov edx, 0x36ee80
push ebx
mov dword [ebp - 0x38], 0
xorps xmm0, xmm0
push esi
mov ebx, dword [ecx]
movlpd qword [ebp - 0x34], xmm0
push edi
mov byte [ebp - 1], 0
mov eax, dword [ebx + 0x170]
test eax, eax
mov dword [ebp - 0x24], 0
cmovne edx, eax
mov eax, dword [ebp + 0xc]
add eax, 0x35
mov dword [ebp - 0x2c], edx
mov esi, dword [ecx + eax*4]
lea eax, [ecx + eax*4]
mov dword [ebp - 0x3c], eax
xor al, al
mov byte [ebp - 2], al
mov byte [ecx + 0x13e], al
mov eax, dword [ebp - 0x30]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x34]
mov dword [ebp - 0x28], esi
mov dword [ebp - 0xc], eax
nop dword [eax]
nop dword [eax + eax]
cmp byte [ecx + 0x135], 0
jne 0x42135a
movzx esi, word [ebp + 0x14]
push esi
push dword [ebp + 0x10]
push str.Establish_HTTP_proxy_tunnel_to__s:_d_n
push ebx
call fcn.0041a550
mov eax, dword [ebx + 0xcc]
add esp, 0x10
test eax, eax
je 0x4211b1
push eax
call dword [0x49a004]
add esp, 4
mov dword [ebx + 0xcc], 0
call fcn.00421a40
mov edi, eax
test edi, edi
je 0x421891
push esi
push dword [ebp + 0x10]
push str._s:_d
call fcn.0041bad0
add esp, 0xc
mov dword [ebp - 0x20], eax
test eax, eax
je 0x421887
push 1
push eax
push str.CONNECT
push dword [ebp + 8]
call fcn.00421e10
mov esi, eax
add esp, 0x10
test esi, esi
jne 0x421333
mov ecx, dword [ebp + 8]
mov eax, 0x477e10
mov esi, 0x4874c5
push str.Host:
push ebx
cmp dword [ecx + 0xbc], 1
mov ecx, 0x477e14
mov dword [ebp - 0x14], esi
cmovne eax, ecx
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0x30], eax
call fcn.00421d60
add esp, 8
test eax, eax
jne 0x42124d
push dword [ebp - 0x20]
push str.Host:__s_r_n
call fcn.0041bad0
mov esi, eax
add esp, 8
mov dword [ebp - 0x14], esi
test esi, esi
je 0x42185f
push str.Proxy_Connection:
push ebx
call fcn.00421d60
test eax, eax
mov ecx, str.Proxy_Connection:_Keep_Alive_r_n
mov eax, 0x4874c5
cmovne ecx, eax
push str.User_Agent:
push ebx
mov dword [ebp - 8], ecx
call fcn.00421d60
add esp, 0x10
test eax, eax
jne 0x421290
cmp dword [ebx + 0x304], eax
je 0x421290
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x150]
mov dword [ebp - 0x1c], eax
push dword [ebp - 8]
mov eax, dword [ebp + 8]
mov ecx, 0x4874c5
push dword [ebp - 0x1c]
mov eax, dword [eax + 0x14c]
test eax, eax
cmovne ecx, eax
movzx eax, word [ebp + 0x14]
push ecx
push esi
push dword [ebp - 0x30]
push eax
push dword [ebp + 0x10]
push str.CONNECT__s:_d_HTTP__s_r_n_s_s_s_s
push edi
call fcn.00421c00
mov esi, eax
add esp, 0x24
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x4212dc
cmp byte [eax], 0
je 0x4212dc
push eax
call dword [0x49a004]
add esp, 4
test esi, esi
jne 0x42131f
push edi
push dword [ebp + 8]
call fcn.00421c70
mov esi, eax
add esp, 8
test esi, esi
jne 0x42131f
push 0x4874bc
push edi
call fcn.00421c00
mov esi, eax
add esp, 8
test esi, esi
jne 0x42131f
push dword [ebp + 0xc]
push eax
lea eax, [ebx + 0x8578]
push eax
push dword [ebp + 8]
push edi
call fcn.00421a50
add esp, 0x14
mov esi, eax
xor edi, edi
test esi, esi
je 0x421333
push str.Failed_sending_CONNECT_to_proxy
push ebx
call fcn.0041a4b0
add esp, 8
push dword [ebp - 0x20]
call dword [0x49a004]
push edi
call fcn.004165e0
add esp, 8
test esi, esi
jne 0x42187e
mov ecx, dword [ebp + 8]
mov esi, dword [ebp - 0x28]
mov byte [ecx + 0x135], 1
push dword [ecx + 0xc8]
push dword [ecx + 0xc4]
call fcn.0041e6c0
push edx
push eax
call fcn.0041e650
mov ecx, dword [ebp - 0x2c]
add esp, 0x10
sub ecx, eax
test ecx, ecx
jle 0x421955
cmp dword [ebx + 0x448], 2
jne 0x4213a0
push 0
push 0xffffffffffffffff
push esi
call fcn.00422680
add esp, 0xc
test eax, eax
je 0x42194c
mov ecx, dword [ebp + 8]
lea eax, [ebx + 0x464]
mov dword [ebp - 0x1c], eax
mov esi, eax
mov eax, 1
mov dword [ebp - 0x20], 0
xor edi, edi
mov dword [ebp - 8], eax
mov byte [ecx + 0x135], 0
test eax, eax
je 0x421803
cmp dword [ebp - 0x24], 0
jne 0x42190c
push dword [ecx + 0xc8]
push dword [ecx + 0xc4]
call fcn.0041e6c0
push edx
push eax
call fcn.0041e650
mov ecx, dword [ebp - 0x2c]
add esp, 0x10
sub ecx, eax
test ecx, ecx
jle 0x4218a9
mov eax, 0x3e8
cmp ecx, eax
cmovl eax, ecx
push eax
push 0xffffffffffffffff
push dword [ebp - 0x28]
call fcn.00422680
add esp, 0xc
cmp eax, 0xffffffff
je 0x4217c7
test eax, eax
je 0x4217dc
lea eax, [ebp - 0x18]
push eax
mov eax, 0x4000
sub eax, dword [ebp - 0x20]
push eax
push dword [ebp - 0x1c]
push dword [ebp - 0x28]
push dword [ebp + 8]
call fcn.0041a5d0
add esp, 0x14
test eax, eax
js 0x4217f0
je 0x42145b
xor eax, eax
mov dword [ebp - 8], eax
jmp 0x4217dc
mov ecx, dword [ebp - 0x18]
test ecx, ecx
jg 0x421490
xor eax, eax
mov dword [ebp - 8], eax
cmp dword [ebx + 0x104], eax
je 0x421486
cmp dword [ebx + 0x84fc], eax
je 0x421486
mov ecx, dword [ebp + 8]
mov byte [ecx + 0x13e], 1
jmp 0x4217df
push str.Proxy_CONNECT_aborted
jmp 0x4217cc
add dword [ebp - 0x20], ecx
cmp dword [ebp - 8], 1
jle 0x421533
mov eax, dword [ebp - 0xc]
lea edx, [ebx + 0x464]
or eax, dword [ebp - 0x10]
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], edx
je 0x4214e8
mov eax, ecx
mov ecx, dword [ebp - 0xc]
cdq
sub ecx, eax
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0xc], ecx
sbb eax, edx
mov dword [ebp - 0x10], eax
test eax, eax
jg 0x4217dc
jl 0x421451
test ecx, ecx
jne 0x4217dc
xor eax, eax
mov dword [ebp - 8], eax
jmp 0x4217dc
lea eax, [ebp - 0x14]
mov dword [ebp - 0x14], 0
push eax
push ecx
push edx
push dword [ebp + 8]
call fcn.004222b0
add esp, 0x10
cmp eax, 0xffffffff
jne 0x42151d
push str.chunk_reading_DONE_n
push ebx
call fcn.0041a550
add esp, 8
xor eax, eax
mov dword [ebp - 8], eax
jmp 0x4217dc
push dword [ebp - 0x14]
push str.Read__d_bytes_of_chunk__continue_n
push ebx
call fcn.0041a550
add esp, 0xc
jmp 0x4217dc
xor eax, eax
mov dword [ebp - 0x14], eax
test ecx, ecx
jle 0x4217dc
mov edx, dword [ebp - 0x1c]
inc edi
cmp byte [edx], 0xa
jne 0x4216df
cmp byte [ebx + 0x270], 0
je 0x421566
push dword [ebp + 8]
push edi
push esi
push 1
push ebx
call fcn.0041a3d0
add esp, 0x14
xor eax, eax
cmp byte [ebx + 0x263], al
push edi
setne al
push esi
add eax, 2
push eax
push dword [ebp + 8]
call fcn.0041a270
add esp, 0x10
test eax, eax
jne 0x421968
mov al, byte [esi]
cmp al, 0xd
je 0x4216f4
cmp al, 0xa
je 0x4216f4
mov cl, byte [edi + esi]
lea eax, [edi + esi]
push 0x11
push esi
push str.WWW_Authenticate:
mov dword [ebp - 0x30], eax
mov byte [ebp - 3], cl
mov byte [eax], 0
call fcn.0041d090
add esp, 0xc
test eax, eax
je 0x4215cc
mov eax, dword [ebx + 0x90]
cmp eax, 0x191
je 0x4215ed
push 0x13
push esi
push str.Proxy_authenticate:
call fcn.0041d090
add esp, 0xc
test eax, eax
je 0x421607
mov eax, dword [ebx + 0x90]
cmp eax, 0x197
jne 0x421607
push esi
push eax
push dword [ebp + 8]
call fcn.00420de0
add esp, 0xc
test eax, eax
jne 0x421968
jmp 0x4216c9
push 0xf
push esi
push str.Content_Length:
call fcn.0041d090
add esp, 0xc
test eax, eax
je 0x421636
push 0xa
push 0
add esi, 0xf
push esi
call fcn.00439b87
add esp, 0xc
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x10], edx
jmp 0x4216c9
push str.close
push str.Connection:
push esi
call fcn.00420a80
add esp, 0xc
test al, al
je 0x421653
mov byte [ebp - 1], 1
jmp 0x4216c9
push str.chunked
push str.Transfer_Encoding:
push esi
call fcn.00420a80
add esp, 0xc
test al, al
je 0x421686
push str.CONNECT_responded_chunked_n
push ebx
call fcn.0041a550
push dword [ebp + 8]
mov byte [ebp - 2], 1
call fcn.00422290
add esp, 0xc
jmp 0x4216c9
push str.close
push str.Proxy_Connection:
push esi
call fcn.00420a80
add esp, 0xc
test al, al
je 0x4216a3
mov byte [ebp - 1], 1
jmp 0x4216c9
lea edi, [ebx + 0x90]
push edi
lea eax, [ebp - 0x38]
push eax
push str.HTTP_1._d__d
push esi
call fcn.004119a0
add esp, 0x10
cmp eax, 2
jne 0x4216c9
mov eax, dword [edi]
mov dword [ebx + 0x8564], eax
mov eax, dword [ebp - 0x30]
xor edi, edi
mov edx, dword [ebp - 0x1c]
mov cl, byte [ebp - 3]
mov byte [eax], cl
mov ecx, dword [ebp - 0x18]
lea esi, [edx + 1]
mov eax, dword [ebp - 0x14]
inc eax
inc edx
mov dword [ebp - 0x1c], edx
mov dword [ebp - 0x14], eax
cmp eax, ecx
jl 0x421543
jmp 0x4217dc
cmp dword [ebx + 0x90], 0x197
lea eax, [ebx + 0x464]
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], eax
jne 0x421451
cmp byte [ebx + 0x8504], 0
jne 0x421451
mov ecx, dword [ebp - 0xc]
mov eax, ecx
mov edx, dword [ebp - 0x10]
or eax, edx
mov dword [ebp - 8], 2
je 0x42174f
push edx
push ecx
push str.Ignore__lld_bytes_of_response_body_n
push ebx
call fcn.0041a550
mov eax, dword [ebp - 0x18]
add esp, 0x10
sub eax, dword [ebp - 0x14]
jmp 0x4214b7
mov al, byte [ebp - 2]
test al, al
je 0x421451
mov eax, dword [ebp - 0x18]
sub eax, dword [ebp - 0x14]
push eax
push str._d_bytes_of_chunk_left_n
push ebx
mov byte [ebx + 0xc5], 1
call fcn.0041a550
add esp, 0xc
cmp byte [esi + 1], 0xa
jne 0x421780
inc esi
inc dword [ebp - 0x14]
lea eax, [ebp - 0x18]
push eax
mov eax, dword [ebp - 0x18]
sub eax, dword [ebp - 0x14]
push eax
lea eax, [esi + 1]
push eax
push dword [ebp + 8]
call fcn.004222b0
add esp, 0x10
cmp eax, 0xffffffff
jne 0x4217b4
push str.chunk_reading_DONE_n
push ebx
call fcn.0041a550
add esp, 8
xor eax, eax
mov dword [ebp - 8], eax
jmp 0x4217dc
push dword [ebp - 0x18]
push str.Read__d_bytes_of_chunk__continue_n
push ebx
call fcn.0041a550
add esp, 0xc
jmp 0x4217dc
push str.Proxy_CONNECT_aborted_due_to_select_poll_error
push ebx
mov dword [ebp - 0x24], 1
call fcn.0041a4b0
add esp, 8
mov ecx, dword [ebp + 8]
push ecx
call fcn.0041eaa0
add esp, 4
test eax, eax
jne 0x42189d
cmp dword [ebp - 0x20], 0x4000
mov ecx, dword [ebp + 8]
mov eax, dword [ebp - 8]
jb 0x4213c6
cmp dword [ebp - 0x24], 0
jne 0x42190c
cmp dword [ebx + 0x8564], 0xc8
je 0x42183b
push ecx
call fcn.00420c20
add esp, 4
test eax, eax
jne 0x421968
mov ecx, dword [ebp + 8]
cmp byte [ecx + 0x128], al
je 0x42183b
mov byte [ebp - 1], 1
jmp 0x421841
cmp byte [ebp - 1], 0
je 0x42184a
cmp dword [ebx + 0xcc], 0
jne 0x4218c3
cmp dword [ebx + 0xcc], 0
je 0x4218d7
mov esi, dword [ebp - 0x28]
jmp 0x421170
push edi
call dword [0x49a004]
push dword [ebp - 0x20]
call dword [0x49a004]
add esp, 8
mov eax, 0x1b
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push edi
call dword [0x49a004]
add esp, 4
pop edi
pop esi
mov eax, 0x1b
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
mov eax, 0x2a
pop ebx
mov esp, ebp
pop ebp
ret
push str.Proxy_CONNECT_aborted_due_to_timeout
push ebx
call fcn.0041a4b0
add esp, 8
mov eax, 0x38
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 0x3c]
push dword [esi]
call dword [sym.imp.WS2_32.dll_closesocket]
mov ecx, dword [ebp + 8]
mov dword [esi], 0xffffffff
mov eax, dword [ebx + 0x90]
cmp eax, 0xc8
je 0x421918
push eax
push str.Received_HTTP_code__d_from_proxy_after_CONNECT
push ebx
call fcn.0041a4b0
add esp, 0xc
cmp byte [ebp - 1], 0
je 0x42190c
cmp dword [ebx + 0xcc], 0
je 0x42190c
mov eax, dword [ebp + 8]
mov byte [eax + 0x13e], 1
pop edi
pop esi
mov eax, 0x38
pop ebx
mov esp, ebp
pop ebp
ret
push dword [ecx + 0x14c]
call fcn.004165e0
mov eax, dword [ebp + 8]
push str.Proxy_replied_OK_to_CONNECT_request_n
push ebx
mov dword [eax + 0x14c], 0
mov byte [ebx + 0x8500], 1
call fcn.0041a550
add esp, 0xc
mov byte [ebx + 0xc5], 0
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push str.Proxy_CONNECT_aborted_due_to_timeout
push ebx
call fcn.0041a4b0
mov eax, 0x38
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret