[GH-ISSUE #503] DNS Queries over HTTPS (DOH), tracking #209

Closed
opened 2026-03-07 22:48:33 +03:00 by kerem · 12 comments
Owner

Originally created by @rumpelsepp on GitHub (May 31, 2018).
Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/503

I just wanted to create a tracking issue for this. Since last month or so, mozilla is experimenting with this.

https://datatracker.ietf.org/doc/draft-ietf-doh-dns-over-https/
https://groups.google.com/forum/#!msg/mozilla.dev.platform/_8OAKUHso0c/QUhjVYz3CAAJ
https://bugzilla.mozilla.org/show_bug.cgi?id=1446404

One could argue that an HTTP library could be used for this; the advantage of having this also in TRust-DNS would be the unification of the API for different transports.

Originally created by @rumpelsepp on GitHub (May 31, 2018). Original GitHub issue: https://github.com/hickory-dns/hickory-dns/issues/503 I just wanted to create a tracking issue for this. Since last month or so, mozilla is experimenting with this. https://datatracker.ietf.org/doc/draft-ietf-doh-dns-over-https/ https://groups.google.com/forum/#!msg/mozilla.dev.platform/_8OAKUHso0c/QUhjVYz3CAAJ https://bugzilla.mozilla.org/show_bug.cgi?id=1446404 One could argue that an HTTP library could be used for this; the advantage of having this also in TRust-DNS would be the unification of the API for different transports.
kerem 2026-03-07 22:48:33 +03:00
Author
Owner

@bluejekyll commented on GitHub (May 31, 2018):

Are you looking for the Resolver or Server support for this?

Edit: Gah, I should have read the title more closely... :)

<!-- gh-comment-id:393685554 --> @bluejekyll commented on GitHub (May 31, 2018): Are you looking for the Resolver or Server support for this? Edit: Gah, I should have read the title more closely... :)
Author
Owner

@rumpelsepp commented on GitHub (Jun 1, 2018):

:) Since the RFC is not yet released, I thought it might be useful to have an issue to track its status.

<!-- gh-comment-id:393758522 --> @rumpelsepp commented on GitHub (Jun 1, 2018): :) Since the RFC is not yet released, I thought it might be useful to have an issue to track its status.
Author
Owner

@bluejekyll commented on GitHub (Jun 7, 2018):

Ok, I've started work on this. I'm planning to directly use the https://crates.io/crates/h2 library for this support. The work looks something like this:

  • create the trust-dns/https crate
  • implement the HttpsClientStream wrapper for h2::client
  • integrate HttpsClientStream into trust-dns
  • integrate HttpsClientStream into trust-dns-resolver
  • implement the HttpsStream wrapper for h2::server
  • integrate HttpsStream into trust-dns-server
<!-- gh-comment-id:395419277 --> @bluejekyll commented on GitHub (Jun 7, 2018): Ok, I've started work on this. I'm planning to directly use the https://crates.io/crates/h2 library for this support. The work looks something like this: - [x] create the `trust-dns/https` crate - [x] implement the `HttpsClientStream` wrapper for `h2::client` - [x] integrate `HttpsClientStream` into `trust-dns` - [x] integrate `HttpsClientStream` into `trust-dns-resolver` - [x] implement the `HttpsStream` wrapper for `h2::server` - [x] integrate `HttpsStream` into `trust-dns-server`
Author
Owner

@briansmith commented on GitHub (Jun 7, 2018):

integrate HttpsClientStream into trust-dns-resolver

It would be great if there could be a way to avoid building HttpsClientStream, and all its dependencies, when building trust-dns-resolver.

<!-- gh-comment-id:395512101 --> @briansmith commented on GitHub (Jun 7, 2018): > integrate HttpsClientStream into trust-dns-resolver It would be great if there could be a way to avoid building HttpsClientStream, and all its dependencies, when building trust-dns-resolver.
Author
Owner

@bluejekyll commented on GitHub (Jun 7, 2018):

