Find the answer to your Linux question:
Results 1 to 2 of 2
I want to password protect my site. I followed the instructions at http://httpd.apache.org/docs/howto/auth.html , but I still am not prompted for a username/password. Yes, I have both restarted apache and ...
  1. #1
    Just Joined!
    Join Date
    Mar 2005
    Location
    San Francisco, CA
    Posts
    1

    Apache Authentication/Authorization woes (Debian Woody)



    I want to password protect my site. I followed the instructions at http://httpd.apache.org/docs/howto/auth.html , but I still am not prompted for a username/password. Yes, I have both restarted apache and my server.

    In my httpd.conf I have:
    <Directory />
    Options SymLinksIfOwnerMatch
    AllowOverride AuthConfig
    AuthType Basic
    AuthName "MySite.Net Authentication"
    AuthUserFile /var/www/.htpasswd
    Require user smaccdev
    </Directory>

    /var/www/.htaccess:
    AuthType Basic
    AuthName "MySite.Net"
    AuthUserFile /var/www/.htpasswd
    Require user testuser

    /var/www/.htpasswd:
    testuserencrypted password gobbledygook)

    Using apache 1.3 on a pretty vanilla install of Debian Woody.

    Thanks for the help!

  2. #2
    Just Joined!
    Join Date
    Jul 2004
    Location
    MN USA
    Posts
    70

    auth problem

    Did you make sure your .htpasswd has the correct permissions and owner to allow the web server to read it?

    Also, is there a reason you have the authorization info for /var/www in the <directory> section and override in an .htaccess file? I use basic auth, but it's all setup in the directory section of httpd.conf. You should be able to dump the .htaccess file without a problem. (just make sure BOTH users are in the list for httpd.conf)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •