WindowsAuthenticationEventArgs

WindowsAuthenticationEventArgs

System.Web.Security (system.web.dll)sealed class

This class is a custom System.EventArgs that is used in the event handler for the WindowsAuthenticationModule.Authenticate event. It provides three properties: Context, which provides a reference to the current System.Web.HttpContext; User, which will be a null reference and Identity, which will contain the information received from IIS. You can implement a custom authentication scheme and set the User property programmatically to the appropriate user identity. If you don't set it to a non-null value, the WindowsAuthenticationModule creates a System.Security.Principal.WindowsPrincipal object based on the information supplied by IIS and assign it to the System.Web.HttpContext.User property.

The easiest way to set a default identity for impersonation is by using the settings in the web.config file. You should use this event only if you need to implement a custom authentication scheme.

public sealed class WindowsAuthenticationEventArgs : EventArgs { // Public Constructors    public WindowsAuthenticationEventArgs(System.Security.Principal.WindowsIdentity identity,          System.Web.HttpContext context); // Public Instance Properties    public HttpContext Context{get; }    public WindowsIdentity Identity{get; }    public IPrincipal User{set; get; } }

Hierarchy

System.Object System.EventArgs WindowsAuthenticationEventArgs

Passed To

WindowsAuthenticationEventHandler.{BeginInvoke( ), Invoke( )}



ASP. NET in a Nutshell
ASP.NET in a Nutshell, Second Edition
ISBN: 0596005202
EAN: 2147483647
Year: 2003
Pages: 873

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net