0

So I tried using this in the httpd conf at the bottom of the config file. My goal is to have this rule whitelist the wordpress admin to certain ip addresses. We have a quite a few installs on the server and want to protect this. However when placed, it doesn't recognize the rule and over looks it completely. I've tested it in a virtual hosts .htaccess file to verify the code is working

<FilesMatch "^wp\-login">
order deny,allow
deny from all
allow from 1.2.3.4
</FilesMatch>

Any help is appriciated. Bonus point if someone can get it to redirect the user else where as well. Thanks

Alex Bloom
  • 83
  • 1
  • 1
  • 7

1 Answers1

0

use this directive and try

<Files wp-admin.php>
Order allow,deny
Deny from all
</Files> 

or

<Files wp/-admin.php>
Order allow,deny
Deny from all
</Files> 
0xSAM
  • 39
  • 7