NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.3: NDN, CCN, CCNx, content centric networks
API Documentation
ndn::security::v1::IdentityCertificate Class Reference

#include <identity-certificate.hpp>

Inheritance diagram for ndn::security::v1::IdentityCertificate:
Collaboration diagram for ndn::security::v1::IdentityCertificate:

Classes

class  Error
 

Public Member Functions

 IdentityCertificate ()
 The default constructor. More...
 
 IdentityCertificate (const Data &data)
 Create an IdentityCertificate from the content in the data packet. More...
 
 IdentityCertificate (const Block &block)
 Create an IdentityCertificate from a block. More...
 
void wireDecode (const Block &wire)
 
void setName (const Name &name)
 
const NamegetPublicKeyName () const
 
- Public Member Functions inherited from ndn::security::v1::Certificate
 Certificate ()
 The default constructor. More...
 
 Certificate (const Data &data)
 Create a Certificate from the content in the data packet. More...
 
 Certificate (const Block &block)
 Create a Certificate from the a block. More...
 
virtual ~Certificate ()
 
void wireDecode (const Block &wire)
 
void encode ()
 encode certificate info into content More...
 
void addSubjectDescription (const CertificateSubjectDescription &description)
 Add a subject description. More...
 
const SubjectDescriptionListgetSubjectDescriptionList () const
 
SubjectDescriptionListgetSubjectDescriptionList ()
 
void addExtension (const CertificateExtension &extension)
 Add a certificate extension. More...
 
const ExtensionListgetExtensionList () const
 
ExtensionListgetExtensionList ()
 
void setNotBefore (const time::system_clock::TimePoint &notBefore)
 
time::system_clock::TimePointgetNotBefore ()
 
const time::system_clock::TimePointgetNotBefore () const
 
void setNotAfter (const time::system_clock::TimePoint &notAfter)
 
time::system_clock::TimePointgetNotAfter ()
 
const time::system_clock::TimePointgetNotAfter () const
 
void setPublicKeyInfo (const PublicKey &key)
 
PublicKeygetPublicKeyInfo ()
 
const PublicKeygetPublicKeyInfo () const
 
bool isTooEarly ()
 Check if the certificate is valid. More...
 
bool isTooLate ()
 Check if the certificate is valid. More...
 
void printCertificate (std::ostream &os, const std::string &indent="") const
 
- Public Member Functions inherited from ndn::Data
 Data ()
 Create an empty Data object. More...
 
 Data (const Name &name)
 Create a new Data object with the given name. More...
 
 Data (const Block &wire)
 Create a new Data object from wire encoding. More...
 
template<encoding::Tag TAG>
size_t wireEncode (EncodingImpl< TAG > &encoder, bool wantUnsignedPortionOnly=false) const
 Fast encoding or block size estimation. More...
 
const BlockwireEncode () const
 Encode to a wire format. More...
 
const BlockwireEncode (EncodingBuffer &encoder, const Block &signatureValue) const
 Finalize Data packet encoding with the specified SignatureValue. More...
 
void wireDecode (const Block &wire)
 Decode from the wire format. More...
 
bool hasWire () const
 Check if Data is already has wire encoding. More...
 
const NamegetName () const
 Get name of the Data packet. More...
 
DatasetName (const Name &name)
 Set name to a copy of the given Name. More...
 
const NamegetFullName () const
 Get full name of Data packet, including the implicit digest. More...
 
const MetaInfogetMetaInfo () const
 Get MetaInfo block from Data packet. More...
 
DatasetMetaInfo (const MetaInfo &metaInfo)
 Set metaInfo to a copy of the given MetaInfo. More...
 
uint32_t getContentType () const
 
DatasetContentType (uint32_t type)
 
const time::milliseconds & getFreshnessPeriod () const
 
DatasetFreshnessPeriod (const time::milliseconds &freshnessPeriod)
 
const name::ComponentgetFinalBlockId () const
 
DatasetFinalBlockId (const name::Component &finalBlockId)
 
const BlockgetContent () const
 Get content Block. More...
 
DatasetContent (const uint8_t *buffer, size_t bufferSize)
 Set the content from the buffer (buffer will be copied) More...
 
DatasetContent (const Block &block)
 Set the content from the block. More...
 
DatasetContent (const ConstBufferPtr &contentValue)
 Set the content from the pointer to immutable buffer. More...
 
const SignaturegetSignature () const
 
DatasetSignature (const Signature &signature)
 Set the signature to a copy of the given signature. More...
 
DatasetSignatureValue (const Block &value)
 
bool operator== (const Data &other) const
 
bool operator!= (const Data &other) const
 
- Public Member Functions inherited from ndn::TagHost
template<typename T >
shared_ptr< T > getTag () const
 get a tag item More...
 
template<typename T >
void setTag (shared_ptr< T > tag) const
 set a tag item More...
 
template<typename T >
void removeTag () const
 remove tag item More...
 

Static Public Member Functions

static bool isIdentityCertificate (const Certificate &certificate)
 
static Name certificateNameToPublicKeyName (const Name &certificateName)
 Get the public key name from the full certificate name. More...
 

Protected Attributes

Name m_publicKeyName
 
- Protected Attributes inherited from ndn::security::v1::Certificate
SubjectDescriptionList m_subjectDescriptionList
 
time::system_clock::TimePoint m_notBefore
 
time::system_clock::TimePoint m_notAfter
 
PublicKey m_key
 
ExtensionList m_extensionList
 

Additional Inherited Members

- Public Types inherited from ndn::security::v1::Certificate
typedef std::vector< CertificateSubjectDescriptionSubjectDescriptionList
 
typedef std::vector< CertificateExtensionExtensionList
 
- Protected Member Functions inherited from ndn::security::v1::Certificate
void decode ()
 
- Protected Member Functions inherited from ndn::Data
void onChanged ()
 Clear the wire encoding. More...
 

Detailed Description

Definition at line 34 of file identity-certificate.hpp.

Constructor & Destructor Documentation

◆ IdentityCertificate() [1/3]

ndn::security::v1::IdentityCertificate::IdentityCertificate ( )

The default constructor.

Definition at line 36 of file identity-certificate.cpp.

References ndn::Data::setFreshnessPeriod().

Referenced by ndn::security::v1::IdentityCertificate::Error::Error().

◆ IdentityCertificate() [2/3]

ndn::security::v1::IdentityCertificate::IdentityCertificate ( const Data data)
explicit

Create an IdentityCertificate from the content in the data packet.

Parameters
dataThe data packet with the content to decode.

Definition at line 41 of file identity-certificate.cpp.

◆ IdentityCertificate() [3/3]

ndn::security::v1::IdentityCertificate::IdentityCertificate ( const Block block)
explicit

Create an IdentityCertificate from a block.

Parameters
blockThe raw block of the certificate.

Definition at line 47 of file identity-certificate.cpp.

Member Function Documentation

◆ wireDecode()

void ndn::security::v1::IdentityCertificate::wireDecode ( const Block wire)

◆ setName()

◆ getPublicKeyName()

const Name& ndn::security::v1::IdentityCertificate::getPublicKeyName ( ) const
inline

◆ isIdentityCertificate()

bool ndn::security::v1::IdentityCertificate::isIdentityCertificate ( const Certificate certificate)
static

Definition at line 103 of file identity-certificate.cpp.

Referenced by getPublicKeyName().

◆ certificateNameToPublicKeyName()

Member Data Documentation

◆ m_publicKeyName

Name ndn::security::v1::IdentityCertificate::m_publicKeyName
protected

Definition at line 97 of file identity-certificate.hpp.

Referenced by getPublicKeyName(), and setName().


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