- Notifications
You must be signed in to change notification settings - Fork329
Extend DialOptions to allow Host header override#336
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Couldn't you useHost
inHTTPHeader
?
bendiscz commentedMar 6, 2023 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
That does not work unfortunately. |
Sounds good will get this in then after#256 |
Or you know what we could actually check for |
Checking for Should I change the patch? |
Go for it and thank you for your contribution. It's still going to take me a while to merge as I need to take care of#256 |
b06417f
tof7bed7c
CompareThanks@bendiscz |
The standard
http.Request.Host
field allows to override theHost
header that is sent with the HTTP request (URL.Host
is used by default). Such option can be useful in various scenarios, for example when running behind some proxy server.This patch extends the
DialOptions
struct withHost
field that basically does the same.