curl-library
Re: Name resolution when using a proxy
From: Daniel Stenberg <daniel_at_haxx.se>
Date: Mon, 16 Jan 2006 23:50:17 +0100 (CET)
Date: Mon, 16 Jan 2006 23:50:17 +0100 (CET)
On Mon, 16 Jan 2006, Karl M wrote:
(Please don't start a new thread by replying to an old mail, it makes threaded
displays screwed up.)
> At one time I thought I saw something on this, but now I can't find it in
> the documentation. When I am using a proxy, how do I (or can I) control
> whether the target url is resolved locally or by the proxy? I have
> conditions where I need both choices.
With HTTP the client hands over the full URL to the proxy and the proxy will
resolve the host name.
If you *really* want to do it client-side, then you need to first resolve the
name and then "re-arrange" the URL to use IP numericals only and set the Host:
header to contain the host name you resolved.
-- Commercial curl and libcurl Technical Support: http://haxx.se/curl.htmlReceived on 2006-01-16