Class BasicAuthenticationMiddleware
- Assembly
- Cuemon.AspNetCore.Authentication.dll
Provides a HTTP Basic Authentication middleware implementation for ASP.NET Core.
public class BasicAuthenticationMiddleware : ConfigurableMiddleware<BasicAuthenticationOptions>, IConfigurable<BasicAuthenticationOptions>
- Inheritance
-
BasicAuthenticationMiddleware
- Implements
- Inherited Members
Constructors
BasicAuthenticationMiddleware(RequestDelegate, IOptions<BasicAuthenticationOptions>)
Initializes a new instance of the BasicAuthenticationMiddleware class.
public BasicAuthenticationMiddleware(RequestDelegate next, IOptions<BasicAuthenticationOptions> setup)
Parameters
next
RequestDelegateThe delegate of the request pipeline to invoke.
setup
IOptions<BasicAuthenticationOptions>The BasicAuthenticationOptions which need to be configured.
BasicAuthenticationMiddleware(RequestDelegate, Action<BasicAuthenticationOptions>)
Initializes a new instance of the BasicAuthenticationMiddleware class.
public BasicAuthenticationMiddleware(RequestDelegate next, Action<BasicAuthenticationOptions> setup)
Parameters
next
RequestDelegateThe delegate of the request pipeline to invoke.
setup
Action<BasicAuthenticationOptions>The middleware BasicAuthenticationOptions which need to be configured.
Methods
InvokeAsync(HttpContext)
Executes the BasicAuthenticationMiddleware.
public override async Task InvokeAsync(HttpContext context)
Parameters
context
HttpContextThe context of the current request.
Returns
- Task
A task that represents the execution of this middleware.