1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2025-07-14 19:54:57 +03:00

Cedar: handle UDP acceleration and R-UDP versions

This commit is contained in:
dnobori
2019-11-22 00:51:09 +01:00
committed by Davide Beatrici
parent 6b08a451da
commit 1d2a58b172
9 changed files with 252 additions and 48 deletions

View File

@ -5822,8 +5822,22 @@ void CiGetSessionStatus(RPC_CLIENT_GET_CONNECTION_STATUS *st, SESSION *s)
StrCpy(st->ProtocolDetails, sizeof(st->ProtocolDetails), s->ProtocolDetails);
Trim(st->ProtocolDetails);
// UDP acceleration function
st->IsUdpAccelerationEnabled = s->UseUdpAcceleration;
st->IsUsingUdpAcceleration = s->IsUsingUdpAcceleration;
if (s->IpcSessionShared != NULL && IsEmptyStr(s->IpcSessionShared->ProtocolDetails) == false)
{
char tmp[sizeof(s->IpcSessionShared->ProtocolDetails)];
StrCpy(tmp, sizeof(tmp), s->IpcSessionShared->ProtocolDetails);
Trim(tmp);
StrCat(st->ProtocolDetails, sizeof(st->ProtocolDetails), " ");
StrCat(st->ProtocolDetails, sizeof(st->ProtocolDetails), tmp);
st->IsUdpAccelerationEnabled = s->IpcSessionShared->EnableUdpAccel;
st->IsUsingUdpAcceleration = s->IpcSessionShared->UsingUdpAccel;
}
else
{
st->IsUdpAccelerationEnabled = s->UseUdpAcceleration;
st->IsUsingUdpAcceleration = s->IsUsingUdpAcceleration;
}
// Session key
Copy(st->SessionKey, s->SessionKey, SHA1_SIZE);
// Policy