aboutsummaryrefslogtreecommitdiffstats
path: root/src/vcl/vcl_private.h
diff options
context:
space:
mode:
authorqinyang <qiny@yusur.tech>2023-06-27 01:11:53 -0700
committerFlorin Coras <florin.coras@gmail.com>2023-07-21 16:27:14 +0000
commitaf9b7156c8fd16c671ce9332613faaf864b075b3 (patch)
tree201f45dacba23771db635c563b34315b6594d4af /src/vcl/vcl_private.h
parentae916b39049669bbada12dbcfecbb4e3f9c09c69 (diff)
vcl: ldp support SO_ORIGINAL_DST
Type: improvement Support SO_ORIGINAL_DST socket option to get original dst_ip4 and dst_port if nat44 rule enabled. Change-Id: If00e00d03e48f3b78a23a68f1b078954d79dd0f7 Signed-off-by: qinyang <qiny@yusur.tech>
Diffstat (limited to 'src/vcl/vcl_private.h')
-rw-r--r--src/vcl/vcl_private.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vcl/vcl_private.h b/src/vcl/vcl_private.h
index 39a0f05034f..8345e34e0c1 100644
--- a/src/vcl/vcl_private.h
+++ b/src/vcl/vcl_private.h
@@ -180,6 +180,9 @@ typedef struct vcl_session_
#if VCL_ELOG
elog_track_t elog_track;
#endif
+
+ u16 original_dst_port; /**< original dst port (network order) */
+ u32 original_dst_ip4; /**< original dst ip4 (network order) */
} vcl_session_t;
typedef struct vppcom_cfg_t_
@@ -208,6 +211,7 @@ typedef struct vppcom_cfg_t_
u32 tls_engine;
u8 mt_wrk_supported;
u8 huge_page;
+ u8 app_original_dst;
} vppcom_cfg_t;
void vppcom_cfg (vppcom_cfg_t * vcl_cfg);