Re: GPGME S/MIME expired flag support?
"Kevin J. McCarthy" <[email protected]> Sat, 4 Jul 2026 11:33:19 +0800
| Newsgroups | gmane.mail.mutt.devel |
|---|---|
| Message-ID | <[email protected]> |
--k+y9Sy/Y9J9k8Q06 Content-Type: text/plain; charset=utf-8; format=flowed Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jul 03, 2026 at 08:55:02PM +0200, Robert J=C3=A4schke via Mutt-dev = wrote: >Am 02.07.2026 schrieb Kevin J. McCarthy: >> In the Mutt GPGME code, in get_candidates(), the APPLICATION_PGP section= has >> code to check for revoked/expired/disabled flags: >[...] >> However, the APPLICATION_SMIME code in the same function is missing those >> checks. > >Thank you for finding that code. For testing purposes, I have added just >the lines > > if (key->expired) > flags |=3D KEYFLAG_EXPIRED; > >to the corresponding S/MIME loop and it works as expected (although the >option pgp_show_unusable seems to be ignored but I have to further check >that). I'm glad that is working. That's good in that it means the S/MIME GPGME backend flags are set. So it's just a matter of hooking them up. The check for the $pgp_show_unusable is there in crypt_select_key(), so I'm not seeing right away why that isn't working for you. You may have to add muttdbg() statements and see what the problem is. >While diving through crypt-gpgme.c I found the functions >crypt_select_key and crypt_entry_fmt. That led me to the option >pgp_entry_format and its sequence for the time: > >%[<s>] date of the key where <s> is an strftime(3) expression > >I wonder why it shows the creation date and not the expiration date of >the key? Yeah, that's not going to be changeable. The format string is shared=20 across GPGME and PGP classic, and I assure people will notice if you=20 just change it. Adding multiple dates also involves mucking in the=20 gnupgparse parser, which I'd rather not do for something like this. Let's see if you can discover why the $pgp_show_unusable isn't working=20 for you. --=20 Kevin J. McCarthy GPG Fingerprint: 8975 A9B3 3AA3 7910 385C 5308 ADEF 7684 8031 6BDA --k+y9Sy/Y9J9k8Q06 Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEiXWpszqjeRA4XFMIre92hIAxa9oFAmpIfv8ACgkQre92hIAx a9pa+g/+JZk4kk8Wg2W1ZOpY2CYTpirmgfWoBnX99uSYwonW0SOr/ILTO74CwqcI kWcj06p91sV36jD74GYS6fxhdVROfLuK0+lS0pv4fvEuAb1+7NQ4qwyhmpoA8tXX lOZ8f31sYP5IEnNUNz2DXW5EH346Nbo4gCstEJibmdk7OjKMonTEhJb9k6EXtBxt zLvVZvdZnlsOPDtDLGWUt+Y78iUC5lb3hKG5AWPb/fU5BL5CoOS8fRasHGd8Qt7X JfBX0HpHimz9lFsohf7/H3KjRm8JLNZ3UiqApAnYlBCnplR1jN31vE2bqfcVYPnx yf6MiK1z2bHGJQewqnPEjlz83J0OC9CbNM6VhOTwT/wYOsSlMruXTXl2DMceaMxs Rtwu2Yybh+OE+bEgU2ZhAJ6bPjrGTmwQGmACkVnF29XlE5dSDJJDQTV1JraivK3k GW7Q2MNoC68O1urcc9fGx5BbeAeNTzzN9rafxFpl7ZfwPMrVLkAMMVBJ5Wtxu0PU NM6GuDe1ivIwGgEAZNjQXuXiLNiQ75bg73b9cMa/NeCpwtyxDGqYm4wXLGKveUsM ZVv2A2mNYSPJmJa4FfGrpzV66Zsv+LTJz24Lc4NygXsKW4yOCe5Bh9PXKmUOmR4i hJavCUANh6MZiruSlRQeyAmDbpi4Xj7MfdC3Ly23cYHtenfs460= =AMMV -----END PGP SIGNATURE----- --k+y9Sy/Y9J9k8Q06--