You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Unauthorized result uses wrong HTTP status code #10
The UnauthorizedResult class is currently mapped to the Unauthorized ASP.NET Core action result, but that is actually incorrect and is the result of an ambiguity in language.
"Unauthorized" in the HTTP sense of the word actually typically means "Unauthenticated" and uses the 401 status code. This status code can cause things like authentication challenges, when that's not what we want if we return an UnauthorizedResult.
Our definition of "Unauthorized" means you are likely authenticated (as authentication is not a concern of this library) but are not allowed to perform the operation. Therefore, the correct status code to return in this case is 403, which is "Forbidden."
Activity
Refactor result extensions with RFC7807 problem details support (#11)
paulirwin commentedon Nov 7, 2025
Fixed by #11