WdfRequestImpersonate function (wdfrequest.h)

[Applies to UMDF only]

The WdfRequestImpersonate method registers a driver-supplied event callback function that the framework should call for impersonation.

Syntax

NTSTATUS WdfRequestImpersonate(
  [in]           WDFREQUEST                   Request,
  [in]           SECURITY_IMPERSONATION_LEVEL ImpersonationLevel,
  [in]           PFN_WDF_REQUEST_IMPERSONATE  EvtRequestImpersonate,
  [in, optional] PVOID                        Context
);

Parameters

[in] Request

A handle to the framework request object that represents the I/O request that is being completed.

[in] ImpersonationLevel

A SECURITY_IMPERSONATION_LEVEL-typed value that identifies the level of impersonation.

[in] EvtRequestImpersonate

A pointer to the driver's EvtRequestImpersonate event callback function.

[in, optional] Context

A pointer to a buffer that contains context information that is related to the impersonation call. The framework passes this context information in a call to the EvtRequestImpersonate event callback function. This parameter is optional and can be NULL

Return value

If the WdfRequestImpersonate method encounters no errors, it returns STATUS_SUCCESS.

The method might return other NTSTATUS values.

Remarks

The WdfRequestImpersonate method does not return until the EvtRequestImpersonate event callback function completes.

For more information, see Handling Client Impersonation in UMDF Drivers.

Requirements

Requirement Value
Minimum supported client Windows 8.1
Target Platform Universal
Minimum UMDF version 2.0
Header wdfrequest.h (include Wdf.h)
Library WUDFx02000.lib
DLL WUDFx02000.dll
IRQL PASSIVE_LEVEL

See also

EvtRequestImpersonate

IWDFIoRequest::Impersonate