22 #ifndef NDN_SECURITY_V2_VALIDATION_POLICY_HPP 23 #define NDN_SECURITY_V2_VALIDATION_POLICY_HPP 27 #include "../../data.hpp" 28 #include "../../interest.hpp" 41 const shared_ptr<ValidationState>& state)>;
106 checkPolicy(
const Data& data,
const shared_ptr<ValidationState>& state,
147 checkPolicy(static_cast<const Data&>(certificate), state, continueValidation);
175 #endif // NDN_SECURITY_V2_VALIDATION_POLICY_HPP void setInnerPolicy(unique_ptr< ValidationPolicy > innerPolicy)
Set inner policy.
Copyright (c) 2013-2017 Regents of the University of California.
The certificate following the certificate format naming convention.
virtual ~ValidationPolicy()=default
void setValidator(Validator &validator)
Set validator to which the policy is associated.
bool hasInnerPolicy() const
Check if inner policy is set.
Represents an Interest packet.
ValidationPolicy & getInnerPolicy()
Return the inner policy.
Abstraction that implements validation policy for Data and Interest packets.
unique_ptr< ValidationPolicy > m_innerPolicy
std::function< void(const shared_ptr< CertificateRequest > &certRequest, const shared_ptr< ValidationState > &state)> ValidationContinuation
static Name getKeyLocatorName(const SignatureInfo &si, ValidationState &state)
Represents an absolute name.
virtual void checkPolicy(const Data &data, const shared_ptr< ValidationState > &state, const ValidationContinuation &continueValidation)=0
Check data against the policy.
virtual void checkPolicy(const Certificate &certificate, const shared_ptr< ValidationState > &state, const ValidationContinuation &continueValidation)
Check certificate against the policy.
Represents a Data packet.
#define NDN_CXX_PUBLIC_WITH_TESTS_ELSE_PROTECTED
Interface for validating data and interest packets.