Networking Forums

Networking Forums > Computer Networking > Linux Networking > Need help setting up User Auth w/ apache

Reply
Thread Tools Display Modes

Need help setting up User Auth w/ apache

 
 
ed west
Guest
Posts: n/a

 
      02-24-2004, 04:51 PM
Hello,

I am having some trouble getting user authentication on apache
working. I am using apache 2.0.40 on RedHat 9, kernel version
2.4.20-20.9. I made a password file .htpasswd with htpasswd, chown
apache.apache, made sure the directory it is in is world readable, and
made the changes to httpd.conf (and restarted apache).

<Directory /www/somedir/bla/hblah/blah/phpMyAdmin>
AuthType Basic
AuthName "phpMyAdmin"
AuthUserFile /www/somedir/.htpasswd
require valid-user
</Directory>

I get the following error - any suggestions? Do I have to do
something with Limit? Thanks!!

401 Authorization Required
Authorization Required

This server could not verify that you are authorized to access the
document requested. Either you supplied the wrong credentials (e.g.,
bad password), or your browser doesn't understand how to supply the
credentials required.

Additionally, a 404 Not Found error was encountered while trying to
use an ErrorDocument to handle the request.
 
Reply With Quote
 
 
 
 
David Efflandt
Guest
Posts: n/a

 
      02-25-2004, 09:31 AM
On 24 Feb 2004 09:51:21 -0800, ed west <(E-Mail Removed)> wrote:
> Hello,
>
> I am having some trouble getting user authentication on apache
> working. I am using apache 2.0.40 on RedHat 9, kernel version
> 2.4.20-20.9. I made a password file .htpasswd with htpasswd, chown
> apache.apache, made sure the directory it is in is world readable, and
> made the changes to httpd.conf (and restarted apache).


Does .htpasswd have 644 permission (or at least 604)? Is the dir 755?
You mention read permission (which allows dir listing), but dir needs 'x'
permission to access it. Apparently there is also a problem with your
ErrorDocument. What do your server logs say?

><Directory /www/somedir/bla/hblah/blah/phpMyAdmin>
> AuthType Basic
> AuthName "phpMyAdmin"
> AuthUserFile /www/somedir/.htpasswd
> require valid-user
></Directory>
>
> I get the following error - any suggestions? Do I have to do
> something with Limit? Thanks!!


No you do not need Limit to password protect all access to that path

> 401 Authorization Required
> Authorization Required
>
> This server could not verify that you are authorized to access the
> document requested. Either you supplied the wrong credentials (e.g.,
> bad password), or your browser doesn't understand how to supply the
> credentials required.
>
> Additionally, a 404 Not Found error was encountered while trying to
> use an ErrorDocument to handle the request.



--
David Efflandt - All spam ignored http://www.de-srv.com/
http://www.autox.chicago.il.us/ http://www.berniesfloral.net/
 
Reply With Quote
 
ANdre H
Guest
Posts: n/a

 
      02-25-2004, 09:55 AM
This is an exemple,but look at AuthType, AuthUserFile AuthGrouFile !!
in a <Directory ... >
AuthName "Please enter your userID and password"
AuthType Basic
AuthUserFile /usr/apache/my/passwd
AuthGroupFile /usr//apachel/my/group

<Limit GET POST PUT>
require group AHuser
</Limit>
</Directory>
"ed west" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) m...
> Hello,
>
> I am having some trouble getting user authentication on apache
> working. I am using apache 2.0.40 on RedHat 9, kernel version
> 2.4.20-20.9. I made a password file .htpasswd with htpasswd, chown
> apache.apache, made sure the directory it is in is world readable, and
> made the changes to httpd.conf (and restarted apache).
>
> <Directory /www/somedir/bla/hblah/blah/phpMyAdmin>
> AuthType Basic
> AuthName "phpMyAdmin"
> AuthUserFile /www/somedir/.htpasswd
> require valid-user
> </Directory>
>
> I get the following error - any suggestions? Do I have to do
> something with Limit? Thanks!!
>
> 401 Authorization Required
> Authorization Required
>
> This server could not verify that you are authorized to access the
> document requested. Either you supplied the wrong credentials (e.g.,
> bad password), or your browser doesn't understand how to supply the
> credentials required.
>
> Additionally, a 404 Not Found error was encountered while trying to
> use an ErrorDocument to handle the request.



 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
mapping user's home directory to URL using apache. query.cdac@gmail.com Linux Networking 3 04-18-2007 11:57 AM
Need help with LDAP or Kerberos auth, apache + active directory Linux Networking 0 08-05-2005 12:09 PM
Problem setting up GPO for IPSec + CA/Certificate Auth Ewan Windows Networking 0 07-30-2005 02:36 PM
setting up Apache. Dave Linux Networking 2 11-11-2003 02:05 AM
Setting up apache help Ian Linux Networking 2 10-07-2003 01:15 PM



1 2 3 4 5 6 7 8 9 10 11