[openpgp] Re: ML-KEM and ML-DSA secret key format

Daniel Huigens <d.huigens@protonmail.com> Sun, 02 March 2025 09:45 UTC

Return-Path: <d.huigens@protonmail.com>
X-Original-To: openpgp@mail2.ietf.org
Delivered-To: openpgp@mail2.ietf.org
Received: from localhost (localhost [127.0.0.1]) by mail2.ietf.org (Postfix) with ESMTP id 6CE2B4C9C1C for <openpgp@mail2.ietf.org>; Sun, 2 Mar 2025 01:45:34 -0800 (PST)
X-Virus-Scanned: amavisd-new at ietf.org
X-Spam-Flag: NO
X-Spam-Score: -2.096
X-Spam-Level:
X-Spam-Status: No, score=-2.096 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, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: mail2.ietf.org (amavisd-new); dkim=pass (2048-bit key) header.d=protonmail.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 j6C8eLvMmvcm for <openpgp@mail2.ietf.org>; Sun, 2 Mar 2025 01:45:33 -0800 (PST)
Received: from mail-10631.protonmail.ch (mail-10631.protonmail.ch [79.135.106.31]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by mail2.ietf.org (Postfix) with ESMTPS id 6B2584C9C17 for <openpgp@ietf.org>; Sun, 2 Mar 2025 01:45:33 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1740908731; x=1741167931; bh=08LL1FvbVugkSP8PJegscpB7I7+ngDYG05As8vzGtPg=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector:List-Unsubscribe:List-Unsubscribe-Post; b=JHZTTCiWC9AAr0LvOf4+c5i+jSKrvVFRqxRyi4SmhnkbqqREwViot8WVJZJ7Ma8WA BysZVMiVddnhFCYQu4UuHo4vn5WAjjZWLooltQEEoc0J6yjRwR6UJTu5de2m+4Gk7c OhyYzQnbAkllvRLkoce4Rt+8zIfmMhpgcbaIdmIRHrhy4/m7KSRvTvdIpT/C/JS4bH ur9MB/QDdlisAt2JLT3tgCjPHRePx94bCW4hSjluRx5EcrIYPOFn9VJZxpV8KCcnCN 3xoF2ErHBmokwzHuc5WHIDsOzjXq5J4xlWGJuWJiBcz3MTGeJpwz0PLWfOdpcwRDnQ 3L9JxKZIs8g+A==
Date: Sun, 02 Mar 2025 09:45:27 +0000
To: Michael Richardson <mcr+ietf@sandelman.ca>
From: Daniel Huigens <d.huigens@protonmail.com>
Message-ID: <dyqPyn1cRMvwM3rEiTJjgrPDFCQYaiJx9j9cP4NCpUB-9SxCXLvx2hMP3qOI4BkC-fAJVYp7BRBquo2so7eNkuj-nPcBpKdBNba31Oy9YqE=@protonmail.com>
In-Reply-To: <2484.1740769703@obiwan.sandelman.ca>
References: <vN75HSFXALBJQMd1A60IEhI_gqmw27cvjvVTK6APPoK-NjROf5a0KTPiRtUC3G04hrX_pb1Yzpu7n2R90yIVYbqJZpRPkkyxLbH6cy7tpjw=@wussler.it> <9ca7ac72-e56b-4ac8-a894-44e31718c046@cs.tcd.ie> <oa-f1kLfj5SY47NIE1x6kqQxWfe-oQZUOsKevSWMfmafdVuLPL06GEWJR9wIjny9tb6FuaGd98pTESiVGrHP2tzWTCYgg_chitIqcGF2Eks=@wussler.it> <2d1d43103913268d6a6e4d1257ff6c842535ac51.camel@redhat.com> <Vng9thV-ERMDuIUawJIDLdf1BWWMl_fIBrSnEYJJ_aEVtw3VM-450tDZEZp0WXgzVokxcawyKPpcuRyqbdzDaL9NN5mJJogYPsQjiynVygI=@wussler.it> <2484.1740769703@obiwan.sandelman.ca>
Feedback-ID: 2934448:user:proton
X-Pm-Message-ID: f889235a0ffa4526dc7be2d16416cf0264e0ceeb
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
Message-ID-Hash: M23NCMJSRZ6C2KK33IB6AEZ3NDLEKSYD
X-Message-ID-Hash: M23NCMJSRZ6C2KK33IB6AEZ3NDLEKSYD
X-MailFrom: d.huigens@protonmail.com
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-openpgp.ietf.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
CC: "openpgp@ietf.org" <openpgp@ietf.org>
X-Mailman-Version: 3.3.9rc6
Precedence: list
Subject: [openpgp] Re: ML-KEM and ML-DSA secret key format
List-Id: "Ongoing discussion of OpenPGP issues." <openpgp.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/openpgp/hqhmrNdyz1v4GNc_4ixG4Q854m8>
List-Archive: <https://mailarchive.ietf.org/arch/browse/openpgp>
List-Help: <mailto:openpgp-request@ietf.org?subject=help>
List-Owner: <mailto:openpgp-owner@ietf.org>
List-Post: <mailto:openpgp@ietf.org>
List-Subscribe: <mailto:openpgp-join@ietf.org>
List-Unsubscribe: <mailto:openpgp-leave@ietf.org>

Hi Michael,

I agree with most of what you wrote, but I don't think any of it
implies that we need to wait for the decision in LAMPS or base
our own decision (for the OpenPGP wire format) on it (if you even
meant to imply that, perhaps you didn't).

If we mainly care about importing an OpenPGP key to an HSM, then
storing the key as a seed up until that point is most convenient
as you can go from a seed to an expanded key but not the other way
around. So even if the HSM vendor decides not to support seeds in
any way, we could convert the seed to an expanded key in software
and then import that in whichever format the HSM vendors like
(without specifying an OpenPGP-specific wire format for it).

If we care about moving keys between HSMs, that can happen again
in some format decided on by the HSM vendors and doesn't need to be
specified by OpenPGP, specifically.

It's only if we care about exporting an HSM key to a "software-backed"
OpenPGP key that supporting an expanded key wire format could make
sense, but IMHO this is not a use case that we should want to support.

Best,
Daniel


On Friday, February 28th, 2025 at 20:08, Michael Richardson wrote:
> The reason why the PKCS8 discussion in LAMPS is relevant to OPENPGP is
> because one can hope that there will be support in OPENPGP products for
> smaller/personal HSMs (USB tokens). The tokens might get used with a variety
> of protocols.
> 
> Today, signing of software is largely a PGP thing not an S/MIME thing.
> (It's different in the MS-MSI space)
> Particularly when it comes to signing git commits.
> 
> My opinion is that there are very few situations where it's better to move a
> private key rather than just have two or more signing keys be validated.
> At least -- in an PKIX situation with a certification authority.
> I think that YUM, and APT based systems can now specify a PGP keyring for
> each source, and a signature from any key in that keyring is valid.
> (And we've finally moved beyond mixing all the keys up for the different
> sources)
> 
> Having a way to backup a private key from one token to another one seems
> (rather than generating a new key) might be operationally important for in
> the software signing space.
> I don't think the same considerations apply to individual use personal keys.
> 
> I also think that OPENPGP key format allows us to have multiple private keys
> attached to a single identity, and for those keys to reside on distinct
> tokens. I admit that I've never tried this, but I ought to already.
> 
> 
> --
> Michael Richardson mcr+IETF@sandelman.ca . o O ( IPv6 IøT consulting )
> 
> Sandelman Software Works Inc, Ottawa and Worldwide
> _______________________________________________
> openpgp mailing list -- openpgp@ietf.org
> To unsubscribe send an email to openpgp-leave@ietf.org