You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Jake Garfield <jg...@earthlink.net> on 2009/02/18 12:47:45 UTC

[users@httpd] turn off basic authentication for one file

Please forgive me if this is a dumb question, but is there a way to turn off basic authentication for ONE file?  I suppose there is some type of .htaccess syntax for that. How would I do that?

thanks,
-jg






---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] turn off basic authentication for one file

Posted by Peter Schober <pe...@univie.ac.at>.
* André Warnier <aw...@ice-sa.com> [2009-02-18 18:18]:
> I don't think it is a dumb question, because authentication tends to be  
> "sticky", and there are no directives like
> AuthType None
> or
> Require None
> or
> Satisfy nothing

But 

<Files somefile>
  Allow from all
  Satisfy any
</Files>

should do, even if this is within a protected Directory, Location, etc.

cheers,
-peter

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] turn off basic authentication for one file

Posted by André Warnier <aw...@ice-sa.com>.
Jake Garfield wrote:
> Please forgive me if this is a dumb question, but is there a way to turn off basic authentication for ONE file?  I suppose there is some type of .htaccess syntax for that. How would I do that?
> 
I don't think it is a dumb question, because authentication tends to be 
"sticky", and there are no directives like
AuthType None
or
Require None
or
Satisfy nothing

If you authentication is not set at the document root level ("/"), then 
you could try the following or some variation :

Alias /secure/my_file.html /var/www/htdocs/free/my_file.html

<Location /secure>
   (authentication)
...
</Location>

<Directory /var/www/htdocs/free>
(no authentication)
Allow from all
</Directory>



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org