kgpg
#include <kgpgsigntransactionhelper.h>
Public Types | |
enum | carefulCheck { noAnswer = 0, notChecked = 1, normalChecking = 2, carefulChecking = 3 } |
enum | lineParseResults { handledFalse, handledTrue, notHandled } |
enum | ts_signuid { TS_ALREADY_SIGNED = KGpgTransaction::TS_COMMON_END + 1 } |
Public Member Functions | |
virtual | ~KGpgSignTransactionHelper () |
carefulCheck | getChecking (void) const |
const KGpgKeyNode * | getKey (void) const |
bool | getLocal (void) const |
QString | getSigner (void) const |
void | setChecking (const carefulCheck level) |
void | setKey (const KGpgKeyNode *node) |
void | setLocal (const bool local) |
void | setSecringFile (const QString &filename) |
void | setSigner (const QString &signer) |
Protected Member Functions | |
KGpgSignTransactionHelper (const QString &signer, const bool local, const carefulCheck checking) | |
virtual KGpgTransaction * | asTransaction ()=0 |
KGpgTransaction::ts_boolanswer | boolQuestion (const QString &line) |
lineParseResults | nextLine (const QString &line) |
virtual void | replaceCmd (const QString &cmd)=0 |
Protected Attributes | |
int | m_signerPos |
Detailed Description
helper class for key signing transactions
Definition at line 25 of file kgpgsigntransactionhelper.h.
Member Enumeration Documentation
Enumerator | |
---|---|
noAnswer | |
notChecked | |
normalChecking | |
carefulChecking |
Definition at line 38 of file kgpgsigntransactionhelper.h.
the outcomes of nextLine()
Definition at line 32 of file kgpgsigntransactionhelper.h.
Enumerator | |
---|---|
TS_ALREADY_SIGNED |
user id is alredy signed by given key |
Definition at line 45 of file kgpgsigntransactionhelper.h.
Constructor & Destructor Documentation
|
virtual |
destructor
Definition at line 28 of file kgpgsigntransactionhelper.cpp.
|
protected |
constructor
- Parameters
-
signer id of the key to sign with local if signature should be local (not exportable) checking how carefully the identity of the key owner was checked
Definition at line 19 of file kgpgsigntransactionhelper.cpp.
Member Function Documentation
|
protectedpure virtual |
returns the transaction object to use
This should really be static_cast<>(this) as you should only use this class as one of two anchestors of a transaction.
Implemented in KGpgSignUid, and KGpgSignKey.
|
protected |
Definition at line 69 of file kgpgsigntransactionhelper.cpp.
KGpgSignTransactionHelper::carefulCheck KGpgSignTransactionHelper::getChecking | ( | void | ) | const |
check if local signing is requested
Definition at line 116 of file kgpgsigntransactionhelper.cpp.
const KGpgKeyNode * KGpgSignTransactionHelper::getKey | ( | void | ) | const |
get the key node this transaction is using
Definition at line 39 of file kgpgsigntransactionhelper.cpp.
bool KGpgSignTransactionHelper::getLocal | ( | void | ) | const |
check if local signing is requested
Definition at line 104 of file kgpgsigntransactionhelper.cpp.
QString KGpgSignTransactionHelper::getSigner | ( | void | ) | const |
get key id which is used to sign
Definition at line 130 of file kgpgsigntransactionhelper.cpp.
|
protected |
handle signing commands from GnuPG
- Parameters
-
line input to parse
This will handle the GnuPG commands specific to signing.
Definition at line 45 of file kgpgsigntransactionhelper.cpp.
|
protectedpure virtual |
replaces the command passed to GnuPG
- Parameters
-
cmd new command to use
Implemented in KGpgSignUid, and KGpgSignKey.
void KGpgSignTransactionHelper::setChecking | ( | const carefulCheck | level | ) |
set the level how carefully the identity was checked
- Parameters
-
level level to set
Definition at line 110 of file kgpgsigntransactionhelper.cpp.
void KGpgSignTransactionHelper::setKey | ( | const KGpgKeyNode * | node | ) |
set key node this transaction is using
- Parameters
-
node new key node
Definition at line 33 of file kgpgsigntransactionhelper.cpp.
void KGpgSignTransactionHelper::setLocal | ( | const bool | local | ) |
set if the signature should be local (not exportable)
- Parameters
-
local flag if local signature should be applied
Definition at line 91 of file kgpgsigntransactionhelper.cpp.
void KGpgSignTransactionHelper::setSecringFile | ( | const QString & | filename | ) |
add a secret keyring file
This allows to specify an additional file where secret keys are stored to be used by this operation. This is especially useful if a different GnuPG home directory is set but the original keys should be used for signing.
Definition at line 136 of file kgpgsigntransactionhelper.cpp.
void KGpgSignTransactionHelper::setSigner | ( | const QString & | signer | ) |
set which private key is used to sign
- Parameters
-
signer id of private key to use
Definition at line 122 of file kgpgsigntransactionhelper.cpp.
Member Data Documentation
|
protected |
position of the signer argument in GnuPG command line
Definition at line 133 of file kgpgsigntransactionhelper.h.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:42:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.