This will be optional in the Resolver like the dns-over-tls features, and default to off. Do you have more concerns than that?

<!-- gh-comment-id:395545955 --> @bluejekyll commented on GitHub (Jun 7, 2018): This will be optional in the Resolver like the dns-over-tls features, and default to off. Do you have more concerns than that?
Author
Owner

@briansmith commented on GitHub (Jun 7, 2018):

This will be optional in the Resolver like the dns-over-tls features, and default to off.

Sounds good.

Do you have more concerns than that?

Nope!

<!-- gh-comment-id:395548825 --> @briansmith commented on GitHub (Jun 7, 2018): > This will be optional in the Resolver like the dns-over-tls features, and default to off. Sounds good. > Do you have more concerns than that? Nope!
Author
Owner

@bluejekyll commented on GitHub (Jun 17, 2018):

FYI, I think the HttpsClientStream is done. before merging, I'm going to see what some of the underlying changes look like to support in the Resolver.

<!-- gh-comment-id:397898152 --> @bluejekyll commented on GitHub (Jun 17, 2018): FYI, I think the HttpsClientStream is done. before merging, I'm going to see what some of the underlying changes look like to support in the Resolver.
Author
Owner

@bluejekyll commented on GitHub (Jun 24, 2018):

Ok, with #519 there is now a viable implementation of DNS-over-HTTPS in TRust-DNS.

I had to hack around what appears to be a poor abstraction over the IO streams. I want to look into that in a little more detail to see if there is a better solution, so this isn't landing yet.

Also, note that this initial implementation will only support Rustls for the TLS implementation.

<!-- gh-comment-id:399773094 --> @bluejekyll commented on GitHub (Jun 24, 2018): Ok, with #519 there is now a viable implementation of DNS-over-HTTPS in TRust-DNS. I had to hack around what appears to be a poor abstraction over the IO streams. I want to look into that in a little more detail to see if there is a better solution, so this isn't landing yet. Also, note that this initial implementation will only support Rustls for the TLS implementation.
Author
Owner

@rumpelsepp commented on GitHub (Jun 25, 2018):

Thank you so much for your hard work!

<!-- gh-comment-id:399840547 --> @rumpelsepp commented on GitHub (Jun 25, 2018): Thank you so much for your hard work!
Author
Owner

@bluejekyll commented on GitHub (Jun 29, 2018):

That took a while, but #520 is going to be the path to merging. This is gets rid of the unnecessary Vec that was holding all the H2 responses, instead passing that back with a oneshot channel. There's some additional cleanup I want to do, but this is starting to look good.

Once this is all clean, the resolver will be merged, then I'll start working on the server/client.

<!-- gh-comment-id:401498125 --> @bluejekyll commented on GitHub (Jun 29, 2018): That took a while, but #520 is going to be the path to merging. This is gets rid of the unnecessary Vec that was holding all the H2 responses, instead passing that back with a oneshot channel. There's some additional cleanup I want to do, but this is starting to look good. Once this is all clean, the resolver will be merged, then I'll start working on the server/client.
Author
Owner

@bluejekyll commented on GitHub (Jul 9, 2018):

I just merged #520

This means that master now has dns-over-https support for the Resolver. It currently only works with rustls and requires the dns-over-https feature to be enabled. I'll open some bugs for supporting the Client and the Server at some point in the future.

<!-- gh-comment-id:403382787 --> @bluejekyll commented on GitHub (Jul 9, 2018): I just merged #520 This means that master now has dns-over-https support for the Resolver. It currently only works with `rustls` and requires the `dns-over-https` feature to be enabled. I'll open some bugs for supporting the Client and the Server at some point in the future.
Author
Owner

@bluejekyll commented on GitHub (Oct 5, 2018):

This was resolved completely in #557

<!-- gh-comment-id:427433415 --> @bluejekyll commented on GitHub (Oct 5, 2018): This was resolved completely in #557
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hickory-dns#209
No description provided.