ICertRequest2::GetIssuedCertificate method (certcli.h)

The GetIssuedCertificate method retrieves a certificate's disposition by specifying either the request ID or the certificate serial number.

This method is effectively the same as calling ICertRequest3::RetrievePending, with the additional capability of specifying a serial number for the certificate in question.

Syntax

HRESULT GetIssuedCertificate(
  [in]          const BSTR strConfig,
  [in]          LONG       RequestId,
  [in]          const BSTR strSerialNumber,
  [out, retval] LONG       *pDisposition
);

Parameters

[in] strConfig

Represents a valid configuration string for the Certificate Services server. The string can be either an HTTPS URL for an enrollment server or in the form ComputerName\CAName, where ComputerName is the network name of the server, and CAName is the common name of the certification authority, as entered during Certificate Services setup. For information about the configuration string name, see ICertConfig.

Windows Server 2008, Windows Vista, Windows Server 2003 and Windows XP:  An HTTPS URL is not supported as an input.

[in] RequestId

A LONG value that represents the certificate request ID in the Certificates Services database. Use –1 for this value if the serial number (passed in as strSerialNumber) is to be used instead of the request ID.

[in] strSerialNumber

A BSTR value that represents the certificate serial number, as issued by the CA. For strSerialNumber to be used, you must specify a value of –1 for RequestId.

[out, retval] pDisposition

A pointer to a LONG value that represents the certificate's disposition. The disposition is one of the following values.

Value Meaning
CR_DISP_DENIED
Request denied.
CR_DISP_ERROR
Request failed.
CR_DISP_INCOMPLETE
Request did not complete.
CR_DISP_ISSUED
Certificate issued.
CR_DISP_ISSUED_OUT_OF_BAND
Certificate issued separately.
CR_DISP_UNDER_SUBMISSION
Request taken under submission.

Return value

C++

If the method succeeds, the method returns S_OK.

If the method fails, it returns an HRESULT value that indicates the error. For a list of common error codes, see Common HRESULT Values.

VB

The return value is a Long that represents the certificate's disposition.

Requirements

   
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header certcli.h (include Certsrv.h)
Library Certidl.lib
DLL Certcli.dll