]> git.notmuchmail.org Git - notmuch/blobdiff - notmuch-show.c
crypto: signature verification reports valid User IDs
[notmuch] / notmuch-show.c
index 74e77249d123816257388d3a993811f37fba682b..bb44d93820b1f9236078b5ee42e5ef2e90575abb 100644 (file)
@@ -446,15 +446,11 @@ format_part_sigstatus_sprinter (sprinter_t *sp, mime_node_t *node)
                sp->map_key (sp, "expires");
                sp->integer (sp, expires);
            }
-           /* output user id only if validity is FULL or ULTIMATE. */
-           /* note that gmime is using the term "trust" here, which
-            * is WRONG.  It's actually user id "validity". */
            if (certificate) {
-               const char *name = g_mime_certificate_get_uid (certificate);
-               GMimeCertificateTrust trust = g_mime_certificate_get_trust (certificate);
-               if (name && (trust == GMIME_CERTIFICATE_TRUST_FULLY || trust == GMIME_CERTIFICATE_TRUST_ULTIMATE)) {
+               const char *uid = g_mime_certificate_get_valid_userid (certificate);
+               if (uid) {
                    sp->map_key (sp, "userid");
-                   sp->string (sp, name);
+                   sp->string (sp, uid);
                }
            }
        } else if (certificate) {