mirror of
https://github.com/comit-network/xmr-btc-swap.git
synced 2025-03-01 11:11:14 -05:00
Quad9 dns instead of system dns
This commit is contained in:
parent
56a23fa98f
commit
08c5d1c12e
1
Cargo.lock
generated
1
Cargo.lock
generated
@ -3699,6 +3699,7 @@ dependencies = [
|
|||||||
"tracing-appender",
|
"tracing-appender",
|
||||||
"tracing-futures",
|
"tracing-futures",
|
||||||
"tracing-subscriber",
|
"tracing-subscriber",
|
||||||
|
"trust-dns-resolver",
|
||||||
"url 2.2.1",
|
"url 2.2.1",
|
||||||
"uuid",
|
"uuid",
|
||||||
"void",
|
"void",
|
||||||
|
@ -56,6 +56,7 @@ tracing = { version = "0.1", features = ["attributes"] }
|
|||||||
tracing-appender = "0.1"
|
tracing-appender = "0.1"
|
||||||
tracing-futures = { version = "0.2", features = ["std-future", "futures-03"] }
|
tracing-futures = { version = "0.2", features = ["std-future", "futures-03"] }
|
||||||
tracing-subscriber = { version = "0.2", default-features = false, features = ["fmt", "ansi", "env-filter", "chrono", "tracing-log"] }
|
tracing-subscriber = { version = "0.2", default-features = false, features = ["fmt", "ansi", "env-filter", "chrono", "tracing-log"] }
|
||||||
|
trust-dns-resolver = "0.20"
|
||||||
url = { version = "2", features = ["serde"] }
|
url = { version = "2", features = ["serde"] }
|
||||||
uuid = { version = "0.8", features = ["serde", "v4"] }
|
uuid = { version = "0.8", features = ["serde", "v4"] }
|
||||||
void = "1"
|
void = "1"
|
||||||
|
@ -23,7 +23,9 @@ pub fn build(id_keys: &identity::Keypair) -> Result<SwapTransport> {
|
|||||||
let noise = NoiseConfig::xx(dh_keys).into_authenticated();
|
let noise = NoiseConfig::xx(dh_keys).into_authenticated();
|
||||||
|
|
||||||
let tcp = TokioTcpConfig::new().nodelay(true);
|
let tcp = TokioTcpConfig::new().nodelay(true);
|
||||||
let dns = TokioDnsConfig::system(tcp)?;
|
let config = trust_dns_resolver::config::ResolverConfig::quad9();
|
||||||
|
let opts = trust_dns_resolver::config::ResolverOpts::default();
|
||||||
|
let dns = TokioDnsConfig::custom(tcp, config, opts)?;
|
||||||
let websocket = WsConfig::new(dns.clone());
|
let websocket = WsConfig::new(dns.clone());
|
||||||
|
|
||||||
let transport = websocket
|
let transport = websocket
|
||||||
|
Loading…
x
Reference in New Issue
Block a user