From 1b01fbc234f02c964deeffb866060e563c072c5b Mon Sep 17 00:00:00 2001 From: "Bryn M. Reeves" Date: Sat, 21 Jun 2014 16:42:04 +0100 Subject: [distupgrade] elide passwords in /root/preupgrade Signed-off-by: Bryn M. Reeves --- sos/plugins/distupgrade.py | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/sos/plugins/distupgrade.py b/sos/plugins/distupgrade.py index 8bc44c23..a98d3713 100644 --- a/sos/plugins/distupgrade.py +++ b/sos/plugins/distupgrade.py @@ -34,6 +34,23 @@ class RedHatDistUpgrade(DistUpgrade, RedHatPlugin): "/root/preupgrade/kickstart" ) - + def postproc(self): + self.doRegexSub( + "/root/preupgrade/kickstart/anaconda-ks.cfg", + r"(useradd --password) (.*)", + r"\1 ********" + ) + + self.doRegexSub( + "/root/preupgrade/kickstart/anaconda-ks.cfg", + r"(\s*rootpw\s*).*", + r"\1********" + ) + + self.doRegexSub( + "/root/preupgrade/kickstart/untrackeduser", + r"\/home\/.*", + r"/home/******** path redacted ********" + ) # vim: et ts=4 sw=4 -- cgit