commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Lubke <Ryan.Lu...@Sun.COM>
Subject [httpclient] Patch for HttpMethodBase.addHostRequestHeader
Date Tue, 21 May 2002 20:41:20 GMT
Hi,

According to section 14.23 of RFC 2616,
the host header can also have a port.  If the port is omitted from the
header, then port 80 is assumed.  Since the method never considers a
port, then if accessing a server on, say, 8080, would produce an
incorrect header.

I've attached a possible fix for this.

Additionally, within the same section, it states that if the requested
URI does not include an Internet host name for the service being
request, that the Host header should be given an emtpy value.  I'm
assuming this means an IP address vs a hostname.  I currently don't see
any logic to handle this.  Did I miss something here?

Thanks

-rl





Mime
View raw message