ndn::security::v2::validator_config::HyperRelationChecker Class Reference

#include <checker.hpp>

+ Inheritance diagram for ndn::security::v2::validator_config::HyperRelationChecker:
+ Collaboration diagram for ndn::security::v2::validator_config::HyperRelationChecker:

Public Member Functions

 HyperRelationChecker (const std::string &pktNameExpr, const std::string pktNameExpand, const std::string &klNameExpr, const std::string klNameExpand, const NameRelation &hyperRelation)
 
bool check (uint32_t pktType, const Name &pktName, const Name &klName, const shared_ptr< ValidationState > &state)
 Check if packet name ane KeyLocator satisfy the checker's conditions. More...
 

Static Public Member Functions

static unique_ptr< Checkercreate (const ConfigSection &configSection, const std::string &configFilename)
 create a checker from configuration section More...
 

Protected Member Functions

bool checkNames (const Name &pktName, const Name &klName, const shared_ptr< ValidationState > &state) override
 

Detailed Description

Definition at line 114 of file checker.hpp.

Constructor & Destructor Documentation

ndn::security::v2::validator_config::HyperRelationChecker::HyperRelationChecker ( const std::string &  pktNameExpr,
const std::string  pktNameExpand,
const std::string &  klNameExpr,
const std::string  klNameExpand,
const NameRelation hyperRelation 
)

Definition at line 94 of file checker.cpp.

Member Function Documentation

bool ndn::security::v2::validator_config::Checker::check ( uint32_t  pktType,
const Name pktName,
const Name klName,
const shared_ptr< ValidationState > &  state 
)
inherited

Check if packet name ane KeyLocator satisfy the checker's conditions.

Parameters
pktTypetlv::Interest or tlv::Data
pktNamepacket's name
klNameKeyLocator's name
stateValidation state
Return values
falsedata is immediately invalid. Will call state::fail() with proper code and message.
truefurther signature verification is needed.

Definition at line 38 of file checker.cpp.

bool ndn::security::v2::validator_config::HyperRelationChecker::checkNames ( const Name pktName,
const Name klName,
const shared_ptr< ValidationState > &  state 
)
overrideprotectedvirtual

Implements ndn::security::v2::validator_config::Checker.

Definition at line 104 of file checker.cpp.

unique_ptr< Checker > ndn::security::v2::validator_config::Checker::create ( const ConfigSection configSection,
const std::string &  configFilename 
)
staticinherited

create a checker from configuration section

Parameters
configSectionThe section containing the definition of checker.
configFilenameThe configuration file name.
Returns
a checker created from configuration

Definition at line 126 of file checker.cpp.