Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/SoftEtherVPN/SoftEtherVPN_Stable.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordnobori <da.git@softether.co.jp>2021-08-15 19:13:46 +0300
committerdnobori <da.git@softether.co.jp>2021-08-15 19:13:46 +0300
commit005285bf4326276fc58aa2a03b90f8020302638f (patch)
tree1d8aa745f8ffab99dbb7fcb05566e03dff2733c6 /src/Cedar/Logging.c
parentddc99f085fd6c54feaf4e41912bc8ab5903bdf8e (diff)
v4.37-9758-betav4.37-9758-beta
Diffstat (limited to 'src/Cedar/Logging.c')
-rw-r--r--src/Cedar/Logging.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/Cedar/Logging.c b/src/Cedar/Logging.c
index 9ec6a5a0..34060308 100644
--- a/src/Cedar/Logging.c
+++ b/src/Cedar/Logging.c
@@ -1147,11 +1147,23 @@ bool PacketLog(HUB *hub, SESSION *src_session, SESSION *dest_session, PKT *packe
if (src_session != NULL && src_session->NormalClient)
{
StrCpy(pl->SrcPhysicalIP, sizeof(pl->SrcPhysicalIP), src_session->ClientIP);
+ if (src_session->ClientPort != 0)
+ {
+ char tmp[32] = {0};
+ Format(tmp, sizeof(tmp), "(port=%u)", src_session->ClientPort);
+ StrCat(pl->SrcPhysicalIP, sizeof(pl->SrcPhysicalIP), tmp);
+ }
}
if (dest_session != NULL && dest_session->NormalClient)
{
StrCpy(pl->DestPhysicalIP, sizeof(pl->DestPhysicalIP), dest_session->ClientIP);
+ if (dest_session->ClientPort != 0)
+ {
+ char tmp[32] = {0};
+ Format(tmp, sizeof(tmp), "(port=%u)", dest_session->ClientPort);
+ StrCat(pl->DestPhysicalIP, sizeof(pl->DestPhysicalIP), tmp);
+ }
}
pl->WritePhysicalIP = true;