super_dns_client 0.3.0 copy "super_dns_client: ^0.3.0" to clipboard
super_dns_client: ^0.3.0 copied to clipboard

A modern and lightweight Dart library for performing DNS-over-HTTPS (DoH) lookups. Supports multiple resolvers and easy integration for Flutter and server-side apps.

Changelog #

0.3.0 #

✨ New Features #

  • Added BaseUdpSrvClient abstract class for shared SRV lookup logic.
  • Implemented:
    • SystemUdpSrvClient: queries SRV records via system-configured DNS (UDP → TCP fallback).
    • PublicUdpSrvClient: queries SRV records via public resolvers (Quad9, AdGuard, Yandex, OpenDNS, etc.).
    • DnsOverHttps.lookupSrvMulti(): sequential SRV lookup (Google → Cloudflare fallback).
    • DnsOverHttps.lookupSrvParallel(): parallel SRV lookup (runs both resolvers simultaneously).
  • Added SrvRecord model for typed SRV response handling instead of generic Map.
  • Improved example dns_client_example.dart to demonstrate all client types:
    • System resolver
    • Public resolver
    • DoH (Google, Cloudflare, Mullvad)
  • Added complete test coverage for:
    • UDP/TCP SRV clients
    • DoH SRV (multi + parallel)
    • System and public resolver detection
    • Error fallback (UDP timeout → TCP)
  • Refactored project structure:

lib/src/doh/ lib/src/udp_tcp/ lib/src/models/ example/dns_client_example.dart

⚙️ Improvements #

  • Enhanced fallback logic between Google and Cloudflare DoH resolvers.
  • Added English-only documentation comments for consistency.
  • Improved debug logging for all SRV clients.

🧩 Fixes #

  • Better error handling for IPv6 and system DNS detection.
  • Tests now handle dynamic DNS environments safely (no hardcoded IPs).
  • Fixed internal method visibility and export paths.

🧪 Tests #

  • Added new unit tests for:
    • DnsOverHttps.lookupSrvMulti()
    • DnsOverHttps.lookupSrvParallel()
  • Ensured 100% test coverage across DoH, UDP, and TCP clients.

🔧 Misc #

  • Updated GitHub workflows (analyze.yml, test.yml).
  • Cleaned up comments and improved readability throughout the codebase.

0.2.1 #

🛠 Fixes #

  • Exported DnsOverHttpsBinaryClient in super_dns_client.dart so it is now publicly accessible from the package import.

🔧 Internal #

  • Minor cleanup before pub.dev publish

0.2.0 #

✨ New Features #

  • Added DnsOverHttpsBinaryClient for binary DNS-over-HTTPS lookups (RFC 8484).
  • Support for SRV record resolution over DoH.
  • Added DnsResolver object model (name, url, supportsGet, isTrusted).
  • Built-in non-GAFAM resolvers:
    • Quad9
    • AdGuard
    • Yandex
    • OpenDNS
    • Mullvad (GET only)

⚙️ Improvements #

  • Automatic GET/POST selection depending on resolver capability.
  • Unified lookup() and lookupDataByRRType() API with optional resolverName.
  • Enhanced error handling for invalid resolvers and DoH failures.

🧪 Tests & Examples #

  • Added unit tests for SRV and A record lookups via Quad9.
  • Updated example to demonstrate both DnsOverHttps and DnsOverHttpsBinaryClient usage.

0.1.0 #

🎉 Initial release of super_dns_client

  • Added DNS-over-HTTPS client implementation
  • Supported Google, Cloudflare, Quad9, and OpenDNS resolvers
  • Supported record types: A, AAAA, CNAME, SRV, TXT
  • Added base response model with freezed and json_serializable
  • Unit tests and CI configuration ready
2
likes
0
points
751
downloads

Publisher

unverified uploader

Weekly Downloads

A modern and lightweight Dart library for performing DNS-over-HTTPS (DoH) lookups. Supports multiple resolvers and easy integration for Flutter and server-side apps.

Repository (GitHub)
View/report issues

Topics

#dns #doh #network #http #resolver

License

unknown (license)

Dependencies

equatable, freezed_annotation, http, json_annotation, super_dns, super_raw

More

Packages that depend on super_dns_client