summaryrefslogtreecommitdiff
path: root/hosts/vidhar/network/ruleset.nft
diff options
context:
space:
mode:
Diffstat (limited to 'hosts/vidhar/network/ruleset.nft')
-rw-r--r--hosts/vidhar/network/ruleset.nft30
1 files changed, 25 insertions, 5 deletions
diff --git a/hosts/vidhar/network/ruleset.nft b/hosts/vidhar/network/ruleset.nft
index fb04e449..c4c2fbe6 100644
--- a/hosts/vidhar/network/ruleset.nft
+++ b/hosts/vidhar/network/ruleset.nft
@@ -80,6 +80,7 @@ table inet filter {
80 counter dns-rx {} 80 counter dns-rx {}
81 counter wg-rx {} 81 counter wg-rx {}
82 counter yggdrasil-gre-rx {} 82 counter yggdrasil-gre-rx {}
83 counter wifibh-gre-rx {}
83 counter ipv6-pd-rx {} 84 counter ipv6-pd-rx {}
84 counter ntp-rx {} 85 counter ntp-rx {}
85 counter dhcp-rx {} 86 counter dhcp-rx {}
@@ -106,6 +107,7 @@ table inet filter {
106 counter dns-tx {} 107 counter dns-tx {}
107 counter wg-tx {} 108 counter wg-tx {}
108 counter yggdrasil-gre-tx {} 109 counter yggdrasil-gre-tx {}
110 counter wifibh-gre-tx {}
109 counter ipv6-pd-tx {} 111 counter ipv6-pd-tx {}
110 counter ntp-tx {} 112 counter ntp-tx {}
111 counter dhcp-tx {} 113 counter dhcp-tx {}
@@ -136,8 +138,7 @@ table inet filter {
136 oifname {lan, dsl} meta l4proto $icmp_protos jump forward_icmp_accept 138 oifname {lan, dsl} meta l4proto $icmp_protos jump forward_icmp_accept
137 139
138 iifname lan oifname dsl counter name fw-lan accept 140 iifname lan oifname dsl counter name fw-lan accept
139 iifname dsl oifname { lan, dmz01 } ct state {established, related} counter name fw-dsl accept 141 iifname dsl oifname lan ct state {established, related} counter name fw-dsl accept
140
141 142
142 143
143 limit name lim_reject log level debug prefix "drop forward: " counter name reject-ratelimit-fw drop 144 limit name lim_reject log level debug prefix "drop forward: " counter name reject-ratelimit-fw drop
@@ -165,18 +166,19 @@ table inet filter {
165 iifname { lan, mgmt, dsl, yggdrasil } tcp dport 22 counter name ssh-rx accept 166 iifname { lan, mgmt, dsl, yggdrasil } tcp dport 22 counter name ssh-rx accept
166 iifname { lan, mgmt, dsl, yggdrasil } udp dport 60001-61000 counter name mosh-rx accept 167 iifname { lan, mgmt, dsl, yggdrasil } udp dport 60001-61000 counter name mosh-rx accept
167 168
168 iifname { lan, mgmt, dmz01 } tcp dport 53 counter name dns-rx accept 169 iifname { lan, mgmt } tcp dport 53 counter name dns-rx accept
169 iifname { lan, mgmt, dmz01 } udp dport 53 counter name dns-rx accept 170 iifname { lan, mgmt } udp dport 53 counter name dns-rx accept
170 171
171 iifname { lan, mgmt, dsl } meta protocol ip udp dport 51820 counter name wg-rx accept 172 iifname { lan, mgmt, dsl } meta protocol ip udp dport 51820 counter name wg-rx accept
172 iifname { lan, mgmt, dsl } meta protocol ip6 udp dport 51821 counter name wg-rx accept 173 iifname { lan, mgmt, dsl } meta protocol ip6 udp dport 51821 counter name wg-rx accept
173 iifname "yggdrasil-wg-*" meta l4proto gre counter name yggdrasil-gre-rx accept 174 iifname "yggdrasil-wg-*" meta l4proto gre counter name yggdrasil-gre-rx accept
175 iifname wifibh meta l4proto gre counter name wifibh-gre-rx accept
174 176
175 iifname dsl meta protocol ip6 udp dport 546 udp sport 547 counter name ipv6-pd-rx accept 177 iifname dsl meta protocol ip6 udp dport 546 udp sport 547 counter name ipv6-pd-rx accept
176 178
177 iifname mgmt udp dport 123 counter name ntp-rx accept 179 iifname mgmt udp dport 123 counter name ntp-rx accept
178 180
179 iifname { lan, mgmt, dmz01 } udp dport 67 counter name dhcp-rx accept 181 iifname { lan, mgmt } udp dport 67 counter name dhcp-rx accept
180 182
181 iifname lan udp dport { 137, 138, 3702 } counter name samba-rx accept 183 iifname lan udp dport { 137, 138, 3702 } counter name samba-rx accept
182 iifname lan tcp dport { 445, 139, 5357 } counter name samba-rx accept 184 iifname lan tcp dport { 445, 139, 5357 } counter name samba-rx accept
@@ -215,6 +217,7 @@ table inet filter {
215 meta protocol ip udp sport 51820 counter name wg-tx 217 meta protocol ip udp sport 51820 counter name wg-tx
216 meta protocol ip6 udp sport 51821 counter name wg-tx 218 meta protocol ip6 udp sport 51821 counter name wg-tx
217 iifname "yggdrasil-wg-*" meta l4proto gre counter name yggdrasil-gre-tx 219 iifname "yggdrasil-wg-*" meta l4proto gre counter name yggdrasil-gre-tx
220 iifname wifibh meta l4proto gre counter name wifibh-gre-tx
218 221
219 meta protocol ip6 udp sport 546 udp dport 547 counter name ipv6-pd-tx 222 meta protocol ip6 udp sport 546 udp dport 547 counter name ipv6-pd-tx
220 223
@@ -235,6 +238,23 @@ table inet filter {
235 } 238 }
236} 239}
237 240
241table bridge filter {
242 counter br-invalid-fw {}
243 counter br-wifibh-fw {}
244 counter br-lan-fw {}
245
246 chain forward {
247 type filter hook forward priority filter
248 policy drop
249
250
251 ct state invalid log level debug prefix "drop invalid forward: " counter name invalid-fw drop
252
253 iifname "wifibh01.lan" counter name wifibh-fw accept
254 iifname "eno2.lan" counter name lan-fw accept
255 }
256}
257
238table ip nat { 258table ip nat {
239 counter dsl-nat {} 259 counter dsl-nat {}
240 260