homepage Welcome to WebmasterWorld Guest from 54.167.174.90
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
Forum Library, Charter, Moderators: Ocean10000 & incrediBILL & phranque

Apache Web Server Forum

    
formmail.pl Modification for .htaccess
request to path cgi-sys
nativenewyorker

10+ Year Member



 
Msg#: 162 posted 4:20 pm on Apr 10, 2003 (gmt 0)

key_master had posted the following last summer:

SetEnvIfNoCase Request_URI formmail ban
<Files ~ "\.cgi$\.pl$">
order deny,allow
deny from env=ban
</Files>

Until now it was stopping all requests to cgi-bin for formamail with a 301 Forbidden. However, requests to cgi-sys are passing through with a code 200. Does anyone have any ideas about how to modify the code above for .htaccess?

Thanks in advance,
Ted

 

marcs

10+ Year Member



 
Msg#: 162 posted 2:25 am on Apr 11, 2003 (gmt 0)

Do you by chance have this .htaccess file in your cgi-bin directory? If so, it would only affect files/requests in that directory.

If so, add it to the cgi-sys directory also.

nativenewyorker

10+ Year Member



 
Msg#: 162 posted 3:00 am on Apr 11, 2003 (gmt 0)

marcs,

From what I understand about .htaccess, it can only be placed in the root directory. As I mentioned, it has worked fine stopping requests to cgi-bin. Surprisingly, there is no cgi-sys directory.

Ted

marcs

10+ Year Member



 
Msg#: 162 posted 3:05 am on Apr 11, 2003 (gmt 0)

.htaccess affects the directory it is in (which can be any directory) and directories below it.

Not sure on your original question, hope someone can answer that for you. Looks to me like it should work. If there is no cgi-sys dir then they should get a 404 anyway.

nativenewyorker

10+ Year Member



 
Msg#: 162 posted 7:58 am on Apr 11, 2003 (gmt 0)

I meant 403 Forbidden, not 301.

Ted

nativenewyorker

10+ Year Member



 
Msg#: 162 posted 10:39 pm on Apr 12, 2003 (gmt 0)

Anyone have any suggestions on how to ban access to cgi-sys?

Thanks,
Ted

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved