Page MenuHome GnuPG

GnuPG: Deletion of kyber key fails
Open, NormalPublic

Description

Deleting a kyber key currently fails with the error "Ungültiger Wert":

C:\Users\g10>gpg --version
gpg (GnuPG) 2.5.13
libgcrypt 1.11.2

C:\Users\g10>gpg --full-gen-key
[... 16: ecc and kyber ...]
pub   brainpoolP256r1 2025-10-27 [SC]
      20C8E01A8C25E1F9367DBBCD5BD18ED025C98841
uid                      kyber
sub   ky768_bp256 2025-10-27 [E]
      13E62ACECD2692E4A4461A9FE21562E30709C99E106FDD476F88B0FDAC8AB23A

C:\Users\g10>gpg -v --delete-secret-and-public-keys 20C8E01A8C25E1F9367DBBCD5BD18ED025C98841
[...]
gpg: enabled compatibility flags:

sec  brainpoolP256r1/5BD18ED025C98841 2025-10-27 kyber

Diesen Schlüssel aus dem Schlüsselbund löschen? (j/N) j
Dies ist ein privater Schlüssel! - Wirklich löschen? (j/N) j
gpg: pinentry launched (4868 qt 1.3.2 - - - - 0/0 -)
gpg: Fehler beim Löschen des privaten Unterschlüssels: Ungültiger Wert
gpg: 20C8E01A8C25E1F9367DBBCD5BD18ED025C98841: delete key failed: Ungültiger Wert

Details

Version
gpg4win-5.0.0-beta395 @ win11

Event Timeline

timegrid created this object with edit policy "Contributor (Project)".
werner edited projects, added gnupg26, PQC, Bug Report; removed gnupg.

Workaround is to use --with-keygrip and delete both <keygrip>.key files. Problem here is that one part may be on a smartcard or one part might be shared (although not allowed) with other keys.

Note that currently Kleopatra (gpg4win 5 beta) fails to delete the key, which might impact other operations. I'm currently trying to figure out, if some other bugs/quirks are a subsequent error or not.