mihirdilip / aspnetcore-authentication-basic Goto Github PK
View Code? Open in Web Editor NEWEasy to use and very light weight Microsoft style Basic Scheme Authentication Implementation for ASP.NET Core.
License: MIT License
Easy to use and very light weight Microsoft style Basic Scheme Authentication Implementation for ASP.NET Core.
License: MIT License
Hello, excuse me, now I want to implement a function, that is, when the browser accesses the interface, the pop-up window to enter the account password, if the input error page will display a custom error message.
First of all, you can use a browser pop-up, OnValidateCredentials, to enter your account or password, but if you enter the wrong password, you'll see this:
First of all, I found that your "OnHandleChallenge" method did what I wanted, which is for the page to return custom information:
I then tried to mimic the OnHandleChallenge method in the "OnValidateCredentials" method, returning an error message when it failed:
After I entered the wrong account password, the effect was not what I thought, he did not return the custom data, but returned the browser error message:
So I'm trying to use, in combination with the "OnHandleChallenge" and "OnValidateCredentials" methods to get what I want. However, I found that when the two are used together, accessing the interface does not trigger a browser pop-up, but directly returns a custom message for the "OnHandleChallenge" method, so is there a way to combine the effects of the two?
In the description it is said that the package can be used fro .Net core, but in details it is said that .NET Framework 4.6.1 is also supported. Please keep the title and content consistent.
Please add an example how to use with .Net framework 4.6.1.
Also fix the phrase โ Always use HTTPS (SSL Certificate) protocol in production when using API Key authentication.โ as this repo is about basic authentication.
expect http digest schemal
Just wanted to say thank you. This is very tidy implementation of the basic implementation that works flawlessly.
The log statement at line 56 breaks the promise to ignore authentication if the endpoint is annotated with [AllowAnonymous]
.
When querying an endpoint annotated with [AllowAnonymous]
, authentication logic should be ignored.
When querying an endpoint annotated with [AllowAnonymous]
, two lines of log output are produced, stating that nothing is going on. (logspam)
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
info: AspNetCore.Authentication.Basic.BasicHandler[0]
No 'Authorization' header found in the request.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.