From 673b9d3f2630f812bcef95666a1097747844c92b Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Fri, 30 Oct 2020 20:36:22 +0100 Subject: tests: shell: exercise validation with nft -c Using oif in fib from prerouting is not support, make sure -c reports an error. Signed-off-by: Pablo Neira Ayuso --- tests/shell/testcases/nft-f/0023check_1 | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100755 tests/shell/testcases/nft-f/0023check_1 (limited to 'tests/shell/testcases') diff --git a/tests/shell/testcases/nft-f/0023check_1 b/tests/shell/testcases/nft-f/0023check_1 new file mode 100755 index 00000000..42793b6e --- /dev/null +++ b/tests/shell/testcases/nft-f/0023check_1 @@ -0,0 +1,12 @@ +#!/bin/bash + +RULESET="table ip foo { + chain bar { + type filter hook prerouting priority 0; + } +}" + +$NFT -f - <<< "$RULESET" + +$NFT -c add rule foo bar fib saddr . oif type local && exit 1 +exit 0 -- cgit v1.2.3