summaryrefslogtreecommitdiff
path: root/smoketest/scripts/cli
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2023-02-28 22:18:04 +0100
committerGitHub <noreply@github.com>2023-02-28 22:18:04 +0100
commit851364c00e0521a0afee4b449b0a31de442016f3 (patch)
tree4113337d39047b0266e8fe26d66cd8dd708c4788 /smoketest/scripts/cli
parent36cf6ea9a1c86de1352ceef9b0fd8088f1e53a44 (diff)
parentbbfe6b54b58b68768f6427496d8ac3c1ef38da93 (diff)
downloadvyos-1x-851364c00e0521a0afee4b449b0a31de442016f3.tar.gz
vyos-1x-851364c00e0521a0afee4b449b0a31de442016f3.zip
Merge pull request #1857 from nicolas-fort/nft_queue
T5037: Firewall: Add queue action and options to firewall
Diffstat (limited to 'smoketest/scripts/cli')
-rwxr-xr-xsmoketest/scripts/cli/test_firewall.py13
1 files changed, 12 insertions, 1 deletions
diff --git a/smoketest/scripts/cli/test_firewall.py b/smoketest/scripts/cli/test_firewall.py
index f1c18d761..41ba633d9 100755
--- a/smoketest/scripts/cli/test_firewall.py
+++ b/smoketest/scripts/cli/test_firewall.py
@@ -284,6 +284,15 @@ class TestFirewall(VyOSUnitTestSHIM.TestCase):
self.cli_set(['firewall', 'name', name2, 'rule', '1', 'action', 'jump'])
self.cli_set(['firewall', 'name', name2, 'rule', '1', 'jump-target', name])
+ self.cli_set(['firewall', 'name', name2, 'rule', '2', 'protocol', 'tcp'])
+ self.cli_set(['firewall', 'name', name2, 'rule', '2', 'action', 'queue'])
+ self.cli_set(['firewall', 'name', name2, 'rule', '2', 'queue', '3'])
+ self.cli_set(['firewall', 'name', name2, 'rule', '3', 'protocol', 'udp'])
+ self.cli_set(['firewall', 'name', name2, 'rule', '3', 'action', 'queue'])
+ self.cli_set(['firewall', 'name', name2, 'rule', '3', 'queue-options', 'fanout'])
+ self.cli_set(['firewall', 'name', name2, 'rule', '3', 'queue-options', 'bypass'])
+ self.cli_set(['firewall', 'name', name2, 'rule', '3', 'queue', '0-15'])
+
self.cli_set(['firewall', 'interface', interface, 'in', 'name', name])
self.cli_commit()
@@ -294,7 +303,9 @@ class TestFirewall(VyOSUnitTestSHIM.TestCase):
['ip length 1-30000', 'ip length != 60000-65535', 'ip dscp 0x03-0x0b', 'ip dscp != 0x15-0x19', 'return'],
[f'log prefix "[{name}-default-D]"', 'drop'],
['ip saddr 198.51.100.1', f'jump NAME_{name}'],
- [f'log prefix "[{name2}-default-J]"', f'jump NAME_{name}']
+ [f'log prefix "[{name2}-default-J]"', f'jump NAME_{name}'],
+ [f'meta l4proto tcp','queue to 3'],
+ [f'meta l4proto udp','queue flags bypass,fanout to 0-15']
]
self.verify_nftables(nftables_search, 'ip vyos_filter')