Export (0) Print
Expand All

ICertificateEnrollmentPolicyServerSetup::SetProperty method

The SetProperty method specifies a CEPSetupProperty enumeration value for the Certificate Enrollment Policy (CEP) Web Service configuration.

Syntax


HRESULT SetProperty(
  [in]  CEPSetupProperty propertyId,
  [in]  VARIANT *pPropertyValue
);

Parameters

propertyId [in]

A value of the CEPSetupProperty enumeration that specifies the property value to set. The following values are valid.

ValueDescription
ENUM_CEPSETUPPROP_AUTHENTICATION

The pPropertyValue parameter contains a value that identifies the type of authentication to be used.

ENUM_CEPSETUPPROP_SSLCERTHASH

The pPropertyValue parameter contains a hash of the certificate, if any, used during authentication. ENUM_CEPSETUPPROP_AUTHENTICATION must be set to X509AuthCertificate.

ENUM_CEPSETUPPROP_KEYBASED_RENEWAL

The pPropertyValue parameter specifies whether to set up the Enrollment Policy Server in a mode that returns policies for KeyBasedRenewal templates only.

ENUM_CEPSETUPPROP_URL

You cannot specify this value.

 

pPropertyValue [in]

A pointer to a VARIANT variable that contains the property value.

If you specify ENUM_CEPSETUPPROP_AUTHENTICATION in the propertyId parameter, the VARIANT subtype must be VT_I2, VT_I4 or VT_UII4, and the pPropertyValue argument must be one of the following constants:

  • X509AuthKerberos
  • X509AuthUsername
  • X509AuthCertificate

If you specify ENUM_CEPSETUPPROP_SSLCERTHASH in the propertyId parameter, you must set the pPropertyValue parameter to a VT_BSTR subtype that contains a hash of the certificate used for authentication.

If you specify ENUM_CEPSETUPPROP_AUTHENTICATION in the propertyId parameter, the pPropertyValue parameter contains the authentication procedure.

If you specify ENUM_CEPSETUPPROP_URL in the propertyId parameter, the pPropertyValue parameter contains the Certificate Enrollment Policy (CEP) Web Service URL.

If you specify ENUM_CEPSETUPPROP_KEYBASED_RENEWAL in the propertyId parameter, you must set the pPropertyValue parameter to the VT_BOOL subtype that indicates whether to set up the Enrollment Policy Server in a mode that returns policies for KeyBasedRenewal templates only.

Return value

Return codeDescription
E_INVALIDARG

The propertyId argument is not a member of the CEPSetupProperty enumeration type or you have tried to set the ENUM_CEPSETUPPROP_URL value.

E_POINTER

The pPropertyValue parameter cannot be NULL.

HRESULT_FROM_WIN32(ERROR_INVALID_STATE)

The ICertificateEnrollmentPolicyServerSetup object has not been initialized.

The ErrorString property value is set to "The setup object has not been initialized. Please initialize the setup object with the InitializeInstallDefaults method."

HRESULT_FROM_WIN32(ERROR_CLUSTER_PROPERTY_DATA_TYPE_MISMATCH)

If you are setting the ENUM_CEPSETUPPROP_AUTHENTICATION property, the VARIANT subtype must be VT_I2, VT_I4, or VT_UI4.

 

Remarks

You must call InitializeInstallDefaults before calling the SetProperty method.

Requirements

Minimum supported client

Windows 7 [desktop apps only]

Minimum supported server

Windows Server 2008 R2 [desktop apps only]

Header

Casetup.h

IDL

Casetup.idl

DLL

Certocm.dll

IID

IID_ICertificateEnrollmentPolicyServerSetup is defined as 859252CC-238C-4a88-B8FD-A37E7D04E68B

See also

GetProperty
ICertificateEnrollmentPolicyServerSetup
InitializeInstallDefaults

 

 

Community Additions

ADD
Show:
© 2014 Microsoft