From: Raindog <ra...@ma...> - 2010-12-09 05:24:04
|
Hello, I discovered that when using a url such as "http://www.example.com:8080", that the HTTP header will only contain: Host: www.example.com When it should contain (at least according to Curl and .NET) the non-default port after it. such as: Host: www.example.com:8080 Thanks. P.S. I got my file uploader working.. Took a while to test everything because of various build issues, but all is done. |
From: Dean M. B. <mik...@gm...> - 2010-12-09 05:27:43
|
On Thu, Dec 9, 2010 at 1:23 PM, Raindog <ra...@ma...> wrote: > Hello, > > I discovered that when using a url such as > "http://www.example.com:8080", that the HTTP header will only contain: > > Host: www.example.com > > When it should contain (at least according to Curl and .NET) the > non-default port after it. such as: > > Host: www.example.com:8080 > Interesting. This looks like a bug to me. Can you file it in https://github.com/cpp-netlib/cpp-netlib/issues ? > > Thanks. > > P.S. > > I got my file uploader working.. Took a while to test everything because > of various build issues, but all is done. > Cool, thanks for letting us know! -- Dean Michael Berris deanberris.com |
From: Raindog <ra...@ma...> - 2010-12-09 07:30:00
|
On 12/8/2010 9:27 PM, Dean Michael Berris wrote: > On Thu, Dec 9, 2010 at 1:23 PM, Raindog<ra...@ma...> wrote: > > Hello, > > > > I discovered that when using a url such as > > "http://www.example.com:8080", that the HTTP header will only contain: > > > > Host: www.example.com > > > > When it should contain (at least according to Curl and .NET) the > > non-default port after it. such as: > > > > Host: www.example.com:8080 > > > > Interesting. This looks like a bug to me. Can you file it in > https://github.com/cpp-netlib/cpp-netlib/issues ? > > > > > Thanks. > > > > P.S. > > > > I got my file uploader working.. Took a while to test everything because > > of various build issues, but all is done. > > > > Cool, thanks for letting us know! > > I also had an issue with some headers not being able to be removed w/ the remove_header directive nor w/ request.remove_header. After some digging it turns out that the headers I wanted to remove are hard coded to be added. Thingslike: Connection: Close and Accept-Encoding During my debugging I was trying to recreate some known working HTTP requests and the working requests did not have those headers so I wanted to remove them but couldn't. Turns out that it did work with them added so it wasn't a big deal. |
From: Dean M. B. <mik...@gm...> - 2010-12-09 07:37:58
|
On Thu, Dec 9, 2010 at 3:29 PM, Raindog <ra...@ma...> wrote: > > I also had an issue with some headers not being able to be removed w/ > the remove_header directive nor w/ request.remove_header. After some > digging it turns out that the headers I wanted to remove are hard coded > to be added. Thingslike: > > Connection: Close > > and > > Accept-Encoding > > During my debugging I was trying to recreate some known working HTTP > requests and the working requests did not have those headers so I wanted > to remove them but couldn't. Turns out that it did work with them added > so it wasn't a big deal. > Is this 0.8? The Connection header AFAIK is required in HTTP requests. In HTTP/1.1 the Accept-Encoding header tells the server to actually just send data encoded a certain way. In 0.9 this should change. Please file issues at https://github.com/cpp-netlib/cpp-netlib/issues so that we can track this appropriately. -- Dean Michael Berris deanberris.com |
From: Raindog <ra...@ma...> - 2010-12-09 07:48:00
|
On 12/8/2010 11:37 PM, Dean Michael Berris wrote: > On Thu, Dec 9, 2010 at 3:29 PM, Raindog<ra...@ma...> wrote: > > > > I also had an issue with some headers not being able to be removed w/ > > the remove_header directive nor w/ request.remove_header. After some > > digging it turns out that the headers I wanted to remove are hard coded > > to be added. Thingslike: > > > > Connection: Close > > > > and > > > > Accept-Encoding > > > > During my debugging I was trying to recreate some known working HTTP > > requests and the working requests did not have those headers so I wanted > > to remove them but couldn't. Turns out that it did work with them added > > so it wasn't a big deal. > > > > Is this 0.8? The Connection header AFAIK is required in HTTP requests. > In HTTP/1.1 the Accept-Encoding header tells the server to actually > just send data encoded a certain way. > > In 0.9 this should change. > > Please file issues at https://github.com/cpp-netlib/cpp-netlib/issues > so that we can track this appropriately. > > I am using the 0.9 branch. |
From: Dean M. B. <mik...@gm...> - 2010-12-09 11:54:13
|
On Thu, Dec 9, 2010 at 3:47 PM, Raindog <ra...@ma...> wrote: > On 12/8/2010 11:37 PM, Dean Michael Berris wrote: >> >> Is this 0.8? The Connection header AFAIK is required in HTTP requests. >> In HTTP/1.1 the Accept-Encoding header tells the server to actually >> just send data encoded a certain way. >> >> In 0.9 this should change. >> >> Please file issues at https://github.com/cpp-netlib/cpp-netlib/issues >> so that we can track this appropriately. >> >> > > I am using the 0.9 branch. > You mean 0.9-devel on my repo right? That's still heavily in flux, but the headers like Connection could be made to be not implicitly defined. As it is right now, the linearize algorithm includes the Connection header if you're not using the keepalive variant of the tags. I have yet to find a way to implement the Asynchronous client that supports the keepalive tag, and re-use connections for HTTP/1.1. HTH -- Dean Michael Berris deanberris.com |