NCryptEnumStorageProviders function (ncrypt.h)
The NCryptEnumStorageProviders function obtains the names of the registered key storage providers.
Syntax
SECURITY_STATUS NCryptEnumStorageProviders(
[out] DWORD *pdwProviderCount,
[out] NCryptProviderName **ppProviderList,
[in] DWORD dwFlags
);
Parameters
[out] pdwProviderCount
The address of a DWORD to receive the number of elements in the ppProviderList array.
[out] ppProviderList
The address of an NCryptProviderName structure pointer to receive an array of the registered key storage provider names. The variable pointed to by the pdwProviderCount parameter receives the number of elements in this array.
When this memory is no longer needed, free it by passing this pointer to the NCryptFreeBuffer function.
[in] dwFlags
Flags that modify function behavior. This can be zero (0) or the following value.
Return value
Returns a status code that indicates the success or failure of the function.
Possible return codes include, but are not limited to, the following.
Return code | Description |
---|---|
|
The function was successful. |
|
The dwFlags parameter contains a value that is not valid. |
|
One or more parameters are not valid. |
|
A memory allocation failure occurred. |
Remarks
A service must not call this function from its StartService Function. If a service calls this function from its StartService function, a deadlock can occur, and the service may stop responding.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows Vista [desktop apps only] |
Minimum supported server | Windows Server 2008 [desktop apps only] |
Target Platform | Windows |
Header | ncrypt.h |
Library | Ncrypt.lib |
DLL | Ncrypt.dll |