zypp::KeyRingReport Struct Reference

Callbacks from signature verification workflow. More...

#include <KeyRing.h>

Inheritance diagram for zypp::KeyRingReport:
[legend]

List of all members.

Public Types

enum  KeyTrust { KEY_DONT_TRUST = 0, KEY_TRUST_TEMPORARILY, KEY_TRUST_AND_IMPORT }
 User reply options for the askUserToTrustKey callback. More...

Public Member Functions

virtual KeyTrust askUserToAcceptKey (const PublicKey &key, const KeyContext &keycontext=KeyContext())
 Ask user to trust and/or import the key to trusted keyring.
virtual bool askUserToAcceptUnsignedFile (const std::string &file, const KeyContext &keycontext=KeyContext())
virtual bool askUserToAcceptUnknownKey (const std::string &file, const std::string &id, const KeyContext &keycontext=KeyContext())
 we DONT know the key, only its id, but we have never seen it, the difference with trust key is that if you dont have it, you can't import it later.
virtual bool askUserToAcceptVerificationFailed (const std::string &file, const PublicKey &key, const KeyContext &keycontext=KeyContext())
 The file filedesc is signed but the verification failed.


Detailed Description

Callbacks from signature verification workflow.

Per default all methods answer false. This may be canged by calling KeyRing::setDefaultAccept.

  KeyRing::setDefaultAccept( KeyRing::ACCEPT_UNSIGNED_FILE | KeyRing::ACCEPT_VERIFICATION_FAILED );
See also:
KeyRing

Definition at line 44 of file KeyRing.h.


Member Enumeration Documentation

User reply options for the askUserToTrustKey callback.

Parameters:
filedes Name of the file (repo alias) or filename if not available
Enumerator:
KEY_DONT_TRUST  User has chosen not to trust the key.
KEY_TRUST_TEMPORARILY  This basically means, we knew the key, but it was not trusted.

User has chosen to continue, but not import the key.

KEY_TRUST_AND_IMPORT  Import the key.

This means saving the key in the trusted database so next run it will appear as trusted. Nothing to do with KEY_TRUST_TEMPORARILY, as you CAN trust a key without importing it, basically you will be asked every time again. There are programs who prefer to manage the trust keyring on their own and use trustKey without importing it into rpm.

Definition at line 51 of file KeyRing.h.


Member Function Documentation

KeyRingReport::KeyTrust zypp::KeyRingReport::askUserToAcceptKey ( const PublicKey key,
const KeyContext keycontext = KeyContext() 
) [virtual]

Ask user to trust and/or import the key to trusted keyring.

See also:
KeyTrust

Definition at line 66 of file KeyRing.cc.

References KEY_DONT_TRUST, KEY_TRUST_AND_IMPORT, KEY_TRUST_TEMPORARILY, zypp::KeyRing::TRUST_AND_IMPORT_KEY, and zypp::KeyRing::TRUST_KEY_TEMPORARILY.

virtual bool zypp::KeyRingReport::askUserToAcceptUnsignedFile ( const std::string &  file,
const KeyContext keycontext = KeyContext() 
) [virtual]

virtual bool zypp::KeyRingReport::askUserToAcceptUnknownKey ( const std::string &  file,
const std::string &  id,
const KeyContext keycontext = KeyContext() 
) [virtual]

we DONT know the key, only its id, but we have never seen it, the difference with trust key is that if you dont have it, you can't import it later.

The answer means continue yes or no?

virtual bool zypp::KeyRingReport::askUserToAcceptVerificationFailed ( const std::string &  file,
const PublicKey key,
const KeyContext keycontext = KeyContext() 
) [virtual]

The file filedesc is signed but the verification failed.

Parameters:
filedesc Filename or its description.


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

doxygen