microsoft-authentication-library-for-js
microsoft-authentication-library-for-js copied to clipboard
Implement RBAC Guard
Closes #5804
A couple notes:
- This is backported from Angular 19. As such, I've had to replace
MaybeAsync<T>in several places with the actual types it desugars to, which may look odd. - There isn't any way to discover differences between CanActivateFn and CanActivateChildFn at runtime, since the types are identical. When an RBAC guard is used in the context of CanActivateChildFn, it will call canActivate on the existing guard, which may result in misleading log messages.
- I would appreciate extra scrutiny of my tests. The majority were copied from
msal.guard.spec.tsto ensure I was passing through values correctly where appropriate.
@microsoft-github-policy-service agree
Reminder: This PR appears to be stale. If this PR is still a work in progress please mark as draft.