Read Only Accounts (#2658)

This commit is contained in:
Joe Milazzo 2024-01-28 09:14:48 -06:00 committed by GitHub
parent 4f5bb57085
commit 9c84e19960
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
17 changed files with 155 additions and 65 deletions

View file

@ -35,7 +35,13 @@ public static class PolicyConstants
/// Used to give a user ability to Login to their account
/// </summary>
public const string LoginRole = "Login";
/// <summary>
/// Restricts the ability to manage their account without an admin
/// </summary>
/// <remarks>This is used explicitly for Demo Server. Not sure why it would be used in another fashion</remarks>
public const string ReadOnlyRole = "Read Only";
public static readonly ImmutableArray<string> ValidRoles =
ImmutableArray.Create(AdminRole, PlebRole, DownloadRole, ChangePasswordRole, BookmarkRole, ChangeRestrictionRole, LoginRole);
ImmutableArray.Create(AdminRole, PlebRole, DownloadRole, ChangePasswordRole, BookmarkRole, ChangeRestrictionRole, LoginRole, ReadOnlyRole);
}