From 815c6a4fbcbb636ce3b4dc98446ad205a30670a6 Mon Sep 17 00:00:00 2001 From: Piotr Bronowski Date: Thu, 9 Jun 2022 09:09:28 +0000 Subject: ipsec: change wildcard value for any protocol of spd policy Currently 0 has been used as the wildcard representing ANY type of protocol. However 0 is valid value of ip protocol (HOPOPT) and therefore it should not be used as a wildcard. Instead 255 is used which is guaranteed by IANA to be reserved and not used as a protocol id. Type: improvement Signed-off-by: Piotr Bronowski Change-Id: I2320bae6fe380cb999dc5a9187beb68fda2d31eb --- src/vnet/ipsec/ipsec_cli.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/vnet/ipsec/ipsec_cli.c') diff --git a/src/vnet/ipsec/ipsec_cli.c b/src/vnet/ipsec/ipsec_cli.c index df8f9378111..8b436b6b805 100644 --- a/src/vnet/ipsec/ipsec_cli.c +++ b/src/vnet/ipsec/ipsec_cli.c @@ -279,6 +279,7 @@ ipsec_policy_add_del_command_fn (vlib_main_t * vm, clib_memset (&p, 0, sizeof (p)); p.lport.stop = p.rport.stop = ~0; remote_range_set = local_range_set = is_outbound = 0; + p.protocol = IPSEC_POLICY_PROTOCOL_ANY; if (!unformat_user (input, unformat_line_input, line_input)) return 0; -- cgit 1.2.3-korg