Hexasoft.BasicAuthentication

Basic Authentication for WebApi projects deployed as Azure Web Apps behind an API Management


Keywords
hexasoft, module, httpmodule, azure, basic, authentication
License
MIT
Install
Install-Package Hexasoft.BasicAuthentication -Version 1.0.0

Documentation

Hexasoft.BasicAuthentication

Hexasoft.BasicAuthentication is a Http Module that adds Basic Authentication to your ASP.NET web application. Ideal for securing WebApi projects deployed as Azure Web Apps behind an Azure API Management.

See: http://stackoverflow.com/questions/33975280/simplest-way-to-add-basic-authentication-to-web-config-with-user-pass

Inspired by Devbridge.BasicAuthentication.

Download

Hexasoft.BasicAuthentication is available as a NuGet package at https://www.nuget.org/packages/Hexasoft.BasicAuthentication

Usage

After installing the package you will see 3 new settings in the appSettings section of your Web.config:

<add key="BasicAuthentication.Required" value="true" />
<add key="BasicAuthentication.Username" value="testuser" />
<add key="BasicAuthentication.Password" value="testpass" />

Use the BasicAuthentication.Required to quickly turn the authentication on or off while the username/password settings are self explanatory. Username is case-insensitive, password is case-sensitive.

As this module was meant to secure WebApi's behind an Azure API Management, it only supports one username/password combination. No support for multiple users,

Version history

  • 1.0.0 Initial public release