29 : m_verifiedCertCache(1_h)
30 , m_unverifiedCertCache(5_min)
38 if (cert !=
nullptr) {
void loadAnchor(const std::string &groupId, Certificate &&cert)
load static trust anchor.
Copyright (c) 2011-2015 Regents of the University of California.
Represents an NDN certificate following the version 2.0 format.
const Certificate * find(const Name &certPrefix) const
Get certificate given key name.
void insert(const std::string &groupId, Certificate &&cert)
Insert a static trust anchor.
void cacheUnverifiedCert(Certificate &&cert)
Cache unverified certificate for a period of time (5 minutes)
void clear()
Remove all certificates from cache.
Represents an Interest packet.
CertificateCache m_unverifiedCertCache
bool isCertKnown(const Name &certPrefix) const
Check if certificate exists in verified, unverified cache, or in the set of trust anchors...
const Certificate * findTrustedCert(const Interest &interestForCert) const
Find a trusted certificate in trust anchor container or in verified cache.
Represents a container for verified certificates.
const CertificateCache & getVerifiedCertCache() const
represents a container for trust anchors.
void resetVerifiedCerts()
Remove any cached verified certificates.
const CertificateCache & getUnverifiedCertCache() const
const Certificate * find(const Name &keyName) const
Search for certificate across all groups (longest prefix match)
void cacheVerifiedCert(Certificate &&cert)
Cache verified certificate a period of time (1 hour)
void resetAnchors()
remove any previously loaded static or dynamic trust anchor
Represents an absolute name.
CertificateCache m_verifiedCertCache
TrustAnchorContainer m_trustAnchors
void insert(const Certificate &cert)
Insert certificate into cache.
void clear()
Remove all static or dynamic anchors.
const TrustAnchorContainer & getTrustAnchors() const
boost::chrono::nanoseconds nanoseconds