diff options
| author | Andre Heinecke <[email protected]> | 2019-12-13 17:06:00 +0000 |
|---|---|---|
| committer | Andre Heinecke <[email protected]> | 2019-12-13 17:06:00 +0000 |
| commit | 194272dbc3e326cc32c1464bc6fda0c0d10b5559 (patch) | |
| tree | a89b7d93b3e192a4f548a19ec9b47316ad1277fa /lang/qt/src | |
| parent | core: Extend gpgme_user_id_t with uidhash member. (diff) | |
| download | gpgme-194272dbc3e326cc32c1464bc6fda0c0d10b5559.tar.gz gpgme-194272dbc3e326cc32c1464bc6fda0c0d10b5559.zip | |
cpp, qt: Use uidhash to select uids for signing
* lang/cpp/src/gpgsignkeyeditinteractor.cpp (action):
Use uidhash instead of number.
(GpgSignKeyEditInteractor::setKey): New.
* lang/cpp/src/gpgsignkeyeditinteractor.h: Update accordingly.
* lang/cpp/src/key.h, lang/cpp/src/key.cpp: Wrap uidhash.
* lang/qt/src/qgpgmesignkeyjob.cpp: Set the key.
--
Using the uidhash avoids problems when the user ids
on --edit-key are different ones then the uids
captured by gpgme when listing keys. Or if
they are in a different order. This can happen
with cached keys or keys with user attributes.
Diffstat (limited to 'lang/qt/src')
| -rw-r--r-- | lang/qt/src/qgpgmesignkeyjob.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lang/qt/src/qgpgmesignkeyjob.cpp b/lang/qt/src/qgpgmesignkeyjob.cpp index 7cd10eb5..1d36d95a 100644 --- a/lang/qt/src/qgpgmesignkeyjob.cpp +++ b/lang/qt/src/qgpgmesignkeyjob.cpp @@ -76,6 +76,7 @@ static QGpgMESignKeyJob::result_type sign_key(Context *ctx, const Key &key, cons skei->setUserIDsToSign(uids); skei->setCheckLevel(checkLevel); skei->setSigningOptions(opts); + skei->setKey(key); if (dupeOk) { ctx->setFlag("extended-edit", "1"); |
