aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/ipsec/ipsec_spd_policy.c
diff options
context:
space:
mode:
authorShivaShankarK <shivaashankar1204@gmail.com>2020-04-14 14:01:03 +0530
committerNeale Ranns <nranns@cisco.com>2020-04-24 07:37:20 +0000
commit0546483ce0b16acb82807aab290ff203e961b23a (patch)
tree6895dee993862e91da0ef0e7ee550b053756bf79 /src/vnet/ipsec/ipsec_spd_policy.c
parentb5c0d35f9445d4d99f2c5c7bd3175e68721a8ee5 (diff)
ipsec: add input node bypass/discard functionality
add bypass/discard functionality to ipsec4-input-feature node Type: feature Signed-off-by: ShivaShankarK <shivaashankar1204@gmail.com> Change-Id: I152a5dfee0296109cccabe349a330dbbe395cc6c
Diffstat (limited to 'src/vnet/ipsec/ipsec_spd_policy.c')
-rw-r--r--src/vnet/ipsec/ipsec_spd_policy.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vnet/ipsec/ipsec_spd_policy.c b/src/vnet/ipsec/ipsec_spd_policy.c
index 6424210b4e3..05cfdf0a671 100644
--- a/src/vnet/ipsec/ipsec_spd_policy.c
+++ b/src/vnet/ipsec/ipsec_spd_policy.c
@@ -123,6 +123,10 @@ ipsec_policy_mk_type (bool is_outbound,
IPSEC_SPD_POLICY_IP4_INBOUND_BYPASS);
return (0);
case IPSEC_POLICY_ACTION_DISCARD:
+ *type = (is_ipv6 ?
+ IPSEC_SPD_POLICY_IP6_INBOUND_DISCARD :
+ IPSEC_SPD_POLICY_IP4_INBOUND_DISCARD);
+ return (0);
case IPSEC_POLICY_ACTION_RESOLVE:
break;
}