Partager via


CryptGetDefaultOIDFunctionAddress

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

This function loads the DLL containing a default function address. It can also be used to return the address of first or next installed default OID function in an initialized function set and load the DLL containing that function address.

Syntax

BOOL WINAPI CryptGetDefaultOIDFunctionAddress(
  HCRYPTOIDFUNCSET hFuncSet,
  DWORD dwEncodingType,
  LPCWSTR pwszDll,
  DWORD dwFlags,
  void** ppvFuncAddr,
  HCRYPTOIDFUNCADDR* phFuncAddr
);

Parameters

  • dwEncodingType
    [in] Specifies the encoding type to be matched. Currently, only X509_ASN_ENCODING is used; however, additional encoding types may be added in the future.
  • pwszDll
    [in] Optional. Set to NULL.
  • dwFlags
    [in] Reserved for future use and must be set to zero.
  • ppvFuncAddr
    [out] Pointer to the return function's address. If the function fails, a NULL is returned in the ppvFuncAddr parameter.
  • phFuncAddr
    [in, out] On the first call to the function, this parameter must be NULL to acquire the first installed function.

    When this function is successful, this parameter is set to a function handle. The function's handle reference count is incremented.

    After the first call to the function, this parameter is set to the pointer returned by the previous call. This input pointer is always freed within the function through a call to the CryptFreeOIDFunctionAddress function by this function. The call to free the pointer is always made even if the main function returns an error

    A non-NULL phFuncAddr parameter must be freed either through a call to the CryptFreeOIDFunctionAddress function or by being passed back as input to this function or as input to the CryptGetOIDFunctionAddress function.

Return Value

If the function succeeds, the return value is nonzero, or TRUE.

If the function fails, the return value is zero, or FALSE.

Remarks

The desktop operating system supports the flag PKCS_7_ASN_ENCODING, but Windows Embedded CE does not and ignores the flag when it is specified.

Requirements

Header wincrypt.h
Library crypt32.lib
Windows Embedded CE Windows CE 3.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Reference

CryptEnumOIDInfo
CryptFindOIDInfo
CryptFreeOIDFunctionAddress
CryptGetOIDFunctionAddress
CryptInitOIDFunctionSet