hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nathan Hazout (JIRA)" <j...@apache.org>
Subject [jira] [Created] (HTTPCLIENT-1682) HttpClient should allow NO port
Date Sun, 30 Aug 2015 07:16:45 GMT
Nathan Hazout created HTTPCLIENT-1682:

             Summary: HttpClient should allow NO port
                 Key: HTTPCLIENT-1682
                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1682
             Project: HttpComponents HttpClient
          Issue Type: Improvement
          Components: HttpClient
            Reporter: Nathan Hazout

I've noticed that the CNN RSS (rss.cnn.com/rss/edition.rss) worked on some applications but
not on mine.
Looking deeper, I saw that CNN rejects HTTP requests with
Host: rss.cnn.com:80
But accepts requests with
Host: rss.cnn.com

Even though 80 is the default port, it only accepts requests with NO port.

According to the HTTP standards, this is a valid request (even if, granted, strange). Also,
I've noticed that major browsers (tested on chrome) strip out the port from the request when
it is 80.

However, using HttpClient, setting no port still forces port 80 into the headers.

Shouldn't HttpClient let the developer set no port all all?
I'm not saying to automatically strip out the port like Chrome does, but maybe let the developer
decide - if he sets no port, then don't set a port for him automatically?

This message was sent by Atlassian JIRA

To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org

View raw message