[PATCH] Blank out passphrases from /root/anaconda-ks.cfg (#868519).
Chris Lumens
clumens at redhat.com
Mon Oct 29 21:43:06 UTC 2012
Note that this means the resulting kickstart file will be less-than-complete,
which is not what we want but is apparently what users want. Any bugs filed
regarding this will be closed WONTFIX.
---
pyanaconda/install.py | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/pyanaconda/install.py b/pyanaconda/install.py
index 0bcfb40..b6fc3e8 100644
--- a/pyanaconda/install.py
+++ b/pyanaconda/install.py
@@ -37,6 +37,12 @@ def _writeKS(ksdata):
path = ROOT_PATH + "/root/anaconda-ks.cfg"
+ # Clear out certain sensitive information that kickstart doesn't have a
+ # way of representing encrypted.
+ for obj in [ksdata.autopart] + ksdata.logvol.dataList() + \
+ ksdata.partition.dataList() + ksdata.raid.dataList():
+ obj.passphrase = ""
+
with open(path, "w") as f:
f.write(str(ksdata))
--
1.7.11.2
More information about the anaconda-patches
mailing list