[TLS] Re: WG Last Call: draft-ietf-tls-mlkem-08 (Ends 2026-07-08)

Nick Sullivan <nicholas.sullivan@gmail.com> Fri, 26 June 2026 18:27 UTC

Return-Path: <nicholas.sullivan@gmail.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 692B91083C618 for <tls@mail2.ietf.org>; Fri, 26 Jun 2026 11:27:04 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ietf.org; s=ietf1; t=1782498424; bh=CCXmsgdwsOZXt1LEHG52C14fdvn1fUKrUieSJH8O49s=; h=References:In-Reply-To:From:Date:Subject:To:Cc; b=L1+udZZx5VWliXLjT0ZumKZ9S1/SMOD7YotxyjU6QOIA5pE+QYvO5fW1VPsjd7bYs cw5m80Ne6/jz5QW/ObcGrhQ+gzKfGwrrlAkeyKiaA/o0IEHxJ1LK+ofUCltSvlO+A1 5MBw6lahlyy40rC+hxcF5tiohmldmaI33dFoxF+g=
X-Virus-Scanned: amavisd-new at ietf.org
X-Spam-Flag: NO
X-Spam-Score: -1.828
X-Spam-Level:
X-Spam-Status: No, score=-1.828 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, HTML_OBFUSCATE_05_10=0.26, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_KAM_HTML_FONT_INVALID=0.01] autolearn=unavailable autolearn_force=no
Authentication-Results: mail2.ietf.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
Received: from mail2.ietf.org ([166.84.6.31]) by localhost (mail2.ietf.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id QlSPxHCucMfC for <tls@mail2.ietf.org>; Fri, 26 Jun 2026 11:27:03 -0700 (PDT)
Received: from mail-yx1-xb136.google.com (mail-yx1-xb136.google.com [IPv6:2607:f8b0:4864:20::b136]) (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 BD3F11083C4A6 for <tls@ietf.org>; Fri, 26 Jun 2026 11:26:43 -0700 (PDT)
Received: by mail-yx1-xb136.google.com with SMTP id 956f58d0204a3-664b05d408bso408185d50.1 for <tls@ietf.org>; Fri, 26 Jun 2026 11:26:43 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; t=1782498403; cv=none; d=google.com; s=arc-20260327; b=lAvStopW9cwFWtvQDKZFCM60Eev51eZ7xJYpKimC+wQNoFTWxyDFEs0UVSvzq6faN3 ekMqNYbQ0n5xTIpUqNlRUh2Dfle7m4FipXnU9etBgrwMjtHgKjwBNNNzGfOGyypWvtGK /9m/HNB0nwlMF8dE+o5mmYl0nTKwAg0vzJ8bHZqjs5gEVE1iRjcgMW8CDbuktReLoDfP o+S0gJaYcJBTdiTpr6iPTget39Om9BoLvepnQZ0H/4b9A5ZqYexxMr57xEOe4Q7WwYYX F82fARfuRgwpUEZ/araIMKKqba+MLuAgAgK5JpdyGp3pYL0YMI9m08LPHgyFn+Y8eSne cmIg==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=XqSz2EcOAiLF3F0WrPSrMxJUb2t6S2upQ4+M9PtM2Yc=; fh=0FjUvRUl9LvdaZtwiWtUjLkGHegWL5ZVZGXggJWf37g=; b=VEbQfqnlDZCnbFPtxo7xiFbjG/sXsVB8okAekM/TsxBEbsVn+VAplMO5gy/PFr8CJI XyGnw0T4ZII694v2ZVcSMzMBUY7K4jQuXpRWSbrHt1vuXFzQ5oojHBX4ZU7xUJXvEULa EuxhuaGNld1q9cD4s0y0Cb46QvQ/FcSccRoQS0Q9Z54umEu2KS6Tet9HOrfMfhz6s/4i qocD3p7LC0t6TkwdQuFQVQIT5H5GF//qEJdat8tRGHH55KH2tsVr7xf+viaUrwfMd/en 3aseYRYZ66fZ7715meAZuhqh2bnXuiQCp9Aa4JPWMmhSftDJ2RDdBkybN2PhmmHc0Uyj +Vrw==; darn=ietf.org
ARC-Authentication-Results: i=1; mx.google.com; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1782498403; x=1783103203; 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=XqSz2EcOAiLF3F0WrPSrMxJUb2t6S2upQ4+M9PtM2Yc=; b=Tp+2iONCQA+6WQEmVTFPPV4BEvtsy0lPNLOfJsnTWl/uK/PGhu3hI0VPSpsc/75A3v xqkYlNC/KfXZD4zo4YUwcGeb0UUhqVpWZN2TqSdM6gpJKdszQi8IwkPZ3PBbhcPIyYQG GtPwobuVhdC7eSsFUM9x/aGAkmNCzPF07SI+vwIBOmpqgQZeLPSgUP+P0myGsvCoJ5jf be2VyFA8YdpX5fV9XkSZJaYEkZurZ+m9pqB1QE89Wi+Y4Q1FPJ1noxA/qQGbxc5l0qrj DsFGm98oKCtbOiVUBxu90qaUAPeA0lcV6MeLSoVpNERXz/wezScX0+3tQnISRCANa83f xFRw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1782498403; x=1783103203; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=XqSz2EcOAiLF3F0WrPSrMxJUb2t6S2upQ4+M9PtM2Yc=; b=lgKQJQYM6BdJBY4WGWytNqxM5R956blLDMZ/RJGs/PGmzj75jVHxw5gXYALOYAih52 jQJyz7aenUZ0VOz5t+ZvVZ6G2iFdvCEJFRHvPhwrtUASWCCrlum8ATN0trqT0YJhTfms nY25mUs1yT9gpm0CXywQ6YyjmYzUUx43XtHiVEXPV50xa6BFIMZf2/rYblxrLbhO4d23 dNuI8o5EIlKNOakqriKnbewBrZ3EGCSVXBZE77g2fti9PZsHHGykn/r+HXkc1CwQ0jha u4YCr4xcmSqkC0HyWVnBIS/+9BScMh+Xs41S9u+/ViiqnwL25nK7LczXxbmi6cSHYIsE QzlQ==
X-Gm-Message-State: AOJu0YxiXIjw/opA9dfk1MMyDFRPlpIcLWIsGsdq5igRBt6LMZySgXZ4 73fYOWt75WdnFNOGJYbnXV6uy6uDUUne6vGIo3PDwAvzqV7bGGZo+f9NJWSzm3JLZHBQkip4lBL 2Qt+4YLI/TNJdZqqlvdDdqNlMU7V3pKw=
X-Gm-Gg: AfdE7cllIc+MCsmiZ+ScoLMd4QWu2pTBoQbRtUwqPD2gnokL4pz4nWgbMC3/4+8CAPu ru08OEqIgkeNKdUhaMlhC1U4L6/xS08nE9e7YdCSaA8+1vRDbjvXyAZGuxzUQwdI8mcRRZiRIUd TpP5VuPFBphfuAO0t8LqaRIZeREn/UU1QhOUHOPfIOeEFB/Cx/7+L1UR+ZerX5KRJO9SOLDIknC WEpd3PZVTowahCpg9Roh7AuvOpHlDt4B9yVmRHA1Hd9d1IeqFFtrVDiI/6bIBOw4InsH5SCKu+/ jBD7m0B5h37fIs/7qBb5wQeNE9lUzWtsiET80uwHUtufbXjI7H0LMPV8tlQoWeYQx9hWjePv3XZ +WrLOkbheaqFB/5CVjFNEIJ2QR2U/8gryVqbK1PjSJTd8oCbg0+av+77IltARuM12
X-Received: by 2002:a05:690e:12c2:b0:664:ae6a:ee4 with SMTP id 956f58d0204a3-664ae6a0f7amr1259755d50.66.1782498403073; Fri, 26 Jun 2026 11:26:43 -0700 (PDT)
MIME-Version: 1.0
References: <178231320760.1520243.5914961961176039994@dt-datatracker-f9b87776f-8pmmg> <2cd74c06-4489-4c68-aad1-bd9b35a05c39@betaapp.fastmail.com> <CAMjbhoW9BmWXvjRxfZALUKoniPYsthhikv2q=iJeXo9X_aMX7Q@mail.gmail.com> <CAOjisRxEJWiq7ESss8MqLxCCxkZUfUDPwNWsgSLCWH4ej+xvLg@mail.gmail.com> <CAOjisRzT9EegXyxcBM1Po_ZTVbXQ0fcMynR31y5jYBdKNmGmYw@mail.gmail.com> <7c36cda6-227d-4a81-b908-3f59052de500@betaapp.fastmail.com>
In-Reply-To: <7c36cda6-227d-4a81-b908-3f59052de500@betaapp.fastmail.com>
From: Nick Sullivan <nicholas.sullivan@gmail.com>
Date: Fri, 26 Jun 2026 14:26:31 -0400
X-Gm-Features: AVVi8CfH5akVrGvDez2vsRI-4La0VJlkFapKRS8LU1rp-t5VTwyjcoqJeQNyVVs
Message-ID: <CAOjisRy=hGVjoC_+mrsQAfUG6HR06yZ_H7L8AUORL_mFb8DgbA@mail.gmail.com>
To: Martin Thomson <mt@lowentropy.net>
Content-Type: multipart/alternative; boundary="00000000000020c30306552c406f"
Message-ID-Hash: WLS4VPTVR3HGMUFELXTINENWZMOMLC4S
X-Message-ID-Hash: WLS4VPTVR3HGMUFELXTINENWZMOMLC4S
X-MailFrom: nicholas.sullivan@gmail.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, Bas Westerbaan <bas=40cloudflare.com@dmarc.ietf.org>, draft-ietf-tls-mlkem@ietf.org, tls-chairs <tls-chairs@ietf.org>
X-Mailman-Version: 3.3.9rc6
Precedence: list
Subject: [TLS] Re: WG Last Call: draft-ietf-tls-mlkem-08 (Ends 2026-07-08)
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/zxh-_S2lGrclUdY8_LquMqQyKc4>
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>

Hi Martin,

Short version: §7.2 and §7.3 aren't symmetric, and that's the root of this.

§7.2 (encapsulation key) is entirely a check on peer-supplied input (both
length and modulus), so a failure is illegal_parameter.

§7.3 (decapsulation input check) is not the mirror image. It bundles one
peer-input check (ciphertext length, the only check FIPS mandates on every
Decaps) with two local decapsulation-key checks (length and embedded hash)
that validate your own key, not anything from the peer. So effectively, to
run a §7.3 check that only fails on peer input, you run the length check
only. §7.3 does not expose this subcheck as separable.

So in this TLS flow, the server's §7.2 check of the client's pk and the
client's ciphertext-length check on the server's ct are peer-input checks,
and failure should be illegal_parameter. The §7.3 dk checks are different:
they are checks on the client's own decapsulation key, so they are local
assurance and should not be a per-Decaps peer-input alert path. With an
already-certified dk, §7.3 reduces to just checking the length and can only
fail with 'illegal parameter'. Bringing the whole §7.3 check into this
section duplicates work and risks conflating errors from a broken keygen
 (not illegal_parameter) and peer-supplied input issues (illegal_parameter).

#25 regresses in two places:
- It replaces §7.2 with a length check (illegal param), letting the other
part of  §7.2 (modulus check) fall through to internal error.
- It adds a wholesale §7.3 check after a length check that fully satisfies §7.3
given dk was generated by this party. This could be read as bringing back
the full validation of a validated dk for every call. (#24 does the same).

So my suggestion is that adding "encapsulation or" to the catch-all on line
245, from #24, is the only change needed. Internal Encap failures errors are
not yet addressed in this document. RNG, memory and other non-peer Encap
failures return internal_error, which is the right alert. (BoringSSL's
Encap can't even return an error; it treats RNG failure as fatal rather
than returnable, but that's a design choice, not a protocol imperative.)

Best,
Nick


On Thu, Jun 25, 2026 at 10:21 PM Martin Thomson <mt@lowentropy.net> wrote:

>
> On Fri, Jun 26, 2026, at 07:39, Nick Sullivan wrote:
> > Quick clarification of my last email. The points, briefly:
> > - Publish -08 as-is: ok
> > - Do not merge #25: it reroutes a failed Section 7.2 encapsulation-key
> > check from illegal_parameter to internal_error, away from -08 (and the
> > approved draft-ietf-tls-ecdhe-mlkem).
> > - Minor, non-blocking: probabilistic wording in Section 4.3, the DTLS
> > freshness clarification, and a note that implicit rejection is not an
> > error.
>
> Nick, that original mail was tl;dr.  I tried.  Are you suggesting that the
> draft is correct without changes?  Just because it works doesn't make it
> good.  A lot depends on how you intend to use this API, but I would greatly
> prefer that it be at least possible to only have to deal with APIs that
> take byte sequences.  (Unlike other uses of the same thing, there is no
> value to obtaining a checked value for multiple uses, because these are
> single-use items.)
>
> With that API, failing the checks in FIPS 203 will be indistinguishable
> from failing to gather entropy or actual cryptographic problems (which we
> generally want to hide; fault injection, etc...).
>
> The part where this gets weird for me is this (which both you and Bas say
> in different ways, I think):
>
> > First, the client need not repeat the decapsulation-key checks on every
> operation [...]
>
> I was not suggesting that the client check the key it made at all (unless
> I'm completely losing it).
>
> #25 says:
>
> > Prior to encapsulation, the server MUST perform the encapsulation key
> check
> > from Section 7.2 of {{FIPS203}}.
> > Prior to decapsulation, the client MUST perform the decapsulation input
> check
> > from Section 7.3 of {{FIPS203}}.
>
> Paraphrasing: "check the stuff you received from the other side before
> using it".  It says nothing of what each peer itself generates.
>
> What am I missing?
>