ICertPolicy::ShutDown method (certpol.h)

The ShutDown method is called by the server engine before the server is terminated.

When ShutDown is called, the policy module should clean up and stop. It is guaranteed that no requests will arrive after ShutDown is called.


HRESULT ShutDown();

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.


When you write custom policy modules, implement this method.


#include <windows.h>
#include <stdio.h>
#include <Certpol.h>

STDMETHODIMP CCertPolicy::ShutDown()
    // Clean up resources used by this process.

    // Display message that this method has been called.
    if ( fDebug )
        printf("Policy module Shutdown was called\n");
    return( S_OK );


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

See also