Name
WindowsImpersonationContext
Synopsis
public class WindowsImpersonationContext { // Public Instance Methods public void Undo( ); // Protected Instance Methods protected override void Finalize( ); // overrides object }
The WindowsImpersonationContext
class represents
the active Windows user prior to code impersonating another Windows
user through a call to the WindowsIdentity.Impersonate(
)
method. The WindowsIdentity.Impersonate(
)
method returns a
WindowsImpersonationContext
object. By calling the
Undo( )
method of this object, the thread access
token reverts to the one contained in the
WindowsImpersonationContext
object.
Returned By
WindowsIdentity.Impersonate( )
Get Programming .NET Security now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.