#!/bin/bash # skeleton $NFT -f /dev/stdin <6 $NFT add rule 'inet inetfoo c dnat to ip daddr map @x6' && exit 1 # should fail: map has wrong family: 6->4 $NFT add rule 'inet inetfoo c dnat to ip6 daddr map @x4' && exit 1 # should fail: rule has no test for l4 protocol $NFT add rule 'inet inetfoo c ip6 saddr f0:0b::a3 dnat to [1c::3]:42' && exit 1 # should fail: rule has no test for l4 protocol, but map has inet_service $NFT add rule 'inet inetfoo c dnat to ip daddr map @y4' && exit 1 # should fail: rule has test for l4 protocol, but map has wrong family: 4->6 $NFT add rule 'inet inetfoo c meta l4proto tcp dnat to ip daddr map @y6' && exit 1 # should fail: rule has test for l4 protocol, but map has wrong family: 6->4 $NFT add rule 'inet inetfoo c meta l4proto tcp dnat to ip6 daddr map @y4' && exit 1 # fail: inet_service, but expect ipv4_addr $NFT -f /dev/stdin <