#include <CAPITrustRootCRLRepository2.h>
CERT_SYSTEM_STORE_CURRENT_USER "Root"These parameters are passed to the Windows CertOpenStore function upon initialization. Consult Microsoft MSDN documentation for details on various options that may be used to target an alternative certificate store. Typically, this class is not used directly by applications and is primarily intended for as a colleague associated with a cache mediator used by the path builder.
TSP-enforcing: No
Definition at line 38 of file CAPITrustRootCRLRepository2.h.
Public Member Functions | |
CPKIFCAPITrustRootCRLRepository2 (int sysStoRegLoc=CERT_SYSTEM_STORE_CURRENT_USER, const char *store=g_defCACCAPITrustStore) | |
virtual | ~CPKIFCAPITrustRootCRLRepository2 (void) |
void | Initialize (void) |
void | GetCRLs (const CPKIFCertificatePtr &cert, CPKIFCRLList &crlList, PKIInfoSource source=ALL) |
CPKIFCAPITrustRootCRLRepository2::CPKIFCAPITrustRootCRLRepository2 | ( | int | sysStoRegLoc = CERT_SYSTEM_STORE_CURRENT_USER , |
|
const char * | store = g_defCACCAPITrustStore | |||
) |
Interface: External
This function creates and initializes CPKIFCAPITrustRootCRLRepository2 objects. The parameters determine which certificate store is associated with an instance of CPKIFCAPITrustRootCRLRepository2. The default certificate store is the "Root" store associated with the current Windows user. For Windows services using PKIF, the sysStoRegLoc parameter should be set to CERT_SYSTEM_STORE_LOCA_MACHINE and the store parameter can be left to the default value. Consult Microsoft MSDN documentation for details on various options that may be used to target an alternative certificate store.
This function does not attempt to open the certificate store identified by the parameters. An attempt to open the store will be made when the Initialize function is called, which occurs when an instance of CPKIFCAPITrustRootCRLRepository2 is passed to the AddColleague function of a mediator class (presumably the CPKIFCacheMediator2 class).
sysStoRegLoc | [in] An integer indicating which certificate store is associated with an instance of CPKIFCAPITrustRootCRLRepository2. |
store | [in] An NULL terminated string indicating which certificate store is associated with an instance of CPKIFCAPITrustRootCRLRepository2. |
Definition at line 50 of file CAPITrustRootCRLRepository2.cpp.
References LOG_STRING_DEBUG, and TOOLKIT_SR_CAPITRUSTROOTCRLSTORE.
CPKIFCAPITrustRootCRLRepository2::~CPKIFCAPITrustRootCRLRepository2 | ( | void | ) | [virtual] |
Interface: External
This function destroys CPKIFCAPITrustRootCRLRepository2 objects.
Definition at line 80 of file CAPITrustRootCRLRepository2.cpp.
References LOG_STRING_DEBUG, and TOOLKIT_SR_CAPITRUSTROOTCRLSTORE.
void CPKIFCAPITrustRootCRLRepository2::Initialize | ( | void | ) | [virtual] |
Interface: External
This function initializes an instance for use in a collection of IPKIFColleague objects held by a mediator.
CPKIFCacheException(CACHE_CERT_STORE_OPEN_FAILED) |
Reimplemented from IPKIFColleague.
Definition at line 104 of file CAPITrustRootCRLRepository2.cpp.
References CACHE_CERT_STORE_OPEN_FAILED, COMMON_ALREADY_INITIALIZED, LOG_STRING_DEBUG, LOG_STRING_WARN, RAISE_CACHE_EXCEPTION, TOOLKIT_SR_CAPIREPOSITORY, and TOOLKIT_SR_CAPITRUSTROOTCRLSTORE.
void CPKIFCAPITrustRootCRLRepository2::GetCRLs | ( | const CPKIFCertificatePtr & | cert, | |
CPKIFCRLList & | crlList, | |||
PKIInfoSource | source = ALL | |||
) | [virtual] |
Interface: External
This function appends pointers to CRLs that may be applicable to the certificate identified by cert to crlList. This function does not ensure that all CRLs are applicable to the specified certificate. The function simply returns without searching when source is equal to REMOTE. This function will search the certificate store identified by the template parameters. This function may generate an exception containing the following error code CACHE_PARSE_ERROR.
CPKIFCacheException(CACHE_PARSE_ERROR) | ||
CPKIFCacheException(COMMON_NOT_INITIALIZED) | ||
CPKIFCacheException(COMMON_INVALID_INPUT) |
cert | [in] Pointer to a certificate for which revocation status is to be checked |
crlList | [out] Reference to a CRL list to receive CRLs that may be associated with the specified certificate |
source | [in] PKIInfoSource indicating the locations to search for CRLs |
Implements IPKIFCRLRepository.
Definition at line 140 of file CAPITrustRootCRLRepository2.cpp.
References CACHE_PARSE_ERROR, COMMON_INVALID_INPUT, COMMON_NOT_INITIALIZED, LOG_STRING_DEBUG, LOG_STRING_ERROR, LOG_STRING_INFO, RAISE_CACHE_EXCEPTION, PKIFENUMS::REMOTE, and TOOLKIT_SR_CAPITRUSTROOTCRLSTORE.