Skip to content

Commit

Permalink
[networking] obfuscate password in netplan
Browse files Browse the repository at this point in the history
resolves: #3365
Signed-off-by: Arif Ali <[email protected]>
  • Loading branch information
arif-ali authored and TurboTurtle committed Sep 28, 2023
1 parent 524d08d commit 87e8482
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions sos/report/plugins/networking.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,5 +299,13 @@ def setup(self):
self.add_cmd_output("/usr/sbin/traceroute -n %s" % self.trace_host,
priority=100)

def postproc(self):

self.do_path_regex_sub(
"/etc/netplan",
r"(\s+password:).*",
r"\1 ******"
)


# vim: set et ts=4 sw=4 :

0 comments on commit 87e8482

Please sign in to comment.