Decrypt GnuPG AEAD packet type 20 password-store entries #61
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Objective
Support existing upstream-compatible password stores whose GPG entries use the GnuPG AEAD packet type 20 format.
Root cause
The affected entries correctly target encryption subkey 4D463BF6BA4D8A9C under primary key 3B98…5429, so key selection is not the failure. The real store's 547 entries use AES-256/OCB GnuPG AEAD packets (tag 20), while IronStorage's current compatibility fixtures and documented profile cover only SEIPD/MDC packet type 18. pgp 0.20 requires GnuPG AEAD support to be explicitly enabled, but crates/storage/src/crypto.rs currently uses default Message::decrypt behavior and rejects tag 20. The resulting decrypt error also causes a correctly prompted passphrase to be discarded rather than persisted.
Scope
Acceptance criteria
Implemented in commit
977eb23and pushed to main.Storage now opts into pgp 0.20 GnuPG AEAD decryption through DecryptionOptions while keeping legacy unauthenticated packets disabled and preserving IronStorage encryption as packet type 18 SEIPDv1/MDC.
Compatibility evidence:
The upstream audit was also documented: pass 1.7.4 delegates gpg file reads/writes to GnuPG; current Homebrew pass depends on GnuPG 2.5.21; GnuPG chooses CFB+MDC or packet-20 OCB from recipient preferences. Default GnuPG rejects missing-MDC legacy data, so IronStorage keeps that unsafe mode disabled.
Verification passed: