I have a Wordpress site on a VPS which keeps getting attached on xmlrpc and wp logins. As part of combatting this I password protected the wp-admin directory (via Cpanel 'Directory Privacy') - but when I go to test it I get browsers not loading the page due to 'too many redirects' (Safari and Chrome). As a plan B I've installed a WP plugin to rename the wp-admin address, but logging in to that redirects back to the same login page instead of successfully going to the dashboard, which also seems like a redirection. Any possible solutions or logs I can look in that might shed some light?
2 Answers
Password protecting the wp-admin directory is not very helpful because wp-admin redirecting to yourdomain.com/wp-login.php
It is best to use two steps authentication or limit the number of login attempts.
-
OK, so its behaving as you'd expect - not an error? Think I;ll go and leave a comment on the website that suggested it! Thanks!– iain-gFeb 23, 2017 at 16:20
The "too many redirects" error can happen depending on server settings. The way to fix it is:
- Find the .htaccess file in your Wordpress installation (by default it'll be in the document root).
Edit this file, by adding the below line to it:
ErrorDocument 401 default