CryptEnumOIDFunction function (wincrypt.h)
The CryptEnumOIDFunction function enumerates the registered object identifier (OID) functions. OID functions that are enumerated can be screened to include those identified by their encoding type, function name, OID, or any combination of encoding type, function name, and OID. For each OID function that matches the selection criteria, an application-provided callback function, pfnEnumOIDFunc, is called.
Syntax
BOOL CryptEnumOIDFunction(
[in] DWORD dwEncodingType,
[in] LPCSTR pszFuncName,
[in] LPCSTR pszOID,
[in] DWORD dwFlags,
[in] void *pvArg,
[in] PFN_CRYPT_ENUM_OID_FUNC pfnEnumOIDFunc
);
Parameters
[in] dwEncodingType
Specifies the encoding type to match. Setting this parameter to CRYPT_MATCH_ANY_ENCODING_TYPE matches any encoding type. Note that if CRYPT_MATCH_ANY_ENCODING_TYPE is not specified, either a certificate or message encoding type is required. If the low-order word that contains the certificate encoding type is nonzero, it is used; otherwise, the high-order word that contains the message encoding type is used. If both are specified, the certificate encoding type in the low-order word is used.
Currently defined encoding types are:
- CRYPT_ASN_ENCODING
- X509_ASN_ENCODING
- PKCS_7_ASN_ENCODING
- CRYPT_MATCH_ANY_ENCODING_TYPE
[in] pszFuncName
Name of a function for which a case insensitive match search is performed. Setting this parameter to NULL results in a match being found for any function name.
[in] pszOID
If the high-order word of pszOID is nonzero, pszOID specifies the object identifier for which a case insensitive match search is performed. If the high-order word of pszOID is zero, pszOID is used to match a numeric object identifier. Setting this parameter to NULL matches any object identifier. Setting this parameter to CRYPT_DEFAULT_OID restricts the enumeration to only the default functions.
[in] dwFlags
Reserved for future use and must be zero.
[in] pvArg
A pointer to arguments to be passed through to the CRYPT_ENUM_OID_FUNCTION callback function.
[in] pfnEnumOIDFunc
A pointer to the callback function that is executed for each OID function that matches the input parameters. For details, see CRYPT_ENUM_OID_FUNCTION.
Return value
If the function succeeds, the function returns nonzero (TRUE).
If the function fails, it returns zero (FALSE). For extended error information, call GetLastError.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps | UWP apps] |
Minimum supported server | Windows Server 2003 [desktop apps | UWP apps] |
Target Platform | Windows |
Header | wincrypt.h |
Library | Crypt32.lib |
DLL | Crypt32.dll |