SeSinglePrivilegeCheck

BOOLEAN
SeSinglePrivilegeCheck(

LUID PrivilegeValue,
KPROCESSOR_MODE PreviousMode
);

SeSinglePrivilegeCheck checks for the passed privilege value in the context of the current thread.

Parameters

PrivilegeValue

Specifies the value of the privilege being checked.

PreviousMode

Specifies the previous execution mode, one of UserMode or KernelMode.

Return Value

SeSinglePrivilegeCheck returns TRUE if the current subject has the required privilege.

Comments

Network transport drivers call this routine.

If PreviousMode is KernelMode, the privilege check always succeeds. Otherwise, this routine uses the token of the user mode thread to determine whether the current (user-mode) thread has been granted the given privilege.

Callers of SeSinglePrivilegeCheck must be running at IRQL PASSIVE_LEVEL.