libkpgp
kpgpkey.h
Go to the documentation of this file.
847 const int result = QString::compare( left->primaryUserID().toLower(), right->primaryUserID().toLower() );
bool isValidEncryptionKey() const
Returns true if the key is a valid encryption key.
Definition: kpgpkey.cpp:187
void setRevoked(const bool revoked)
Sets the flag if the subkey has been revoked to revoked .
Definition: kpgpkey.h:436
Validity
These are the possible validity values for a PGP user id and for the owner trust. ...
Definition: kpgpkey.h:32
Key(const KeyID &keyid=KeyID(), const QString &uid=QString(), const bool secret=false)
Constructs a new PGP key with keyid as key ID of the primary key and uid as primary user ID...
Definition: kpgpkey.cpp:87
static KeyIDList fromStringList(const QStringList &)
Converts from a QStringList to a KeyIDList.
Definition: kpgpkey.cpp:41
void setCanCertify(const bool canCertify)
Sets the flag if the key can be used to certify keys to canCertify .
Definition: kpgpkey.h:762
bool canEncrypt() const
Returns true if the subkey can be used to encrypt data.
Definition: kpgpkey.h:381
void setFingerprint(const KeyID &keyID, const QByteArray &fpr)
Sets the fingerprint of the given subkey to fpr .
Definition: kpgpkey.cpp:252
void setDisabled(const bool disabled)
Sets the flag if the subkey has been disabled to disabled .
Definition: kpgpkey.h:446
void setExpired(const bool expired)
Sets the flag if the subkey has expired to expired .
Definition: kpgpkey.h:441
bool canCertify() const
Returns true if the subkey can be used to certify keys.
Definition: kpgpkey.h:391
Definition: kpgpkey.h:39
void setCanEncrypt(const bool canEncrypt)
Sets the flag if the key can be used to encrypt data to canEncrypt .
Definition: kpgpkey.h:752
void setEncryptionPreference(const EncryptPref encrPref)
Sets the encryption preference for this key to encrPref .
Definition: kpgpkey.h:772
Definition: kpgpkey.h:38
void setKeyLength(const unsigned int keyLen)
Sets the key length of the subkey to keyLen bits.
Definition: kpgpkey.h:476
bool canEncrypt() const
Returns true if the key can be used to encrypt data.
Definition: kpgpkey.h:712
void setInvalid(const bool invalid)
Sets the flag if the subkey is invalid to invalid .
Definition: kpgpkey.h:451
time_t creationDate() const
Returns the creation date of the primary subkey.
Definition: kpgpkey.h:822
void setCanSign(const bool canSign)
Sets the flag if the subkey can be used to sign data to canSign .
Definition: kpgpkey.h:461
void setSecret(const bool secret)
Sets the flag if the key is a secret key to secret .
Definition: kpgpkey.h:727
void setDisabled(const bool disabled)
Sets the flag if the key has been disabled to disabled .
Definition: kpgpkey.h:742
void setInvalid(const bool invalid)
Sets the flag if the user id is invalid to invalid.
Definition: kpgpkey.h:170
EncryptPref encryptionPreference()
Returns the encryption preference for this key.
Definition: kpgpkey.h:767
void setInvalid(const bool invalid)
Sets the flag if the key is invalid to invalid .
Definition: kpgpkey.h:747
KeyID longKeyID() const
Returns the long 64 bit key ID of the subkey if it's available.
Definition: kpgpkey.h:406
This class is used to store information about a subkey of a PGP key.
Definition: kpgpkey.h:183
void addUserID(const QString &uid, const Validity validity=KPGP_VALIDITY_UNKNOWN, const bool revoked=false, const bool invalid=false)
Adds a user ID with the given values to the key if uid isn't an empty string.
Definition: kpgpkey.cpp:200
void setRevoked(const bool revoked)
Sets the flag if the user id has been revoked to revoked.
Definition: kpgpkey.h:165
Definition: kpgpkey.h:50
Definition: kpgpkey.h:35
Definition: kpgpkey.h:57
void setSecret(const bool secret)
Sets the flag if the subkey is a secret subkey to secret .
Definition: kpgpkey.h:431
UserID(const QString &str, const Validity validity=KPGP_VALIDITY_UNKNOWN, const bool revoked=false, const bool invalid=false)
Constructs a new user id with the given values.
Definition: kpgpkey.cpp:53
QString primaryUserID() const
Returns the primary user ID or a null string if there are no user IDs.
Definition: kpgpkey.h:777
void setExpirationDate(const time_t expirationDate)
Sets the expiration date of the subkey to expirationDate seconds since Epoch.
Definition: kpgpkey.h:496
This class is used to store information about a user id of a PGP key.
Definition: kpgpkey.h:72
Definition: kpgpkey.h:37
bool canCertify() const
Returns true if the key can be used to certify keys.
Definition: kpgpkey.h:722
unsigned int keyAlgorithm() const
Returns the key algorithm of the subkey.
Definition: kpgpkey.h:396
bool isValidSigningKey() const
Returns true if the key is a valid signing key.
Definition: kpgpkey.cpp:194
Definition: kpgpkey.h:46
Definition: kpgpkey.h:51
void setCanCertify(const bool canCertify)
Sets the flag if the subkey can be used to certify keys to canCertify .
Definition: kpgpkey.h:466
QByteArray primaryFingerprint() const
Returns the fingerprint of the primary key or a null string if there are no subkeys.
Definition: kpgpkey.h:797
void setFingerprint(const QByteArray &fingerprint)
Sets the fingerprint of the subkey to fingerprint .
Definition: kpgpkey.h:486
void setKeyAlgorithm(const unsigned int keyAlgo)
Sets the key algorithm of the subkey to keyAlgo .
Definition: kpgpkey.h:471
void addSubkey(const KeyID &keyID, const bool secret=false)
Adds a subkey with the given values to the key if keyID isn't an empty string.
Definition: kpgpkey.cpp:222
void setExpired(const bool expired)
Sets the flag if the key has expired to expired .
Definition: kpgpkey.h:737
void setRevoked(const bool revoked)
Sets the flag if the key has been revoked to revoked .
Definition: kpgpkey.h:732
Definition: kpgpkey.h:48
Definition: kpgpkey.h:36
Definition: kpgpkey.h:47
Definition: kpgpkey.h:34
Definition: kpgpkey.h:49
QStringList toStringList() const
Converts from a KeyIDList to a QStringList.
Definition: kpgpkey.cpp:30
Subkey(const KeyID &keyID, const bool secret=false)
Constructs a new subkey with the given key ID.
Definition: kpgpkey.cpp:65
void setCanEncrypt(const bool canEncrypt)
Sets the flag if the subkey can be used to encrypt data to canEncrypt .
Definition: kpgpkey.h:456
void setCanSign(const bool canSign)
Sets the flag if the key can be used to sign data to canSign .
Definition: kpgpkey.h:757
bool matchesUserID(const QString &str, bool cs=true)
Returns true if the given string matches one of the user IDs.
Definition: kpgpkey.cpp:209
Subkey * getSubkey(const KeyID &keyID)
Returns a pointer to the subkey with the given key ID.
Definition: kpgpkey.cpp:230
void setCreationDate(const time_t creationDate)
Sets the creation date of the subkey to creationDate seconds since Epoch.
Definition: kpgpkey.h:491
void cloneKeyTrust(const Key *key)
Set the validity values for the user ids to the validity values of the given key. ...
Definition: kpgpkey.cpp:168
KeyID primaryKeyID() const
Returns the key ID of the primary key or a null string if there are no subkeys.
Definition: kpgpkey.h:787
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:48 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:48 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.