logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: combining multiple access conditions [closed]
Author
weedukind



Joined: 27 Jun 2016
Posts: 1
Location: Munich

PostPosted: Mon 27 Jun '16 10:57    Post subject: combining multiple access conditions [closed] Reply with quote

[closed]

Hi,

I try to add an exception to the access conditions, but it is ignored. .htaccess looks like this:

Code:

AuthName "test"
AuthType Basic
AuthUserFile /path/.htpasswd
Require valid-user
Satisfy any

SetEnvIf HOST "^www.domain.fr" block

Order deny,allow

Deny from env=block


All domains are served except of www.domain.fr, which requires user/password, which works fine.


I added two lines in order to allow .png files to be served by www.domain.fr:

Code:

AuthName "test"
AuthType Basic
AuthUserFile /path/.htpasswd
Require valid-user
Satisfy any

SetEnvIf HOST "^www.domain.fr" block
SetEnvIf Request_URI "\.png$" image # <= new line 1

Order deny,allow

Deny from env=block
Allow from env=image # <= new line 2


Unfortunatly these lines are ignored and .png-files are still protected.

Can anyone tell me, what I am doing wrong?
Back to top


Reply to topic   Topic: combining multiple access conditions [closed] View previous topic :: View next topic
Post new topic   Forum Index -> Apache