On Thu, May 21, 2015 at 10:57:45AM -0400, Sean Boudreau wrote:
>
> On Thu, May 21, 2015 at 02:11:02PM +0200, Daniel Stenberg wrote:
> > On Thu, 21 May 2015, Daniel Stenberg wrote:
> >
> > >Right, and that's a combination we really should not allow. It is
> > >a bug. CURLOPT_HTTPPROXYTUNNEL implies a HTTP proxy, and socks5
> > >means no HTTPTUNNEL...
> >
> > ... so I say we apply this patch so that setting either proxy type
> > or proxytunnel make sure the other option is sensible.
> >
> > You agree?
> >
>
> Isn't it also possible for proxytype to be derived from CURLOPT_PROXY
> by parse_proxy()? ie. I could set CURLOPT_PROXY
> "socks5://<addr>:<port>" and still end up with tunnel_proxy set but not
> httpproxy?
>
> BTW the comment above parse_proxy() should have the bit about it freeing
> the argument removed.
ie this is also needed?
---------------------------------------------------------------------
This transmission (including any attachments) may contain confidential
information, privileged material (including material protected by the
solicitor-client or other applicable privileges), or constitute non-public
information. Any use of this information by anyone other than the intended
recipient is prohibited. If you have received this transmission in error,
please immediately reply to the sender and delete this information from your
system. Use, dissemination, distribution, or reproduction of this transmission
by unintended recipients is not authorized and may be unlawful.
diff --git a/lib/url.c b/lib/url.c
index 1b57ef1..7a603b8 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -5566,8 +5566,10 @@ static CURLcode create_conn(struct SessionHandle *data,
conn->bits.httpproxy = TRUE;
#endif
}
- else
+ else {
conn->bits.httpproxy = FALSE; /* not a HTTP proxy */
+ conn->bits.tunnel_proxy = FALSE;
+ }
conn->bits.proxy = TRUE;
}
else {
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html