X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvnet%2Fipsec%2Fipsec_tun.h;fp=src%2Fvnet%2Fipsec%2Fipsec_tun.h;h=c5fbe59f2b66e6ad8316a22f35a794eb34e39d90;hb=dd4ccf2623b547654d215ffcf42f9813e42aa90c;hp=90f299668dc1894773cd3cf105f8c4e2d41898e2;hpb=0c65f52bb9395526613493aa9c042ea4f6dbc1fc;p=vpp.git diff --git a/src/vnet/ipsec/ipsec_tun.h b/src/vnet/ipsec/ipsec_tun.h index 90f299668dc..c5fbe59f2b6 100644 --- a/src/vnet/ipsec/ipsec_tun.h +++ b/src/vnet/ipsec/ipsec_tun.h @@ -47,12 +47,21 @@ typedef CLIB_PACKED(struct { extern u8 *format_ipsec4_tunnel_key (u8 * s, va_list * args); extern u8 *format_ipsec6_tunnel_key (u8 * s, va_list * args); +#define foreach_ipsec_protect_flags \ + _(L2, 1, "l2") \ + _(ENCAPED, 2, "encapped") \ + _(ITF, 4, "itf") \ + typedef enum ipsec_protect_flags_t_ { - IPSEC_PROTECT_L2 = (1 << 0), - IPSEC_PROTECT_ENCAPED = (1 << 1), + IPSEC_PROTECT_NONE = 0, +#define _(a,b,c) IPSEC_PROTECT_##a = b, + foreach_ipsec_protect_flags +#undef _ } __clib_packed ipsec_protect_flags_t; +extern u8 *format_ipsec_tun_protect_flags (u8 * s, va_list * args); + typedef struct ipsec_ep_t_ { ip46_address_t src; @@ -76,6 +85,7 @@ typedef struct ipsec_tun_protect_t_ ipsec_ep_t itp_crypto; ipsec_protect_flags_t itp_flags; + adj_index_t itp_ai; ipsec_ep_t itp_tun;