libzypp 17.35.16
zypp::KeyRing::Impl Struct Reference

KeyRing implementation. More...

#include <zypp/zypp_detail/keyring_p.h>

Public Member Functions

 Impl (const Pathname &baseTmpDir)
 
void importKey (const PublicKey &key, bool trusted=false)
 
void multiKeyImport (const Pathname &keyfile_r, bool trusted_r=false)
 
void deleteKey (const std::string &id, bool trusted)
 
std::string readSignatureKeyId (const Pathname &signature)
 
bool isKeyTrusted (const std::string &id)
 
bool isKeyKnown (const std::string &id)
 
std::list< PublicKeytrustedPublicKeys ()
 
std::list< PublicKeypublicKeys ()
 
const std::list< PublicKeyData > & trustedPublicKeyData ()
 
const std::list< PublicKeyData > & publicKeyData ()
 
void dumpPublicKey (const std::string &id, bool trusted, std::ostream &stream)
 
PublicKey exportPublicKey (const PublicKeyData &keyData)
 
PublicKey exportTrustedPublicKey (const PublicKeyData &keyData)
 
bool verifyFileSignature (const Pathname &file, const Pathname &signature)
 
bool verifyFileTrustedSignature (const Pathname &file, const Pathname &signature)
 
PublicKeyData publicKeyExists (const std::string &id)
 
PublicKeyData trustedPublicKeyExists (const std::string &id)
 
void allowPreload (bool yesno_r)
 
CachedPublicKeyData::Manip keyRingManip (const Pathname &keyring)
 Impl helper providing on demand a KeyManagerCtx to manip a cached keyring.
 
bool verifyFile (const Pathname &file, const Pathname &signature, const Pathname &keyring)
 
void importKey (const Pathname &keyfile, const Pathname &keyring)
 
PublicKey exportKey (const std::string &id, const Pathname &keyring)
 
PublicKey exportKey (const PublicKeyData &keyData, const Pathname &keyring)
 
PublicKey exportKey (const PublicKey &key, const Pathname &keyring)
 
void dumpPublicKey (const std::string &id, const Pathname &keyring, std::ostream &stream)
 
filesystem::TmpFile dumpPublicKeyToTmp (const std::string &id, const Pathname &keyring)
 
void deleteKey (const std::string &id, const Pathname &keyring)
 
std::list< PublicKeypublicKeys (const Pathname &keyring)
 
const std::list< PublicKeyData > & publicKeyData (const Pathname &keyring)
 
PublicKeyData publicKeyExists (const std::string &id, const Pathname &keyring)
 Get PublicKeyData for ID (false if ID is not found).
 
void preloadCachedKeys ()
 Load key files cached on the system into the generalKeyRing.
 
const Pathname generalKeyRing () const
 
const Pathname trustedKeyRing () const
 

Private Attributes

filesystem::TmpDir _trusted_tmp_dir
 
filesystem::TmpDir _general_tmp_dir
 
Pathname _base_dir
 
bool _allowPreload = false
 
CachedPublicKeyData cachedPublicKeyData
 Functor returning the keyrings data (cached).
 

Detailed Description

KeyRing implementation.

Definition at line 94 of file keyring_p.h.

Constructor & Destructor Documentation

◆ Impl()

zypp::KeyRing::Impl::Impl ( const Pathname & baseTmpDir)

Definition at line 212 of file KeyRing.cc.

Member Function Documentation

◆ importKey() [1/2]

void zypp::KeyRing::Impl::importKey ( const PublicKey & key,
bool trusted = false )

Definition at line 220 of file KeyRing.cc.

◆ multiKeyImport()

void zypp::KeyRing::Impl::multiKeyImport ( const Pathname & keyfile_r,
bool trusted_r = false )

Definition at line 242 of file KeyRing.cc.

◆ deleteKey() [1/2]

void zypp::KeyRing::Impl::deleteKey ( const std::string & id,
bool trusted )

Definition at line 247 of file KeyRing.cc.

◆ readSignatureKeyId()

std::string zypp::KeyRing::Impl::readSignatureKeyId ( const Pathname & signature)

Definition at line 417 of file KeyRing.cc.

◆ isKeyTrusted()

bool zypp::KeyRing::Impl::isKeyTrusted ( const std::string & id)
inline

Definition at line 104 of file keyring_p.h.

◆ isKeyKnown()

bool zypp::KeyRing::Impl::isKeyKnown ( const std::string & id)
inline

Definition at line 106 of file keyring_p.h.

◆ trustedPublicKeys()

std::list< PublicKey > zypp::KeyRing::Impl::trustedPublicKeys ( )
inline

Definition at line 109 of file keyring_p.h.

◆ publicKeys() [1/2]

std::list< PublicKey > zypp::KeyRing::Impl::publicKeys ( )
inline

Definition at line 111 of file keyring_p.h.

◆ trustedPublicKeyData()

const std::list< PublicKeyData > & zypp::KeyRing::Impl::trustedPublicKeyData ( )
inline

Definition at line 114 of file keyring_p.h.

◆ publicKeyData() [1/2]

const std::list< PublicKeyData > & zypp::KeyRing::Impl::publicKeyData ( )
inline

Definition at line 116 of file keyring_p.h.

◆ dumpPublicKey() [1/2]

void zypp::KeyRing::Impl::dumpPublicKey ( const std::string & id,
bool trusted,
std::ostream & stream )
inline

Definition at line 119 of file keyring_p.h.

◆ exportPublicKey()

PublicKey zypp::KeyRing::Impl::exportPublicKey ( const PublicKeyData & keyData)
inline

