Skip to content

Commit

Permalink
AssignRoleToUsers should not be implied by EditUsers (#16954)
Browse files Browse the repository at this point in the history
---------

Co-authored-by: Mike Alhayek <[email protected]>
  • Loading branch information
hishamco and MikeAlhayek authored Nov 25, 2024
1 parent 299a254 commit 1cd5c1c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public static class CommonPermissions

public static readonly Permission ListUsers = new("ListUsers", "List all users", [EditUsers, DeleteUsers]);

public static readonly Permission AssignRoleToUsers = new("AssignRoleToUsers", "Assign any role to users", [EditUsers], true);
public static readonly Permission AssignRoleToUsers = new("AssignRoleToUsers", "Assign any role to users", true);

public static readonly Permission DisableTwoFactorAuthenticationForUsers = new("DisableTwoFactorAuthenticationForUsers", "Disable two-factor authentication for any user", [ManageUsers], true);

Expand Down
4 changes: 4 additions & 0 deletions src/docs/releases/3.0.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,7 @@ The following obsolete settings were removed from `LoginSettings` class
#### Login View Update

The `ExternalLogin` action has been removed from the `Account` controller. If you are using a custom `Login.cshtml` view or `Login` template, please update the external login form action. As of this update, the `ExternalLogin` action has been relocated to the `ExternalAuthentications` controller.

#### AssignRoleToUsers Permission Update

The `AssignRoleToUsers` permission is no longer implicitly granted by `EditUsers`. To maintain the same behavior, make sure to explicitly assign the `AssignRoleToUsers` permission to any role that already has the `EditUsers` permission.

0 comments on commit 1cd5c1c

Please sign in to comment.