diff options
author | Christian Poessinger <christian@poessinger.com> | 2022-09-01 19:35:15 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-01 19:35:15 +0200 |
commit | 735767f09f891c438e43565f935b927e6f1b317d (patch) | |
tree | 81daee7b244db6fea41f76bd70a45e02fce0334b /data/templates/firewall/nftables.j2 | |
parent | 5c20eac6cd62f9145bc27041db9145b8ba231fa0 (diff) | |
parent | 3489089000a43a533fcd89282b0ced2434851c03 (diff) | |
download | vyos-1x-735767f09f891c438e43565f935b927e6f1b317d.tar.gz vyos-1x-735767f09f891c438e43565f935b927e6f1b317d.zip |
Merge pull request #1466 from sever-sever/T538
nat: T538: Add static NAT one-to-one
Diffstat (limited to 'data/templates/firewall/nftables.j2')
-rw-r--r-- | data/templates/firewall/nftables.j2 | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/data/templates/firewall/nftables.j2 b/data/templates/firewall/nftables.j2 index b91fed615..5971e1bbc 100644 --- a/data/templates/firewall/nftables.j2 +++ b/data/templates/firewall/nftables.j2 @@ -181,6 +181,26 @@ table ip nat { } } +table ip vyos_static_nat { + chain PREROUTING { + type nat hook prerouting priority -100; policy accept; + counter jump VYOS_PRE_DNAT_HOOK + } + + chain POSTROUTING { + type nat hook postrouting priority 100; policy accept; + counter jump VYOS_PRE_SNAT_HOOK + } + + chain VYOS_PRE_DNAT_HOOK { + return + } + + chain VYOS_PRE_SNAT_HOOK { + return + } +} + table ip6 nat { chain PREROUTING { type nat hook prerouting priority -100; policy accept; |