User Tools

Site Tools


nftables

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
nftables [2020/08/19 13:38] – loopback output wwnftables [2026/06/20 15:35] (current) – external edit 127.0.0.1
Line 118: Line 118:
 } }
  
 +</code>
 +
 +----
 +
 +===== The Masquerade =====
 +
 +<code>
 +table ip nat {
 +  chain postrouting {
 +    type nat hook postrouting priority 100;
 +    oif $iface_wan masquerade;
 +  }
 +}
 </code> </code>
  
Line 123: Line 136:
  
 ===== The NAT ===== ===== The NAT =====
 +
 +<code>
 +table inet filter {
 +  chain forward {
 +    type filter hook forward priority 0;
 +    policy drop;
 +
 +    jump global
 +
 +    # [...]
 +
 +    ip daddr 192.168.1.10 tcp dport 3389 accept
 +
 +    counter drop
 +  }
 +}
 +
 +</code>
  
 <code> <code>
nftables.1597844339.txt.gz · Last modified: (external edit)