Osman
Well-known member
Not entirely sure, but I just did a quickie fix and made my own cron for it, which does work. Could this type of approach be implemented into options to auto delete every x? Obviously this will stop working the moment I upgrade otherwise, and I don't want to adjust your addon code, I am just testing a solution to my problem.
Hey there,
Thanks for trying to help out with a fix! I took a look at your
ClearAll code, and honestly, I have to strongly advise against using it.
The issue is that DELETE ... 1=1 wipes everything indiscriminately. So, if you've banned an attacker for 24 hours and your cron runs at hour 12, that attacker gets released early. Plus, it nukes your entire Whitelist and all your attack statistics. You’d be solving one problem but creating several new security holes.
Good News: We're about to release version 1.0.26, which fixes this performance bottleneck properly at the source. We've completely refactored the query logic, so it runs instantly even with millions of records. We've also built in the "Auto-Prune" (Retention) feature you were looking for—but ours is smart enough to clean up old junk without touching active bans.
So, please disable your custom cron job and hang tight for the official update. It’s safer and does exactly what you need.