|
NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.5: NDN, CCN, CCNx, content centric networks
|
API Documentation
|
Go to the documentation of this file.
22 #ifndef NDN_SECURITY_V2_VALIDATION_STATE_HPP
23 #define NDN_SECURITY_V2_VALIDATION_STATE_HPP
31 #include <unordered_set>
32 #include <boost/logic/tribool.hpp>
113 verifyOriginalPacket(
const Certificate& trustedCert) = 0;
119 bypassValidation() = 0;
136 verifyCertificateChain(
const Certificate& trustedCert);
142 std::unordered_set<Name> m_seenCertificateNames;
150 std::list<v2::Certificate> m_certificateChain;
190 verifyOriginalPacket(
const Certificate& trustedCert)
final;
193 bypassValidation()
final;
239 verifyOriginalPacket(
const Certificate& trustedCert)
final;
242 bypassValidation() final;
254 #endif // NDN_SECURITY_V2_VALIDATION_STATE_HPP
Validation error code and optional detailed error message.
Interface for validating data and interest packets.
Validation state for a data packet.
ndn security v2 Validator
function< void(const Data &data, const ValidationError &error)> DataValidationFailureCallback
Callback to report a failed Data validation.
void fail(const ValidationError &error) final
Call the failure callback.
util::Signal< InterestValidationState, Interest > afterSuccess
boost::logic::tribool m_outcome
function< void(const Interest &interest)> InterestValidationSuccessCallback
Callback to report a successful Interest validation.
void fail(const ValidationError &error) final
Call the failure callback.
~DataValidationState() final
Destructor.
const Interest & getOriginalInterest() const
provides a lightweight signal / event system
Represents an absolute name.
InterestValidationState(const Interest &interest, const InterestValidationSuccessCallback &successCb, const InterestValidationFailureCallback &failureCb)
Create validation state for interest.
The certificate following the certificate format naming convention.
virtual ~ValidationState()
~InterestValidationState() final
Destructor.
function< void(const Interest &interest, const ValidationError &error)> InterestValidationFailureCallback
Callback to report a failed Interest validation.
virtual void fail(const ValidationError &error)=0
Call the failure callback.
void addCertificate(const Certificate &cert)
Add cert to the top of the certificate chain.
Represents an Interest packet.
Base class to store tag information (e.g., inside Interest and Data packets)
ValidationState()
Create validation state.
Represents a Data packet.
function< void(const Data &data)> DataValidationSuccessCallback
Callback to report a successful Data validation.
const Data & getOriginalData() const
boost::logic::tribool getOutcome() const
Validation state for an interest packet.
DataValidationState(const Data &data, const DataValidationSuccessCallback &successCb, const DataValidationFailureCallback &failureCb)
Create validation state for data.
bool hasSeenCertificateName(const Name &certName)
Check if certName has been previously seen and record the supplied name.
Copyright (c) 2011-2015 Regents of the University of California.