diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2020-01-03 17:46:24 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2020-01-05 16:12:30 +0100 |
commit | c1ce4072b72e34300bd7bb406652a60f62384fc8 (patch) | |
tree | fcb64226fbd959a0d89bfb1a08db357cb2fd4bbc /tests/shell/testcases | |
parent | 4441c0233cbcb74b08a53720557e76bf0b26c998 (diff) |
tests: shell: delete flowtable after flushing chain
This patch adds a test to cover delete flowtable after chain flush
including two rule references to the flowtable.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'tests/shell/testcases')
-rwxr-xr-x | tests/shell/testcases/flowtable/0011deleteafterflush_0 | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/shell/testcases/flowtable/0011deleteafterflush_0 b/tests/shell/testcases/flowtable/0011deleteafterflush_0 new file mode 100755 index 00000000..4f519a7c --- /dev/null +++ b/tests/shell/testcases/flowtable/0011deleteafterflush_0 @@ -0,0 +1,10 @@ +#!/bin/bash + +set -e +$NFT add table x +$NFT add chain x y +$NFT add flowtable x f { hook ingress priority 0\; devices = { lo }\;} +$NFT add rule x y ip protocol tcp flow add @f +$NFT add rule x y ip protocol udp flow add @f +$NFT flush chain x y +$NFT delete flowtable x f |