Header field name check for "Transfer-Encoding" should be case insensitive #313

Open
Artalizian opened this Issue Oct 9, 2013 · 1 comment

Comments

Projects
None yet
2 participants
@Artalizian

I've created a client that needs to handle chunked messages, but these don't seem to be processed as chunks because the header field name is expected to be camel cased in cpp-netlib and my server sends them lower cased. I tracked the problem down to the following code in async_protocol_handler.cpp (line 290).

typename headers_range<basic_response<Tag> >::type transfer_encoding_range = headers.equal_range("Transfer-Encoding");

The HTTP/1.1 standard states that field names are case insensitive.

@ghost ghost assigned deanberris Nov 11, 2013

@deanberris

This comment has been minimized.

Show comment
Hide comment
@deanberris

deanberris Nov 11, 2013

Member

Interesting. I thought the std::multimap used in the response used a case-insensitive comparator. I'll look into this and have it fixed for 0.11 -- or if you don't mind making that fix and sending in a PR, that would be most appreciated.

Member

deanberris commented Nov 11, 2013

Interesting. I thought the std::multimap used in the response used a case-insensitive comparator. I'll look into this and have it fixed for 0.11 -- or if you don't mind making that fix and sending in a PR, that would be most appreciated.

leecoder pushed a commit to leecoder/cpp-netlib that referenced this issue Apr 14, 2015

leecoder pushed a commit to leecoder/cpp-netlib that referenced this issue Apr 14, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment