Home
last modified time | relevance | path

Searched refs:userName (Results 1 – 25 of 25) sorted by relevance

/openbmc/phosphor-user-manager/
H A Duser_mgr.cpp182 bool UserMgr::isUserExist(const std::string& userName) in isUserExist() argument
184 if (userName.empty()) in isUserExist()
190 if (usersList.find(userName) == usersList.end()) in isUserExist()
197 void UserMgr::throwForUserDoesNotExist(const std::string& userName) in throwForUserDoesNotExist() argument
199 if (!isUserExist(userName)) in throwForUserDoesNotExist()
201 lg2::error("User '{USERNAME}' does not exist", "USERNAME", userName); in throwForUserDoesNotExist()
220 void UserMgr::throwForUserExists(const std::string& userName) in throwForUserExists() argument
222 if (isUserExist(userName)) in throwForUserExists()
224 lg2::error("User '{USERNAME}' already exists", "USERNAME", userName); in throwForUserExists()
230 const std::string& userName, const std::vector<std::string>& groupNames) in throwForUserNameConstraints() argument
[all …]
H A Duser_mgr.hpp144 * @param[in] userName - Name of the user which has to be created
149 void createUser(std::string userName, std::vector<std::string> groupNames,
155 * @param[in] userName - current name of the user
158 void renameUser(std::string userName, std::string newUserName) override;
163 * @param[in] userName - Name of the user which has to be deleted
165 void deleteUser(std::string userName);
170 * @param[in] userName - user name, for which update is requested
174 void updateGroupsAndPriv(const std::string& userName,
181 * @param[in] userName - user name, for which update is requested
184 void userEnable(const std::string& userName, boo
[all...]
H A Dusers.cpp74 userName(sdbusplus::message::object_path(path).filename()), manager(parent) in Users()
84 manager.getSerializer().erase(userName); in ~Users()
92 manager.deleteUser(userName); in delete_()
105 manager.updateGroupsAndPriv(userName, UsersIface::userGroups(), value); in userPrivilege()
138 manager.updateGroupsAndPriv(userName, value, UsersIface::userPrivilege()); in userGroups()
155 return manager.isUserEnabled(userName); in userEnabled()
173 manager.userEnable(userName, value); in userEnabled()
182 return manager.userLockedForFailedAttempt(userName); in userLockedForFailedAttempt()
197 return manager.userLockedForFailedAttempt(userName, value); in userLockedForFailedAttempt()
206 return manager.userPasswordExpired(userName); in userPasswordExpired()
[all …]
H A Dusers.hpp136 return userName; in getUserName()
150 std::string userName; member in phosphor::user::Users
/openbmc/phosphor-host-ipmid/user_channel/
H A Duser_layer.cpp36 SecureString ipmiUserGetPassword(const std::string& userName) in ipmiUserGetPassword() argument
38 return passwdMgr.getPasswdByUserName(userName); in ipmiUserGetPassword()
41 Cc ipmiClearUserEntryPassword(const std::string& userName) in ipmiClearUserEntryPassword() argument
43 if (passwdMgr.updateUserEntry(userName, "") != 0) in ipmiClearUserEntryPassword()
50 Cc ipmiRenameUserEntryPassword(const std::string& userName, in ipmiRenameUserEntryPassword() argument
53 if (passwdMgr.updateUserEntry(userName, newUserName) != 0) in ipmiRenameUserEntryPassword()
70 uint8_t ipmiUserGetUserId(const std::string& userName) in ipmiUserGetUserId() argument
72 return getUserAccessObject().getUserId(userName); in ipmiUserGetUserId()
75 Cc ipmiUserSetUserName(const uint8_t userId, const char* userName) in ipmiUserSetUserName() argument
77 std::string newUser(userName, 0, ipmiMaxUserName); in ipmiUserSetUserName()
[all …]
H A Duser_mgmt.cpp151 int getUserNameFromPath(const std::string& path, std::string& userName) in getUserService()
154 userName.assign(objPath.filename()); in setDbusProperty()
159 const std::string& userName, const std::string& priv, in setDbusProperty()
165 if (usrAccess.addUserEntry(userName, priv, enabled) == false) in setDbusProperty()
177 reinterpret_cast<char*>(userData->user[usrIndex].userName), 0, in getUserServiceName()
179 if (userName == curName) in getUserServiceName()
188 "USER_NAME", userName, "USER_EVENT", userEvent); in getUserServiceName()
223 static_cast<uint8_t*>(userData->user[usrIndex].userName), in userUpdateHelper()
224 static_cast<uint8_t*>(userData->user[usrIndex].userName) + in userUpdateHelper()
225 sizeof(userData->user[usrIndex].userName), in userUpdateHelper()
201 getUserNameFromPath(const std::string & path,std::string & userName) getUserNameFromPath() argument
209 userUpdateHelper(UserAccess & usrAccess,const UserUpdateEvent & userEvent,const std::string & userName,const std::string & priv,const bool & enabled,const std::string & newUserName) userUpdateHelper() argument
308 std::string userName, priv, newUserName; userUpdatedSignalHandler() local
556 isValidUserName(const std::string & userName) isValidUserName() argument
748 setSpecialUserPassword(const std::string & userName,const SecureString & userPassword) setSpecialUserPassword() argument
761 std::string userName; setUserPassword() local
804 std::string userName; setUserEnabledState() local
901 std::string userName; setUserPrivilegeAccess() local
943 getUserId(const std::string & userName) getUserId() argument
969 getUserName(const uint8_t userId,std::string & userName) getUserName() argument
1001 setUserName(const uint8_t userId,const std::string & userName) setUserName() argument
1253 std::string userName = userInfo[jsonUserName].get<std::string>(); readUserData() local
1428 addUserEntry(const std::string & userName,const std::string & sysPriv,const bool & enabled) addUserEntry() argument
1768 std::string usrPriv, userName; cacheUserDataFile() local
[all...]
H A Duser_layer.hpp93 SecureString ipmiUserGetPassword(const std::string& userName);
102 Cc ipmiClearUserEntryPassword(const std::string& userName);
112 Cc ipmiRenameUserEntryPassword(const std::string& userName,
137 uint8_t ipmiUserGetUserId(const std::string& userName);
142 Cc ipmiUserSetUserName(const uint8_t userId, const char* userName)
152 Cc ipmiUserSetUserName(const uint8_t userId, const std::string& userName);
170 Cc ipmiSetSpecialUserPassword(const std::string& userName,
180 Cc ipmiUserGetUserName(const uint8_t userId, std::string& userName);
243 bool ipmiUserPamAuthenticate(std::string_view userName,
H A Duser_mgmt.hpp73 uint8_t userName[ipmiMaxUserName]; member
168 bool isValidUserName(const std::string& userName);
183 uint8_t getUserId(const std::string& userName);
208 Cc getUserName(const uint8_t userId, std::string& userName);
217 Cc setUserName(const uint8_t userId, const std::string& userName);
244 Cc setSpecialUserPassword(const std::string& userName,
360 bool addUserEntry(const std::string& userName, const std::string& priv,
H A Dpasswd_mgr.hpp50 SecureString getPasswdByUserName(const std::string& userName);
61 int updateUserEntry(const std::string& userName,
102 int updatePasswdSpecialFile(const std::string& userName,
H A Dusercommands.cpp248 std::string userName; in ipmiGetUserName() local
249 if (ipmiUserGetUserName(userId, userName) != ccSuccess) in ipmiGetUserName()
256 if (userName.size() > ipmi::ipmiMaxUserName) in ipmiGetUserName()
262 std::copy(userName.begin(), userName.end(), userNameFixed.begin()); in ipmiGetUserName()
302 std::string userName; in ipmiSetUserPassword() local
303 if (ipmiUserGetUserName(userId, userName) != ccSuccess) in ipmiSetUserPassword()
326 SecureString password = ipmiUserGetPassword(userName); in ipmiSetUserPassword()
H A Dpasswd_mgr.cpp95 SecureString PasswdMgr::getPasswdByUserName(const std::string& userName) in getPasswdByUserName() argument
98 auto iter = passwdMapList.find(userName); in getPasswdByUserName()
106 int PasswdMgr::updateUserEntry(const std::string& userName, in updateUserEntry() argument
115 if (passwdMapList.find(userName) == passwdMapList.end()) in updateUserEntry()
123 if (updatePasswdSpecialFile(userName, newUserName) != 0) in updateUserEntry()
363 int PasswdMgr::updatePasswdSpecialFile(const std::string& userName, in updatePasswdSpecialFile() argument
401 if (userName.compare(lineStr.substr(0, userEPos)) == 0) in updatePasswdSpecialFile()
/openbmc/phosphor-user-manager/test/
H A Dmock_user_mgr.hpp18 MOCK_METHOD1(userLockedForFailedAttempt, bool(const std::string& userName));
19 MOCK_METHOD1(userPasswordExpired, bool(const std::string& userName));
20 MOCK_METHOD1(isUserEnabled, bool(const std::string& userName));
21 MOCK_CONST_METHOD1(getPrimaryGroup, gid_t(const std::string& userName));
23 bool(const std::string& userName, gid_t primaryGid,
H A Duser_mgr_test.cpp40 void createLocalUser(const std::string& userName, in createLocalUser() argument
45 tempObjPath /= userName; in createLocalUser()
58 userName, in createLocalUser()
106 std::string userName = "user"; in TEST_F() local
109 EXPECT_CALL(mockManager, getPrimaryGroup(userName)) in TEST_F()
111 EXPECT_THROW(userInfo = mockManager.getUserInfo(userName), in TEST_F()
118 std::string userName = "testUser"; in TEST_F() local
122 createLocalUser(userName, groups, privilege, true); in TEST_F()
123 EXPECT_CALL(mockManager, userLockedForFailedAttempt(userName)).Times(1); in TEST_F()
124 userInfo = mockManager.getUserInfo(userName); in TEST_F()
138 std::string userName = "ldapUser"; TEST_F() local
160 std::string userName = "ldapUser"; TEST_F() local
[all...]
/openbmc/phosphor-net-ipmid/command/
H A Drakp12.cpp92 session->userName.assign(request->user_name, request->user_name_len); in RAKP12()
119 sizeof(request->user_name_len) + session->userName.size()); in RAKP12()
180 std::string userName(request->user_name, request->user_name_len); in RAKP12() local
182 uint8_t userId = ipmi::ipmiUserGetUserId(userName); in RAKP12()
201 passwd = ipmi::ipmiUserGetPassword(userName); in RAKP12()
211 if (!ipmi::ipmiUserPamAuthenticate(userName, passwd)) in RAKP12()
309 std::copy_n(session->userName.data(), session->userName.size(), iter); in RAKP12()
H A Drakp34.cpp126 auto userLength = static_cast<uint8_t>(session->userName.size()); in RAKP34()
154 std::copy_n(session->userName.data(), userLength, iter); in RAKP34()
211 std::copy_n(session->userName.data(), userLength, iter); in RAKP34()
H A Dpayload_cmds.cpp73 auto userId = ipmi::ipmiUserGetUserId(session->userName); in activatePayload()
162 if (currentSession->userName != solActiveSession->userName && in deactivatePayload()
/openbmc/bios-settings-mgr/src/
H A Dpassword.cpp142 void Password::verifyPassword(std::string userName, std::string currentPassword, in verifyPassword() argument
165 if (userName == "AdminPassword") in verifyPassword()
197 void Password::changePassword(std::string userName, std::string currentPassword, in changePassword() argument
201 verifyPassword(userName, currentPassword, newPassword); in changePassword()
/openbmc/bmcweb/redfish-core/lib/
H A Dvirtual_media.hpp440 std::optional<std::string> userName;
456 std::string&& userName, std::string&& password) in doMountVmLegacy()
458 if (userName.contains('\0')) in doMountVmLegacy()
461 asyncResp->res, userName, "Username", "VirtualMedia.InsertMedia"); in doMountVmLegacy()
465 if (userName.size() > limit) in doMountVmLegacy()
467 messages::stringValueTooLong(asyncResp->res, userName, limit); in doMountVmLegacy()
489 std::move(userName), std::move(password), in doMountVmLegacy()
645 if (!actionParams.userName) in validateParams()
647 actionParams.userName = ""; in validateParams()
657 std::move(*actionParams.userName), in doEjectAction()
439 std::optional<std::string> userName; global() member
455 doMountVmLegacy(const std::shared_ptr<bmcweb::AsyncResp> & asyncResp,const std::string & service,const std::string & name,const std::string & imageUrl,bool rw,std::string && userName,std::string && password) doMountVmLegacy() argument
[all...]
H A Daccount_service.hpp964 std::optional<std::string> userName; member
1018 if (!input.userName && !input.password && !input.serviceAddressList && in handleLDAPPatch()
1051 if (input.userName) in handleLDAPPatch()
1053 handleUserNamePatch(*input.userName, asyncResp, serverT, in handleLDAPPatch()
1586 activeDirectoryObject.userName, // in handleAccountServicePatch()
1602 "LDAP/Authentication/Username", ldapObject.userName, // in handleAccountServicePatch()
/openbmc/bios-settings-mgr/include/
H A Dpassword.hpp73 void changePassword(std::string userName, std::string currentPassword,
77 void verifyPassword(std::string userName, std::string currentPassword,
/openbmc/phosphor-webui/app/access-control/controllers/
H A Dldap-controller.js42 const userName = getUsername(data);
57 'Username': userName,
/openbmc/phosphor-net-ipmid/
H A Dsession.hpp289 std::string userName{}; // User Name member in session::Session
H A Dcommand_table.cpp73 ipmi::ipmiUserGetUserId(session->userName)))}, in executeCommand()
/openbmc/openbmc-test-automation/redfish/account_service/
H A Dtest_user_account.robot564 Redfish.Delete /redfish/v1/AccountService/Accounts/${userName}
705 Redfish.Delete /redfish/v1/AccountService/Accounts/${userName}
/openbmc/intel-ipmi-oem/src/
H A Doemcommands.cpp1266 std::array<uint8_t, ipmi::ipmiMaxUserName>& userName, in ipmiOEMSetUser2Activation() argument
1343 size_t nameLen = strnlen(reinterpret_cast<const char*>(userName.data()), in ipmiOEMSetUser2Activation()
1344 sizeof(userName)); in ipmiOEMSetUser2Activation()
1346 reinterpret_cast<const char*>(userName.data()), nameLen); in ipmiOEMSetUser2Activation()