gpg 2.5.24: PQC interoperability observations (PKESK encoding with v4 keys and ML-KEM subkeys)
Werner Koch
wk at gnupg.org
Wed Nov 18 17:42:51 CET 2026
Hi!
and thanks for testing.
> 1. Messages encrypted to a v4 key with an ML-KEM subkey cannot be
> decrypted
>
> When gpg 2.5.24 encrypts to a v4 key that has an ML-KEM encryption
> subkey, it writes the 20-octet v4 fingerprint in the PKESK packet
> followed by twelve zero octets, as if the field were sized for a
That is quite possible having a v4 subkey does not make any sense
becuase new code is anyway required for the rfc-9980 PQC. But you are
right, at least an error should be emitted.
> I saw this with three different v4 keys. If I remove the twelve
> octets from the packet by hand, the message decrypts correctly.
BTW, are you using the keyboxd (common.conf with use-keyboxd) or
pubring.kbx ? Your gpg.conf would actually be helpful
> Of the PQC test keys I tried, three are rejected because the
> public-key algorithm is unknown, and two more already fail at
That might be. ML-DSA is for example not yet implemented. Also only
unprotected private keys are supported.
> 3. gpgsm does not import a PKCS#12 file with an ML-KEM key
Not yet implemented. Actually only the next version will have some PQC
support for gpgsm. Here are the draft NEWS:
* New and extended features in 2.2.25:
- gpgsm: The default cipher algorithm is now AES256-GCM. Support
for GCM is meanwhile widely enough deployed. We have support for
GCM decryption since version 2.3.2 (2021-08-24). [rG66c1abf48a]
- gpgsm: Support for importing and checking ML-DSA signed
certificates. [T8517]
- gpgsm: Support for ML-KEM+ECC de- and encryption. Obviosuly this
is not yet well tested and thus should not be used for production
use. [T8541]
PCKS#12 import and export of PQC will also soon be availabale but
unfortunately not yet in the next version.
> I can send the test keys, sample messages, and gpg --list-packets
I like sample keys and messages as long as I can put them into the repo.
Shalom-Salam,
Werner
--
The pioneers of a warless world are the youth that
refuse military service. - A. Einstein
-------------- next part --------------
A non-text attachment was scrubbed...
Name: openpgp-digital-signature.asc
Type: application/pgp-signature
Size: 284 bytes
Desc: not available
URL: <https://lists.gnupg.org/pipermail/gnupg-devel/attachments/20261118/6dca0baa/attachment.sig>
More information about the Gnupg-devel
mailing list