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've been tasked with adding Trac to an existing Apache instance. In trying to set up authentication, I've discovered that we allow folks coming from our internal IP to bypass authentication. I need to undo that within the /trac location. Given the below config fragment, how can I do that?

  <Directory /var/www/tools.example.com/public_html>
    Options -Indexes FollowSymLinks MultiViews
    AllowOverride None
    Order Allow,Deny
    AuthUserFile /var/www/users.auth
    AuthGroupFile /var/www/groups.auth
    AuthName "Please log in"
    AuthType Basic
    Require valid-user
    Allow from {some-ip}
    Satisfy Any
  </Directory>

  …

  # For trac
  WSGIScriptAlias /trac /var/www/tools.example.com/public_html/trac/cgi-bin/trac.wsgi
  <Location "/trac/login">
    AuthType Basic
    AuthName "Please log in to trac"
    AuthUserFile /var/www/trac.htpasswd
    Require valid-user
  </Location>

Is there some way I can unset the "Allow from all" just within /trac?

share|improve this question

migrated from webmasters.stackexchange.com Dec 14 '11 at 4:02

This question came from our site for pro webmasters.

1 Answer 1

up vote 1 down vote accepted

Instead of "Satisfy Any" in the general rule, add a Satisfy All in your /trac so that it requires both conditions.

Reference: http://httpd.apache.org/docs/2.2/mod/core.html#satisfy

share|improve this answer

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.