summaryrefslogtreecommitdiffstats
path: root/src/plugins/snat/snat.h
diff options
context:
space:
mode:
authorJuraj Sloboda <jsloboda@cisco.com>2017-04-03 08:43:58 +0200
committerFlorin Coras <florin.coras@gmail.com>2017-04-11 20:38:20 +0000
commit7a1bde061a919af42645e3bc09206b98fbfde9d9 (patch)
treec552d142eabbcce376928fb8ab67345083d2ccd5 /src/plugins/snat/snat.h
parent9f171f5e20d4f30316626987a3dc66c9730e6d73 (diff)
Add ICMP support for deterministic NAT
Change-Id: I9a6bcb7d173a2c13d89784e7ff8a6e42dcee201f Signed-off-by: Juraj Sloboda <jsloboda@cisco.com>
Diffstat (limited to 'src/plugins/snat/snat.h')
-rw-r--r--src/plugins/snat/snat.h19
1 files changed, 14 insertions, 5 deletions
diff --git a/src/plugins/snat/snat.h b/src/plugins/snat/snat.h
index 92b2f7eae80..49b6e374968 100644
--- a/src/plugins/snat/snat.h
+++ b/src/plugins/snat/snat.h
@@ -226,7 +226,8 @@ typedef u32 snat_icmp_match_function_t (struct snat_main_s *sm,
u8 *p_proto,
snat_session_key_t *p_value,
u8 *p_dont_translate,
- void *d);
+ void *d,
+ void *e);
typedef u32 (snat_get_worker_function_t) (ip4_header_t * ip, u32 rx_fib_index);
@@ -404,19 +405,27 @@ typedef struct {
u32 icmp_match_in2out_fast(snat_main_t *sm, vlib_node_runtime_t *node,
u32 thread_index, vlib_buffer_t *b0, u8 *p_proto,
snat_session_key_t *p_value,
- u8 *p_dont_translate, void *d);
+ u8 *p_dont_translate, void *d, void *e);
u32 icmp_match_in2out_slow(snat_main_t *sm, vlib_node_runtime_t *node,
u32 thread_index, vlib_buffer_t *b0, u8 *p_proto,
snat_session_key_t *p_value,
- u8 *p_dont_translate, void *d);
+ u8 *p_dont_translate, void *d, void *e);
+u32 icmp_match_in2out_det(snat_main_t *sm, vlib_node_runtime_t *node,
+ u32 thread_index, vlib_buffer_t *b0, u8 *p_proto,
+ snat_session_key_t *p_value,
+ u8 *p_dont_translate, void *d, void *e);
u32 icmp_match_out2in_fast(snat_main_t *sm, vlib_node_runtime_t *node,
u32 thread_index, vlib_buffer_t *b0, u8 *p_proto,
snat_session_key_t *p_value,
- u8 *p_dont_translate, void *d);
+ u8 *p_dont_translate, void *d, void *e);
u32 icmp_match_out2in_slow(snat_main_t *sm, vlib_node_runtime_t *node,
u32 thread_index, vlib_buffer_t *b0, u8 *p_proto,
snat_session_key_t *p_value,
- u8 *p_dont_translate, void *d);
+ u8 *p_dont_translate, void *d, void *e);
+u32 icmp_match_out2in_det(snat_main_t *sm, vlib_node_runtime_t *node,
+ u32 thread_index, vlib_buffer_t *b0, u8 *p_proto,
+ snat_session_key_t *p_value,
+ u8 *p_dont_translate, void *d, void *e);
static_always_inline u8
icmp_is_error_message (icmp46_header_t * icmp)