Skip to content

fix(blazor): enforce UltimateAuth authorization at route level - #87

Merged
mckaragoz merged 4 commits into
CodeBeamOrg:devfrom
mckaragoz:UAuthAuthorize
Oct 19, 2026
Merged

mckaragoz merged 4 commits into
CodeBeamOrg:devfrom
mckaragoz:UAuthAuthorize

Conversation

@mckaragoz

Copy link
Copy Markdown
Contributor

Summary

  • Add UAuthAuthorizeRouteView to enforce [UAuthAuthorize] on routed Blazor pages without requiring UAuthComponentBase.
  • Preserve ASP.NET Core AuthorizeRouteView behavior and support combined authorization requirements.
  • Prevent unauthorized pages from being instantiated before authorization succeeds.
  • Integrate route authorization with UAuthApp runtime initialization and authentication state changes.
  • Add bUnit tests covering authentication, roles, permissions, route transitions, authorization interoperability, and state lifecycle.

@codecov-commenter

codecov-commenter commented Oct 19, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 83.56164% with 36 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.04%. Comparing base (499ecdd) to head (795f58a).

Files with missing lines Patch % Lines
...lient.Blazor/Components/Base/UAuthComponentBase.cs 74.28% 6 Missing and 3 partials ⚠️
...h.Client.Blazor/Components/UAuthStateView.razor.cs 80.00% 5 Missing and 3 partials ⚠️
...Blazor/Components/UAuthAuthorizeRouteView.razor.cs 90.78% 3 Missing and 4 partials ⚠️
...nt.Blazor/Components/UAuthAuthorizeRouteView.razor 50.00% 2 Missing and 3 partials ⚠️
...timateAuth.Client.Blazor/Components/UAuthApp.razor 0.00% 3 Missing and 1 partial ⚠️
...nt.Blazor/AuthState/UAuthAuthorizationEvaluator.cs 92.30% 1 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev      #87      +/-   ##
==========================================
+ Coverage   85.98%   86.04%   +0.06%     
==========================================
  Files         660      665       +5     
  Lines       18275    18364      +89     
  Branches     2249     2253       +4     
==========================================
+ Hits        15713    15801      +88     
+ Misses       1811     1809       -2     
- Partials      751      754       +3     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mckaragoz
mckaragoz merged commit 035791d into CodeBeamOrg:dev Oct 19, 2026
3 checks passed
@mckaragoz
mckaragoz deleted the UAuthAuthorize branch October 31, 2026 15:42
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.

2 participants