talons

Fork of Claws Mail https://www.claws-mail
Log | Files | Refs | README | LICENSE

commit f146a82069d03ca436712096482a33f4f4991abf
parent bf3f91d9ce21acf3fd52ed6ad4c25a956f1490aa
Author: Paul <paul@claws-mail.org>
Date:   Thu, 26 Jun 2014 05:19:11 +0100

show owner trust in full info

Diffstat:
Msrc/plugins/pgpcore/sgpgme.c | 18++++++++++++++++++
1 file changed, 18 insertions(+), 0 deletions(-)

diff --git a/src/plugins/pgpcore/sgpgme.c b/src/plugins/pgpcore/sgpgme.c @@ -153,6 +153,22 @@ static const gchar *get_validity_str(unsigned long validity) } } +static const gchar *get_owner_trust_str(unsigned long owner_trust) +{ + switch (gpgme_err_code(owner_trust)) { + case GPGME_VALIDITY_NEVER: + return _("Untrusted"); + case GPGME_VALIDITY_MARGINAL: + return _("Marginal"); + case GPGME_VALIDITY_FULL: + return _("Full"); + case GPGME_VALIDITY_ULTIMATE: + return _("Ultimate"); + default: + return _("Unknown"); + } +} + static gchar *extract_name(const char *uid) { if (uid == NULL) @@ -330,6 +346,8 @@ gchar *sgpgme_sigstat_info_full(gpgme_ctx_t ctx, gpgme_verify_result_t status) j++; user = user->next; } + g_string_append_printf(siginfo,_("Owner Trust: %s\n"), + get_owner_trust_str(key->owner_trust)); g_string_append(siginfo, _("Primary key fingerprint:")); const char* primary_fpr = NULL;