add query_over_tcp_only config option for hickory
Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
parent
62fd6e2c7c
commit
35114dde7d
3 changed files with 12 additions and 0 deletions
|
@ -51,6 +51,10 @@ impl Resolver {
|
|||
for sys_conf in sys_conf.name_servers() {
|
||||
let mut ns = sys_conf.clone();
|
||||
|
||||
if config.query_over_tcp_only {
|
||||
ns.protocol = hickory_resolver::config::Protocol::Tcp;
|
||||
}
|
||||
|
||||
ns.trust_negative_responses = !config.query_all_nameservers;
|
||||
|
||||
conf.add_name_server(ns);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue