Empty User Agents still hitting
-
Even though we are running iThemes Security we are still getting lots of hits from individual IP’s to our wp-login.php on a bunch of our wordpress sites. One thing I noticed in all cases is there is no user-agent when I look at the latest visitors in cpanel from those IP’s.
We changed our wp-login.php to be something else in iThemes but the bots still go to wp-login.php. It shows 404. However, we still see the attempts and they are not stopped for hitting a 404 page too many times.
We track the problems on our server using SSH. Example:
grep "POST /wp-login.php" /home/*/access-logs/* | grep “1/Jan/2015” |cut -d/ -f5|cut -d: -f1|sort|uniq -c|sort -n|tail
For domains affected and
grep "POST /wp-login.php" /home/*/access-logs/* | grep “1/Jan/2015” |awk '{print $1}'|cut -d: -f2|sort|uniq -c|sort -n|tail
For IP’s to block.I tried a couple items in the .htaccess that should ban anyone hitting the site with no user-agent but it does not seem to work to stop it. We’ve tried Wordfence to throttle and block (including 404’s by humans and bots over a certain number) and that does not stop them either. We have even gone as far as to create double logins using .htaccess and SSH to set users and passwords. That can’t be done on all websites as it is a pain for our clients. That did not stop it in the middle of an incident either. Not sure if that only prevents new IP’s from attempting to go to that page or not.
So, what is the answer? It seems to me that simply being able to block any IP that access any page on your website more than X number of times would work. You could get complex and make it selected pages but even the Google Bot isn’t going to exceed the 40 and 50 thousand hits we are seeing over night.
Any ideas?
- The topic ‘Empty User Agents still hitting’ is closed to new replies.