IOCSPCAConfiguration::KeySpec property

The KeySpec property gets a value that indicates whether the key bound to the configuration is used for encryption or for signing content. The default implementations of IOCSPAdmin and IOCSPCAConfigurationCollection methods set this value.

Possible values are determined by the cryptographic service provider (CSP) in use.

This property is read-only.

Syntax


HRESULT get_KeySpec(
  [out]  ULONG *pVal
);

Property value

A pointer to a value that indicates how the key is used.

Error codes

If the method succeeds, it 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.

If the method returns HRESULT_FROM_WIN32(ERROR_INVALID_STATE), the method failed to initialize a lock on the OCSPCAConfiguration object, or the object is not initialized.

If the method returns HRESULT_FROM_WIN32(ERROR_OBJECT_NOT_FOUND), the KeySpec member of the OCSPCAConfiguration object was not successfully initialized.

If the method returns E_INVALIDARG, the pVal parameter was set to NULL.

Remarks

For the Microsoft Base Cryptographic Provider, the KeySpec property has the value AT_KEYEXCHANGE for exchange keys and the value AT_SIGNATURE for signature keys. The default value is AT_SIGNATURE.

For information about the other Microsoft CSPs, see Cryptographic Service Providers in the CryptoAPI 2.0 documentation.

For information about a non-Microsoft CSP, see the documentation provided with that CSP.

Requirements

Minimum supported client

None supported

Minimum supported server

Windows Server 2008 Datacenter, Windows Server 2008 Enterprise [desktop apps only]

Header

Certadm.h (include Certserv.h)

IDL

Certadm.idl

Library

Certadm.lib

DLL

Certadm.dll

IID

IID_IOCSPCAConfiguration is defined as AEC92B40-3D46-433F-87D1-B84D5C1E790D

See also

IOCSPCAConfiguration

 

 

Community Additions

ADD
Show:
© 2014 Microsoft