logoalt Hacker News

Show HN: I built a DNS resolver from scratch in Rust – no DNS libraries

68 pointsby rdmetoday at 10:07 AM47 commentsview on HN

I built a DNS resolver that lets me use https://frontend.numa instead of localhost:5173 — auto-generated TLS certs, WebSocket passthrough, path routing. No mkcert, no nginx, no /etc/hosts.


Comments

dwedgetoday at 6:01 PM

I have a couple of projects that once a month need to run a few million dns lookups as quickly as possible. I'm tempted to try this just to see how it performs and if it breaks.

show 1 reply
rdmetoday at 10:09 AM

Since I needed it to be my primary DNS, I also added: recursive resolution from root nameservers, DNSSEC chain-of-trust validation, ad blocking (385K+ domains), and LAN service discovery.

I wrote about the DNSSEC implementation here: https://numa.rs/blog/posts/dnssec-from-scratch.html It's now my daily system DNS. Single binary (~8MB), macOS/Linux/Windows.

`sudo numa install`

show 2 replies
voxadamtoday at 3:09 PM

It's neither here nor there but can I ask about the name? I only ask because when I see "numa" in relation to computing I immediately think "Non-Uniform Memory Access".

Very cool project by the way. I wonder how this would run on an OpenWRT device.

I see in your install.sh that you support Linux and Darwin/MacOS, do you think there would be any major hurdles in supporting FreeBSD?

show 2 replies
Asuka-wxtoday at 6:23 PM

Nice work. What made you choose this license?

p2haritoday at 2:18 PM

Nice idea. To test I ran a simple nextjs on port 3000. Added the service via the dashboard. However, when I visit the url, (using chrome latest version), https://{mygivenname}.numa/ I hit a DNS resolution fail error. If I do not use a trailing '/' then it is going to google search for {mygivenname}.numa and shows me some search results. Should I open an issue?

show 1 reply
kevin061today at 4:24 PM

The interface looks vibecoded. I have no problem with people vibecoding things. In fact, I have zero frontend skills, so I rely on AI to be able to make easy-to-use interfaces. However, I feel like this should be clearly and prominently displayed in the project page.

Furthermore it is a little off-putting to see a vibecoded UI because I have very little confidence that the rest of the backend code is not vibecoded. I know I am possibly being unfair, but this is how it looks to me. If the developer tells me they didn't use AI at all, I would believe it.

show 2 replies
6r17today at 1:22 PM

Same hack here ; I have no DSN running by default - much more handy than having to set up nginx as it has no opinion on the targeted infrastructure. And the bonus point is that you can see every sneaky request that happens when you browse ; so another side-project connected to this is to make an inventory and policy filter

show 1 reply
dev_l1x_betoday at 4:39 PM

How is to compare to AdGuard? If it gets those features I would be switching over.

show 1 reply
arafeqtoday at 2:10 PM

this is really clean. the auto-TLS for local dev is the killer feature imo, so many hours wasted fighting mkcert and nginx configs. do you plan to support docker/container networking? being able to resolve service names across docker compose setups would make this a no-brainer for teams.

show 3 replies
bahadortoday at 1:54 PM

feature request: libnuma so i can use it programmatically with configuration. also, multiple user defined blocklists.

show 1 reply
rbluethltoday at 10:12 AM

Cool idea, every developer running apps in dev on their machine knows this pain for sure. I'll give it a spin and let you know how it goes!

show 1 reply
_kidliketoday at 12:53 PM

very interesting. how does the blocklist work? can one manage the lists? like StevenBlack or others.

show 1 reply
lyfeninjatoday at 10:16 AM

I think I need to give this a go. Cool project.

show 1 reply
bulaneltoday at 5:29 PM

nice

EdoardoIagatoday at 2:09 PM

Rust it’s crazy good

voltagex_today at 1:27 PM

Great idea, pity about the slop.

goodpointtoday at 3:05 PM

we need a [slop] flag in the headlines