From 2dfb973c0dcc6d22113e2370f461f1733035baaf Mon Sep 17 00:00:00 2001 From: Vytas Dauksa Date: Tue, 17 Dec 2013 14:01:44 +0000 Subject: add markmask for hash:ip,mark data type Introduce packet mark mask for hash:ip,mark data type. This allows to set mark bit filter for the ip set. Change-Id: Id8dd9ca7e64477c4f7b022a1d9c1a5b187f1c96e Signed-off-by: Jozsef Kadlecsik --- tests/hash:ip,mark.t | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'tests/hash:ip,mark.t') diff --git a/tests/hash:ip,mark.t b/tests/hash:ip,mark.t index bd5c237..ad76274 100644 --- a/tests/hash:ip,mark.t +++ b/tests/hash:ip,mark.t @@ -122,4 +122,14 @@ 0 ./check_extensions test 2.0.0.20 700 13 12479 # Counters and timeout: destroy set 0 ipset x test +# Create a set with 65502 ( 0x0000FFDE ) markmask +0 ipset create test hash:ip,mark markmask 0x0000FFDE +# Add first value with 86111010 ( 0x0521F322 ) mark +0 ipset add test 19.16.1.254,0x0521F322 +# Test last entry mark was modified to 62210 ( 0x0000F302 ) +0 ipset test test 19.16.1.254,0x0000F302 +# Test that mask is applied for tests as well +0 ipset test test 19.16.1.254,0x0521F322 +# Destroy set +0 ipset x test # eof -- cgit v1.2.3