ndn::security Namespace Reference

Namespaces

 conf
 
 detail
 
 transform
 
 v1
 
 v2
 

Data Structures

class  CertificateCache
 Interface for the cache of validated certificates. More...
 
class  CertificateCacheTtl
 Cache of validated certificates with freshness-based eviction policy. More...
 
class  CertificateContainer
 A handler to search or enumerate certificates of a key. More...
 
class  CFReleaser
 Helper class to wrap CoreFoundation object pointers. More...
 
class  CommandInterestValidator
 a validator for stop-and-wait command Interests More...
 
struct  Factory
 
class  Identity
 represents an identity More...
 
class  IdentityContainer
 A handler to search or enumerate identities in PIB. More...
 
class  Key
 represents a key More...
 
class  KeyChain
 The packet signing interface. More...
 
class  KeyContainer
 A handler to search or enumerate keys of an identity. More...
 
class  Pib
 represents the PIB More...
 
class  PibImpl
 Abstract class of PIB implementation. More...
 
class  PibMemory
 An in-memory implementation of Pib. More...
 
class  PibSqlite3
 Pib backend implementation based on SQLite3 database. More...
 
class  SafeBag
 a secured container for sensitive information(certificate, private key) More...
 
class  SecPublicInfo
 SecPublicInfo is a base class for the storage of public information. More...
 
class  SecPublicInfoSqlite3
 
class  SecTpm
 SecTpm is the base class of the TPM classes. More...
 
class  SecTpmFile
 
class  SecTpmOsx
 
class  SecuredBag
 
class  SigningInfo
 Signing parameters passed to KeyChain. More...
 
class  ValidationRequest
 ValidationRequest contains information related to further validation. More...
 
class  Validator
 provides the interfaces for packet validation. More...
 
class  ValidatorConfig
 
class  ValidatorNull
 
class  ValidatorRegex
 
class  ValidityPeriod
 Abstraction of validity period. More...
 

Typedefs

typedef Factory< KeyChain::PibCreateFuncPibFactory
 
typedef Factory< KeyChain::TpmCreateFuncTpmFactory
 
typedef function< void(const shared_ptr< const Interest > &)> OnInterestValidated
 Callback to report a successful Interest validation. More...
 
typedef function< void(const shared_ptr< const Interest > &, const std::string &)> OnInterestValidationFailed
 Callback to report a failed Interest validation. More...
 
typedef function< void(const shared_ptr< const Data > &)> OnDataValidated
 Callback to report a successful Data validation. More...
 
typedef function< void(const shared_ptr< const Data > &, const std::string &)> OnDataValidationFailed
 Callback to report a failed Data validation. More...
 

Functions

std::ostream & operator<< (std::ostream &os, CommandInterestValidator::ErrorCode error)
 
static void invokeReject (const OnInterestValidationFailed &reject, const Interest &interest, CommandInterestValidator::ErrorCode error)
 
static std::map< std::string, PibFactory > & getPibFactories ()
 
static std::map< std::string, TpmFactory > & getTpmFactories ()
 
static std::tuple< std::string, std::string > parseUri (const std::string &uri)
 
static std::tuple< std::string, std::string > getCanonicalPibLocator (const std::string &pibLocator)
 
static std::tuple< std::string, std::string > getCanonicalTpmLocator (const std::string &tpmLocator)
 
static Name getKeyName (const Name &identity, const name::Component &keyId)
 
template size_t SafeBag::wireEncode< encoding::EncoderTag > (EncodingImpl< encoding::EncoderTag > &encoder) const
 
template size_t SafeBag::wireEncode< encoding::EstimatorTag > (EncodingImpl< encoding::EstimatorTag > &encoder) const
 
static int sqlite3_bind_string (sqlite3_stmt *statement, int index, const string &value, void(*destructor)(void *))
 A utility function to call the normal sqlite3_bind_text where the value and length are value.c_str() and value.size(). More...
 
static string sqlite3_column_string (sqlite3_stmt *statement, int column)
 
SigningInfo signingByIdentity (const Name &identity)
 
SigningInfo signingByKey (const Name &keyName)
 
SigningInfo signingByCertificate (const Name &certName)
 
SigningInfo signingWithSha256 ()
 
std::ostream & operator<< (std::ostream &os, const SigningInfo &si)
 
template size_t ValidityPeriod::wireEncode< encoding::EncoderTag > (EncodingImpl< encoding::EncoderTag > &encoder) const
 
template size_t ValidityPeriod::wireEncode< encoding::EstimatorTag > (EncodingImpl< encoding::EstimatorTag > &encoder) const
 
std::ostream & operator<< (std::ostream &os, const ValidityPeriod &period)
 

