LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 06-22-2009, 10:21 PM   #1
noir911
Member
 
Registered: Apr 2004
Posts: 682

Rep: Reputation: Disabled
RHEL 4: LDAP HTTPD and Active Directory


How do I get RHEl 4.5's HTTPD to authenticate users against Active Directory? In RHEL 5.1 I do this via mod_authnz but AFAIK mod_authnz is not available for

RHEl 4.5.

Here is my /etc/httpd/conf.d/mrtg.conf

Code:
Alias /mrtg /var/www/mrtg


<Directory "/var/www/mrtg/">
    Options Indexes MultiViews
    AllowOverride None
    Order allow,deny
    Allow from all 
    AuthUserFile /var/www/mrtg/.htaccess
</Directory>
Here is my .htaccess

Code:
AuthName "AD"
AuthType Basic
AuthLDAPURL ldap://domain.company.tld:389/ou=mkt,dc=domain,dc=tld?sAMAccountName?sub
AuthBasicProvider ldap
AuthzLDAPAuthoritative off
require valid-user
If I try the above .htaccess with "AllowOverride All" I get HTTP Internal Server Error with: "Invalid command 'AuthBasicProvider', perhaps mis-spelled or

defined by a module not included in the server configuration"

If I try the following .htaccess with "AllowOverride All"

Code:
AuthName "AD"
AuthType Basic
LDAP_Server ad.company.tld
LDAP_Port 389
Base_DN "ou=mkt,dc=domain,dc=tld"
UID_Attr samaccountname
require valid-user
I get HTTP Internal Server Error with "Invalid command 'LDAP_Server', perhaps mis-spelled or defined by a module not included in the server configuration"


Here are the modules loaded via /etc/httpd/conf/httpd.conf

Code:
LoadModule access_module modules/mod_access.so
LoadModule auth_module modules/mod_auth.so
LoadModule auth_anon_module modules/mod_auth_anon.so
LoadModule auth_dbm_module modules/mod_auth_dbm.so
LoadModule auth_digest_module modules/mod_auth_digest.so
LoadModule ldap_module modules/mod_ldap.so
LoadModule auth_ldap_module modules/mod_auth_ldap.so
LoadModule include_module modules/mod_include.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule env_module modules/mod_env.so
LoadModule mime_magic_module modules/mod_mime_magic.so
LoadModule cern_meta_module modules/mod_cern_meta.so
LoadModule expires_module modules/mod_expires.so
LoadModule deflate_module modules/mod_deflate.so
LoadModule headers_module modules/mod_headers.so
LoadModule usertrack_module modules/mod_usertrack.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule mime_module modules/mod_mime.so
LoadModule dav_module modules/mod_dav.so
LoadModule status_module modules/mod_status.so
LoadModule autoindex_module modules/mod_autoindex.so
LoadModule asis_module modules/mod_asis.so
LoadModule info_module modules/mod_info.so
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule vhost_alias_module modules/mod_vhost_alias.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule dir_module modules/mod_dir.so
LoadModule imap_module modules/mod_imap.so
LoadModule actions_module modules/mod_actions.so
LoadModule speling_module modules/mod_speling.so
LoadModule userdir_module modules/mod_userdir.so
LoadModule alias_module modules/mod_alias.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so
LoadModule cache_module modules/mod_cache.so
LoadModule suexec_module modules/mod_suexec.so
LoadModule disk_cache_module modules/mod_disk_cache.so
LoadModule file_cache_module modules/mod_file_cache.so
LoadModule mem_cache_module modules/mod_mem_cache.so
LoadModule cgi_module modules/mod_cgi.so
Thanks.
 
Old 06-23-2009, 02:24 AM   #2
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
I guess RHEL 4.5 comes with apache 2.0.x, that why these directives not work.
If so you have to either upgrade apache to 2.2.x, or use the directives that are available for mod_auth and mod_auth_ldap that comes with apache 2.0.x

Regards
 
  


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
Active Directory vs LDAP alex r Linux - Software 26 04-07-2010 04:47 AM
how to sync LDAP with MS active directory? cpliu903 Linux - Server 3 12-01-2008 06:59 AM
ldap authentication against active directory Hubert Kiyimba Solaris / OpenSolaris 1 03-16-2007 10:41 AM
ldap & active directory ziox Linux - Security 1 05-02-2006 04:34 AM
LDAP and Active Directory Ecalvam Linux - Networking 5 11-10-2005 08:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 01:31 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