| Crates.io | dns-resolver-rs |
| lib.rs | dns-resolver-rs |
| version | 0.1.1 |
| created_at | 2025-09-20 13:13:51.501601+00 |
| updated_at | 2025-09-20 13:27:11.355027+00 |
| description | A simple DNS resolver server built with Axum and Tokio |
| homepage | https://github.com/gausk/dns-resolver |
| repository | https://github.com/gausk/dns-resolver |
| max_upload_size | |
| id | 1847721 |
| size | 75,483 |
A comprehensive recursive DNS resolver written in Rust that provides both a library interface and an HTTP REST API server for DNS resolution.
Try the DNS resolver online:
Clone the repository and build:
git clone https://github.com/gausk/dns-resolver.git
cd dns-resolver
cargo build --release
Start the DNS resolver HTTP server locally:
cargo run --release
The server runs on http://localhost:3000 and provides:
http://localhost:3000/curl "http://localhost:3000/resolve?domain=google.com"
# Response: {"ip":"172.217.14.110"}
curl "http://localhost:3000/reverse_resolve?ip=8.8.8.8"
# Response: {"domain":"dns.google"}
Run the example with default domains:
cargo run --example resolve
Or specify custom domains:
cargo run --example resolve -- google.com github.com rust-lang.org
Run the test suite:
cargo test