I try to configure a simple block of an IP address in my .htaccess. I followed examples I found here in this forum, that seemed to work fine for other users, but do not work for me and I really don't get why.
My .htaccess file :
Order Allow,Deny
Allow from all
Deny from aaa.bbb.ccc.ddd
I expect that the configured IP address (aaa.bbb.ccc.ddd) will be blocked. But unfortunately it is not blocked.
If I set 'Deny from all' in the third line of my .htaccess, all access is blocked as expected.
My website uses the cloudflare, so I think the possible reason is that apache cannot get the real IP of the visitor,so I install the mod_remoteip through the easyapche4 as the cloudflare suggest:
[root@cento-001 ~]# httpd -M | grep remoteip
remoteip_module (shared)
but still do not work for me.
I appreciate any help, pointing me in the right direction.
Thanks~
My .htaccess file :
Order Allow,Deny
Allow from all
Deny from aaa.bbb.ccc.ddd
I expect that the configured IP address (aaa.bbb.ccc.ddd) will be blocked. But unfortunately it is not blocked.
If I set 'Deny from all' in the third line of my .htaccess, all access is blocked as expected.
My website uses the cloudflare, so I think the possible reason is that apache cannot get the real IP of the visitor,so I install the mod_remoteip through the easyapche4 as the cloudflare suggest:
[root@cento-001 ~]# httpd -M | grep remoteip
remoteip_module (shared)
but still do not work for me.
I appreciate any help, pointing me in the right direction.
Thanks~