diff options
author | Neale Ranns <nranns@cisco.com> | 2019-04-04 12:43:36 +0000 |
---|---|---|
committer | Damjan Marion <dmarion@me.com> | 2019-04-05 07:52:55 +0000 |
commit | b71fa75d48b16f45618ba3fe3aa847c331f837b0 (patch) | |
tree | 8018d3f038b069c0db6e6e32c84ada77340b31c3 /src/vnet/ipsec/ipsec_punt.c | |
parent | 6416e6274d0817a347d5b54bc61b4f1b617ff363 (diff) |
IPSEC: punt reasons; SPI=0, no-tunnel
Change-Id: If76992e283a27fa193a6865257ab3aa764066e48
Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'src/vnet/ipsec/ipsec_punt.c')
-rw-r--r-- | src/vnet/ipsec/ipsec_punt.c | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/src/vnet/ipsec/ipsec_punt.c b/src/vnet/ipsec/ipsec_punt.c new file mode 100644 index 00000000000..357e9596cfc --- /dev/null +++ b/src/vnet/ipsec/ipsec_punt.c @@ -0,0 +1,51 @@ +/* + * esp_decrypt.c : IPSec ESP decrypt node + * + * Copyright (c) 2015 Cisco and/or its affiliates. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at: + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include <vnet/ipsec/ipsec.h> +#include <vnet/ipsec/ipsec_punt.h> + +static vlib_punt_hdl_t punt_hdl; + +vlib_punt_reason_t ipsec_punt_reason[IPSEC_PUNT_N_REASONS]; + +static clib_error_t * +ipsec_punt_init (vlib_main_t * vm) +{ + clib_error_t *error; + + if ((error = vlib_call_init_function (vm, punt_init))) + return (error); + + punt_hdl = vlib_punt_client_register ("ipsec"); + +#define _(s,v) vlib_punt_reason_alloc (punt_hdl, v, \ + &ipsec_punt_reason[IPSEC_PUNT_##s]); + foreach_ipsec_punt_reason +#undef _ + return (error); +} + +VLIB_INIT_FUNCTION (ipsec_punt_init); + + +/* + * fd.io coding-style-patch-verification: ON + * + * Local Variables: + * eval: (c-set-style "gnu") + * End: + */ |