Curl does not lowercase header names for HTTP/2 and HTTP/3 #4400
Curl does not currently lower case HTTP header names as required by HTTP/2 and HTTP/3. The lower-level libraries that curl uses (nghttp for HTTP/2 and ngtcp2/quiche for HTTP/3) do lower case the header names, but it does mean for some of the output, before the lower library is invoked, curl can show upper case header names which could be confusing.
While this may seem somewhat pedantic, I still see some developers who are caught by surprised by this more strict requirement for HTTP/2 and HTTP/3 so would prefer curl to not display this as it does currently.
As I see it, we can do one of three things here:
I've taken a stab at option 3 here: master...bazzadp:lowercase_h2_h3_headernames.
I'd appreciate your thoughts on this and if it's worth submitting this as a pull request?
It's my first potential commit to curl, and my C is a little rusty, so please be kind :-)
The text was updated successfully, but these errors were encountered:
It's the same with
A fact, incidentally, that caused me some confusion when I initially tried to test the HTTP/2 part of this change, as didn't realise I had to explicitly turn on
Anyway, because I went with my option 3, this change also changes the non-debug lines below this (except for the
as opposed to:
So there is still value in this change, even when not in debug mode, and even when h3 changes to act more like h2.
We should probably at least make the
#ifdef CURLDEBUG #define DEBUG_HTTP3 #endif
The HTTP/2 debug is completely disabled by default pretty much because it generates so much data that is mostly uninteresting for everyone as long as you don't actually debug HTTP/2 related issues.