Geek pop quiz.
Jan. 16th, 2007 04:22 pmHave a server running Apache 2.
HTAccess files are enabled. Password protection is working just fine in every way right now. mod_access is installed.
I want to deny all access from a domain name or IP range, without disabling the password protection.
The docs all say I should add
When I add this to the .htaccess file, I get a "500 internal server error" on that folder and all subfolders. Removing it again makes things work. The same thing applies for just about every other configuration of allow/deny I try. For example,
The same behaviour happens when I stick the commands under the Directory section of httpd.conf and make Apache reload it: 500 internal server error.
Any thoughts?
HTAccess files are enabled. Password protection is working just fine in every way right now. mod_access is installed.
I want to deny all access from a domain name or IP range, without disabling the password protection.
The docs all say I should add
Order Allow,Deny
Deny from baddomainname.com
Allow from all
When I add this to the .htaccess file, I get a "500 internal server error" on that folder and all subfolders. Removing it again makes things work. The same thing applies for just about every other configuration of allow/deny I try. For example,
order deny,allowproduces the same result: 500 internal server error. This happens whether I disable the password protection or not.
deny from baddomainname.com
The same behaviour happens when I stick the commands under the Directory section of httpd.conf and make Apache reload it: 500 internal server error.
Any thoughts?
(no subject)
Date: 2007-01-16 09:34 pm (UTC)(no subject)
Date: 2007-01-16 09:39 pm (UTC)Order Allow,Deny
Allow from all
Deny from foo.apache.org
(no subject)
Date: 2007-01-16 09:42 pm (UTC)(no subject)
Date: 2007-01-16 09:43 pm (UTC)(no subject)
Date: 2007-01-16 09:43 pm (UTC)(Same results from that configuration, too)
(no subject)
Date: 2007-01-16 10:00 pm (UTC)Order Allow,Deny
Allow from all
Deny from 192.168.2.101
Where my local ip address for my workstation is 192.168.2.101, and it still got through.
Maybe you're missing a module or something here?
(no subject)
Date: 2007-01-16 10:36 pm (UTC)(no subject)
Date: 2007-01-16 10:54 pm (UTC)(no subject)
Date: 2007-01-17 12:08 am (UTC)(no subject)
Date: 2007-01-17 03:08 am (UTC)It adds/removes entries to your hosts.deny file based on ssh security log entries. You can deny IP addressess access to your box if they fail X number of ssh logins. Has a few other useful features too. Really cuts down on the brute force ssh attacks.
mine
Date: 2007-01-16 11:50 pm (UTC)Order Deny,Allow
Deny from env=cockbites
I've got a long list of these, which I use to block referrer spam.
Re: mine
Date: 2007-01-17 12:09 am (UTC)(no subject)
Date: 2007-01-17 12:49 am (UTC)A.
(no subject)
Date: 2007-01-17 02:06 am (UTC)So no typos, and no bad carriage returns or anything like that.
And I tried removing the password protection, too, leaving *just* the stuff from above, with no help.