Closed rugved-bodke-stigya closed 1 week ago
That's not an issue.
On the other side, your code is working as expected, I'm going to assume, that when you said that is working with any random string, you're referring to the swagger green button for "Authorize". Remember, that button has no verification after you enter your credentials. If you run your code without putting anything in Authorize beforehand, you're going to see something like:
And that input has the verification of your code to check username and password.
Check this for more info: https://fastapi.tiangolo.com/advanced/security/http-basic-auth/
Privileged issue
Issue Content
Hi I'm struggling to place a basic auth, and using the latest fastapi version but still the app is working with any random string