(feat) allow setting --host-resolver-rules#309
Open
timkent wants to merge 1 commit intosensepost:masterfrom
Open
(feat) allow setting --host-resolver-rules#309timkent wants to merge 1 commit intosensepost:masterfrom
timkent wants to merge 1 commit intosensepost:masterfrom
Conversation
Open
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I wanted to use this tool to test some reverse proxies that use split DNS, so I can't assume that the DNS host is available or pointing to the correct place.
To do this I have added a
--chrome-host-resolver-rulesoption that passes through to the Chrome--host-resolver-rulesoption. The format of the rules are explained here:https://chromium.googlesource.com/chromium/src/+/HEAD/net/dns/mapped_host_resolver.h#40
Here is an example where it is sending my request for
http://example.comto127.0.0.1:8000andhttps://example.comto127.0.0.1:8443using the one rule:I did some limited testing and Chrome appears to be sending the correct host header and SNI.
Thank you for this awesome project!