cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Downloading a file through HTTP proxy gives incorrect progress data when used CURLOPT_PROGRESSFUNCTION

From: Ray Satiro via curl-library <curl-library_at_cool.haxx.se>
Date: Mon, 24 Oct 2016 23:22:46 -0400

On 10/24/2016 7:22 PM, manish wrote:
> Thanks for the response. If proxy reply didn't include content length,
> does that means my proxy set up have issues? I used basic steps to set
> up a squid http proxy.

Please don't top post [1]. I don't know if your proxy has issues. I set
up squid 3.5 with a default configuration and when I request some FTP
files (all from the same FTP server) squid replies with either chunked
transfer encoding or content length, it looks like depending on the file
type. In the case of chunked transfer then the total size is unknown,
which is expected. For example I requested a binary file and it replied
with

< Content-Type: text/plain
< Content-Length: 113234161

then I requested an xml file from the same server and it replied with

< Content-Type: text/xml
< Transfer-Encoding: chunked

css was also chunked. All files had the correct content, none had
unwanted CRLF conversion.

If you want to find out why squid doesn't give you the content length
for your file, or why there is CRLF conversion, I would ask squid
support [2].

[1]: https://curl.haxx.se/mail/etiquette.html#Do_Not_Top_Post
[2]: http://www.squid-cache.org/Support/

-------------------------------------------------------------------
List admin: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2016-10-25