[issue214] gpgme: add gpgme_key_t->fpr

Marc Mutz <[email protected]>
Newsgroups gmane.comp.encryption.gpg.gpa.devel
Message-ID <[email protected]>
New submission from Marc Mutz <[email protected]>:

Whenever I need to identify a key I'm told to use "the fingerprint". E.g. when  
saving the preferred signing key for an identity to a config file, or when   
trying to determine whether or not a given key represents a root certificate. 
Whenever I do key->subkeys->fpr, therefore, I do wonder why it isn't  
key->subkeys->next->fpr that I should use. What happens if the first subkey is  
deleted from a key, or revoked? This looks even more curious in gpgme++: 
  const char * fpr = key.subkey(0).fingerprint(); // why _0_?   
I therefore added Key::primaryFingerprint() to gpgme++, to hide this particular  
question-raising-whenever-reading-the-code. Maybe much of the need for this 
could go away when some functions in gpgme took gpgme_key_t's instead of const 
char *, see  e.g. #213, and esp. a gpgme_op_keylist_* variant.

----------
assignedto: marcus
messages: 1055
nosy: marc, marcus
priority: wish
status: unread
title: gpgme: add gpgme_key_t->fpr
topic: GPGME
______________________________________________________
Aegypten issue tracker <[email protected]>
<https://intevation.de/roundup/aegypten/issue214>
______________________________________________________
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.