CPKIFFuncStorage Class Reference

#include <PKIFFuncStorage.h>

Inheritance diagram for CPKIFFuncStorage:

Inheritance graph
[legend]
Collaboration diagram for CPKIFFuncStorage:

Collaboration graph
[legend]

List of all members.


Detailed Description

The CPKIFFuncStorage class provides a means for applications to pass a vector of function pointers to the certification path validation logic in PKIF. For each certificate processed during a path validation operation, each function pointer present in the active instance of CPKIFFuncStorage will be invoked. This permits applications to extend the certification path validation engine with application-specific processing, e.g. to permit enforcement of key usage-related certificate extensions or private certificate extensions. The functions passed via CPKIFFuncStorage are not used to override errors. To override path validation errors, see the CPKIFPathSettings::SetOverrideCallback function.

TSP-enforcing: Yes

Definition at line 32 of file PKIFFuncStorage.h.


Public Member Functions

 CPKIFFuncStorage (void(*)(const CPKIFCertificateNodeEntryPtr &, CPKIFPathValidationResults &, CertificateType))
 ~CPKIFFuncStorage ()
void addFuncs (CPKIFFuncStorage &v)
void addFunc (void(*)(const CPKIFCertificateNodeEntryPtr &, CPKIFPathValidationResults &, CertificateType))
void getFuncs (std::vector< void(*)(const CPKIFCertificateNodeEntryPtr &, CPKIFPathValidationResults &, CertificateType)> &vec)
void operator() (const CPKIFCertificateNodeEntryPtr &, CPKIFPathValidationResults &, CertificateType)
bool empty ()

Constructor & Destructor Documentation

CPKIFFuncStorage::CPKIFFuncStorage ( void(*)(const CPKIFCertificateNodeEntryPtr &, CPKIFPathValidationResults &, CertificateType f  ) 

Interface: External

This is a constructor for CPKIFFuncStorage class. It adds the function pointer passed as funcPtr to the list of function pointers managed by the new instance. NULL can be passed to defer specification of a function pointer until later, e.g. via a call to addFunc.

Returns:
None
Parameters:
f  [in] Pointer to a function that will be added to the aggregation of function pointers. May be NULL to create an empty object.

Definition at line 31 of file PKIFFuncStorage.cpp.

CPKIFFuncStorage::~CPKIFFuncStorage (  ) 

Interface: External

Destroys a CPKIFFuncStorage object

Returns:
None

Definition at line 46 of file PKIFFuncStorage.cpp.


Member Function Documentation

void CPKIFFuncStorage::addFuncs ( CPKIFFuncStorage v  ) 

Interface: External

This version of addFuncs accepts a reference to a CPKIFFuncStorage object and appends the list of function pointers available from it to the list maintained internally.

Returns:
None
Parameters:
v  [in] Holds the list of function pointers, which will be added to the storage.

Definition at line 59 of file PKIFFuncStorage.cpp.

References m_impl.

void CPKIFFuncStorage::addFunc ( void(*)(const CPKIFCertificateNodeEntryPtr &, CPKIFPathValidationResults &, CertificateType f  ) 

Interface: External

This function accepts a pointer to a function and adds it to the list of function pointers stored internally. The functions managed by an instance of CPKIFFuncStorage will be invoked in the order they were added (beginning with the parameter to the constructor, if non-NULL) during path validation. The following sample code demonstrates typical usage of this function:

Returns:
None
Parameters:
f  [in] Pointer to an application-specified function that will be added to the list of function pointers managed by the object.

Definition at line 89 of file PKIFFuncStorage.cpp.

void CPKIFFuncStorage::getFuncs ( std::vector< void(*)(const CPKIFCertificateNodeEntryPtr &, CPKIFPathValidationResults &, CertificateType)> &  vec  ) 

Interface: External

This function returns the list of functions stored in CPKIFFuncStorage object.

Returns:
None
Parameters:
vec  [out] All the function pointers that are stored will be added to this vector.

Definition at line 72 of file PKIFFuncStorage.cpp.

void CPKIFFuncStorage::operator() ( const CPKIFCertificateNodeEntryPtr p,
CPKIFPathValidationResults r,
CertificateType  t 
)

Interface: External

This function operator is invoked by the certification path validation functionality. It iterates over each function pointer specified by the application and invokes each passing the parameters provided by the validation engine. Application functions should throw an exception if path validation should not continue.

Returns:
None
Parameters:
p  [in] The certificate node currently being processed by the validation engine
r  [in] The in-progress path validation results object
t  [in] An enumerated value indicating the function of the certificate in the current path, e.g. EE or INTERMEDIATE

Definition at line 105 of file PKIFFuncStorage.cpp.

bool CPKIFFuncStorage::empty (  ) 

Interface: External

Boolean value which is set to true if the storage is empty and false if not.

Returns:
True if storage is empty

Definition at line 130 of file PKIFFuncStorage.cpp.

Referenced by CPKIFPathBasicChecks2::DoChecks().


The documentation for this class was generated from the following files:

Generated on Mon Nov 15 11:20:18 2010 for PublicKeyInfrastructureFramework(PKIF) by  doxygen 1.5.6