1
0
mirror of https://github.com/SoftEtherVPN/SoftEtherVPN.git synced 2024-11-22 17:39:53 +03:00

Fix buffer overflow during NETBIOS name resolution

If SecureNAT is enabled and the hostname of the server
is longer than 16characters, every NETBIOS name resolution
query triggers the buffer overflow. If the server was built
with stack protection, the process will be killed.
This commit is contained in:
stffabi 2019-09-04 14:32:19 +02:00
parent 9e46402e6b
commit 850a5faa0d

View File

@ -6118,7 +6118,7 @@ void EncodeNetBiosName(UCHAR *dst, char *src)
copy_len = 16;
}
Copy(tmp, src, StrLen(src));
Copy(tmp, src, copy_len);
wp = 0;