Function at 0x140051070
Capabilities:
Check http status code

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r14
push r15
sub rsp, 0x30
mov rbp, r8
mov rdi, rdx
mov r15, rcx
lea rdx, str.WWW_Authenticate:
mov r8d, reloc.WS2_32.dll_recvfrom
mov rcx, r9
mov rbx, r9
call fcn.14002fa10
test eax, eax
je 0x1400510bd
mov r14d, dword [rdi + 0x13c]
cmp r14d, 0x191
je 0x1400510e6
mov r8d, reloc.WS2_32.dll_send
lea rdx, str.Proxy_authenticate:
mov rcx, rbx
call fcn.14002fa10
test eax, eax
je 0x140051144
mov r14d, dword [rdi + 0x13c]
cmp r14d, 0x197
jne 0x140051144
mov rcx, rbx
call fcn.140059040
mov rsi, rax
test rax, rax
jne 0x140051100
mov eax, 0x1b
jmp 0x14005130e
mov r9, rbx
lea r8, str.CONNECT:_fwd_auth_header__s
mov rdx, r15
mov rcx, rdi
call fcn.1400317f0
cmp r14d, 0x197
mov r8, rsi
mov rcx, rdi
sete dl
call fcn.14005a6d0
mov rcx, rsi
mov ebx, eax
call qword [fcn.1400c1880]
test ebx, ebx
je 0x14005130c
mov eax, ebx
jmp 0x14005130e
mov r8d, reloc.WS2_32.dll_ntohs
lea rdx, str.Content_Length:
mov rcx, rbx
call fcn.14002fa10
test eax, eax
je 0x1400511a1
mov r8d, dword [rdi + 0x13c]
lea eax, [r8 - 0xc8]
cmp eax, 0x64
jae 0x140051184
lea rdx, str.Ignoring_Content_Length_in_CONNECT__03d_response
mov rcx, rdi
call fcn.1400317a0
jmp 0x14005130c
lea r9, [rbp + 0xa0]
xor edx, edx
lea rcx, [rbx + 0xf]
mov r8d, 0xa
call fcn.14005ff40
jmp 0x14005130c
lea r9, str.close
mov qword [rsp + 0x20], 5
mov r8d, listen
lea rdx, str.Connection:
mov rcx, rbx
call fcn.140058f60
test al, al
jne 0x140051305
mov r8d, reloc.WS2_32.dll_select
lea rdx, str.Transfer_Encoding:
mov rcx, rbx
call fcn.14002fa10
test eax, eax
je 0x140051265
mov r8d, dword [rdi + 0x13c]
lea eax, [r8 - 0xc8]
cmp eax, 0x64
jae 0x14005120e
lea rdx, str.Ignoring_Transfer_Encoding_in_CONNECT__03d_response
mov rcx, rdi
call fcn.1400317a0
jmp 0x14005130c
lea r9, str.chunked
mov qword [rsp + 0x20], 7
mov r8d, reloc.WS2_32.dll_select
lea rdx, str.Transfer_Encoding:
mov rcx, rbx
call fcn.140058f60
test al, al
je 0x14005130c
lea rdx, str.CONNECT_responded_chunked
mov rcx, rdi
call fcn.1400317a0
lea rdx, [rbp + 0x50]
mov byte [rbp + 0xac], 1
mov r8b, 1
mov rcx, rdi
call fcn.14007d8e0
jmp 0x14005130c
lea r9, str.close
mov qword [rsp + 0x20], 5
mov r8d, reloc.WS2_32.dll_recvfrom
lea rdx, str.Proxy_Connection:
mov rcx, rbx
call fcn.140058f60
test al, al
jne 0x140051305
mov r8d, 7
lea rdx, str.HTTP_1.
mov rcx, rbx
call fcn.1400c8910
test eax, eax
jne 0x14005130c
movzx eax, byte [rbx + 7]
sub al, 0x30
cmp al, 1
ja 0x14005130c
cmp byte [rbx + 8], 0x20
jne 0x14005130c
movsx ecx, byte [rbx + 9]
lea eax, [rcx - 0x30]
cmp al, 9
ja 0x14005130c
movsx edx, byte [rbx + 0xa]
lea eax, [rdx - 0x30]
cmp al, 9
ja 0x14005130c
movsx r8d, byte [rbx + 0xb]
lea eax, [r8 - 0x30]
cmp al, 9
ja 0x14005130c
movzx eax, byte [rbx + 0xc]
sub al, 0x30
cmp al, 9
jbe 0x14005130c
lea ecx, [rcx + rcx*4]
lea ecx, [rdx + rcx*2]
lea ecx, [rcx + rcx*4]
lea ecx, [rcx - 0xa68]
lea ecx, [r8 + rcx*2]
mov dword [rdi + 0x13c], ecx
mov dword [rdi + 0x12bc], ecx
jmp 0x14005130c
mov byte [rbp + 0xad], 1
xor eax, eax
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
add rsp, 0x30
pop r15
pop r14
pop rdi
ret