예제 #1
0
 public async Task TestLookupWithGoogle(string domain, DnsQueryType type)
 {
     using var client = new DnsHttpClient(new HttpClient { BaseAddress = new Uri("https://dns.google/") });
     await client.RunQuery(domain, type);
 }
예제 #2
0
 public async Task TestLookupWithCloudFlare(string domain, DnsQueryType type)
 {
     using var client = new DnsHttpClient(new HttpClient { BaseAddress = new Uri("https://cloudflare-dns.com/") });
     await client.RunQuery(domain, type, type == DnsQueryType.ANY?DnsResponseCode.NotImp : DnsResponseCode.NoError);
 }