Jump to content

Sending a HEAD request returns 407 Proxy Authentication Required


fungi8210

Recommended Posts

Hi,

    I'm trying to send a HEAD request to a webserver to query a file's meta data.

I used telnet to connect to my remote webserver as such

 

> telnet kitty.2y.idv.tw 80

 

I then typed a HEAD request message as

 

HEAD http://kitty.2y.idv.tw/pro/she.3gp HTTP/1.1

Host: kitty.2y.idv.tw

 

but It returns 407 Authentication Required.

 

If instead, I sent my HEAD request as

 

HEAD /pro/she.3gp HTTP/1.1

Host: kitty.2y.idv.tw

 

I will successfully received the HEAD response.

 

Can anybody explain to me why this is happening?

This only happens to kitty.2y.idv.tw, I tried it on other webserver and it works file with absolute URI

 

So which URI is the legitmate one to use? Absolute URI or Relative URI?

 

thanks!

I'd guess (and it is only a guess) that the message should be self-explanatory and that the different form triggers a proxy routing on that server due to a malformed HEAD resource request.

 

If the URI which omits the server name doesn't trigger the proxy request I'd go with that if it raises no other side issues. The RFCs seem as clear as mud here but maybe you might check them over?

 

Header Field Definitions RFC http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.23

 

HEAD http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html

 

HEAD http://en.wikipedia.org/wiki/HTTP#Request_Methods

 

http://gbiv.com/protocols/uri/rfc/rfc3986.html#generic-syntax

 

 

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.