diff options
author | yuhuan.yang <yuhuan.yang@samsung.com> | 2018-01-24 13:22:45 +0800 |
---|---|---|
committer | Yang Yuhuan <yuhuan.yang@10.113.136.109> | 2018-01-29 06:13:53 +0000 |
commit | f79af1e7433f6ce6995e791520ac4c7fdc79a456 (patch) | |
tree | d4469edfe57f928a9d1d2391ecfee261bc5b4de5 | |
parent | 6d1d038329acc59e9a0bdf015e7d97b664f2d3d9 (diff) | |
download | mic-f79af1e7433f6ce6995e791520ac4c7fdc79a456.tar.gz mic-f79af1e7433f6ce6995e791520ac4c7fdc79a456.tar.bz2 mic-f79af1e7433f6ce6995e791520ac4c7fdc79a456.zip |
Use SHA512 instead of MD5 to encrypt root password
Change-Id: I646334220703dedc28b7b1286e28e01ef4c485de
(cherry picked from commit 707754fa61eb4ae452e3af267e14290552122549)
-rwxr-xr-x | mic/kickstart/__init__.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mic/kickstart/__init__.py b/mic/kickstart/__init__.py index fd2806d..75678ad 100755 --- a/mic/kickstart/__init__.py +++ b/mic/kickstart/__init__.py @@ -265,7 +265,7 @@ class RootPasswordConfig(KickstartConfig): p1 = subprocess.Popen(["/bin/echo", "root:%s" %password], stdout = subprocess.PIPE, preexec_fn = self.chroot) - p2 = subprocess.Popen(["/usr/sbin/chpasswd", "-m"], + p2 = subprocess.Popen(["/usr/sbin/chpasswd", "-c","SHA512"], stdin = p1.stdout, stdout = subprocess.PIPE, preexec_fn = self.chroot) |