summaryrefslogtreecommitdiffstats
path: root/tests/py/ip/snat.t
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@netfilter.org>2021-09-06 22:04:51 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2021-09-09 01:13:47 +0200
commit34f31e741d961b059a990579c2402dc39981e1e8 (patch)
tree5fd872e9d48bd603d2078165aeebe6b6e969f0da /tests/py/ip/snat.t
parent10105b3fb0123dd4bb84e39f0611102247765b7b (diff)
netlink: rework range_expr_to_prefix()
Consolidate prefix calculation in range_expr_is_prefix(). Add tests/py for 9208fb30dc49 ("src: Check range bounds before converting to prefix"). Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'tests/py/ip/snat.t')
-rw-r--r--tests/py/ip/snat.t2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/py/ip/snat.t b/tests/py/ip/snat.t
index 38acf52f..a8ff8d1a 100644
--- a/tests/py/ip/snat.t
+++ b/tests/py/ip/snat.t
@@ -6,6 +6,8 @@ iifname "eth0" tcp dport 80-90 snat to 192.168.3.2;ok
iifname "eth0" tcp dport != 80-90 snat to 192.168.3.2;ok
iifname "eth0" tcp dport {80, 90, 23} snat to 192.168.3.2;ok
iifname "eth0" tcp dport != {80, 90, 23} snat to 192.168.3.2;ok
+iifname "eth0" tcp dport 80-90 snat to 192.168.3.0-192.168.3.255;ok;iifname "eth0" tcp dport 80-90 snat to 192.168.3.0/24
+iifname "eth0" tcp dport 80-90 snat to 192.168.3.15-192.168.3.240;ok
iifname "eth0" tcp dport != 23-34 snat to 192.168.3.2;ok