1
0
Fork 0
forked from External/ergo
This commit is contained in:
Shivaram Lingamneni 2019-05-22 22:16:01 -04:00
parent 678c8606b6
commit dcb3487566
3 changed files with 19 additions and 1 deletions

View file

@ -574,6 +574,13 @@ func capHandler(server *Server, client *Client, msg ircmsg.IrcMessage, rb *Respo
}
}
// #511: oragono.io/nope is a fake cap to trap bad clients who blindly request
// every offered capability:
if toAdd.Has(caps.Nope) {
client.Quit(client.t("Requesting the oragono.io/nope CAP is forbidden"), rb.session)
return true
}
// update maxlenrest, just in case they altered the maxline cap
rb.session.SetMaxlenRest()