Variables

const std::string DEFAULT_PIB_SCHEME = "pib-sqlite3"
 
const std::string DEFAULT_TPM_SCHEME = "tpm-file"
 
 SecPublicInfoSqlite3
 
pib sqlite3
 
 SecTpmFile
 
tpm file
 
static const string INITIALIZATION
 
 WireEncodable< SafeBag >
 
 WireDecodable< SafeBag >
 
static const string INIT_TPM_INFO_TABLE
 
static const string INIT_ID_TABLE
 
static const string INIT_KEY_TABLE
 
static const string INIT_CERT_TABLE
 
static Oid SECP256R1 ("1.2.840.10045.3.1.7")
 
static Oid SECP384R1 ("1.3.132.0.34")
 
 WireEncodable< ValidityPeriod >
 
 WireEncodableWithEncodingBuffer< ValidityPeriod >
 
 WireDecodable< ValidityPeriod >
 
static const size_t ISO_DATETIME_SIZE = 15
 
static const size_t NOT_BEFORE_OFFSET = 0
 
static const size_t NOT_AFTER_OFFSET = 1
 

Typedef Documentation

typedef function<void(const shared_ptr<const Data>&)> ndn::security::OnDataValidated

Callback to report a successful Data validation.

Definition at line 40 of file validation-request.hpp.

typedef function<void(const shared_ptr<const Data>&, const std::string&)> ndn::security::OnDataValidationFailed

Callback to report a failed Data validation.

Definition at line 44 of file validation-request.hpp.

typedef function<void(const shared_ptr<const Interest>&)> ndn::security::OnInterestValidated

Callback to report a successful Interest validation.

Definition at line 33 of file validation-request.hpp.

typedef function<void(const shared_ptr<const Interest>&, const std::string&)> ndn::security::OnInterestValidationFailed

Callback to report a failed Interest validation.

Definition at line 37 of file validation-request.hpp.

Function Documentation

static std::tuple<std::string, std::string> ndn::security::getCanonicalPibLocator ( const std::string &  pibLocator)
inlinestatic

Definition at line 188 of file key-chain.cpp.

static std::tuple<std::string, std::string> ndn::security::getCanonicalTpmLocator ( const std::string &  tpmLocator)
inlinestatic

Definition at line 226 of file key-chain.cpp.

static Name ndn::security::getKeyName ( const Name identity,
const name::Component keyId 
)
static

Definition at line 207 of file pib-sqlite3.cpp.

static std::map<std::string, PibFactory>& ndn::security::getPibFactories ( )
static

Definition at line 88 of file key-chain.cpp.

static std::map<std::string, TpmFactory>& ndn::security::getTpmFactories ( )
static

Definition at line 95 of file key-chain.cpp.

static void ndn::security::invokeReject ( const OnInterestValidationFailed reject,
const Interest interest,
CommandInterestValidator::ErrorCode  error 
)
static

Definition at line 56 of file command-interest-validator.cpp.

std::ostream & ndn::security::operator<< ( std::ostream &  os,
CommandInterestValidator::ErrorCode  error 
)

Definition at line 30 of file command-interest-validator.cpp.

std::ostream & ndn::security::operator<< ( std::ostream &  os,
const SigningInfo si 
)

Definition at line 111 of file signing-info.cpp.

std::ostream & ndn::security::operator<< ( std::ostream &  os,
const ValidityPeriod period 
)

Definition at line 164 of file validity-period.cpp.

static std::tuple<std::string, std::string> ndn::security::parseUri ( const std::string &  uri)
inlinestatic

Definition at line 168 of file key-chain.cpp.

template size_t ndn::security::SafeBag::wireEncode< encoding::EncoderTag > ( EncodingImpl< encoding::EncoderTag > &  encoder) const
template size_t ndn::security::SafeBag::wireEncode< encoding::EstimatorTag > ( EncodingImpl< encoding::EstimatorTag > &  encoder) const
SigningInfo ndn::security::signingByCertificate ( const Name certName)
Returns
a SigningInfo for signing with a certificate

Definition at line 40 of file signing-helpers.cpp.

SigningInfo ndn::security::signingByIdentity ( const Name identity)
Returns
a SigningInfo for signing with an identity

Definition at line 28 of file signing-helpers.cpp.

SigningInfo ndn::security::signingByKey ( const Name keyName)
Returns
a SigningInfo for signing with a key

Definition at line 34 of file signing-helpers.cpp.

SigningInfo ndn::security::signingWithSha256 ( )
Returns
a SigningInfo for signing with Sha256

Definition at line 46 of file signing-helpers.cpp.

static int ndn::security::sqlite3_bind_string ( sqlite3_stmt *  statement,
int  index,
const string &  value,
void(*)(void *)  destructor 
)
static

