summaryrefslogtreecommitdiffstats
path: root/src/plugins/cnat/cnat_node_snat.c
diff options
context:
space:
mode:
authorNathan Skrzypczak <nathan.skrzypczak@gmail.com>2020-09-08 15:16:08 +0200
committerDave Barach <openvpp@barachs.net>2020-09-25 19:55:39 +0000
commitece39214bcb05c535ba5de9af97b5f84f6911cba (patch)
treef7c606d8fb1b880d59f150fdfcd9ab1f17da9b1d /src/plugins/cnat/cnat_node_snat.c
parent277d402bee6f4ad0ffe185515de44e6457a57a9e (diff)
cnat: Ip ICMP error support
Type: feature Add CNAT translation for ICMP 4 & 6 errors inner packet will be translated according to existing sessions. Change-Id: If118751988f44ef96b800878596296d1ab8ab6f8 Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
Diffstat (limited to 'src/plugins/cnat/cnat_node_snat.c')
-rw-r--r--src/plugins/cnat/cnat_node_snat.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/cnat/cnat_node_snat.c b/src/plugins/cnat/cnat_node_snat.c
index cc1421be084..aaa9e162ef0 100644
--- a/src/plugins/cnat/cnat_node_snat.c
+++ b/src/plugins/cnat/cnat_node_snat.c
@@ -81,7 +81,8 @@ cnat_snat_inline (vlib_main_t * vm,
vnet_feature_next (&arc_next0, b);
next0 = arc_next0;
- if (iproto != IP_PROTOCOL_UDP && iproto != IP_PROTOCOL_TCP)
+ if (iproto != IP_PROTOCOL_UDP && iproto != IP_PROTOCOL_TCP
+ && iproto != IP_PROTOCOL_ICMP && iproto != IP_PROTOCOL_ICMP6)
{
/* Dont translate */
goto trace;