NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.3: NDN, CCN, CCNx, content centric networks
API Documentation
validation-request.hpp
Go to the documentation of this file.
1
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
24
#ifndef NDN_SECURITY_VALIDATION_REQUEST_HPP
25
#define NDN_SECURITY_VALIDATION_REQUEST_HPP
26
27
#include "../interest.hpp"
28
29
namespace
ndn
{
30
namespace
security
{
31
33
typedef
function<void(const shared_ptr<const Interest>&)>
OnInterestValidated
;
34
36
typedef
function<void(const shared_ptr<const Interest>&,
37
const
std::string&)>
OnInterestValidationFailed
;
38
40
typedef
function<void(const shared_ptr<const Data>&)>
OnDataValidated
;
41
43
typedef
function<void(const shared_ptr<const Data>&,
44
const
std::string&)>
OnDataValidationFailed
;
45
55
class
ValidationRequest
56
{
57
public
:
58
ValidationRequest
(
const
Interest
& interest,
59
const
OnDataValidated
& onDataValidated,
60
const
OnDataValidationFailed
& onDataValidationFailed,
61
int
nRetries,
int
nSteps)
62
:
m_interest
(interest)
63
,
m_onDataValidated
(onDataValidated)
64
,
m_onDataValidationFailed
(onDataValidationFailed)
65
,
m_nRetries
(nRetries)
66
,
m_nSteps
(nSteps)
67
{
68
}
69
70
virtual
71
~ValidationRequest
()
72
{
73
}
74
76
Interest
m_interest
;
78
OnDataValidated
m_onDataValidated
;
80
OnDataValidationFailed
m_onDataValidationFailed
;
82
int
m_nRetries
;
84
int
m_nSteps
;
85
};
86
87
}
// namespace security
88
89
using
security::ValidationRequest
;
90
using
security::OnInterestValidated
;
91
using
security::OnInterestValidationFailed
;
92
using
security::OnDataValidated
;
93
using
security::OnDataValidationFailed
;
94
95
}
// namespace ndn
96
97
#endif //NDN_SECURITY_VALIDATION_REQUEST_HPP
ndn::security::OnInterestValidationFailed
function< void(const shared_ptr< const Interest > &, const std::string &)> OnInterestValidationFailed
Callback to report a failed Interest validation.
Definition:
validation-request.hpp:37
ndn
Copyright (c) 2011-2015 Regents of the University of California.
Definition:
ndn-strategy-choice-helper.hpp:34
ndn::security::ValidationRequest::m_interest
Interest m_interest
the Interest for the requested data/certificate.
Definition:
validation-request.hpp:76
ndn::security::ValidationRequest::ValidationRequest
ValidationRequest(const Interest &interest, const OnDataValidated &onDataValidated, const OnDataValidationFailed &onDataValidationFailed, int nRetries, int nSteps)
Definition:
validation-request.hpp:58
ndn::Interest
represents an Interest packet
Definition:
interest.hpp:42
ndn::security::ValidationRequest
ValidationRequest contains information related to further validation.
Definition:
validation-request.hpp:55
ndn::security::ValidationRequest::m_nRetries
int m_nRetries
the number of retries when the interest times out.
Definition:
validation-request.hpp:82
ndn::security::OnDataValidationFailed
function< void(const shared_ptr< const Data > &, const std::string &)> OnDataValidationFailed
Callback to report a failed Data validation.
Definition:
validation-request.hpp:44
ndn::security::OnDataValidated
function< void(const shared_ptr< const Data > &)> OnDataValidated
Callback to report a successful Data validation.
Definition:
validation-request.hpp:40
ndn::security::OnInterestValidated
function< void(const shared_ptr< const Interest > &)> OnInterestValidated
Callback to report a successful Interest validation.
Definition:
validation-request.hpp:33
ndn::security::ValidationRequest::m_nSteps
int m_nSteps
the number of validation steps that have been performed.
Definition:
validation-request.hpp:84
ndn::security::ValidationRequest::m_onDataValidationFailed
OnDataValidationFailed m_onDataValidationFailed
callback when the retrieved certificate cannot be authenticated.
Definition:
validation-request.hpp:80
ndn::security::ValidationRequest::m_onDataValidated
OnDataValidated m_onDataValidated
callback when the retrieved certificate is authenticated.
Definition:
validation-request.hpp:78
ndn::security::ValidationRequest::~ValidationRequest
virtual ~ValidationRequest()
Definition:
validation-request.hpp:71
security
ndnSIM
ndn-cxx
src
security
validation-request.hpp
Generated on Wed Jan 11 2017 18:17:14 for ndnSIM by
1.8.13