apache authentication exclude directory

Posted on 2009-12-21
Last Modified: 2012-06-22

I have authentication on a virtual host in apache:
<Directory "/var/www/html/john">
AuthType Basic
AuthName "Restricted Files"
AuthUserFile /etc/httpd/conf/access
Require user John

inside this virtualhost is a folder called Files

How can I exclude the authentication from the Files directory?

I want unrestricted access to /Files, but the authentication must apply to everything else
Question by:zattz
    1 Comment
    LVL 15

    Accepted Solution

    I assume you already have authentication setup for everything else?

    In you Files directory create an ".htaccess" file with the following contents:
    Allow from all
    Satisfy Any

    Open in new window


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    6 Surprising Benefits of Threat Intelligence

    All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

    Over the last year I have answered a couple of basic URL rewriting questions several times so I thought I might as well have a stab at: explaining the basics, providing a few useful links and consolidating some of the most common queries into a sing…
    It is possible to boost certain documents at query time in Solr. Query time boosting can be a powerful resource for finding the most relevant and "best" content. Of course the more information you index, the more fields you will be able to use for y…
    Hi everyone! This is Experts Exchange customer support.  This quick video will show you how to change your primary email address.  If you have any questions, then please Write a Comment below!
    In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now