The DeleteSecurityContext function deletes the local data structures associated with the specified security context.
SECURITY_STATUS DeleteSecurityContext(
  PCtxtHandle phContext  // handle of the context to delete
);
 If the function succeeds, the return value is SEC_E_OK.
If the function fails, the return value can be the following error code.
| Value | Meaning | 
|---|---|
| SEC_E_INVALID_HANDLE | The handle passed to the function is invalid. | 
The DeleteSecurityContext function terminates a security context. No further use of the context is permitted.