mirror of
https://github.com/SoftEtherVPN/SoftEtherVPN.git
synced 2026-02-20 01:20:09 +03:00
Merge pull request #2181 from jgrasboeck/fix_openvpn_auth_failed_reply
Openvpn: only send AUTH_FAILED reply on auth errors
This commit is contained in:
@ -2562,9 +2562,16 @@ void OvsRecvPacket(OPENVPN_SERVER *s, LIST *recv_packet_list, UINT protocol)
|
|||||||
Debug("OpenVPN Channel %u Failed.\n", j);
|
Debug("OpenVPN Channel %u Failed.\n", j);
|
||||||
OvsLog(s, se, c, "LO_CHANNEL_FAILED");
|
OvsLog(s, se, c, "LO_CHANNEL_FAILED");
|
||||||
|
|
||||||
// Return the AUTH_FAILED
|
if ((se->IpcAsync->ErrorCode == ERR_AUTHTYPE_NOT_SUPPORTED) ||
|
||||||
str = "AUTH_FAILED";
|
(se->IpcAsync->ErrorCode == ERR_AUTH_FAILED) ||
|
||||||
WriteFifo(c->SslPipe->SslInOut->SendFifo, str, StrSize(str));
|
(se->IpcAsync->ErrorCode == ERR_PROXY_AUTH_FAILED) ||
|
||||||
|
(se->IpcAsync->ErrorCode == ERR_USER_AUTHTYPE_NOT_PASSWORD) ||
|
||||||
|
(se->IpcAsync->ErrorCode == ERR_NOT_SUPPORTED_AUTH_ON_OPENSOURCE))
|
||||||
|
{
|
||||||
|
// Return the AUTH_FAILED
|
||||||
|
str = "AUTH_FAILED";
|
||||||
|
WriteFifo(c->SslPipe->SslInOut->SendFifo, str, StrSize(str));
|
||||||
|
}
|
||||||
|
|
||||||
s->SessionEstablishedCount++;
|
s->SessionEstablishedCount++;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user