summaryrefslogtreecommitdiff
path: root/redfish-core/lib/account_service.hpp
diff options
context:
space:
mode:
authorAppaRao Puli <apparao.puli@linux.intel.com>2019-10-16 12:19:36 +0300
committerAppaRao Puli <apparao.puli@linux.intel.com>2019-10-22 05:44:48 +0300
commitc80fee55c3663e5ac620a4d11378799c91867b76 (patch)
treed7b54d8b6b5208bd2ee11c703b31f5a479384f6f /redfish-core/lib/account_service.hpp
parent41d1d1833f476766f88cfb624e66eef7906bdf8c (diff)
downloadbmcweb-c80fee55c3663e5ac620a4d11378799c91867b76.tar.xz
Renamed User role name to ReadOnly
As per redfish specification (DSP0266), there are set of predefined privilege roles. In OpenBMC code has "User" as role name instead of "ReadOnly". So corrected the same. Updated Redfish.md accordingly. Spec says: Role Name = "ReadOnly" ▪ AssignedPrivileges = Login, ConfigureSelf Tested: - Role collection shows new role. - GET on /redfish/v1/AccountService/Roles/ReadOnly URI shows correct AssignedPrivileges. - Ran negative test with /redfish/v1/AccountService/Roles/User and observed error(404 - Not Found). - Ran Redfish validator and no new issues observed. Signed-off-by: AppaRao Puli <apparao.puli@linux.intel.com> Change-Id: I7b0132c628fb4950b6ec095269cd1a12e92aea9a
Diffstat (limited to 'redfish-core/lib/account_service.hpp')
-rw-r--r--redfish-core/lib/account_service.hpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/redfish-core/lib/account_service.hpp b/redfish-core/lib/account_service.hpp
index a183f6867b..7f34949fae 100644
--- a/redfish-core/lib/account_service.hpp
+++ b/redfish-core/lib/account_service.hpp
@@ -84,7 +84,7 @@ inline std::string getRoleIdFromPrivilege(std::string_view role)
}
else if (role == "priv-user")
{
- return "User";
+ return "ReadOnly";
}
else if (role == "priv-operator")
{
@@ -102,7 +102,7 @@ inline std::string getPrivilegeFromRoleId(std::string_view role)
{
return "priv-callback";
}
- else if (role == "User")
+ else if (role == "ReadOnly")
{
return "priv-user";
}