I have added a Kyber768 encryption subkey to my existing primary key. But trying to decrypt a message encrypted to that new subkey yields the following error:
gpg: encrypted with ky768_bp256 key, ID B15C12AEB7588C1F […] gpg: public key decryption failed: Wrong secret key used gpg: decryption failed: Wrong secret key used
It seems this is because the session key is a AES128 key, as can be shown when listing the packets of the encrypted message (session key algo: 7):
$ gpg --list-packets test.asc gpg: encrypted with ky768_bp256 key, ID B15C12AEB7588C1F […] gpg: public key decryption failed: Wrong secret key used gpg: decryption failed: Wrong secret key used # off=0 ctb=85 tag=1 hlen=3 plen=1195 :pubkey enc packet: version 3, algo 8, keyid B15C12AEB7588C1F session key algo: 7 data: [515 bits] data: [8704 bits] data: [192 bits] # off=1198 ctb=d4 tag=20 hlen=2 plen=0 partial new-ctb :aead encrypted packet: cipher=7 aead=2 cb=16 length: unknown
while GnuPG is apparently expecting the session key to be a AES256 key – If I force GnuPG to use AES256 as the symmetric algo (--cipher-algo AES256) when encrypting the message, I can decrypt it without issue. (For completeness I also tried forcing it to use a AES192 key – this yields the same “wrong secret key” error.)
The preferences on my existing key (which I have not modified in a while), do place AES128 as the preferred symmetric algorithm, _before_ AES256. If I update those to use the new default preferences (with AES256 as the preferred symmetric algo), then GnuPG will automatically use AES256 by default and decryption will again work without any issue.
So it seems that
A) when encrypting a message to a Kyber key, GnuPG always dutifully selects the symmetric algorithm based on the recipient’s preferences (unless overridden by --cipher-algo), but
B) when decrypting a message encrypted with a Kyber key, GnuPG only expects a AES256 session key and cannot handle a AES128 or AES192 key.