Knowledgebase

Restricting image directory script execution with DirectoryMatch or mod rewrite

Posted by tvcnet, 03-19-2010, 06:35 PM
Hi folks, Just stumped on this one and wondering if we have any mod rewrite or .htaccess editing experts out there. My goal is to have one entry in the public_html/.htaccess file which prevents scripts from executing (to keep the hackers out). Placing a .htaccess file with the restrictions in each directory is easy enough to do, but my goal here is to do it account wide. I tried the below but just can't seem to get it working. Any ideas anyone? AllowOverride None Addhandler text/plain .pl .cgi .php .py .jsp .asp .shtml .sh php_admin_flag engine off This is supposed to ensure all directories within account directories named /images will turn scripts into text so they wont' execute. I suppose you can do the same with mod redirect but the thought gives me a headache... Ideas? Many thanks, Jim



Was this answer helpful?

Add to Favourites Add to Favourites

Print this Article Print this Article

Also Read


Language:

Client Login

Email

Password

Remember Me

Search