Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add RoleType and HasFullAccess to IRole #16781

Open
wants to merge 12 commits into
base: main
Choose a base branch
from
Open

Conversation

MikeAlhayek
Copy link
Member

@MikeAlhayek MikeAlhayek commented Sep 22, 2024

Fix #11920

A role now has a way to specify HasFullAccess instead of having to manually select all permissions. On the UI, when HasFullAccess is checked, all permissions will be hidden.

Additionally, a new RoleType was added to distinguish between Standard and System roles. On the UI, System roles cannot be removed.

Roles Now Include Types and an Option for Full Access to All Permissions

Two new properties have been added to the IRole interface:

  • Type: This property allows defining the role type as either Standard or System. System roles, such as 'Anonymous' and 'Authenticated', are non-removable.

  • HasFullAccess: This property eliminates the need to specify individual permissions. When set to true, the role is granted all permissions by default, which is particularly useful for roles like Administrator.

!!! note
When a user with a role that has HasFullAccess logs in, role-specific claims are excluded from the claims principal.

@MikeAlhayek MikeAlhayek marked this pull request as ready for review September 23, 2024 16:13
@Piedone
Copy link
Member

Piedone commented Sep 23, 2024

See #16763 (comment).

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.

Add IsSystem prorperty to IRole interface to allow identifing the system roles easily.
2 participants