diff options
author | Jeremy Katz <katzj@redhat.com> | 2001-07-03 00:44:20 +0000 |
---|---|---|
committer | Jeremy Katz <katzj@redhat.com> | 2001-07-03 00:44:20 +0000 |
commit | ead13b3e2196c2e6efdb642f3c1887f19405d6fc (patch) | |
tree | b84b125b84c8e4aa5e9f35b4c8827cbfa906ae41 /users.py | |
parent | 799fd0fc2912b0ce9dc03399c87225cf42c0dad3 (diff) | |
download | anaconda-ead13b3e2196c2e6efdb642f3c1887f19405d6fc.tar.gz anaconda-ead13b3e2196c2e6efdb642f3c1887f19405d6fc.tar.xz anaconda-ead13b3e2196c2e6efdb642f3c1887f19405d6fc.zip |
if the user has requested md5 passwords, write out the root password in the
autogenerated ks.cfg as an md5 crypted password (46294)
Diffstat (limited to 'users.py')
-rw-r--r-- | users.py | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -94,8 +94,12 @@ class RootPassword(Password): setPassword(instPath, "root", self.getCrypted (), auth.useMD5, alreadyCrypted = 1) - def writeKS(self, f): - f.write("rootpw --iscrypted %s\n" % self.getCrypted()) + def writeKS(self, f, auth): + pure = self.getPure() + if pure: + f.write("rootpw --iscrypted %s\n" %(cryptPassword(pure, auth.useMD5))) + else: + f.write("rootpw --iscrypted %s\n" %(self.getCrypted())) def cryptPassword(password, useMD5): if useMD5: |