LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   apache mod_auth_pam (https://www.linuxquestions.org/questions/linux-software-2/apache-mod_auth_pam-361396/)

stomach 09-08-2005 08:05 AM

apache mod_auth_pam
 
Good Day,

I installed the module auth of the apache

httpd.conf

Code:

LoadModule auth_pam_module modules/mod_auth_pam.so
LoadModule auth_sys_group_module modules/mod_auth_sys_group.so

and

Code:

<Directory /home/httpd/html>
  AuthPAM_Enabled on
  AuthAuthoritative off
  AllowOverride None
  AuthName "Family Secrets"
  AuthType "basic"
  require group users
</Directory>


/etc/pam.d/httpd

Code:

#%PAM-1.0
auth      required    /lib/security/pam_unix.so
account    required    /lib/security/pam_unix.so


When it asks for login, happens this error:

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.


/var/log/httpd/errors
Code:

[Thu Sep 08 10:03:49 2005] [error] [client 192.168.254.4] PAM: user 'stomach' - not authenticated: Authentication failure
:scratch: :scratch: :scratch:

stomach 09-08-2005 09:52 AM

help please:cry:

Matir 09-08-2005 09:56 AM

It may be related to this.

stomach 09-08-2005 10:09 AM

I looked at is page, but I did not understand. It does not have as to make this?

Matir 09-08-2005 10:14 AM

If you use shadow passwords and apache cannot read the shadow file, then apache cannot authenticate users.

stomach 09-08-2005 10:21 AM

Then it does not have advantage to use this module

Matir 09-08-2005 10:22 AM

Why not? How else would you perform pam auth?

stomach 09-08-2005 10:24 AM

I do not go to have problems, modifying the group of shadow?

Matir 09-08-2005 10:28 AM

If shadow is, as it defaults to, 600 permissions owned by root:root, then apache would need to run as root to authenticate against the shadow file.

stomach 09-08-2005 10:29 AM

Thanks!
it functioned perfectly!
:)

it forgives my English is bad

Matir 09-08-2005 10:31 AM

I'm glad you were able to get it working. :)

Your english is not too bad, and I understand that we're a global community, not confined to any singular land or language.

stomach 09-08-2005 10:36 AM

Ok thanks! I go to start to participate more, of this great community! Perhaps I go to change my user, for my true name. Thus it is more easy for the people to understand me.

Matir 09-08-2005 10:42 AM

Yes, it is a great community. :) We all have much to learn and much to share.


All times are GMT -5. The time now is 09:23 AM.