CERT_STORE_PROV_INFO structure (wincrypt.h)
The CERT_STORE_PROV_INFO structure contains information returned by the installed
CertDllOpenStoreProv function when a store is opened by using the
CertOpenStore function.
When opening a store, the CertOpenStore function sets all fields in the CERT_STORE_PROV_INFO structure to zero except cbSize, which is set to the size of CERT_STORE_PROV_INFO. The structure is updated by the CertDllOpenStoreProv installable function. If there are no additional callback functions to be called, then cStoreProvFunc remains zero upon return.
Syntax
typedef struct _CERT_STORE_PROV_INFO {
DWORD cbSize;
DWORD cStoreProvFunc;
void **rgpvStoreProvFunc;
HCERTSTOREPROV hStoreProv;
DWORD dwStoreProvFlags;
HCRYPTOIDFUNCADDR hStoreProvFuncAddr2;
} CERT_STORE_PROV_INFO, *PCERT_STORE_PROV_INFO;
Members
cbSize
Contains the size, in bytes, of this structure.
cStoreProvFunc
Contains the number of elements in the rgpvStoreProvFunc array. This count must include any NULL values that are used in indexes prior to the last callback function implemented. For example, if only one callback function is implemented, but it is at index 2 (CERT_STORE_PROV_WRITE_CERT_FUNC), with NULL for indexes 0 and 1, then the number 3 should be passed for this parameter.
rgpvStoreProvFunc
An array of pointers to the callback functions that are implemented by the provider. This array is indexed by the values given in the following table, and they must be in the order shown. The associated callback function is shown as well. All callback functions that are not implemented must be set to NULL. The array does not have to contain all callback function indexes, it only needs to contain the highest callback function index implemented. For example, if only the CERT_STORE_PROV_WRITE_CERT_FUNC (2) callback function is implemented, the array only needs to contain three elements.
hStoreProv
A 32-bit, application-defined value that is the first parameter passed to all callbacks. An application can specify the contents of this member as desired. Typically, this is a pointer to data that is specific to the application, such as provider state information for each store opened.
dwStoreProvFlags
Contains a set of flags that specify how the provider works. Contains zero or a combination of one or more of the following values.
Value | Meaning |
---|---|
|
The provider stores certificates, certificate revocation lists, and certificate trust lists that are external to the store's cache. |
|
The store was successfully deleted. The CertStoreProvCloseCallback callback is not called. |
|
By default, the provider will persist changes that are made to the store. If this flag is set, the provider does not persist the changes made to the store. |
|
The provider persists contexts to a system store. |
|
The provider persists contexts to a LocalMachine system store. |
hStoreProvFuncAddr2
Contains the handle returned by CryptGetOIDFunctionAddress. CertCloseStore calls CryptFreeOIDFunctionAddress to free a non-null hStoreProvFuncAddr2. This allows the callback to call one other installable function that will be freed when the store is closed.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Header | wincrypt.h |