cURL / Mailing Lists / curl-library / Single Mail


Re: Upload via proxy

From: Daniel Stenberg <>
Date: Fri, 21 Dec 2001 09:10:15 +0100 (MET)

On Thu, 20 Dec 2001, raoul cridlig wrote:

> I can upload via proxy with curl bin, but not with my code, and I don't
> understand why...

So what command line options do you use to make it work?

> curl_easy_setopt(curl, CURLOPT_POSTQUOTE, headerlist);

Uh. When doing FTP upload over a HTTP proxy, you can't do CURLOPT_POSTQUOTE
unless you "tunnel" trough the proxy using the CURLOPT_HTTPPROXYTUNNEL

FAQ entry 3.12 explains this:

  3.12 Why do FTP specific features over HTTP proxy fail?

  Because when you use a HTTP proxy, the protocol spoken on the network will
  be HTTP, even if you specify a FTP URL. This effectively means that you
  normally can't use FTP specific features such as ftp upload and ftp quote

  There is one exception to this rule, and that is if you can "tunnel
  through" the given HTTP proxy. Proxy tunneling is enabled with a special
  option (-p) and is generally not available as proxy admins usually disable
  tunneling to other ports than 443 (which is used for HTTPS access through

    Daniel Stenberg -- curl groks URLs --
Received on 2001-12-22