Compartilhar via


GetUserToken Function

The GetUserToken callback function retrieves the authenticated user impersonation token from IIS.

BOOL WINAPI * GetUserToken(
   PHTTP_FILTER_CONTEXT pfc,
   HANDLE phToken
);

Parameters

  • pfc
    Points to the HTTP_FILTER_CONTEXT Structure that is associated with the current, active HTTP transaction.

  • phToken
    Points to the impersonation token.

Return Values

Returns true if the function was successful; otherwise false. The GetLastError function indicates the reason for failure. The most common reason is as follows:

Return code

Description

ERROR_INVALID_PARAMETER

If pfc, the server context that pfc points to, or phToken is invalid.

Remarks

Header names should include the trailing colon (:). The special values method, URL, and version can be used to retrieve the individual portions of the request line. The special values must not include the trailing colon.

The special values "method", "url", and "version" can be used in SF_NOTIFY_PREPROC_HEADERS or SF_NOTIFY_AUTH_COMPLETE to retrieve the individual portions of the request line. The special value "status" can be used in SF_NOTIFY_SEND_RESPONSE to retrieve the entire response line. The special values must not include the trailing colon and should be lower-case.

Requirements

Client: Requires Windows XP Professional, or Windows 2000 Professional.

Server: Requires Windows Server 2003, or Windows 2000 Server.

Product: IIS

Header: Declared in httpfilt.h.