Revert "ruleset: dispatch ct states using verdict map"
[project/firewall4.git] / tests / 01_configuration / 02_rule_order
index 2778cce805de2bdbf8ba975c4c2b73e6d4721361..93a0f08d7c8ceb12b51765d511215854baa3de24 100644 (file)
@@ -66,20 +66,17 @@ table inet fw4
 flush table inet fw4
 
 table inet fw4 {
-       #
-       # Set definitions
-       #
-
-
        #
        # Defines
        #
 
        define lan_devices = { "br-lan" }
        define lan_subnets = { 10.0.0.0/24, 192.168.26.0/24, 2001:db8:1000::/60, fd63:e2f:f706::/60 }
+
        define wan_devices = { "pppoe-wan" }
        define wan_subnets = { 10.11.12.0/24 }
 
+
        #
        # User includes
        #
@@ -119,6 +116,10 @@ table inet fw4 {
                oifname "pppoe-wan" jump output_wan comment "!fw4: Handle wan IPv4/IPv6 output traffic"
        }
 
+       chain prerouting {
+               type filter hook prerouting priority filter; policy accept;
+       }
+
        chain handle_reject {
                meta l4proto tcp reject with tcp reset comment "!fw4: Reject TCP traffic"
                reject with icmpx type port-unreachable comment "!fw4: Reject any other traffic"
@@ -186,7 +187,7 @@ table inet fw4 {
 
 
        #
-       # Raw rules (notrack & helper)
+       # Raw rules (notrack)
        #
 
        chain raw_prerouting {
@@ -215,7 +216,7 @@ table inet fw4 {
        }
 
        chain mangle_output {
-               type filter hook output priority mangle; policy accept;
+               type route hook output priority mangle; policy accept;
        }
 
        chain mangle_forward {
@@ -228,5 +229,11 @@ table inet fw4 {
 [call] ctx.call object <network.interface> method <dump> args <null>
 [call] ctx.call object <service> method <get_data> args <{ "type": "firewall" }>
 [call] fs.open path </proc/version> mode <r>
+[call] fs.glob pattern </usr/share/nftables.d/ruleset-pre/*.nft>
+[call] fs.glob pattern </usr/share/nftables.d/ruleset-post/*.nft>
+[call] fs.glob pattern </usr/share/nftables.d/table-pre/*.nft>
+[call] fs.glob pattern </usr/share/nftables.d/table-post/*.nft>
+[call] fs.lsdir path </usr/share/nftables.d/chain-pre>
+[call] fs.lsdir path </usr/share/nftables.d/chain-post>
 [call] fs.popen cmdline </usr/sbin/nft --terse --json list flowtables inet> mode <r>
 -- End --