LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-12-2012, 11:54 PM   #1
evocage
LQ Newbie
 
Registered: Aug 2011
Posts: 28

Rep: Reputation: Disabled
Apache authentucation


Hi Guys,

I just configured apache2 in ubuntu 11.04. I used basic authentication. But authentication is happening only one time. When browser is closed completely then its again asking for authentication. But it should be authenticate each time without closing the browser.

Have any idea then share it.

I also want to authenticate using ldap user but its giving error like :

Unknown Authn provider: ldap

how can I resolve it ?



Thanks
 
Old 02-13-2012, 12:58 AM   #2
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
Hello,

How did you configure authentication? Post your configuration file (masking/hiding personal info) so that we can have a look at it. What module are you using for LDAP authentication?

Kind regards,

Eric
 
Old 02-13-2012, 01:17 AM   #3
j-ray
Senior Member
 
Registered: Jan 2002
Location: germany
Distribution: ubuntu, mint, suse
Posts: 1,591

Rep: Reputation: 145Reputation: 145
Http basic auth is always valid until you quit the browser. Do you have an ldap server running within reach?
 
Old 02-13-2012, 01:19 AM   #4
evocage
LQ Newbie
 
Registered: Aug 2011
Posts: 28

Original Poster
Rep: Reputation: Disabled
Hi Eric,

My configuration details are as follows:

AuthBasicProvider ldap
AuthType Basic
AuthzLDAPAuthoritative on
AuthLDAPUrl ldap://ldap.example.com/ou=users,dc=example,dc=com
AuthName "Permission Denied"
AuthUserFile /usr/local/secret
Require user admin jack
Have any suggestion ..
 
Old 02-13-2012, 02:06 AM   #5
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
Unknown Authn provider: ldap
You should make sure that you load both the authnz_ldap_module and ldap_module modules in your apache config file

Regards
 
Old 02-13-2012, 02:35 AM   #6
evocage
LQ Newbie
 
Registered: Aug 2011
Posts: 28

Original Poster
Rep: Reputation: Disabled
Hi bathory,

I installed from apt-get then is it necessary to include these module in apache2.conf file.

Please let me know.



Thanks
 
Old 02-13-2012, 02:45 AM   #7
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
AFAIK in debian based distros, you need to use a2enmod to enable apache modules. So try:
Code:
a2enmod ldap
a2enmod authnz_ldap
 
Old 02-13-2012, 03:23 AM   #8
evocage
LQ Newbie
 
Registered: Aug 2011
Posts: 28

Original Poster
Rep: Reputation: Disabled
Hey,

Can you tell me how to add in apache2.conf file.

When I run this command

a2enmod ldap
Module ldap already enabled

# a2enmod authnz_ldap
Considering dependency ldap for authnz_ldap:
Module ldap already enabled
Module authnz_ldap already enabled



Thanks

Last edited by evocage; 02-13-2012 at 03:26 AM.
 
Old 02-13-2012, 04:05 AM   #9
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Quote:
Originally Posted by evocage View Post
Hey,

Can you tell me how to add in apache2.conf file.

When I run this command

a2enmod ldap
Module ldap already enabled

# a2enmod authnz_ldap
Considering dependency ldap for authnz_ldap:
Module ldap already enabled
Module authnz_ldap already enabled
So the modules are enabled. You don't need to add anything in apache2.conf as a2enmod has taken care to create the needed files/symlinks in /etc/apache2/mods-enabled.
Restart apache and see if you still get that error "Unknown Authn provider: ldap"
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
setting up apache from scratch on a linux machine, apache failed message upon bootup dramous43 Linux - Enterprise 2 01-26-2010 07:53 AM
Apache Webserver on Slackware - Failed to Start Apache - 'no listening sockets .." CCTVGuru Linux - Server 4 10-11-2009 01:14 AM
Mail from Apache being rejected - Cannot route to sender apache@localhost.localdomain jimwillsher Linux - Networking 2 01-19-2006 12:41 AM
Apache Webserver 403 Forbidden Errors (User not in apache group?) Mankind75 Mandriva 4 07-08-2004 05:30 AM
apache benchmarks (apache v13 / apache v20) ; large differences between benchmarking markus1982 Linux - Software 0 02-08-2003 10:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 12:55 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration