diff options
author | Nathan Skrzypczak <nathan.skrzypczak@gmail.com> | 2021-10-14 18:41:57 +0300 |
---|---|---|
committer | Beno�t Ganne <bganne@cisco.com> | 2023-08-08 14:06:08 +0000 |
commit | 6631032791f842017c20ddf217e915c465ff809d (patch) | |
tree | 80c72dd02c55f96bed52821b9a24404599055166 /src/plugins/cnat/cnat_src_policy.c | |
parent | cad2111129b57c9c14f5c6bc645286fdc5bf4a3c (diff) |
cnat: flag to disable rsession
This adds a flag on the translation
asking the VIP & input-feature nodes
not to create the return session when
translating / load-balancing an incoming
flow. This is needed with maglev & DSR
Type: feature
Change-Id: I699012310ddc59f6ceeeb4878638eac6da5128dc
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
Diffstat (limited to 'src/plugins/cnat/cnat_src_policy.c')
-rw-r--r-- | src/plugins/cnat/cnat_src_policy.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/cnat/cnat_src_policy.c b/src/plugins/cnat/cnat_src_policy.c index cac24b7742c..8f3f3375148 100644 --- a/src/plugins/cnat/cnat_src_policy.c +++ b/src/plugins/cnat/cnat_src_policy.c @@ -59,8 +59,8 @@ cnat_vip_default_source_policy (vlib_main_t * vm, u16 sport; sport = udp0->src_port; /* Allocate a port only if asked and if we actually sNATed */ - if ((ct->flags & CNAT_TRANSLATION_FLAG_ALLOCATE_PORT) - && (*rsession_flags & CNAT_SESSION_FLAG_HAS_SNAT)) + if ((ct->flags & CNAT_TR_FLAG_ALLOCATE_PORT) && + (*rsession_flags & CNAT_SESSION_FLAG_HAS_SNAT)) { sport = 0; /* force allocation */ session->value.flags |= CNAT_SESSION_FLAG_ALLOC_PORT; |