Definition at line 122 of file keyring_p.h.

◆ exportTrustedPublicKey()

PublicKey zypp::KeyRing::Impl::exportTrustedPublicKey ( const PublicKeyData & keyData)
inline

Definition at line 124 of file keyring_p.h.

◆ verifyFileSignature()

bool zypp::KeyRing::Impl::verifyFileSignature ( const Pathname & file,
const Pathname & signature )
inline

Definition at line 127 of file keyring_p.h.

◆ verifyFileTrustedSignature()

bool zypp::KeyRing::Impl::verifyFileTrustedSignature ( const Pathname & file,
const Pathname & signature )
inline

Definition at line 129 of file keyring_p.h.

◆ publicKeyExists() [1/2]

PublicKeyData zypp::KeyRing::Impl::publicKeyExists ( const std::string & id)
inline

Definition at line 132 of file keyring_p.h.

◆ trustedPublicKeyExists()

PublicKeyData zypp::KeyRing::Impl::trustedPublicKeyExists ( const std::string & id)
inline

Definition at line 134 of file keyring_p.h.

◆ allowPreload()

void zypp::KeyRing::Impl::allowPreload ( bool yesno_r)
inline

Definition at line 137 of file keyring_p.h.

◆ keyRingManip()

CachedPublicKeyData::Manip zypp::KeyRing::Impl::keyRingManip ( const Pathname & keyring)
inline

Impl helper providing on demand a KeyManagerCtx to manip a cached keyring.

Definition at line 141 of file keyring_p.h.

◆ verifyFile()

bool zypp::KeyRing::Impl::verifyFile ( const Pathname & file,
const Pathname & signature,
const Pathname & keyring )

Definition at line 433 of file KeyRing.cc.

◆ importKey() [2/2]

void zypp::KeyRing::Impl::importKey ( const Pathname & keyfile,
const Pathname & keyring )

Definition at line 397 of file KeyRing.cc.

◆ exportKey() [1/3]

PublicKey zypp::KeyRing::Impl::exportKey ( const std::string & id,
const Pathname & keyring )

Definition at line 355 of file KeyRing.cc.

◆ exportKey() [2/3]

PublicKey zypp::KeyRing::Impl::exportKey ( const PublicKeyData & keyData,
const Pathname & keyring )

Definition at line 350 of file KeyRing.cc.

◆ exportKey() [3/3]

PublicKey zypp::KeyRing::Impl::exportKey ( const PublicKey & key,
const Pathname & keyring )
inline

Definition at line 149 of file keyring_p.h.

◆ dumpPublicKey() [2/2]

void zypp::KeyRing::Impl::dumpPublicKey ( const std::string & id,
const Pathname & keyring,
std::ostream & stream )

Definition at line 367 of file KeyRing.cc.

◆ dumpPublicKeyToTmp()

filesystem::TmpFile zypp::KeyRing::Impl::dumpPublicKeyToTmp ( const std::string & id,
const Pathname & keyring )

Definition at line 372 of file KeyRing.cc.

◆ deleteKey() [2/2]

void zypp::KeyRing::Impl::deleteKey ( const std::string & id,
const Pathname & keyring )

Definition at line 410 of file KeyRing.cc.

◆ publicKeys() [2/2]

std::list< PublicKey > zypp::KeyRing::Impl::publicKeys ( const Pathname & keyring)

Definition at line 383 of file KeyRing.cc.

◆ publicKeyData() [2/2]

const std::list< PublicKeyData > & zypp::KeyRing::Impl::publicKeyData ( const Pathname & keyring)
inline

Definition at line 158 of file keyring_p.h.

◆ publicKeyExists() [2/2]

PublicKeyData zypp::KeyRing::Impl::publicKeyExists ( const std::string & id,
const Pathname & keyring )

Get PublicKeyData for ID (false if ID is not found).

Definition at line 276 of file KeyRing.cc.

◆ preloadCachedKeys()

void zypp::KeyRing::Impl::preloadCachedKeys ( )

Load key files cached on the system into the generalKeyRing.

Definition at line 296 of file KeyRing.cc.

◆ generalKeyRing()

const Pathname zypp::KeyRing::Impl::generalKeyRing ( ) const
inline

Definition at line 166 of file keyring_p.h.

◆ trustedKeyRing()

const Pathname zypp::KeyRing::Impl::trustedKeyRing ( ) const
inline

Definition at line 168 of file keyring_p.h.

Member Data Documentation

◆ _trusted_tmp_dir

filesystem::TmpDir zypp::KeyRing::Impl::_trusted_tmp_dir
private

Definition at line 173 of file keyring_p.h.

◆ _general_tmp_dir

filesystem::TmpDir zypp::KeyRing::Impl::_general_tmp_dir
private

Definition at line 174 of file keyring_p.h.

◆ _base_dir

Pathname zypp::KeyRing::Impl::_base_dir
private

Definition at line 175 of file keyring_p.h.

◆ _allowPreload

bool zypp::KeyRing::Impl::_allowPreload = false
private

Definition at line 176 of file keyring_p.h.

◆ cachedPublicKeyData

CachedPublicKeyData zypp::KeyRing::Impl::cachedPublicKeyData
private

Functor returning the keyrings data (cached).

const std::list<PublicKeyData> & cachedPublicKeyData( const Pathname & keyring );
CachedPublicKeyData cachedPublicKeyData
Functor returning the keyrings data (cached).
Definition keyring_p.h:183

Definition at line 183 of file keyring_p.h.


The documentation for this struct was generated from the following files: