Created
March 26, 2014 14:57
-
-
Save jalal/9785258 to your computer and use it in GitHub Desktop.
Short piece of Apache config to stop Wordpress brute force login attempts (for .htaccess)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# added by jalal to stop brute force login attempts | |
RewriteCond %{REQUEST_METHOD} POST | |
RewriteCond %{REQUEST_URI} .(wp-comments-post|wp-login)\.php* | |
RewriteCond %{HTTP_REFERER} !.*domain.com.* [OR] | |
RewriteCond %{HTTP_USER_AGENT} ^$ | |
RewriteRule (.*) http://%{REMOTE_ADDR}/$ [R=301,L] | |
# end brute force handling |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment