1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-07-10 19:43:13 +02:00

Protect 2 more commands against rogue server to server traffic.

This commit is contained in:
Bram Matthys
2019-02-11 08:47:51 +01:00
parent 294560f944
commit c6f01aa3f1
2 changed files with 7 additions and 1 deletions
+4 -1
View File
@@ -354,11 +354,14 @@ CMD_FUNC(m_cap)
{
struct clicap_cmd *cmd;
if (!MyConnect(sptr))
return 0;
/* CAP is marked as "no fake lag" because we use custom fake lag rules:
* Only add a 1 second fake lag penalty if this is the XXth command.
* This will speed up connections considerably.
*/
if (MyConnect(sptr) && (sptr->local->receiveM > 15))
if (sptr->local->receiveM > 15)
cptr->local->since++;
if (DISABLE_CAP)
+3
View File
@@ -99,6 +99,9 @@ CMD_FUNC(m_watch)
int awaynotify = 0;
int did_l=0, did_s=0;
if (!MyClient(sptr))
return 0;
if (parc < 2)
{
/*