Skip to content

Commit ebd9436

Browse files
committed
fix: improve iptables checker
Update iptables checker to avoid returning a false positive with the following string: 0.0.0.0 iptables -t nat -D Signed-off-by: Fabrice Fontaine <[email protected]>
1 parent cbff7bb commit ebd9436

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cve_bin_tool/checkers/iptables.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class IptablesChecker(Checker):
1717
CONTAINS_PATTERNS: list[str] = []
1818
FILENAME_PATTERNS: list[str] = []
1919
VERSION_PATTERNS = [
20-
r"\r?\n([0-9]{1,2}\.[0-9]+\.[0-9]+\.?[0-9]*)\r?\niptables",
20+
r"\r?\n([1-9]{1,2}\.[0-9]+\.[0-9]+\.?[0-9]*)\r?\niptables",
2121
r"iptables-([0-9]+\.[0-9]+\.[0-9]+\.?[0-9]*)",
2222
r"iptables-rules>[a-zA-Z %:\r\n]*([0-9]+\.[0-9]+\.[0-9]+\.?[0-9]*)",
2323
r"iptables-save v%s on %s\r?\n([0-9]+\.[0-9]+\.[0-9]+\.?[0-9]*)",

0 commit comments

Comments
 (0)