Soenneker.Validators.BasicAuth 4.0.205

Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
dotnet add package Soenneker.Validators.BasicAuth --version 4.0.205
                    
NuGet\Install-Package Soenneker.Validators.BasicAuth -Version 4.0.205
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Validators.BasicAuth" Version="4.0.205" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Validators.BasicAuth" Version="4.0.205" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Validators.BasicAuth" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Soenneker.Validators.BasicAuth --version 4.0.205
                    
#r "nuget: Soenneker.Validators.BasicAuth, 4.0.205"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Soenneker.Validators.BasicAuth@4.0.205
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Soenneker.Validators.BasicAuth&version=4.0.205
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Validators.BasicAuth&version=4.0.205
                    
Install as a Cake Tool

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

Soenneker.Validators.BasicAuth

A lightweight validation module for validating HTTP Basic Authentication credentials.

Install

dotnet add package Soenneker.Validators.BasicAuth

Quick start

using Soenneker.Validators.BasicAuth.Registrars;
using Microsoft.Extensions.DependencyInjection;

var services = new ServiceCollection();
var result = services.AddBasicAuthValidatorAsSingleton();

Adds IBasicAuthValidator as a singleton service.

What you get

  • IBasicAuthValidator — A lightweight validation module for validating HTTP Basic Authentication credentials.
  • BasicAuthValidatorRegistrar — A lightweight validation module for validating HTTP Basic Authentication credentials.

API at a glance

API What it does Result / important behavior
IBasicAuthValidator.Validate(httpContext, configuredUsername, configuredPasswordPhc) Strict validator: throws UnauthorizedAccessException on any failure. true if strict validator: throws UnauthorizedAccessException on any failure; otherwise, false.
IBasicAuthValidator.ValidateSafe(httpContext, configuredUsername, configuredPasswordPhc) Validates Basic credentials and returns false instead of throwing when credentials or configuration are invalid. true if the supplied credentials match the configured credentials; otherwise, false.
BasicAuthValidatorRegistrar.AddBasicAuthValidatorAsSingleton(services) Adds IBasicAuthValidator as a singleton service. The same service collection, so additional registrations can be chained.
BasicAuthValidatorRegistrar.AddBasicAuthValidatorAsScoped(services) Adds IBasicAuthValidator as a scoped service. The same service collection, so additional registrations can be chained.
Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Soenneker.Validators.BasicAuth:

Package Downloads
Soenneker.Hangfire.BasicAuthentication

Protects the Hangfire dashboard with PBKDF2-backed HTTP Basic authentication

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
4.0.213 70 9/1/2026
4.0.212 80 8/31/2026
4.0.211 74 8/31/2026
4.0.210 90 8/31/2026
4.0.209 73 8/31/2026
4.0.208 82 8/30/2026
4.0.207 85 8/30/2026
4.0.206 98 8/30/2026
4.0.205 94 8/30/2026
4.0.204 80 8/30/2026
4.0.203 82 8/29/2026
4.0.202 79 8/29/2026
4.0.200 168 8/26/2026
4.0.199 102 8/26/2026
4.0.198 95 8/25/2026
4.0.197 124 8/21/2026
4.0.196 234 8/18/2026
4.0.195 166 8/13/2026
4.0.194 115 8/13/2026
4.0.193 91 8/12/2026
Loading failed

Update dependency Soenneker.Extensions.Configuration to 4.0.866 (#460)