diff options
author | Phil Sutter <phil@nwl.cc> | 2018-06-08 17:27:18 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2018-06-11 11:31:49 +0200 |
commit | f63b54623fcd1ab7d2f51928571c164409f00175 (patch) | |
tree | 49acf0abdbeb4552f66a720fb5ca76a8ce9930d2 /tests/py/any/fwd.t.payload | |
parent | 78f8d8127eac64abb14e1d4a4309b353ba03bdb6 (diff) |
JSON: Support latest enhancements of fwd statement
JSON equivalent of fwd statement was too primitive to support the added
address and family parameters, so make its value an object and accept
the device expression as value of a "dev" property in there. Then add
optional "addr" and "family" properties to it.
While being at it, add a testcase to make sure the extended syntax works
right.
Signed-off-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'tests/py/any/fwd.t.payload')
-rw-r--r-- | tests/py/any/fwd.t.payload | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/py/any/fwd.t.payload b/tests/py/any/fwd.t.payload index 696b55ef..966c08b0 100644 --- a/tests/py/any/fwd.t.payload +++ b/tests/py/any/fwd.t.payload @@ -12,3 +12,9 @@ netdev test-netdev ingress [ lookup reg 1 set __map%d dreg 1 ] [ fwd sreg_dev 1 ] +# fwd ip to 192.168.2.200 device "lo" +netdev test-netdev ingress + [ immediate reg 1 0x00000001 ] + [ immediate reg 2 0xc802a8c0 ] + [ fwd sreg_dev 1 sreg_addr 2 nfproto 2 ] + |