Function at 0x4c2ff0
Capabilities:
Check http status code

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
push ebx
push esi
mov esi, ecx
mov dword [ebp - 0x34], edx
lea ecx, [edx + 0x11a]
mov dword [ebp - 0xc], esi
lea ecx, [esi + ecx*4]
mov dword [ebp - 0x40], 0
xor bl, bl
mov dword [ebp - 0x30], 0
mov eax, dword [esi + edx*4 + 0x154]
xorps xmm0, xmm0
mov dword [ebp - 0x38], eax
xor al, al
cmp dword [ecx], 2
push edi
mov edi, dword [esi]
movlpd qword [ebp - 0x4c], xmm0
mov byte [ebp - 5], bl
mov byte [ebp - 6], al
mov dword [ebp - 0x14], ecx
je 0x4c3980
mov byte [esi + 0x1f5], al
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x4c]
mov dword [ebp - 0x18], eax
cmp dword [ecx], 0
jne 0x4c326f
push dword [ebp + 0xc]
push dword [ebp + 8]
push str.Establish_HTTP_proxy_tunnel_to__s:_hu_n
push edi
call fcn.004ac3b0
push dword [edi + 0x144]
call dword [0x74b960]
add esp, 0x14
mov dword [edi + 0x144], 0
call fcn.004bc220
mov ebx, eax
test ebx, ebx
je 0x4c3859
push dword [ebp + 0xc]
push dword [ebp + 8]
push str._s:_hu
call fcn.004c17d0
add esp, 0xc
mov dword [ebp - 0x2c], eax
test eax, eax
je 0x4c3852
push 1
push eax
mov edx, str.CONNECT
mov ecx, esi
call fcn.004bbe50
push dword [ebp - 0x2c]
mov esi, eax
call dword [0x74b960]
add esp, 0xc
test esi, esi
jne 0x4c3257
mov ecx, dword [ebp - 0xc]
mov edx, 0x6f2178
push dword [ebp + 0xc]
mov eax, 0x6f217c
mov esi, 0x6d18c8
mov dword [ebp - 0x24], esi
cmp dword [ecx + 0x138], 1
mov cl, byte [ecx + 0x1e6]
cmovne eax, edx
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x10], eax
test cl, cl
mov edx, esi
mov eax, 0x6f0fcc
cmove eax, edx
push eax
push dword [ebp + 8]
mov eax, 0x6f0fd0
cmove eax, edx
push eax
push str._s_s_s:_hu
call fcn.004c17d0
add esp, 0x14
mov dword [ebp - 0x2c], eax
test eax, eax
je 0x4c3852
mov ecx, dword [ebp - 0xc]
mov edx, str.Host:
call fcn.004bb6f0
test eax, eax
jne 0x4c3166
push dword [ebp - 0x2c]
push str.Host:__s_r_n
call fcn.004c17d0
mov esi, eax
add esp, 8
mov dword [ebp - 0x24], esi
test esi, esi
je 0x4c3846
mov ecx, dword [ebp - 0xc]
mov edx, str.Proxy_Connection:
call fcn.004bb6f0
test eax, eax
mov ecx, 0x6d18c8
mov eax, str.Proxy_Connection:_Keep_Alive_r_n
mov edx, str.User_Agent:
cmove ecx, eax
mov dword [ebp - 0x20], ecx
mov ecx, dword [ebp - 0xc]
call fcn.004bb6f0
test eax, eax
jne 0x4c31aa
cmp dword [edi + 0x3a4], eax
je 0x4c31aa
mov eax, dword [ebp - 0xc]
mov eax, dword [eax + 0x224]
mov dword [ebp - 0x28], eax
push dword [ebp - 0x20]
mov eax, dword [ebp - 0xc]
mov ecx, 0x6d18c8
push dword [ebp - 0x28]
mov eax, dword [eax + 0x220]
test eax, eax
cmovne ecx, eax
push ecx
push esi
push dword [ebp - 0x10]
push dword [ebp - 0x2c]
push str.CONNECT__s_HTTP__s_r_n_s_s_s_s
push ebx
call fcn.004bc400
mov esi, eax
add esp, 0x20
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x4c31f1
cmp byte [eax], 0
je 0x4c31f1
push eax
call dword [0x74b960]
add esp, 4
push dword [ebp - 0x2c]
call dword [0x74b960]
add esp, 4
test esi, esi
jne 0x4c3243
mov ecx, dword [ebp - 0xc]
mov dl, 1
push ebx
call fcn.004bc8b0
mov esi, eax
add esp, 4
test esi, esi
jne 0x4c3243
push 0x6e96ec
push ebx
call fcn.004bc400
mov esi, eax
add esp, 8
test esi, esi
jne 0x4c3243
push dword [ebp - 0x34]
mov edx, dword [ebp - 0xc]
mov ecx, ebx
push eax
lea eax, [edi + 0x86cc]
push eax
call fcn.004bc250
add esp, 0xc
mov esi, eax
xor ebx, ebx
test esi, esi
je 0x4c3257
push str.Failed_sending_CONNECT_to_proxy
push edi
call fcn.004ac430
add esp, 8
mov ecx, ebx
call fcn.004bc230
test esi, esi
jne 0x4c3865
mov eax, dword [ebp - 0x14]
mov dword [eax], 1
push 1
xor edx, edx
mov ecx, edi
call fcn.004ace60
add esp, 4
test eax, eax
jle 0x4c3989
cmp byte [ebp + 0x10], 0
jne 0x4c32a5
mov ecx, dword [ebp - 0x38]
or edx, 0xffffffff
push 0
push 0xffffffffffffffff
call fcn.004ae2b0
add esp, 8
test eax, eax
je 0x4c3980
lea eax, [edi + 0x584]
mov dword [ebp - 0x28], 0
mov ecx, 1
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x10], ecx
mov esi, eax
xor ebx, ebx
test ecx, ecx
je 0x4c37c0
cmp dword [ebp - 0x30], 0
jne 0x4c3997
push 1
xor edx, edx
mov ecx, edi
call fcn.004ace60
mov ecx, eax
add esp, 4
test ecx, ecx
jle 0x4c3989
mov eax, 0x3e8
cmp ecx, eax
cmovl eax, ecx
mov ecx, dword [ebp - 0x38]
push eax
push 0xffffffffffffffff
or edx, 0xffffffff
call fcn.004ae2b0
add esp, 8
cmp eax, 0xffffffff
je 0x4c378b
test eax, eax
je 0x4c37a0
mov edx, dword [ebp - 0x38]
lea eax, [ebp - 0x3c]
mov ecx, dword [ebp - 0xc]
push eax
mov eax, 0x4000
sub eax, dword [ebp - 0x28]
push eax
push dword [ebp - 0x20]
call fcn.004ac9f0
add esp, 0xc
cmp eax, 0x51
je 0x4c37b0
test eax, eax
je 0x4c334c
xor eax, eax
mov dword [ebp - 0x10], eax
jmp 0x4c37a0
mov ecx, dword [ebp - 0x3c]
mov dword [ebp - 0x2c], ecx
test ecx, ecx
jg 0x4c338f
xor eax, eax
mov dword [ebp - 0x10], eax
cmp dword [edi + 0x180], eax
je 0x4c3385
cmp dword [edi + 0x861c], eax
je 0x4c3385
mov eax, dword [ebp - 0xc]
push str.Proxy_CONNECT_connection_closed_n
push edi
mov byte [eax + 0x1f5], 1
call fcn.004ac3b0
jmp 0x4c379d
push str.Proxy_CONNECT_aborted
jmp 0x4c3790
add dword [ebp - 0x28], ecx
cmp dword [ebp - 0x10], 1
jle 0x4c3436
mov eax, dword [ebp - 0x18]
lea edx, [edi + 0x584]
or eax, dword [ebp - 0x1c]
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x20], edx
je 0x4c33e3
mov eax, ecx
mov ecx, dword [ebp - 0x18]
cdq
sub ecx, eax
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x18], ecx
sbb eax, edx
mov dword [ebp - 0x1c], eax
test eax, eax
jg 0x4c37a0
jl 0x4c33d9
test ecx, ecx
jne 0x4c37a0
xor eax, eax
mov dword [ebp - 0x10], eax
jmp 0x4c37a0
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], 0
push eax
push ecx
mov ecx, dword [ebp - 0xc]
call fcn.004d97a0
add esp, 8
cmp eax, 0xffffffff
jne 0x4c3420
push str.chunk_reading_DONE_n
push edi
call fcn.004ac3b0
add esp, 8
xor eax, eax
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x14]
mov dword [eax], 2
jmp 0x4c37a0
push dword [ebp - 0x2c]
push str.Read__zd_bytes_of_chunk__continue_n
push edi
call fcn.004ac3b0
add esp, 0xc
jmp 0x4c37a0
xor eax, eax
mov dword [ebp - 0x24], eax
test ecx, ecx
jle 0x4c37a0
mov edx, dword [ebp - 0x20]
inc ebx
cmp byte [edx], 0xa
jne 0x4c3625
cmp byte [edi + 0x310], 0
je 0x4c346d
push dword [ebp - 0xc]
mov edx, 1
mov ecx, edi
push ebx
push esi
call fcn.004acb80
add esp, 0xc
mov ecx, dword [ebp - 0xc]
xor edx, edx
cmp byte [edi + 0x304], dl
push ebx
setne dl
push esi
add edx, 2
call fcn.004ac980
add dword [edi + 0x86c8], ebx
add esp, 8
add dword [edi + 0x80], ebx
test eax, eax
jne 0x4c3982
mov al, byte [esi]
cmp al, 0xd
je 0x4c363a
cmp al, 0xa
je 0x4c363a
mov cl, byte [ebx + esi]
lea eax, [ebx + esi]
mov byte [ebp - 7], cl
mov edx, esi
push 0x11
mov ecx, str.WWW_Authenticate:
mov dword [ebp - 0x48], eax
mov byte [eax], 0
call fcn.004d14e0
add esp, 4
test eax, eax
je 0x4c34e0
mov ebx, dword [edi + 0xc8]
cmp ebx, 0x191
je 0x4c3505
push 0x13
mov edx, esi
lea ebx, [edi + 0xc8]
mov ecx, str.Proxy_authenticate:
call fcn.004d14e0
add esp, 4
test eax, eax
je 0x4c354e
mov ebx, dword [ebx]
cmp ebx, 0x197
jne 0x4c3548
mov ecx, esi
call fcn.004bb760
mov esi, eax
test esi, esi
je 0x4c3859
mov ecx, dword [ebp - 0xc]
cmp ebx, 0x197
push esi
sete dl
call fcn.004bbf60
add esp, 4
mov ebx, eax
push esi
call dword [0x74b960]
add esp, 4
test ebx, ebx
je 0x4c360f
mov eax, ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
lea ebx, [edi + 0xc8]
push 0xf
mov edx, esi
mov ecx, str.Content_Length:
call fcn.004d14e0
add esp, 4
test eax, eax
je 0x4c357f
push 0xa
push 0
add esi, 0xf
push esi
call dword [0x681498]
add esp, 0xc
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x1c], edx
jmp 0x4c360f
push str.close
mov edx, str.Connection:
mov ecx, esi
call fcn.004bc530
add esp, 4
test al, al
je 0x4c359d
mov byte [ebp - 5], 1
jmp 0x4c360f
push str.chunked
mov edx, str.Transfer_Encoding:
mov ecx, esi
call fcn.004bc530
add esp, 4
test al, al
je 0x4c35d1
push str.CONNECT_responded_chunked_n
push edi
call fcn.004ac3b0
mov ecx, dword [ebp - 0xc]
add esp, 8
mov byte [ebp - 6], 1
call fcn.004d9780
jmp 0x4c360f
push str.close
mov edx, str.Proxy_Connection:
mov ecx, esi
call fcn.004bc530
add esp, 4
test al, al
je 0x4c35ef
mov byte [ebp - 5], 1
jmp 0x4c360f
push ebx
lea eax, [ebp - 0x40]
push eax
push str.HTTP_1._d__d
push esi
call fcn.0047a620
add esp, 0x10
cmp eax, 2
jne 0x4c360f
mov eax, dword [ebx]
mov dword [edi + 0x86b8], eax
mov eax, dword [ebp - 0x48]
xor ebx, ebx
mov edx, dword [ebp - 0x20]
mov cl, byte [ebp - 7]
mov byte [eax], cl
mov eax, dword [ebp - 0x24]
lea esi, [edx + 1]
mov ecx, dword [ebp - 0x2c]
inc eax
inc edx
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x24], eax
cmp eax, ecx
jl 0x4c3446
jmp 0x4c37a0
cmp dword [edi + 0xc8], 0x197
lea eax, [edi + 0x584]
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x20], eax
jne 0x4c3755
cmp byte [edi + 0x8624], 0
jne 0x4c3755
mov ecx, dword [ebp - 0x18]
mov eax, ecx
mov edx, dword [ebp - 0x1c]
or eax, edx
mov dword [ebp - 0x10], 2
je 0x4c36c8
push edx
push ecx
push str.Ignore__lld_bytes_of_response_body_n
push edi
call fcn.004ac3b0
mov eax, dword [ebp - 0x2c]
add esp, 0x10
sub eax, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x18]
cdq
sub ecx, eax
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x18], ecx
sbb eax, edx
mov dword [ebp - 0x1c], eax
test eax, eax
jg 0x4c3780
jl 0x4c36b3
test ecx, ecx
jne 0x4c3780
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x10], 0
mov dword [eax], 2
jmp 0x4c37a0
cmp byte [ebp - 6], 0
je 0x4c36b3
mov eax, dword [ebp - 0x2c]
sub eax, dword [ebp - 0x24]
push eax
push str._zd_bytes_of_chunk_left_n
push edi
mov byte [edi + 0x13d], 1
call fcn.004ac3b0
mov edx, dword [ebp - 0x24]
lea eax, [esi + 1]
mov ecx, dword [ebp - 0x2c]
add esp, 0xc
cmp byte [eax], 0xa
cmovne eax, esi
mov esi, eax
lea eax, [ebp - 0x3c]
push eax
lea eax, [edx + 1]
cmovne eax, edx
sub ecx, eax
lea edx, [esi + 1]
push ecx
mov ecx, dword [ebp - 0xc]
call fcn.004d97a0
add esp, 8
cmp eax, 0xffffffff
jne 0x4c3739
push str.chunk_reading_DONE_n
push edi
call fcn.004ac3b0
add esp, 8
xor eax, eax
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x14]
mov dword [eax], 2
jmp 0x4c37a0
push dword [ebp - 0x3c]
push str.Read__zd_bytes_of_chunk__continue_n
push edi
call fcn.004ac3b0
mov eax, dword [ebp - 0x14]
add esp, 0xc
mov dword [eax], 2
jmp 0x4c37a0
xor eax, eax
cmp dword [edi + 0x86b8], 0xc8
mov dword [ebp - 0x10], eax
jne 0x4c3780
mov eax, dword [ebp - 0x2c]
sub eax, dword [ebp - 0x24]
add eax, 0xffffffff
je 0x4c3780
push eax
push str.Proxy_CONNECT_followed_by__zd_bytes_of_opaque_data._Data_ignored__known_bug_39_
push edi
call fcn.004ac430
add esp, 0xc
mov eax, dword [ebp - 0x14]
mov dword [eax], 2
jmp 0x4c37a0
push str.Proxy_CONNECT_aborted_due_to_select_poll_error
push edi
mov dword [ebp - 0x30], 1
call fcn.004ac430
add esp, 8
mov ecx, dword [ebp - 0xc]
call fcn.004bfbb0
test eax, eax
jne 0x4c386e
cmp dword [ebp - 0x28], 0x4000
mov ecx, dword [ebp - 0x10]
jb 0x4c32c1
cmp dword [ebp - 0x30], 0
jne 0x4c3997
cmp dword [edi + 0x86b8], 0xc8
mov esi, dword [ebp - 0xc]
je 0x4c37f7
mov ecx, esi
call fcn.004bbb70
test eax, eax
jne 0x4c3982
cmp byte [esi + 0x1e0], al
je 0x4c37f7
mov bl, 1
mov byte [ebp - 5], bl
jmp 0x4c37fe
mov bl, byte [ebp - 5]
test bl, bl
je 0x4c3807
cmp dword [edi + 0x144], 0
jne 0x4c387a
mov eax, dword [edi + 0x144]
mov ecx, dword [ebp - 0x14]
test eax, eax
je 0x4c3899
cmp dword [ecx], 2
jne 0x4c383c
push 0
push str.TUNNEL_STATE_switched_to:__d_n
push edi
mov dword [ecx], 0
call fcn.004ac3b0
mov eax, dword [edi + 0x144]
add esp, 0xc
mov ecx, dword [ebp - 0x14]
test eax, eax
jne 0x4c3054
jmp 0x4c3899
push dword [ebp - 0x2c]
call dword [0x74b960]
add esp, 4
mov ecx, ebx
call fcn.004bc230
mov eax, 0x1b
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, 0x2a
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x34]
mov ecx, esi
mov edx, dword [esi + eax*4 + 0x154]
call fcn.004ae180
mov eax, dword [ebp - 0x34]
mov dword [esi + eax*4 + 0x154], 0xffffffff
cmp dword [edi + 0xc8], 0xc8
je 0x4c393b
test bl, bl
je 0x4c38cd
cmp dword [edi + 0x144], 0
je 0x4c38cd
push str.Connect_me_again_please_n
push edi
mov byte [esi + 0x1f5], 1
call fcn.004ac3b0
add esp, 8
jmp 0x4c3909
push dword [edi + 0x144]
call dword [0x74b960]
mov ebx, dword [ebp - 0x34]
add esp, 4
mov dword [edi + 0x144], 0
mov ecx, esi
mov byte [esi + 0x1e0], 1
mov edx, dword [esi + ebx*4 + 0x154]
call fcn.004ae180
mov dword [esi + ebx*4 + 0x154], 0xffffffff
mov eax, dword [ebp - 0x14]
mov dword [eax], 0
cmp byte [esi + 0x1f5], 0
jne 0x4c3980
push dword [edi + 0xc8]
push str.Received_HTTP_code__d_from_proxy_after_CONNECT
push edi
call fcn.004ac430
add esp, 0xc
mov eax, 0x38
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x14]
mov dword [eax], 2
push dword [esi + 0x220]
call dword [0x74b960]
add esp, 4
mov dword [esi + 0x220], 0
mov byte [edi + 0x8620], 1
push str.Proxy_replied_OK_to_CONNECT_request_n
push edi
call fcn.004ac3b0
mov byte [edi + 0x13d], 0
add esp, 8
mov byte [esi + 0x1ef], 0
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.Proxy_CONNECT_aborted_due_to_timeout
push edi
call fcn.004ac430
add esp, 8
pop edi
pop esi
mov eax, 0x38
pop ebx
mov esp, ebp
pop ebp
ret