Let’s explore the new .NET 7 features for improving and simplifying authentication and authorization support in .NET applications.
Read more…
Brought to you by @andrea.chiarelli
Let’s explore the new .NET 7 features for improving and simplifying authentication and authorization support in .NET applications.
Read more…
Brought to you by @andrea.chiarelli
I don’t see the top level Authentication object on the WebApplicationBuilder in .Net 7. Are you sure this made it in the final .net 7 release?
Hey @HWouters,
You are right. The code snippet used the Authentication
object that was present in one of the previews but was removed in the final release of .NET.
I updated the code with the correct statement.
Sorry for the inconvenience and thank you for reporting it!
Notice that now you don’t need anymore to call
UseAuthentication()
andUseAuthorization()
.
You definitely still need UseAuthorization() if you still want problem details.
Hi @davidhenley,
Thank you for pointing out this. Actually, you need UseAuthorization()
when you need to customize the default behavior of the authorization middleware. I should have specified this more clearly
This post is 404 or am I missing something?
I just tested it and it works. Here’s the link: What's New in .NET 7 for Authentication and Authorization