main icon indicating copy to clipboard operation
main copied to clipboard

mod rate limiting

Open raf924 opened this issue 4 years ago • 1 comments

Noticed something earlier today. I was testing a bot and I had messed up the joining process so it spammed hc and was rate-limited as it should be. Then when I tried to speak on programming with my mod user (which was connected during the aforementioned testing) was also rate-limited which was undesirable.

So I guess what I'm asking is to for hc to check for mod status before checking the IP (or the hash? idk).

Also maybe, let the mods enable/disable rate-limiting for all mods so as to avoid the previous JBot situations.

All my love.

raf924 avatar Nov 26 '20 19:11 raf924

Atm, the "mods don't get ratelimited" feature isn't part of the official release. It's been part of prod for long enough that I think it'd be safe enough to add into the official source.

The current implementation is amazingly hacky. What I think we should do is pass the socket reference over to the frisk function (instead of passing just the ip address), that way the join function can apply some special boolean property to the socket. frisk can then check this property before proceeding and also pull the address.

marzavec avatar Dec 03 '20 03:12 marzavec