From 939d00f473f4861932134b5c80aec40a330964aa Mon Sep 17 00:00:00 2001 From: bvassova Date: Mon, 26 Jul 2021 16:20:39 +0200 Subject: [pulp] adding obfuscation of proxy_password in /etc/pulp/server/plugins.conf.d/ Resolves: #2564 Signed-off-by: Barbora Vassova bvassova@redhat.com --- sos/report/plugins/pulp.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sos/report/plugins/pulp.py b/sos/report/plugins/pulp.py index ca49ff06..5a620751 100644 --- a/sos/report/plugins/pulp.py +++ b/sos/report/plugins/pulp.py @@ -160,8 +160,8 @@ class Pulp(Plugin, RedHatPlugin): # Now handle JSON-formatted data in the same /etc/pulp directory # structure. We use a different substitution string here to preserve # the file's JSON syntax. - jreg = r"(\s*\".*(passw|cred|token|secret).*\"\s*:\s*\")(.*)(\")" - repl = r"\1********\4" + jreg = r"(\s*\".*(passw|cred|token|secret).*\"\s*:(\s))(.*)(\w+)" + repl = r"\1********" self.do_path_regex_sub("/etc/pulp(.*)(.json$)", jreg, repl) # obfuscate SECRET_KEY = .. and 'PASSWORD': .. in dynaconf list output -- cgit