November Happy Hour will be moved to Thursday December 5th.

Class BasicAuthentication

Handle basic authentication logons with EPiServers extranet functionality.

Inheritance
System.Object
BasicAuthentication
Implements
System.Web.IHttpModule
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.Security
Assembly: EPiServer.dll
Version: 9.12.2
Syntax
public class BasicAuthentication : IHttpModule

Constructors

BasicAuthentication()

Declaration
public BasicAuthentication()

Methods

DecodeAuthenticationHeader(String, out String, out String)

Decodes the authentication header for Basic authentication.

Declaration
public static bool DecodeAuthenticationHeader(string authenticationHeader, out string username, out string password)
Parameters
Type Name Description
System.String authenticationHeader

The authentication from the request.

System.String username

The username extracted from the authentication header.

System.String password

The password extracted from the authentication header.

Returns
Type Description
System.Boolean

true if username and password could be retreived from the authentication header; otherwise false

Dispose()

Disposes of the resources (other than memory) used by the module that implements System.Web.IHttpModule.

Declaration
public void Dispose()

Init(HttpApplication)

Initializes a module and prepares it to handle requests.

Declaration
public void Init(HttpApplication application)
Parameters
Type Name Description
System.Web.HttpApplication application

An System.Web.HttpApplication that provides access to the methods, properties, and events common to all application objects within an ASP.NET application

IsAlreadyAuthenticated(IPrincipal)

Determines whether the aupplied principal is authenticated.

Declaration
public static bool IsAlreadyAuthenticated(IPrincipal currentUser)
Parameters
Type Name Description
System.Security.Principal.IPrincipal currentUser

The current user.

Returns
Type Description
System.Boolean

true if the current user is authenticated; otherwise, false.

Implements

System.Web.IHttpModule

Extension Methods