Subject: [TLS] HTTPSSVC record draft - ESNI alternative for HTTPS

From: Erik Nygren <[email-masked]>
Date: Mon, 8 Jul 2019 17:27:28 -0400

For those not on the HTTP-WG or DNSOP lists, Ben Mike and I have
a draft for an "HTTPSSVC" DNS record.  There's a -03 that incorporates
some feedback from the first version:

    https://tools.ietf.org/html/draft-nygren-httpbis-httpssvc-03

This attempts to address a number of problems (ESNI, QUIC bootstrapping,
HTTP-to-HTTPS redirection via DNS, SRV-equivalent for HTTP, etc) in a
holistic manner through a new extensible DNS record, rather than in a
piecemeal fashion.  It is based on some previous proposals such as "Alt-Svc
in the DNS" and "Service Bindings" but takes into account feedback received
in DNSOP and elsewhere.

In particular for the TLS WG, we'd be interested in hearing if this would
solve enough of the ESNI-key-delivery-via-DNS needs for the HTTPS use-case.

Feedback is most welcome and we're looking forward to discussing with
people in Montreal.

While this is still an individual draft, we have been tracking it here:
    https://github.com/MikeBishop/dns-alt-svc
but as always, commentary on the IETF lists is generally preferable.
There is even a preliminary private type implementation in BIND
of the -01 version (with the -02 wire format supported by ifdefs)
from Mark Andrews:
https://gitlab.isc.org/isc-projects/bind9/merge_requests/2135

>From the abstract:

This document specifies an "HTTPSSVC" DNS resource record type to
facilitate the lookup of information needed to make connections for HTTPS
URIs.  The HTTPSSVC DNS RR mechanism allows an HTTPS origin hostname to be
served from multiple network services, each with associated parameters
(such as transport protocol and keying material for encrypting TLS SNI).
It also provides a solution for the inability of the DNS to allow a CNAME
to be placed at the apex of a domain name.  Finally, it provides a way to
indicate that the origin supports HTTPS without having to resort to
redirects, allowing clients to remove HTTP from the bootstrapping process.

By allowing this information to be bootstrapped in the DNS, it allows for
clients to learn of alternative services before their first contact with
the origin.  This arrangement offers potential benefits to both performance
and privacy.

This proposal is inspired by and based on recent DNS usage proposals such
as ALTSVC, ANAME, and ESNIKEYS (as well as long standing desires to have
SRV or a functional equivalent implemented for HTTP).  These proposals each
provide an important function but are potentially incompatible with each
other, such as when an origin is load-balanced across multiple hosting
providers (multi-CDN). Furthermore, these each add potential cases for
adding additional record lookups in-addition to AAAA/A lookups.  This
design attempts to provide a unified framework that encompasses the key
functionality of these proposals, as well as providing some extensibility
for addressing similar future challenges.

--

Some likely FAQs (with some others listed in an appendix):

Q: Why this is HTTP-specific?
A: This is because every protocol has different bootstrap requirements.
This draft is concerned with improving the efficiency and security of
bootstrapping HTTPS connections.  This proposal does offer room for
non-HTTPS protocols, but the nature of DNS requires underscore prefixing to
support protocol-keyed answers within a single RRTYPE.  It's also unlikely
that a single RR format would be the ideal bootstrap mechanism for every
protocol, and there's no reason that multiple protocols should have to
share an RRTYPE.

Q: Why is ESNI addressed directly?
A: This helps make a major motivation of this draft more clear.  Splitting
out those sections to a separate-but-associated "alt-svc attribute for ESNI
keys" draft might make sense, but keeping it here helps work through some
of the issues together.

Q: Why does this try to address the HSTS case?
A: This is a unique opportunity to fix HTTPS bootstrap and avoid providing
insecure defaults.  We'd originally proposed a separate Alt-Svc attribute
to indicate hsts-style behavior, but then realized that it would make sense
to push on that as the default here.

Best, Erik

---

From: Stephen Farrell <[email-masked]>
Date: Mon, 8 Jul 2019 22:39:48 +0100

Hi Erik,

> solve enough of the ESNI-key-delivery-via-DNS needs for the HTTPS use-case.

I'm not clear if you envisage this entirely replacing the
new ESNI RR (as defined in ESNI draft-03), or if you envisage
both being defined, with this one (HTTPSSVC) being used for
the web and the ESNI RR for non-web uses of TLS, or maybe
something else?

It'd seem like a bad plan two have multiple ways of doing
the same thing, but I guess there're trade-offs in various
directions here.

BTW - I read an earlier version of your draft and there
were a few detailed discrepancies vs. the ESNI draft but
those could be resolved later.

Cheers,
S.

---

From: Erik Nygren <[email-masked]>
Date: Mon, 8 Jul 2019 18:08:50 -0400

Hi Stephen,

> the same thing, but I guess there're trade-offs in various

My thinking is that different protocols have different needs
and requirements for key delivery via DNS.  As such, separating
out the ESNI key format from the DNS record for provisioning
makes sense.  EKR had the valid point that it would be valuable
to have a basic way of doing ESNI key provisioning for protocols
lacking complex requirements.

This could end up as "protocols should specify bindings for how
ESNI keys are delivered via DNS", with a HTTPSSVC RR for the HTTPS
use-case, perhaps with other protocol bindings for other things with
specific requirements, and with an ESNI RR (which might be able
to be made simpler if some of the Web requirements can be abstracted)
for generic use-cases.

A downside is that this does add complexity for tools that operate entirely
at the TLS layer such as openssl s_client that would be happier if only
an ESNI record existed.  However, the HTTPS use-case
already has a bunch of other scenarios such as HTTP/3 that break/blur
this abstraction layer such that it may be that this type of HTTPS
connection
management and DNS resolution needs to be done at the HTTP session layer
regardless, with TLS libraries providing an interface to pass in ESNI keys.

Encrypting authoritative DNS from recursives to authorities is in
its early days, but it would not surprise me if similar requirements
show up there and require a new DNS record type.  (eg, an extensible
NS record or an extensible record named by an NS record that includes
information about protocols and ESNI keys and the like.)

Best, Erik

---

From: Stephen Farrell <[email-masked]>
Date: Mon, 8 Jul 2019 23:27:57 +0100

I'm not sure what I think about the general idea TBH but
just on this bit...

On 08/07/2019 23:08, Erik Nygren wrote:
> an ESNI record existed. 

I don't think that's such a big deal for the library as
that's unlikely to include the code to do DNS queries.
Being able to parse a couple of different wrappers for
ESNIKeys isn't that big a deal.

And at least the code I've done for s_client assumes it
gets the RR value on the command line (for now anyway)
so that's also no biggie. But I figure s_client isn't
that important as an application anwyay;-)

Having different DNS RRTYPEs one might need to probe
or otherwise know about would make like harder for
real application code that does DNS though, and for
servers who might end up having to publish the same
things in different ways. So I hope we don't create
that kind of problem.

Cheers,
S.