You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
HTTPClientSession::proxyConnect() sends a CONNECT message to the proxy and then returns the initialised socket. However, the CONNECT message it sends to the server contains the IP address and port of the intended remote server, not the hostname and port as RFC seems to require:
The Request-URI portion of the Request-Line is always
an 'authority' as defined by URI Generic Syntax [2], which is to say
the host name and port number destination of the requested connection
separated by a colon:"
HTTPClientSession::proxyConnect() sends a CONNECT message to the proxy and then returns the initialised socket. However, the CONNECT message it sends to the server contains the IP address and port of the intended remote server, not the hostname and port as RFC seems to require:
Some Wireshark output of the relevant request, cropped to the relevant bit: https://gist.github.com/4567639
The cause is the line in HTTPClientSession::proxyConnect()
SocketAddress targetAddress(getHost(), getPort());
which does a DNS lookup on the hostname.
I have locally patched to this to some ugly slow std::stringsteam code:
, but my upstream proxy(which I think is Squid) accepts either form so this isn't that important really.
The text was updated successfully, but these errors were encountered: