Closed s3cur3 closed 2 years ago
You shouldn't be setting those headers manually, they will be picked up from other places (such as Mint.HTTP.connect/3
) and set as appropriate by Mint.
Also, they are HTTP/2 specific headers so they will not be set for HTTP/1 requests.
Ahhh... Thanks for pointing me in the right direction. Yeah, the reason I wasn't getting the headers by default was that I was on an HTTP1 connection. Thanks so much!
Hi there! Lemme start by saying thank you for maintaining such a foundational library in the Elixir community. ❤️
I have a project where I'm trying to replay browser interactions, and I'd like to do so exactly, down to the request headers. I'm hitting an error, though, trying to use Mint to send the exact headers that a real Chromium-based browser did. The headers that begin with a
:
character (":authority"
,":method"
,":path"
, and":scheme"
) are rejected by Mint as invalid.Here's an example of the headers I'm trying to reproduce:
Minimal reproducer:
If this is a behavior you're interested in changing, I'd be happy to submit a PR.