This support function allows your ISAPI extension to retrieve context and credential handles to the CtxtHandle and CredHandle structures, as defined in the header file sspi.h. Once these handles are retrieved, they can be used to query or manipulate the server certificate information by using the standard certificate APIs that are also defined in sspi.h.
BOOL ServerSupportFunction(
HCONN ConnID,
DWORD HSE_REQ_GET_SSPI_INFO,
LPVOID lpvBuffer,
LPDWORD lpdwSize,
LPDWORD lpdwDataType
);
You must ensure that lpvBuffer and lpdwDataType point to buffers that are of sufficient size for the two returned structures.
HSE_REQ_GET_SSPI_INFO is not supported if your ISAPI extension is running in a separate process from IIS because context and credential handles are not designed to be valid across process boundaries.