Reputation: 1
Im building a RPMpackage which has to protect Apache hosted websites
I want to protect the CPU and Apache when someone is scanning the website. I want the visitor to get a 403 before it hits the virtualhosts even if the file/directory exists or not.
Currently i have this setup:
<DirectoryMatch "^/.*/.git/">Deny from all</Directorymatch>
<Files ~ "^.git">Order allow,denyDeny from all</Files>
This protects existing files directories and scripts. Bit i would like for Apache to throw the 403 error even when the files dont exist in order to protect apache/php/mysql
Is this possible?
I tried directory / directorymatch and the files directives in apache
they only protect the website when the files or directories do exist on the server
Upvotes: 0
Views: 17