Re: wwwoffle make GET from HEAD

Juliusz Chroboczek <[email protected]>
Newsgroups gmane.network.wwwoffle.user
Message-ID <[email protected]>
> > > What browser are you using that makes a HEAD request followed by a GET
> > > request?

> > Both IE and Mozilla-derived browsers do that on file downloads (that's
> > how they can display the file size and the MIME type in the ``save
> > as'' dialog).

> Firefox doesn't show the size of mime type in the save-as dialog box
> for me.

Same here, but it still send a HEAD request before displaying the
dialog box (see the attached trace).  Curiously enough, both requests
are marked uncacheable, which makes the issue you point out even worse.

> Why can't they use a GET request and start downloading in the
> background.

I agree, that's The Right Thing to do in that case.

> The best option would then seem to be that when online a HEAD request
> to WWWOFFLE is a non-cached HEAD request to the end server (unless the
> cached page is new enough not to make the request).

What I've done in Polipo was caching both HEAD and GET requests, and
allowing a cached GET to satisfy a client-side HEAD.

                                        Juliusz

P.S. Here's a trace of what Firefox 0.9.3  (Debian GNU/Linux) does on
     ``save as'':

HEAD /test.bin HTTP/1.1
Host: lanthane.pps.jussieu.fr:1234
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040917 Firefox/0.9.3
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Accept-Language: en
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 300
Connection: keep-alive
Pragma: no-cache
Cache-Control: no-cache

HTTP/1.1 200 Okay
Content-Type: application/octet-stream
Content-Length: 123

GET /test.bin HTTP/1.1
Host: lanthane.pps.jussieu.fr:1234
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040917 Firefox/0.9.3
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Accept-Language: en
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 300
Connection: keep-alive
Referer: http://www.pps.jussieu.fr/~jch/test.html
Pragma: no-cache
Cache-Control: no-cache
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.