diff options
| author | Ingo Klöcker <[email protected]> | 2021-05-05 16:38:16 +0000 |
|---|---|---|
| committer | Ingo Klöcker <[email protected]> | 2021-05-05 17:26:33 +0000 |
| commit | f0858e45b0be260730e742643e741547123d4287 (patch) | |
| tree | 9fb594a4d50c4155f59ac29b80068a1ae28bd7e7 /lang/qt/src/signkeyjob.h | |
| parent | qt: Pimpl QGpgMESignKeyJob (diff) | |
| download | gpgme-f0858e45b0be260730e742643e741547123d4287.tar.gz gpgme-f0858e45b0be260730e742643e741547123d4287.zip | |
qt: Extend SignKeyJob to create trust signatures
* lang/qt/src/signkeyjob.h (SignKeyJob::setTrustSignature): New.
* lang/qt/src/qgpgmesignkeyjob.h, lang/qt/src/qgpgmesignkeyjob.cpp
(QGpgMESignKeyJob::setTrustSignature): New.
* lang/qt/src/qgpgmesignkeyjob.cpp (sign_key): Handle trust signatures.
(QGpgMESignKeyJob::start): Pass trust signature attributes to sign_key.
(QGpgMESignKeyJob::setTrustSignature): New.
--
This allows Kleopatra to create trust signatures for trusted
introducers.
GnuPG-bug-id: 5245, 5421
Diffstat (limited to '')
| -rw-r--r-- | lang/qt/src/signkeyjob.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/lang/qt/src/signkeyjob.h b/lang/qt/src/signkeyjob.h index e3ae75f7..461b9b3a 100644 --- a/lang/qt/src/signkeyjob.h +++ b/lang/qt/src/signkeyjob.h @@ -43,6 +43,7 @@ namespace GpgME { class Error; class Key; +enum class TrustSignatureTrust : char; } class QString; @@ -127,6 +128,25 @@ public: **/ virtual void setRemark(const QString &) {}; + /** + * If set, then the created signature will be a trust signature. By default, + * no trust signatures are created. + * + * @a trust is the amount of trust to put into the signed key, either + * @c TrustSignatureTrust::Partial or @c TrustSignatureTrust::Complete. + * @a depth is the level of the trust signature. Values between 0 and 255 are + * allowed. Level 0 has the same meaning as an ordinary validity signature. + * Level 1 means that the signed key is asserted to be a valid trusted + * introducer. Level n >= 2 means that the signed key is asserted to be + * trusted to issue level n-1 trust signatures, i.e., that it is a "meta + * introducer". + * @a scope is a domain name that limits the scope of trust of the signed key + * to user IDs with email addresses matching the domain (or a subdomain). + * + * Not pure virtual for ABI compatibility. + **/ + virtual void setTrustSignature(GpgME::TrustSignatureTrust trust, unsigned short depth, const QString &scope) { Q_UNUSED(trust); Q_UNUSED(depth); Q_UNUSED(scope); }; + Q_SIGNALS: void result(const GpgME::Error &result, const QString &auditLogAsHtml = QString(), const GpgME::Error &auditLogError = GpgME::Error()); }; |