A utility function to call the normal sqlite3_bind_text where the value and length are value.c_str() and value.size().

Definition at line 98 of file sec-public-info-sqlite3.cpp.

static string ndn::security::sqlite3_column_string ( sqlite3_stmt *  statement,
int  column 
)
static

Definition at line 107 of file sec-public-info-sqlite3.cpp.

template size_t ndn::security::ValidityPeriod::wireEncode< encoding::EncoderTag > ( EncodingImpl< encoding::EncoderTag > &  encoder) const
template size_t ndn::security::ValidityPeriod::wireEncode< encoding::EstimatorTag > ( EncodingImpl< encoding::EstimatorTag > &  encoder) const

Variable Documentation

const std::string ndn::security::DEFAULT_PIB_SCHEME = "pib-sqlite3"

Definition at line 51 of file key-chain.cpp.

const std::string ndn::security::DEFAULT_TPM_SCHEME = "tpm-file"

Definition at line 56 of file key-chain.cpp.

tpm ndn::security::file

Definition at line 70 of file key-chain.cpp.

const string ndn::security::INIT_CERT_TABLE
static
Initial value:
=
"CREATE TABLE IF NOT EXISTS "
" Certificate( "
" cert_name BLOB NOT NULL, "
" cert_issuer BLOB NOT NULL, "
" identity_name BLOB NOT NULL, "
" key_identifier BLOB NOT NULL, "
" not_before TIMESTAMP, "
" not_after TIMESTAMP, "
" certificate_data BLOB NOT NULL, "
" valid_flag INTEGER DEFAULT 1, "
" default_cert INTEGER DEFAULT 0, "
" PRIMARY KEY (cert_name) "
" ); "
"CREATE INDEX cert_index ON Certificate(cert_name); "
"CREATE INDEX subject ON Certificate(identity_name);"

Definition at line 76 of file sec-public-info-sqlite3.cpp.

const string ndn::security::INIT_ID_TABLE
static
Initial value:
=
"CREATE TABLE IF NOT EXISTS "
" Identity( "
" identity_name BLOB NOT NULL, "
" default_identity INTEGER DEFAULT 0, "
" PRIMARY KEY (identity_name) "
" ); "
"CREATE INDEX identity_index ON Identity(identity_name);"

Definition at line 53 of file sec-public-info-sqlite3.cpp.

const string ndn::security::INIT_KEY_TABLE
static
Initial value:
=
"CREATE TABLE IF NOT EXISTS "
" Key( "
" identity_name BLOB NOT NULL, "
" key_identifier BLOB NOT NULL, "
" key_type INTEGER, "
" public_key BLOB, "
" default_key INTEGER DEFAULT 0, "
" active INTEGER DEFAULT 0, "
" PRIMARY KEY (identity_name, key_identifier)"
" ); "
"CREATE INDEX key_index ON Key(identity_name); "

Definition at line 62 of file sec-public-info-sqlite3.cpp.

const string ndn::security::INIT_TPM_INFO_TABLE
static
Initial value:
=
"CREATE TABLE IF NOT EXISTS "
" TpmInfo( "
" tpm_locator BLOB NOT NULL,"
" PRIMARY KEY (tpm_locator) "
" ); "

Definition at line 46 of file sec-public-info-sqlite3.cpp.

const string ndn::security::INITIALIZATION
static

Definition at line 38 of file pib-sqlite3.cpp.

const size_t ndn::security::ISO_DATETIME_SIZE = 15
static

Definition at line 36 of file validity-period.cpp.

const size_t ndn::security::NOT_AFTER_OFFSET = 1
static

Definition at line 38 of file validity-period.cpp.

const size_t ndn::security::NOT_BEFORE_OFFSET = 0
static

Definition at line 37 of file validity-period.cpp.

Oid ndn::security::SECP256R1("1.2.840.10045.3.1.7")
static
Oid ndn::security::SECP384R1("1.3.132.0.34")
static

Definition at line 70 of file key-chain.cpp.

pib ndn::security::sqlite3

Definition at line 64 of file key-chain.cpp.

ndn::security::WireDecodable< SafeBag >

Definition at line 31 of file safe-bag.cpp.

ndn::security::WireDecodable< ValidityPeriod >

Definition at line 32 of file validity-period.cpp.

ndn::security::WireEncodable< SafeBag >

Definition at line 30 of file safe-bag.cpp.

ndn::security::WireEncodable< ValidityPeriod >

Definition at line 30 of file validity-period.cpp.

ndn::security::WireEncodableWithEncodingBuffer< ValidityPeriod >

Definition at line 31 of file validity-period.cpp.