mirror of
https://github.com/xcat2/confluent.git
synced 2024-11-26 11:30:23 +00:00
Set password before access
In at least one scenario, we want the password to be squared away before we start manipulating the user access level.
This commit is contained in:
parent
2e93af9b5e
commit
59f00dd10b
@ -745,14 +745,16 @@ class IpmiHandler(object):
|
||||
if 'username' in user:
|
||||
self.ipmicmd.set_user_name(uid=user['uid'],
|
||||
name=user['username'])
|
||||
if 'privilege_level' in user:
|
||||
self.ipmicmd.set_user_access(uid=user['uid'],
|
||||
privilege_level=user['privilege_level'])
|
||||
|
||||
if 'password' in user:
|
||||
self.ipmicmd.set_user_password(uid=user['uid'],
|
||||
password=user['password'])
|
||||
self.ipmicmd.set_user_password(uid=user['uid'],
|
||||
mode='enable', password=user['password'])
|
||||
if 'privilege_level' in user:
|
||||
self.ipmicmd.set_user_access(uid=user['uid'],
|
||||
privilege_level=user[
|
||||
'privilege_level'])
|
||||
if 'enabled' in user:
|
||||
if user['enabled'] == 'yes':
|
||||
mode = 'enable'
|
||||
|
Loading…
Reference in New Issue
Block a user