mirror of
https://github.com/SoftEtherVPN/SoftEtherVPN.git
synced 2024-11-22 17:39:53 +03:00
Peer info optional in OvsParseKeyMethod2()
This commit is contained in:
parent
462840cf6e
commit
78bcc07fa9
@ -1151,14 +1151,17 @@ UINT OvsParseKeyMethod2(OPENVPN_KEY_METHOD_2 *ret, UCHAR *data, UINT size, bool
|
|||||||
// Random2
|
// Random2
|
||||||
if (ReadBuf(b, ret->Random2, sizeof(ret->Random2)) == sizeof(ret->Random2))
|
if (ReadBuf(b, ret->Random2, sizeof(ret->Random2)) == sizeof(ret->Random2))
|
||||||
{
|
{
|
||||||
// String
|
// String
|
||||||
if (OvsReadStringFromBuf(b, ret->OptionString, sizeof(ret->OptionString)) &&
|
if (OvsReadStringFromBuf(b, ret->OptionString, sizeof(ret->OptionString)) &&
|
||||||
OvsReadStringFromBuf(b, ret->Username, sizeof(ret->Username)) &&
|
OvsReadStringFromBuf(b, ret->Username, sizeof(ret->Username)) &&
|
||||||
OvsReadStringFromBuf(b, ret->Password, sizeof(ret->Password)) &&
|
OvsReadStringFromBuf(b, ret->Password, sizeof(ret->Password)))
|
||||||
OvsReadStringFromBuf(b, ret->PeerInfo, sizeof(ret->PeerInfo)))
|
{
|
||||||
{
|
if (!OvsReadStringFromBuf(b, ret->PeerInfo, sizeof(ret->PeerInfo)))
|
||||||
read_size = b->Current;
|
{
|
||||||
}
|
Zero(ret->PeerInfo, sizeof(ret->PeerInfo));
|
||||||
|
}
|
||||||
|
read_size = b->Current;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user