Merge lp:~alexandru-sirbu/cloud-init/hashed-password-change into lp:~cloud-init-dev/cloud-init/trunk
Proposed by
Alex Sirbu
Status: | Merged |
---|---|
Merged at revision: | 1174 |
Proposed branch: | lp:~alexandru-sirbu/cloud-init/hashed-password-change |
Merge into: | lp:~cloud-init-dev/cloud-init/trunk |
Diff against target: |
14 lines (+4/-0) 1 file modified
cloudinit/distros/__init__.py (+4/-0) |
To merge this branch: | bzr merge lp:~alexandru-sirbu/cloud-init/hashed-password-change |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Dan Watkins | Approve | ||
Review via email: mp+287755@code.launchpad.net |
Description of the change
There was no way to change the password of an already existing user, by providing the new hashed password as an input.
The function def set_passwd(self, user, passwd, hashed=False): from the distros/__init__.py file already has the possibility of changing the password by giving it a hashed string, but this functionality wasn't used anywhere. By adding a new argument, hashed_passwd, to be used in the create_user function in a similar way to the plain_text_passwd, and by using the before mentioned function with the hashed paremeter set to True, the goal of changing the password with a hashed string is met.
To post a comment you must log in.
One minor change requested. :)