Show HN: Golang DNS server, including DNSSEC and DNS-over-TLS
github.com
github.com
TRust-DNS has been coming along over the last couple of years, there've been a few discussion here about it, these ones had a lot of comments:
https://news.ycombinator.com/item?id=12332876
https://news.ycombinator.com/item?id=13099979
TRust-DNS consists of essentially 3 components. The Server supports on-line DNSSec signing of all the current DNSSec standard algorithms, and some additional RFCs around limiting the response of those to what the client connection supports. It supports DNS over TLS as well. Recently I added support for TLSA and CAA records as well. There are definitely some more than can be supported.
The Client, which is for managing the server and performing raw connections to DNS servers for things like dynamic update, etc. It supports DNS over TLS, with three variant TLS impls for different combinations based on toolchain requirements. It also can perform DNSSec validation.
The Resolver, which is what I anticipate most people will use going into the future. This currently doesn't support DNS over TLS. I have plans to do that, but I haven't figured out the configuraton side of it yet. This also is capable of DNSSec validation. It has some neat features around DNS server selection specifically for ranking DNS servers and using the most responsive. I have some plans at some point to try and implement a caching resolver for the three major platforms, but haven't gotten there yet.
Happy to answer any questions.
It looks like Tenta DNS currently supports more features around scaling and production use, while Trust DNS includes a client component.
My goals with TRust-DNS are a little more than just shiny new language. I really want to leverage Rust's safety guarantees, especially in regards building high performance implementations for core tools like this. I believe that with Rust we can produce more hardened software and deliver at a faster pace than other more traditional low level languages.
I haven't yet had a chance to really optimize the library. In my measurements for example, BIND responds to queries in 100 micro-seconds, whereas TRust-DNS is now down to 250 (on my local system, YMMV). There are a couple of low-hanging fruit things that I hope to get to soon, that should bring that down significantly.
The big difference is that RRDNS contains all of our business logic to enable things like Orange clouding, and other DNS based features. Those depend a lot on how our infrastructure works, and are not useful to others. It's also a much older codebase (it probably started before 1.4?) and therefore goes out of its way to avoid putting pressure on the GC and had other funny bits in it. Finally, RRDNS has seen a lot of abuse and by now is pretty well hardened :)
I did find this one: https://github.com/tenta-browser/tenta-dns/blob/master/src/t...
That's an internal test, meaning it has access to the package internals. A better test would test from outside the boundaries of the package to only interact with exposed symbols.
I would just caution people against doing direct comparisons of unit test suites between Ruby/Python and Go projects, because a lot of Ruby/Python testing really just mitigates deficiencies in those languages, and those deficiencies have created a sort of culture of exuberant, creative testing that isn't present in other languages.
Tests are good! Everything should have tests.
It looks to me more like compile-to-JS languages are winning this race. Which is good, as it enables sthings like ClojureScript and Elm. Also many of us think the lack of static types is the least of the problems in JS.
edit: Seems the TS tools also have JS linting functionality, where you put JSDoc annotations in comments and use the new --checkJs options, I guess you may have meant this too.
DNS Benchmark (https://www.grc.com/dns/benchmark.htm) shows this results: https://ghostbin.com/paste/rr65w
Are they normal? Or are they slow because the servers are located in the US?
In addition, if you'd be willing to share, visit https://nstoro.com/api/v1/geolookup and shoot us the results to hello@tenta.com. That API will pull your IP and the physical location of the box you connected to. If that location isn't Amsterdam, then we'll need to take a look at our routing.
All of these things could be done with PowerDNS, but it would also require a number of other programs "helping" in order to get TLS and BGP, and the configuration would be a mess. With TentaDNS it's all in one convenient, easy to run place, with a single set of config, running multiple (even 10s or hundreds) of resolver configs all in one place.
That having been said, our Authoritative support (e.g. being the main nameserver for a domain) still lacks a lot of features, while our recursive support (e.g. being the resolver you use for your browser) is top notch.
A lot of this sounds like rewriting the wheel in Go because Go is "hip".
Do one thing, and do it well.
What's a recommended way of using your product in a redundant way? PowerDNS for example has multiple backends, what I am missing is a bind style backend that is based on JSON files and is able to reload on the fly, so that I don't have to deal with a SQL database. Is this something that could be achieved with Tenta?
Additionally, if you file a feature request for JSON support in the bindbackend, we might consider it!
We've decided to go with TLS instead of DNSCrypt, since it's a well understood (and now RFC standardized protocol). While we're the first to support this publicly, we expect others to follow soon, which, combined with DNSSEC, will provide true security for DNS.
I looked at dnscrypt myself, it's implementation is much more complex than using standard TLS support libraries that already exist. TLS and dnscrypt seem to cover similar use cases...