43 }) ip4_and_esp_header_t;
51 }) ip4_and_udp_and_esp_header_t;
58 }) ip6_and_esp_header_t;
75 #define ESP_SEQ_MAX (4294967295UL) 76 #define ESP_MAX_BLOCK_SIZE (16) 77 #define ESP_MAX_IV_SIZE (16) 78 #define ESP_MAX_ICV_SIZE (32) 113 aad = (esp_aead_t *) data;
116 if (ipsec_sa_is_set_USE_ESN (sa))
177 "Custom meta-data too large for vnet_buffer_opaque_t");
179 #define esp_post_data(b) \ 180 ((esp_post_data_t *)((u8 *)((b)->opaque) \ 181 + STRUCT_OFFSET_OF (vnet_buffer_opaque_t, unused))) 185 "Custom meta-data too large for vnet_buffer_opaque2_t");
187 #define esp_post_data2(b) \ 188 ((esp_decrypt_packet_data2_t *)((u8 *)((b)->opaque2) \ 189 + STRUCT_OFFSET_OF (vnet_buffer_opaque2_t, unused)))
The post data structure to for esp_encrypt/decrypt_inline to write to vib_buffer_t opaque unused fiel...
static u16 esp_aad_fill(u8 *data, const esp_header_t *esp, const ipsec_sa_t *sa)
struct esp_aead_t_ esp_aead_t
AES GCM Additional Authentication data.
AES GCM Additional Authentication data.
STATIC_ASSERT(sizeof(esp_post_data_t)<=STRUCT_SIZE_OF(vnet_buffer_opaque_t, unused), "Custom meta-data too large for vnet_buffer_opaque_t")
static int esp_seq_advance(ipsec_sa_t *sa)
u32 data[3]
for GCM: when using ESN it's: SPI, seq-hi, seg-low else SPI, seq-low
esp_async_post_next_t esp_decrypt_async_next
typedef CLIB_PACKED(struct { ip4_header_t ip4;esp_header_t esp;}) ip4_and_esp_header_t
esp_async_post_next_t esp_encrypt_async_next
STATIC_ASSERT_SIZEOF(esp_decrypt_packet_data_t, 3 *sizeof(u64))
enum ipsec_sad_flags_t_ ipsec_sa_flags_t
u8 * format_esp_header(u8 *s, va_list *args)
VLIB buffer representation.
esp_decrypt_packet_data_t decrypt_data
#define STRUCT_SIZE_OF(t, f)