Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm trying to convert some rules and settings from Apache to lighttpd but i'm stuck with this Files rule:

<Directory /var/www/html/attachments>  
<Files ~ "\.(php\d*|cgi|pl|phtml)$">  
   order allow,deny  
   deny from all  
</Files>  
</Directory> 

Looking at the documentation i could see that i can use the url.access-deny.

$HTTP["url"] =~ "^/var/www/html/attachments" {
url.access-deny = ("")
}

But don't know how to convert the Files part, any idea?

Thanks!

share|improve this question
add comment

1 Answer

This should work:

$PHYSICAL["path"] =~ "\.(php\d*|cgi|pl|phtml)$" {
        access.deny-all = "enable" 
}
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.