27 #include "pib-identity-container.hpp"
30 class TestKeyChain_Management_Test;
60 class Error :
public std::runtime_error
63 Error(
const std::string& what)
64 : std::runtime_error(what)
104 ptr_lib::shared_ptr<PibIdentity>
112 ptr_lib::shared_ptr<PibIdentity>&
125 friend TestKeyChain_Management_Test;
133 Pib(
const std::string& scheme,
const std::string& location,
134 const ptr_lib::shared_ptr<PibImpl>& pibImpl);
148 ptr_lib::shared_ptr<PibIdentity>
149 addIdentity(
const Name& identityName);
158 removeIdentity(
const Name& identityName);
166 ptr_lib::shared_ptr<PibIdentity>
167 setDefaultIdentity(
const Name& identityName);
171 Pib& operator=(
const Pib& other);
174 std::string location_;
176 ptr_lib::shared_ptr<PibIdentity> defaultIdentity_;
180 ptr_lib::shared_ptr<PibImpl> pibImpl_;
ptr_lib::shared_ptr< PibIdentity > getIdentity(const Name &identityName)
Get the identity with name identityName.
Definition: pib.cpp:101
void getAllIdentityNames(std::vector< Name > &nameList)
Append all the identity names to the nameList.
Definition: pib.cpp:122
std::string getTpmLocator()
Get the TPM Locator.
Definition: pib.cpp:52
A PibIdentityContainer is used to search/enumerate the identities in a PIB.
Definition: pib-identity-container.hpp:44
KeyChain is the main class of the security library.
Definition: key-chain.hpp:53
std::string getScheme() const
Get the scheme of the PIB locator.
Definition: pib.hpp:74
A Name holds an array of Name::Component and represents an NDN name.
Definition: name.hpp:40
void setTpmLocator(const std::string &tpmLocator)
Set the corresponding TPM information to tpmLocator.
Definition: pib.cpp:42
std::string getPibLocator() const
Get the PIB locator.
Definition: pib.hpp:81
ptr_lib::shared_ptr< PibIdentity > & getDefaultIdentity()
Get the default identity.
Definition: pib.cpp:109
A Pib::Error extends runtime_error and represents a semantic error in PIB processing.
Definition: pib.hpp:60
In general, a PIB (Public Information Base) stores the public portion of a user's cryptography keys...
Definition: pib.hpp:54