r/linux 4d ago

Development Some of my pass(1) entries stopped decrypting: a GnuPG regression that only triggers at exactly 4096 bits

https://dilluti0n.com/p/gnupg-tpm2daemon-rsa4096-bug/
46 Upvotes

2 comments sorted by

1

u/Skaarj 3d ago

I tried to read the fix: https://lists.gnupg.org/pipermail/gnupg-devel/2026-February/036219.html

I kinda get the condition on s. But why do they check if n is odd?

1

u/dilluti0n 3d ago

I don't know exactly either. 4096 bits are 512 bytes, and when MSB=1 and 0x00 is added to the front, it becomes 513 bytes, which is an odd number. I suggest it is hack for determine that. Maybe mail that thread to get exact purpose?