trust-store
0.0.1
Provides a common implementation of a trust store to be used by trusted helpers.
|
The Request struct encapsulates information about a trust request answered by the user. More...
#include <request.h>
Public Types | |
enum | Answer { Answer::denied, Answer::granted } |
Enumerates the possible answers given by a user. More... | |
typedef std::chrono::system_clock::duration | Duration |
Duration in wallclock time. More... | |
typedef std::chrono::system_clock::time_point | Timestamp |
Requests are timestamped with wallclock time. More... | |
Public Attributes | |
std::string | from |
std::uint64_t | feature |
Timestamp | when |
Answer | answer |
Static Public Attributes | |
static constexpr const unsigned int | default_feature = 0 |
Default feature identifier. More... | |
The Request struct encapsulates information about a trust request answered by the user.
A Request is the main entity managed by the trust-store API. Whenever an application tries to access the functionality offered by a trusted helper, the trusted helper checks whether the application has issued a request before. If a query against the trust store returns yes and the user previously granted trust to the application, the application's request to the trusted helpers functionality is granted. If the user previously rejected the request, the app's request is denied. If no previous request can be found, the trusted helper issues a question to the user, collects the answer and transacts the complete request to the store.
typedef std::chrono::system_clock::duration core::trust::Request::Duration |
typedef std::chrono::system_clock::time_point core::trust::Request::Timestamp |
|
strong |
|
static |
std::uint64_t core::trust::Request::feature |
std::string core::trust::Request::from |
Timestamp core::trust::Request::when |