Skip to content

Revise IAuthorizationRequirementData article details#37347

Open
guardrex wants to merge 4 commits into
mainfrom
guardrex-patch-4
Open

Revise IAuthorizationRequirementData article details#37347
guardrex wants to merge 4 commits into
mainfrom
guardrex-patch-4

Conversation

@guardrex

@guardrex guardrex commented Jul 17, 2026

Copy link
Copy Markdown
Collaborator

Fixes #37340

Updates the Security-node article to clarify that the IAuthorizationRequirementData interface isn't supported in Razor components, hubs, and AuthorizeFilters. I also adjusted the sample app description, specifying it uses a Minimal API endpoint.

Side Note: I see new API coming for .NET 11+, and we'll take care of that later. For now, I'm just trying to get the phrasing of these remarks correct.

I originally created the BWA to only demonstrate use with a Minimal API endpoint ...

... using the same AuthorizationHandler that I found in the original MVC sample.

Is the BWA implementation a sensible demo?

Also, can you take a look at the original MVC sample, which now accompanies the new MVC authz node article?

In the MVC sample ...

Similar question, given that it's demoed with an AuthorizationHandler, which is what I assume makes it work with a controller. I need guidance from you on how to phrase the support remark in the MVC article, unless you just want to stick with what we're placing in the main article.


Internal previews

📄 File 🔗 Preview link
aspnetcore/security/authorization/custom-authorization-policies-with-iauthorizationrequirementdata.md aspnetcore/security/authorization/custom-authorization-policies-with-iauthorizationrequirementdata

Updated the article to clarify that the IAuthorizationRequirementData interface is supported only in Minimal APIs. Adjusted the sample app description to specify the endpoint and the age requirement.
@guardrex
guardrex requested a review from halter73 July 17, 2026 10:57
@guardrex guardrex self-assigned this Jul 17, 2026
guardrex added 3 commits July 17, 2026 09:10
Clarified that IAuthorizationRequirementData isn't supported in Razor components.
Clarified that IAuthorizationRequirementData is not supported for certain authorization attributes, including Razor components and SignalR hub classes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Blazor][Signalr] Add a note about IAuthorizationRequirementData only being supported in Minimal APIs

1 participant