Infinitive loop of requests with HTTP proxy in certain conditions #6828
Labels
Comments
Probably there should be a check that all the headers were received before deciding whether to retry the request due to auth. |
bagder
added a commit
that referenced
this issue
Apr 5, 2021
... to fix the retry-loop. Reported-by: Daniel Kurečka Fixes #6828 Closes #[fill in]
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I did this
Recently I came up to a few public proxies that were returning 407 status code with Proxy-Authenticate response header while also missing final CRLF to indicate end-of-headers. Curl with such a proxy will repeat the CONNECT request indefinitely.
Here is how to reproduce it:
curl -v -x http://localhost:8787 https://example.com
I expected the following
It should end up with some error instead.
curl/libcurl version
curl 7.75.0 (x86_64-pc-linux-musl) libcurl/7.75.0 OpenSSL/1.1.1k zlib/1.2.11 libssh2/1.9.0 nghttp2/1.41.0
Release-Date: 2021-02-03
Protocols: dict file ftp ftps gopher gophers http https imap imaps mqtt pop3 pop3s rtsp scp sftp smb smbs smtp smtps telnet tftp
Features: alt-svc AsynchDNS HTTP2 HTTPS-proxy IPv6 Largefile libz NTLM NTLM_WB SSL TLS-SRP UnixSockets
operating system
Linux flanker 5.4.0-70-generic 78-Ubuntu SMP Fri Mar 19 13:29:52 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
The text was updated successfully, but these errors were encountered: