git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] http: match headers case-insensitively when redacting

From
Daniel Stenberg <daniel@haxx.se>
Date
Sep 21, 2021, 22:00 UTC
Message-ID
<nycvar.QRO.7.76.2109212351440.26668@fvyyl>
In-Reply-To
<YUoorS6UwA1DmwBm@coredump.intra.peff.net>
On Tue, 21 Sep 2021, Jeff King wrote:
> I cc'd you here mostly as an FYI. I think Git was doing the wrong thing
> in assuming case here (we're only expecting these particular headers
> coming from the client, but for response headers, I thnk curl will give
> us whatever form the server sent us).
That'd be correct, yes.
Show 7 quoted lines
> But certainly I found the behavior surprising. :) I'd guess it's because 
> HTTP/2 is sending some binary goo instead of text headers, and the names we 
> get are just coming from some lookup table? Or maybe I'm just showing my 
> ignorance of HTTP/2.
>
> At any rate, I wonder if it would be friendlier for curl to hand strings
> to the debug function with the usual capitalization.

Maybe that could've been a good idea if we had done it when we introduced HTTP/2 support. Now, I think that ship has sailed already as libcurl has supported HTTP/2 since late 2013 and changing anything like that now will just risk introducing the reverse surprise in applications. Better not rock that boat now methinks.

> PS This nit aside, it is totally cool that I have been seamlessly using
>   HTTP/2 to talk to github.com without even realizing it. I wonder for
>   how long!

I don't know when github.com started supporting h2, but since libcurl 7.62.0 (released Oct 31, 2018) it has negotiated h2 by default over HTTPS.

-- 
  / daniel.haxx.se
Previous: Jeff KingNext: Jeff King
Message 5 of 22 in “http: match headers case-insensitively when redacting”
  1. http: match headers case-insensitively when redactingJeff King, Sep 21, 2021
  2. Jeff KingSep 21, 2021
  3. Carlo ArenasSep 21, 2021
  4. Jeff KingSep 21, 2021
  5. Daniel StenbergSep 21, 2021
  6. Jeff KingSep 22, 2021
  7. Eric SunshineSep 21, 2021
  8. Jeff KingSep 21, 2021
  9. Junio C HamanoSep 22, 2021
  10. Taylor BlauSep 21, 2021
  11. Jeff KingSep 22, 2021
  12. Bagas SanjayaSep 22, 2021
  13. Jeff KingSep 22, 2021
  14. Ævar Arnfjörð BjarmasonSep 23, 2021
  15. Jeff KingSep 23, 2021
  16. Junio C HamanoSep 22, 2021
  17. Jeff KingSep 22, 2021
  18. Junio C HamanoSep 22, 2021
  19. Jeff KingSep 22, 2021
  20. Junio C HamanoSep 22, 2021
  21. http: match headers case-insensitively when redactingJeff King, Sep 22, 2021
  22. Jeff KingSep 22, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.