I saw this problems half a year ago – I saw in my logs that thousands of thousands POST requests from a botnet were made. Luckily my clients didn’t needed the email share feature so I disabled it. To reduce the server load (because POST requests aren’t cached by the Cachify plugin) I wrote a small htaccess snippet to block the requests (ending in a 403 response). This solved the problem itself but the requests from the botnet didn’t stop.
So I wrote a small fail2ban filter to block access to the whole server via iptables. Within minutes, over 1000 IP addresses were blocked … and counting.
The user agent string is on every request the same:
Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.99 Safari/537.36
Here a request from my log file:
XXX.XXX.XXX.XXX - - [11/Apr/2017:11:22:26 +0200] "POST https://URL/?share=email&nb=1 HTTP/1.1" 403 270 "https://URL/?share=email&nb=1" "Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.99 Safari/537.36"
Here is a list with a bunch of IPs: you can clearly see that most IPs are from the same range (from china): https://pastebin.com/msgNmrqS
I hope this can help to find a suitable solution.
-
This reply was modified 7 years, 7 months ago by pixelbargmbh.
-
This reply was modified 7 years, 7 months ago by pixelbargmbh.