nlsr::security::CertificateStore Class Reference

Store certificates for names. More...

#include <certificate-store.hpp>

Public Member Functions

 CertificateStore (ndn::Face &face, ConfParameter &confParam, Lsdb &lsdb)
 
void afterFetcherSignalEmitted (const ndn::Data &lsaSegment)
 
const ndn::security::Certificate * find (const ndn::Name &name) const
 Find a certificate. More...
 
void insert (const ndn::security::Certificate &certificate)
 
void publishCertFromCache (const ndn::Name &keyName)
 Retrieves the chain of certificates from Validator's cache and store them in Nlsr's own CertificateStore. More...
 

Detailed Description

Store certificates for names.

Stores certificates that this router claims to be authoritative for. That is, this stores only the certificates that we will reply to KEY interests with, e.g. when other routers are verifying data we have sent.

Definition at line 45 of file certificate-store.hpp.

Constructor & Destructor Documentation

◆ CertificateStore()

nlsr::security::CertificateStore::CertificateStore ( ndn::Face &  face,
ConfParameter confParam,
Lsdb lsdb 
)

Definition at line 34 of file certificate-store.cpp.

Member Function Documentation

◆ afterFetcherSignalEmitted()

void nlsr::security::CertificateStore::afterFetcherSignalEmitted ( const ndn::Data &  lsaSegment)

Definition at line 186 of file certificate-store.cpp.

◆ find()

const ndn::security::Certificate * nlsr::security::CertificateStore::find ( const ndn::Name &  name) const

Find a certificate.

Parameters
nameEither key name or certificate name.

Find a certificate that NLSR has. First it checks against the certificates this NLSR claims to be authoritative for, usually something like this specific router's certificate, and then checks the cache of certificates it has already fetched. If none can be found, it will return an null pointer.

Definition at line 58 of file certificate-store.cpp.

◆ insert()

void nlsr::security::CertificateStore::insert ( const ndn::security::Certificate &  certificate)

Definition at line 51 of file certificate-store.cpp.

◆ publishCertFromCache()

void nlsr::security::CertificateStore::publishCertFromCache ( const ndn::Name &  keyName)

Retrieves the chain of certificates from Validator's cache and store them in Nlsr's own CertificateStore.

Parameters
keyNameName of the first key in the certificate chain.

Definition at line 162 of file certificate-store.cpp.