[TLS] Re: Implicit ECH Config for TLS 1.3 – addressing public_name fingerprinting

Eric Rescorla <ekr@rtfm.com> Wed, 26 February 2025 18:26 UTC

Return-Path: <ekr@rtfm.com>
X-Original-To: tls@mail2.ietf.org
Delivered-To: tls@mail2.ietf.org
Received: from localhost (localhost [127.0.0.1]) by mail2.ietf.org (Postfix) with ESMTP id 22795214AF0 for <tls@mail2.ietf.org>; Wed, 26 Feb 2025 10:26:49 -0800 (PST)
X-Virus-Scanned: amavisd-new at ietf.org
X-Spam-Flag: NO
X-Spam-Score: -1.887
X-Spam-Level:
X-Spam-Status: No, score=-1.887 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001, T_KAM_HTML_FONT_INVALID=0.01] autolearn=ham autolearn_force=no
Authentication-Results: mail2.ietfa.org (amavisd-new); dkim=pass (2048-bit key) header.d=rtfm-com.20230601.gappssmtp.com
Received: from mail2.ietf.org ([166.84.6.31]) by localhost (mail2.ietfa.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id bZ5OfsjtprFN for <tls@mail2.ietf.org>; Wed, 26 Feb 2025 10:26:46 -0800 (PST)
Received: from mail-yw1-x112f.google.com (mail-yw1-x112f.google.com [IPv6:2607:f8b0:4864:20::112f]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by mail2.ietf.org (Postfix) with ESMTPS id AD093214AC0 for <TLS@ietf.org>; Wed, 26 Feb 2025 10:26:46 -0800 (PST)
Received: by mail-yw1-x112f.google.com with SMTP id 00721157ae682-6ef7c9e9592so1445037b3.1 for <TLS@ietf.org>; Wed, 26 Feb 2025 10:26:46 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rtfm-com.20230601.gappssmtp.com; s=20230601; t=1740594406; x=1741199206; darn=ietf.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=gs6vQ4wzH+iob1T33wAgIIF5X13FFNkwTVHhxChmpy8=; b=CGHq5VJya6t28FSKKY2uqNz3UReWYaw59+O1Iy0tlIgtHa+qQsQqIyHrwsJ7lE9n+K T0uLA47a8DWhRLzQB/TrHhEDgvI7WiDUjV2E8jR05R14uVE9M49fCbH1ME1lodg34LtA 9gYrg/rhzj8dG+5zwHu7PXEetWE35qoayl/TDKwe7wEqoFNjy2hkBkwMZmeWOtwGWzb9 2IP+/YD66bozJ6K8XnqEnd3Pa/U6SUgwyVk5oPfKEt+EfImMuAKHAT3nfyJLFNOw6y7C ERwf1eINeEUuj6He/WZTOoY9ZovZQRTh08MELXcUhm1qZXK48FWapWR6U6ub3f/4LhMM wlOA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1740594406; x=1741199206; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=gs6vQ4wzH+iob1T33wAgIIF5X13FFNkwTVHhxChmpy8=; b=mrvQ+rcvLsd1zX2QSz0gQrQskDuQdqy4VrJ5cFB7DtzfP2ff6K5nAFfNOGStzwvE4l JlNl548QAecmrEWZ4WZnF4wNV73zuRFc7wH2fXDYkJdsayB598sGbTnv5KMzQHyL6xs5 FUVA9LDBsn05l1CW/072FphYt0TOwGT3yZx9RBs3MMdDrUs7xnVdUgGBAwHna1G/17Xt Qhqr0GCD/QoiCp2oOwnJL4qUJnirRJ3TslAmX9GWQb67TiPMy5O+OE0N3ny7c+ZNws0D k8omfKB0j1qwDw22AC94nUeVBN6U1rGUEYcQstQV/nnwX0UEzsskIGa0uwXQHzDCeUoE vp/A==
X-Gm-Message-State: AOJu0YwyBANRgMIooJ5AK3vt5x2WYYoGanb1u6p+/h1OZfJ2P/+UwguO klBbm0cyLH9UCWIxhCq/iMAgGHUJcsOZO9VzNuuDEul1nV1Mc9bT1m7dVtlyHTPzTaKzc7hmhR6 g+qhBg+mk4eDI2+NWeukRhgjHXOUo0Kl3DUQxYyzt8syLTvpk4A0=
X-Gm-Gg: ASbGncs8uGl5r7aPWwDEXdhTGrLflhsvFF+vaBnIZLDG1TbCqIjOy1nLhN6CB7Jlyag 6uc786q4xxRJ8po8d4GLu3XxNSav1DOIQYFhxCTCfesSuxGv5jW6BdzGT+PaB/9o1M833Tln/3q g4Z5t8Otdr9jezcLqQwqFHjh5Am1CnQMl1BM8MojHVKA==
X-Google-Smtp-Source: AGHT+IHilyOARej2n5SLPPQ+qpt2M8nRZfdt3T3PDMwPuaz8cSY7kGE3u9bUVmDQAAmI65mTPoyEyv6m52EiHViCZtA=
X-Received: by 2002:a05:690c:6912:b0:6f9:88f2:b8d with SMTP id 00721157ae682-6fd109e6973mr81116547b3.11.1740594406022; Wed, 26 Feb 2025 10:26:46 -0800 (PST)
MIME-Version: 1.0
References: <CAOjisRzBNG2KdAZXssnR9Ura9HuAUKxOH+VLCAE5B9MfYyeT2A@mail.gmail.com>
In-Reply-To: <CAOjisRzBNG2KdAZXssnR9Ura9HuAUKxOH+VLCAE5B9MfYyeT2A@mail.gmail.com>
From: Eric Rescorla <ekr@rtfm.com>
Date: Wed, 26 Feb 2025 10:26:07 -0800
X-Gm-Features: AQ5f1JqYEz0NjWr8lbaOjqFJQZHH7e0KluCKdjfBVLZpzbsIV2T_ZdFUH7jybnA
Message-ID: <CABcZeBM6=OuVS86oCfd1HM8z-41uOQEe2znKE=E_y0-1u0vYxQ@mail.gmail.com>
To: Nick Sullivan <nicholas.sullivan@gmail.com>
Content-Type: multipart/alternative; boundary="000000000000450432062f0fb711"
Message-ID-Hash: I2UL6RI2LVBFSCIKSQTV56IJUIGUYVQI
X-Message-ID-Hash: I2UL6RI2LVBFSCIKSQTV56IJUIGUYVQI
X-MailFrom: ekr@rtfm.com
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-tls.ietf.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
CC: "tls@ietf.org" <TLS@ietf.org>
X-Mailman-Version: 3.3.9rc6
Precedence: list
Subject: [TLS] Re: Implicit ECH Config for TLS 1.3 – addressing public_name fingerprinting
List-Id: "This is the mailing list for the Transport Layer Security working group of the IETF." <tls.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/tls/oGNdAC-a__uMR53pis4B9bI5_7k>
List-Archive: <https://mailarchive.ietf.org/arch/browse/tls>
List-Help: <mailto:tls-request@ietf.org?subject=help>
List-Owner: <mailto:tls-owner@ietf.org>
List-Post: <mailto:tls@ietf.org>
List-Subscribe: <mailto:tls-join@ietf.org>
List-Unsubscribe: <mailto:tls-leave@ietf.org>

Nick,

Thanks for proposing this. This is an interesting idea, but I'm not
entirely sure it meaningfully reduces the impact of fingerprinting
in practice. Specifically, it seems mainly useful when there are
ECH and non-ECH domains on the same IP and there isn't a critical
mass of ECH. More detail below.


Stepping back from this specific mechanism, at a high level, there are
four main types of connections, as shown in the table below:

Client      |                   Server Behavior
Behavior    |   No ECH                                  ECH Capable
            |------------------------------------------------------
No ECH      |  No ECH Extension                    No ECH Extension
ECH Capable |  GREASE ECH                          Real ECH


Any on-path attacker can easily determine whether ECH (GREASE or Real)
is in use just by looking for the presence of the ECH extension.
However, determining GREASE from Real is more complicated and mostly
depends on looking at the public name or the config_id. As this draft
observes, this is facilitated by the fact that the public names and
config IDs for ECH capable servers are public and relatively stable.

However, an attacker who is able to learn these stable values is
*also* able to learn the IPs for these servers, which means
that they can fairly readily learn which servers support ECH, at
least some of the time. This is obviously a bigger list than just
the stable names, but I doubt is impractically large. The point
here is that ECH Capable clients will use ECH if possible, and so
if you observe an ECH handshake to a server IP that you know does
ECH, then it's a strong indicator that it's Real ECH regardless of
the public name or config_id.

The major remaining source of ambiguity from the attacker's
perspective is servers which share non-ECH and ECH domains on the same
IP address. In this case, you will have some handshakes that are Real
ECH and some which are GREASE, and it might be useful to distinguish
them if the set of GREASE ECH connections is a large fraction of
the connections to the server (again, non-ECH connections can be
handled separately). Is this a common configuration?

Separately, I don't think it works well to let the client select any
outer SNI rather than the public name, because there is a high
probability that they will choose a domain associated with a different
IP (or rather, a different provider), which would make the real ECH
detectable again. It seems like it would work better to have the
client know which domains were valid for those IPs.  I don't have a
great solution here that doesn't require publishing a huge list of
customer names, though.


-Ekr








On Tue, Feb 25, 2025 at 11:18 PM Nick Sullivan <nicholas.sullivan@gmail.com>
wrote:

> Hi everyone,
>
> I’ve put together a draft, “Implicit ECH Configuration for TLS 1.3” (
> https://www.ietf.org/archive/id/draft-sullivan-tls-implicit-ech-00.html)
> as a potential starting point for improving ECH’s “do not stick out”
> compliance. Global deployments of ECH have become biased because a single
> public_name dominates most ECH connections, making it a prime target for
> fingerprinting (see https://github.com/net4people/bbs/issues/417) As
> discussed on the TLS WG mailing list (see
> https://mailarchive.ietf.org/arch/msg/tls/4rq4sZzpI9rjYgDLJ2IO-vG9DRw/)
> the outer SNI remains the primary identifier that enables on-path
> adversaries to identify ECH traffic.
>
> To mitigate these linkability risks, various past proposals were
> considered. One idea was to randomize or override the outer SNI rather than
> always using the provided public_name. For example, Stephen Farrell
> suggested allowing clients to use an arbitrary or blank outer SNI (for
> certain use cases like censorship circumvention). This would, in theory,
> make the outer handshake less predictable, increasing traffic diversity
> across ECH connections. However, others in the WG (e.g. Chris Wood)
> cautioned that relaxing this requirement essentially reintroduces domain
> fronting, a side-effect the group was wary of.
>
> The consensus was that fallback reliability and simplicity favored
> sticking with the public_name in SNI. See Github discussions:
> https://github.com/tlswg/draft-ietf-tls-esni/issues/396
> <https://github.com/tlswg/draft-ietf-tls-esni/issues/396#:~:text=For%20at%20least%20command%20line,benefit%20from%20that%20option%20too>
> .
>
> Relatedly, early drafts used an 8-byte config_id, but as documented in
> discussions around 2020-2021, it was shortened to one byte to reduce its
> uniqueness and tracking potential—a change that was well received by
> privacy advocates yet noted by implementers as complicating the deployment
> complexity for multi-key scenarios, though not enough to hinder deployment.
>
> Implicit ECH Configuration, introduced in
> draft-sullivan-tls-implicit-ech-00, builds on this prior work to propose a
> mode of ECH that minimizes explicit signaling of the server’s identity.
> This draft introduces an optional “implicit” mode via a new extension in
> ECHConfigContents. When this extension is present, clients MAY choose any
> valid outer SNI and a randomized config_id instead of relying on a
> potentially globally dominant public_name. Client-facing servers, in turn,
> MUST perform uniform trial decryption to ensure that every handshake is
> processed identically, regardless of whether a valid or a phony config_id
> or outer SNI is provided.
>
> This approach enables clients to adopt custom strategies for maintaining
> broad reachability, ensuring that a single public_name does not become a
> reliable way for external observers to distinguish ECH from ECH GREASE at
> scale. It is also useful for improving privacy when client-facing servers
> support only one or a small number of domains, as it enables clients to
> choose the outer SNI such that it is not merely a direct stand-in for the
> inner name.
>
> Importantly, I don’t believe this approach reintroduces domain fronting.
> It’s not possible to use implicit configuration ECH to connect to one site
> on a server and then trick that server into serving HTTP responses for a
> second, different site when the TLS certificate used to establish the
> connection is not authoritative for that second site – the essential thing
> that distinguishes domain fronting from other techniques. Implicit mode
> effectively relegates the outer SNI to a mostly symbolic role for these
> connections, used solely for ensuring network reachability—similar to how
> certain legacy TLS 1.2 messages were retained in TLS 1.3 to address network
> ossification issues.
>
> This change may have fit into the main ECH draft if it had been proposed
> earlier. However, ECH has already been submitted to IESG for publication,
> so I put this together as a standalone extension. I welcome your feedback
> on this proposal as we work to reduce fingerprinting risks without
> sacrificing deployability.
>
>
> Nick
> _______________________________________________
> TLS mailing list -- tls@ietf.org
> To unsubscribe send an email to tls-leave@ietf.org
>