Skip to content

Commit 6615f49

Browse files
committed
[cleaner] Treat IPv6 netmask as part of obfuscated string
We need to add the netmask to the string to obfuscate, i.e. to the first group of matched r.e. Otherwise, '2620:52:0:25c0::/64' like string is obfuscated to '534f:53ff:fe00:0002::/64/64'. Closes: #4124 Signed-off-by: Pavel Moravec <[email protected]>
1 parent 2ffe279 commit 6615f49

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sos/cleaner/parsers/ipv6_parser.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class SoSIPv6Parser(SoSCleanerParser):
2727
# a trailing prefix for the network bits.
2828
r"(?<![:\\.\\-a-z0-9])((([0-9a-f]{1,4})(:[0-9a-f]{1,4}){7})|"
2929
r"(([0-9a-f]{1,4}(:[0-9a-f]{0,4}){0,5}))([^.])::(([0-9a-f]{1,4}"
30-
r"(:[0-9a-f]{1,4}){0,5})?))(/\d{1,3})?(?![:\\a-z0-9])"
30+
r"(:[0-9a-f]{1,4}){0,5})?)(/\d{1,3})?)(?![:\\a-z0-9])"
3131
]
3232
parser_skip_files = [
3333
'etc/dnsmasq.conf.*',

0 commit comments

Comments
 (0)