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

Disassembly:
sub esp, 0x38
push ebx
push ebp
push edi
mov edi, dword [esp + 0x48]
mov ebp, dword [edi]
xor ebx, ebx
mov dword [esp + 0x38], ebx
mov eax, dword [ebp + 0x194]
cmp eax, ebx
mov dword [esp + 0x28], eax
jne 0x47a768
mov dword [esp + 0x28], 0x36ee80
mov eax, dword [esp + 0x4c]
mov ecx, dword [edi + eax*4 + 0x130]
mov dword [esp + 0x2c], ecx
cmp dword [edi + eax*4 + 0x484], 2
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x24], ebx
jne 0x47a79e
pop edi
pop ebp
xor eax, eax
pop ebx
add esp, 0x38
ret
mov dword [edi + 0x1f8], ebx
push esi
jmp 0x47a7b0
cmp dword [edi + eax*4 + 0x484], ebx
jne 0x47a9d5
movzx esi, word [esp + 0x58]
mov edx, dword [esp + 0x54]
push esi
push edx
push str.Establish_HTTP_proxy_tunnel_to__s:_hu_n
push ebp
call fcn.004622f0
mov eax, dword [ebp + 0xcc]
add esp, 0x10
cmp eax, ebx
je 0x47a7f0
push eax
call dword [0x50b0d8]
add esp, 4
mov dword [ebp + 0xcc], ebx
call fcn.00475310
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x1c], ebx
je 0x47b053
mov eax, dword [esp + 0x54]
push esi
push eax
push str._s:_hu
call fcn.00464cc0
mov edi, eax
add esp, 0xc
test edi, edi
je 0x47b049
mov ecx, dword [esp + 0x4c]
push 1
push edi
push str.CONNECT
push ecx
call fcn.00474f10
push edi
mov esi, eax
call dword [0x50b0d8]
add esp, 0x14
test esi, esi
jne 0x47b035
mov esi, dword [esp + 0x4c]
cmp dword [esi + 0x114], 1
mov ebx, 0x4dc6aa
mov dword [esp + 0x24], ebx
mov dword [esp + 0x18], ebx
mov dword [esp + 0x10], 0x4f0fc8
je 0x47a870
mov dword [esp + 0x10], 0x4f0fcc
mov eax, dword [esi + 0x1b8]
test eax, eax
mov edx, 0x4ed10c
jne 0x47aaec
mov edx, ebx
mov eax, ebx
movzx ecx, word [esp + 0x58]
push ecx
push edx
mov edx, dword [esp + 0x5c]
push edx
push eax
push str._s_s_s:_hu
call fcn.00464cc0
mov edi, eax
add esp, 0x14
test edi, edi
je 0x47b060
push str.Host:
push ebp
call fcn.004749c0
add esp, 8
test eax, eax
jne 0x47a8d5
push edi
push str.Host:__s_r_n
call fcn.00464cc0
mov ebx, eax
add esp, 8
test ebx, ebx
je 0x47b07b
push str.Proxy_Connection:
push ebp
call fcn.004749c0
add esp, 8
test eax, eax
jne 0x47a8ef
mov dword [esp + 0x24], str.Proxy_Connection:_Keep_Alive_r_n
push str.User_Agent:
push ebp
call fcn.004749c0
add esp, 8
test eax, eax
jne 0x47a915
mov eax, dword [ebp + 0x394]
test eax, eax
je 0x47a915
mov eax, dword [esi + 0x22c]
mov dword [esp + 0x18], eax
mov eax, dword [esi + 0x228]
test eax, eax
jne 0x47a924
mov eax, 0x4dc6aa
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x18]
push ecx
mov ecx, dword [esp + 0x20]
push edx
push eax
mov eax, dword [esp + 0x1c]
push ebx
push eax
push edi
push str.CONNECT__s_HTTP__s_r_n_s_s_s_s
push ecx
call fcn.00475c60
add esp, 0x20
test ebx, ebx
mov esi, eax
je 0x47a95d
cmp byte [ebx], 0
je 0x47a95d
push ebx
call dword [0x50b0d8]
add esp, 4
push edi
call dword [0x50b0d8]
add esp, 4
test esi, esi
jne 0x47b01d
mov ebx, dword [esp + 0x1c]
mov edi, dword [esp + 0x4c]
push ebx
push edi
call fcn.00475d60
mov esi, eax
add esp, 8
test esi, esi
jne 0x47b01d
push 0x4de610
push ebx
call fcn.00475c60
mov esi, eax
add esp, 8
test esi, esi
jne 0x47b01d
mov ebx, dword [esp + 0x50]
push ebx
push eax
mov eax, dword [esp + 0x24]
lea edx, [ebp + 0x86b4]
push edx
push edi
push eax
call fcn.00475320
mov esi, eax
add esp, 0x14
test esi, esi
jne 0x47b01d
mov dword [edi + ebx*4 + 0x484], 1
xor ebx, ebx
mov ecx, dword [edi + 0x124]
mov edx, dword [edi + 0x120]
push ecx
push edx
call fcn.00466ae0
push edx
push eax
call fcn.00466b00
mov ecx, dword [esp + 0x3c]
sub ecx, eax
add esp, 0x10
test ecx, ecx
jle 0x47b09d
cmp dword [ebp + 0x530], 2
jne 0x47aa23
mov edx, dword [esp + 0x30]
push ebx
push 0xffffffffffffffff
push 0xffffffffffffffff
push edx
call fcn.00478740
add esp, 0x10
test eax, eax
je 0x47b178
lea eax, [ebp + 0x54c]
xor ebx, ebx
mov dword [esp + 0x1c], eax
mov esi, eax
mov dword [esp + 0x24], ebx
mov dword [esp + 0x18], ebx
mov dword [esp + 0x10], 1
mov eax, dword [esp + 0x10]
test eax, eax
je 0x47af89
mov eax, dword [esp + 0x28]
test eax, eax
jne 0x47b0ab
mov eax, dword [edi + 0x124]
mov ecx, dword [edi + 0x120]
push eax
push ecx
call fcn.00466ae0
push edx
push eax
call fcn.00466b00
mov ecx, dword [esp + 0x3c]
sub ecx, eax
add esp, 0x10
test ecx, ecx
jle 0x47b09d
cmp ecx, 0x3e8
jl 0x47aa91
mov ecx, 0x3e8
mov edx, dword [esp + 0x30]
push ecx
push 0xffffffffffffffff
push 0xffffffffffffffff
push edx
call fcn.00478740
add esp, 0x10
cmp eax, 0xffffffff
je 0x47af52
test eax, eax
je 0x47af68
mov edx, dword [esp + 0x1c]
lea eax, [esp + 0x14]
push eax
mov eax, dword [esp + 0x34]
mov ecx, 0x4000
sub ecx, ebx
push ecx
push edx
push eax
push edi
call fcn.00462020
add esp, 0x14
cmp eax, 0x51
je 0x47af7d
xor ecx, ecx
cmp eax, ecx
je 0x47aaf6
mov dword [esp + 0x10], ecx
jmp 0x47af68
mov eax, 0x4ed0f0
jmp 0x47a887
mov eax, dword [esp + 0x14]
cmp eax, ecx
jg 0x47ab2b
cmp dword [ebp + 0x110], ecx
mov dword [esp + 0x10], ecx
je 0x47ab21
cmp dword [ebp + 0x85ec], ecx
je 0x47ab21
mov dword [edi + 0x1f8], 1
jmp 0x47af68
push str.Proxy_CONNECT_aborted
jmp 0x47af57
mov edx, dword [esp + 0x10]
add ebx, eax
cmp edx, 1
mov dword [esp + 0x24], ebx
jle 0x47abe2
mov edx, dword [esp + 0x40]
mov ebx, dword [esp + 0x44]
or edx, ebx
mov dword [esp + 0x24], ecx
lea ecx, [ebp + 0x54c]
mov dword [esp + 0x1c], ecx
je 0x47ab8c
mov ecx, dword [esp + 0x40]
cdq
sub ecx, eax
mov eax, ebx
sbb eax, edx
test eax, eax
mov dword [esp + 0x40], ecx
mov dword [esp + 0x44], eax
jg 0x47af68
jl 0x47ab7f
mov eax, ecx
test eax, eax
ja 0x47af68
mov dword [esp + 0x10], 0
jmp 0x47af68
lea edx, [esp + 0x34]
push edx
push eax
push ecx
xor ebx, ebx
push edi
mov dword [esp + 0x44], ebx
call fcn.0047c440
add esp, 0x10
cmp eax, 0xffffffff
jne 0x47abca
push str.chunk_reading_DONE_n
push ebp
call fcn.004622f0
mov eax, dword [esp + 0x58]
mov dword [esp + 0x18], ebx
mov dword [edi + eax*4 + 0x484], 2
jmp 0x47af65
mov ecx, dword [esp + 0x34]
push ecx
push str.Read__zd_bytes_of_chunk__continue_n
push ebp
call fcn.004622f0
add esp, 0xc
jmp 0x47af68
xor ebx, ebx
test eax, eax
mov dword [esp + 0x34], ebx
jle 0x47af68
inc dword [esp + 0x18]
mov edx, dword [esp + 0x1c]
cmp byte [edx], 0xa
jne 0x47adb1
mov eax, dword [ebp + 0x2d4]
test eax, eax
je 0x47ac1d
mov eax, dword [esp + 0x18]
push edi
push eax
push esi
push 1
push ebp
call fcn.00462170
add esp, 0x14
mov ecx, dword [ebp + 0x2b8]
test ecx, ecx
mov eax, 2
je 0x47ac31
mov eax, 3
mov ecx, dword [esp + 0x18]
push ecx
push esi
push eax
push edi
call fcn.004627b0
add esp, 0x10
test eax, eax
jne 0x47b17a
mov al, byte [esi]
cmp al, 0xd
je 0x47adcc
cmp al, 0xa
je 0x47adcc
mov eax, dword [esp + 0x18]
mov bl, byte [eax + esi]
push 0x11
push esi
push str.WWW_Authenticate:
mov byte [eax + esi], 0
call fcn.0047b340
add esp, 0xc
test eax, eax
je 0x47ac87
mov eax, dword [ebp + 0x90]
cmp eax, 0x191
je 0x47aca8
push 0x13
push esi
push str.Proxy_authenticate:
call fcn.0047b340
add esp, 0xc
test eax, eax
je 0x47acc0
mov eax, dword [ebp + 0x90]
cmp eax, 0x197
jne 0x47acc0
push esi
push eax
push edi
call fcn.00475030
add esp, 0xc
test eax, eax
jne 0x47b17a
jmp 0x47ad8f
push 0xf
push esi
push str.Content_Length:
call fcn.0047b340
add esp, 0xc
test eax, eax
je 0x47acf1
push 0xa
lea edx, [esi + 0xf]
push 0
push edx
call fcn.00486f01
add esp, 0xc
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], edx
jmp 0x47ad8f
push str.close
push str.Connection:
push esi
call fcn.004755e0
add esp, 0xc
test eax, eax
je 0x47ad12
mov dword [esp + 0x20], 1
jmp 0x47ad8f
push str.chunked
push str.Transfer_Encoding:
push esi
call fcn.004755e0
add esp, 0xc
test eax, eax
je 0x47ad47
push str.CONNECT_responded_chunked_n
push ebp
call fcn.004622f0
push edi
mov dword [esp + 0x44], 1
call fcn.0047c420
add esp, 0xc
jmp 0x47ad8f
push str.close
push str.Proxy_Connection:
push esi
call fcn.004755e0
add esp, 0xc
test eax, eax
je 0x47ad68
mov dword [esp + 0x20], 1
jmp 0x47ad8f
lea edi, [ebp + 0x90]
push edi
lea eax, [esp + 0x40]
push eax
push str.HTTP_1._d__d
push esi
call fcn.00486af6
add esp, 0x10
cmp eax, 2
jne 0x47ad8f
mov ecx, dword [edi]
mov dword [ebp + 0x86a0], ecx
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
mov edi, dword [esp + 0x4c]
mov byte [edx + esi], bl
mov ebx, dword [esp + 0x34]
lea esi, [eax + 1]
mov eax, dword [esp + 0x14]
mov dword [esp + 0x18], 0
mov ecx, dword [esp + 0x1c]
inc ecx
inc ebx
cmp ebx, eax
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x34], ebx
jl 0x47abf0
jmp 0x47af68
lea eax, [ebp + 0x54c]
mov dword [esp + 0x1c], eax
mov eax, dword [ebp + 0x90]
xor ecx, ecx
cmp eax, 0x197
mov dword [esp + 0x24], ecx
jne 0x47af17
cmp dword [ebp + 0x85fc], ecx
jne 0x47af17
mov edx, dword [esp + 0x40]
mov eax, dword [esp + 0x44]
or edx, eax
mov dword [esp + 0x10], 2
je 0x47ae6c
mov ecx, dword [esp + 0x40]
push eax
push ecx
push str.Ignore__lld_bytes_of_response_body_n
push ebp
call fcn.004622f0
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x50]
sub eax, ebx
cdq
add esp, 0x10
sub ecx, eax
mov eax, dword [esp + 0x44]
sbb eax, edx
test eax, eax
mov dword [esp + 0x40], ecx
mov dword [esp + 0x44], eax
jg 0x47af41
jl 0x47ae50
mov eax, ecx
test eax, eax
ja 0x47af41
mov edx, dword [esp + 0x50]
mov dword [esp + 0x10], 0
mov dword [edi + edx*4 + 0x484], 2
jmp 0x47af68
cmp dword [esp + 0x38], ecx
je 0x47af02
mov edx, dword [esp + 0x14]
sub edx, ebx
push edx
push str._zd_bytes_of_chunk_left_n
push ebp
mov dword [ebp + 0xc0], 1
call fcn.004622f0
mov al, byte [esi + 1]
add esp, 0xc
cmp al, 0xa
jne 0x47ae9e
inc esi
inc ebx
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x14]
push eax
sub ecx, ebx
push ecx
lea edx, [esi + 1]
push edx
push edi
call fcn.0047c440
add esp, 0x10
cmp eax, 0xffffffff
jne 0x47aef0
push str.chunk_reading_DONE_n
push ebp
call fcn.004622f0
mov eax, dword [esp + 0x58]
mov edx, eax
mov dword [edi + eax*4 + 0x484], 2
add esp, 8
mov dword [esp + 0x10], 0
mov dword [edi + edx*4 + 0x484], 2
jmp 0x47af68
mov ecx, dword [esp + 0x14]
push ecx
push str.Read__zd_bytes_of_chunk__continue_n
push ebp
call fcn.004622f0
jmp 0x47af3e
mov edx, dword [esp + 0x50]
mov dword [esp + 0x10], ecx
mov dword [edi + edx*4 + 0x484], 2
jmp 0x47af68
cmp dword [ebp + 0x86a0], 0xc8
mov dword [esp + 0x10], ecx
jne 0x47af41
mov eax, dword [esp + 0x14]
sub eax, ebx
dec eax
cmp eax, ecx
je 0x47af41
push eax
push str.Proxy_CONNECT_followed_by__zd_bytes_of_opaque_data._Data_ignored__known_bug_39_
push ebp
call fcn.004623b0
add esp, 0xc
mov edx, dword [esp + 0x50]
mov dword [edi + edx*4 + 0x484], 2
jmp 0x47af68
push str.Proxy_CONNECT_aborted_due_to_select_poll_error
push ebp
mov dword [esp + 0x30], 1
call fcn.004623b0
add esp, 8
push edi
call fcn.00479f90
add esp, 4
test eax, eax
jne 0x47b0b8
mov ebx, dword [esp + 0x24]
cmp ebx, 0x4000
jb 0x47aa41
mov eax, dword [esp + 0x28]
test eax, eax
jne 0x47b0ab
cmp dword [ebp + 0x86a0], 0xc8
je 0x47afc6
push edi
call fcn.00475a90
xor ebx, ebx
add esp, 4
cmp eax, ebx
jne 0x47b17a
cmp dword [edi + 0x1a0], ebx
je 0x47afc8
mov dword [esp + 0x20], 1
jmp 0x47afce
xor ebx, ebx
cmp dword [esp + 0x20], ebx
je 0x47afda
cmp dword [ebp + 0xcc], ebx
jne 0x47b0c5
cmp dword [ebp + 0xcc], ebx
mov esi, dword [esp + 0x50]
je 0x47b006
cmp dword [edi + esi*4 + 0x484], 2
jne 0x47b006
push ebx
push str.TUNNEL_STATE_switched_to:__d_n
push ebp
mov dword [edi + esi*4 + 0x484], ebx
call fcn.004622f0
add esp, 0xc
cmp dword [ebp + 0xcc], ebx
je 0x47b0e5
mov eax, dword [esp + 0x50]
xor ebx, ebx
jmp 0x47a7b0
push str.Failed_sending_CONNECT_to_proxy
push ebp
call fcn.004623b0
add esp, 8
mov eax, esi
pop esi
pop edi
pop ebp
pop ebx
add esp, 0x38
ret
push ebx
call dword [0x50b0d8]
add esp, 4
mov eax, esi
pop esi
pop edi
pop ebp
pop ebx
add esp, 0x38
ret
push ebx
call dword [0x50b0d8]
add esp, 4
pop esi
pop edi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x38
ret
mov eax, dword [esp + 0x1c]
push eax
call dword [0x50b0d8]
add esp, 4
pop esi
pop edi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x38
ret
push edi
call dword [0x50b0d8]
mov ecx, dword [esp + 0x20]
push ecx
call dword [0x50b0d8]
add esp, 8
pop esi
pop edi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x38
ret
push str.Proxy_CONNECT_aborted_due_to_timeout
push ebp
call fcn.004623b0
add esp, 8
pop esi
pop edi
pop ebp
mov eax, 0x38
pop ebx
add esp, 0x38
ret
pop esi
pop edi
pop ebp
mov eax, 0x2a
pop ebx
add esp, 0x38
ret
mov esi, dword [esp + 0x50]
mov edx, dword [edi + esi*4 + 0x130]
push edx
push edi
call fcn.004631d0
add esp, 8
mov dword [edi + esi*4 + 0x130], 0xffffffff
mov eax, dword [ebp + 0x90]
cmp eax, 0xc8
je 0x47b12f
push eax
push str.Received_HTTP_code__d_from_proxy_after_CONNECT
push ebp
call fcn.004623b0
mov eax, dword [esp + 0x2c]
add esp, 0xc
cmp eax, ebx
je 0x47b11b
cmp dword [ebp + 0xcc], ebx
je 0x47b11b
mov dword [edi + 0x1f8], 1
mov dword [edi + esi*4 + 0x484], ebx
pop esi
pop edi
pop ebp
mov eax, 0x38
pop ebx
add esp, 0x38
ret
mov dword [edi + esi*4 + 0x484], 2
mov eax, dword [edi + 0x228]
cmp eax, ebx
je 0x47b154
push eax
call dword [0x50b0d8]
add esp, 4
mov dword [edi + 0x228], ebx
push 0x4f1d10
mov dword [edi + 0x228], ebx
push ebp
mov dword [ebp + 0x85f0], 1
call fcn.004622f0
add esp, 8
mov dword [ebp + 0xc0], ebx
xor eax, eax
pop esi
pop edi
pop ebp
pop ebx
add esp, 0x38
ret