12 #ifndef ZYPP_PUBLICKEY_H 13 #define ZYPP_PUBLICKEY_H 32 struct _gpgme_key_sig;
89 explicit operator bool()
const;
93 std::string id()
const;
102 bool expired()
const;
109 int daysToLive()
const;
146 explicit operator bool()
const;
150 std::string id()
const;
153 std::string name()
const;
156 Date created()
const;
159 Date expires()
const;
162 bool expired()
const;
169 int daysToLive()
const;
172 bool inTrustedRing()
const;
175 bool inKnownRing()
const;
221 explicit operator bool()
const;
225 std::string id()
const;
228 std::string name()
const;
231 std::string fingerprint()
const;
234 std::string algoName()
const;
237 Date created()
const;
240 Date expires()
const;
243 bool expired()
const;
250 int daysToLive()
const;
264 std::string expiresAsString()
const;
267 std::string gpgPubkeyVersion()
const;
270 std::string gpgPubkeyRelease()
const;
273 std::string rpmName ()
const;
277 {
return Edition( gpgPubkeyVersion(), gpgPubkeyRelease() ); }
292 bool hasSubkeys()
const;
303 bool providesKey(
const std::string & id_r )
const;
309 {
return id_r.size() >= 16; }
313 bool hasSignatures()
const;
351 {
return !( lhs == rhs ); }
404 {
return ! ( id().empty() || fingerprint().empty() ); }
406 std::string id()
const;
407 std::string name()
const;
408 std::string fingerprint()
const;
409 std::string algoName()
const;
410 Date created()
const;
411 Date expires()
const;
412 std::string expiresAsString()
const;
413 bool expired()
const;
414 int daysToLive()
const;
415 std::string gpgPubkeyVersion()
const;
416 std::string gpgPubkeyRelease()
const;
418 std::string rpmName ()
const;
427 {
return keyData().
subkeys(); }
446 const std::list<PublicKeyData> & hiddenKeys()
const;
451 bool fileProvidesKey(
const std::string & id_r )
const;
457 bool operator==(
const std::string & sid )
const;
484 #endif // ZYPP_PUBLICKEY_H std::string asString(const Patch::Category &obj)
std::string asString() const
Simple string representation.
static bool isSafeKeyId(const std::string &id_r)
Whether this is a long id (64bit/16byte) or even better a fingerprint.
bool operator!=(const std::string &sid) const
RWCOW_pointer< Impl > _pimpl
PublicSubkeyData implementation.
Edition gpgPubkeyEdition() const
!<
Class representing one GPG Public Keys data.
std::string asString() const
Simple string representation.
Exception thrown when the supplied key is not a valid gpg key.
base::DrunkenBishop AsciiArt
Random art fingerprint visualization type (base::DrunkenBishop).
Iterable< SubkeyIterator > subkeys() const
!<
String related utilities and Regular expression matching.
RWCOW_pointer< Impl > _pimpl
std::string asString() const
Simple string representation.
Edition represents [epoch:]version[-release]
bool hasSubkeys() const
!<
std::ostream & operator<<(std::ostream &str, const PublicKeySignatureData &obj)
bool operator==(const SetRelation::Enum &lhs, const SetCompare &rhs)
Provide a new empty temporary file and delete it when no longer needed.
Iterable< SubkeyIterator > subkeys() const
Iterate any subkeys.
PublicKeySignatureData implementation.
AsciiArt asciiArt() const
!<
std::ostream & operator<<(std::ostream &str, const PublicKeyData &obj)
bool operator!=(const PublicKey &rhs) const
const PublicSubkeyData * SubkeyIterator
RWCOW_pointer< Impl > _pimpl
Pointer to implementation.
Store and operate on date (time_t).
const Arch Arch_armv7hnl Arch_armv7nhl ZYPP_API
bool providesKey(const std::string &id_r) const
!<
BadKeyException()
Ctor taking message.
std::ostream & dumpOn(std::ostream &str, const Capability &obj)
std::ostream & operator<<(std::ostream &str, const PublicSubkeyData &obj)
PublicKey implementation.
~BadKeyException() override
Dtor.
Class representing a GPG Public Keys subkeys.
Class representing one GPG Public Key (PublicKeyData + ASCII armored in a tempfile).
std::ostream & operator<<(std::ostream &str, const PublicKey &obj)
AsciiArt asciiArt() const
Random art fingerprint visualization (base::DrunkenBishop).
Base class for Exception.
static bool isSafeKeyId(const std::string &id_r)
!<
Edition gpgPubkeyEdition() const
Gpg-pubkey Edition built from version and release.
RWCOW_pointer< Impl > _pimpl
BadKeyException(const std::string &msg_r, Pathname keyfile=Pathname())
Ctor taking message.
std::string asString() const
PublicKeyData implementation.
bool operator!=(const PublicKeyData &lhs, const PublicKeyData &rhs)
Easy-to use interface to the ZYPP dependency resolver.
bool providesKey(const std::string &id_r) const
Whether id_r is the id or fingerprint of the primary key or of a subkey.
Class representing a signature on a GPG Public Key.
bool hasSubkeys() const
Whether subkeys is not empty.
Random art fingerprint visualization Visualize fingerprint data on a [17x9] (SSH) or [19x11] (GPG) or...