ICertManageModule::Configure method (certmod.h)

The Configure method displays the module user interface.


HRESULT Configure(
  [in] const BSTR strConfig,
  [in] BSTR       strStorageLocation,
  [in] LONG       Flags


[in] strConfig

Represents the configuration string for the Certificate Services server in the form COMPUTERNAME\CANAME, where COMPUTERNAME is the Certificate Services server's network name, and CANAME is the common name of the certification authority (CA) as entered for the CA during Certificate Services setup. For information about the configuration string name, see ICertConfig.

[in] strStorageLocation

A location that provides storage for the property values, as described in the definition of strStorageLocation in ICertManageModule::GetProperty.

[in] Flags

A value used to determine whether the configuration interface is to be presented to the user. If this value is zero, the user will be presented with an interface for configuring the module. If this value is CMM_REFRESHONLY, Certificate Services will not display the user interface, but the latest changes to the configuration of the module will be in effect when future certificate requests are processed (this allows changes to be incorporated without requiring a response to a user interface).

Return value


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.


The Configure method displays the module user interface (if one exists), which allows the user to view and change the module's configurable items. A module that implements ICertManageModule can have its Configure method called when the Certificate Services Manager Policy or Exit Module property page is active and the user chooses the Configure button. The Certificate Services Manager will pass the location referenced by strStorageLocation to this module, and the implementation of this method can then use this location as needed. Note that it is possible that a module may not have configurable items (hence, a user interface would not be necessary), but it would still be necessary to implement this method. The example below does not allow a user to make a configuration change, but it does implement this method.


#include <windows.h>
#include <Certmod.h>

HRESULT CCertManagePolicyModule::Configure( 
            /* [in] */ const BSTR strConfig,
            /* [in] */ BSTR strStorageLocation,
            /* [in] */ LONG Flags)
    if ( CMM_REFRESHONLY != Flags )
                   L"This module has no configurable items",

    return S_OK;


Minimum supported client None supported
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header certmod.h (include Certsrv.h)
Library Certidl.lib

See also