HomePage » Security » SecurityLDAP


Using LDAP for authentication on Linux




LDAP and PAM on Fedora

This is work in progress..
Reference:

Install the necessary packages
yum -y install openldap openldap-clients openldap-devel openldap-servers adminutil migrationtools luma


Create the ldap directory
mkdir /var/lib/ldap/comme.ca
chown ldap:ldap /var/lib/ldap/comme.ca


edit /etc/openldap/ldap.conf
HOST ism.comme.ca
BASE dc=ism,dc=comme,dc=ca


generate ldap root password
slappasswd


edit /etc/openldap/slapd.conf
database bdb
suffix          "dc=ism,dc=comme,dc=ca"
rootdn          "uid=root,dc=ism,dc=comme,dc=ca"
rootpw		<paste the root password generated previously>


add root account to LDAP
create a file comme.ldif
dn: dc=ism,dc=comme,dc=ca
objectclass: dcobject
objectClass: organization
o: comme ca ism
dc: ism


Then run this
/usr/bin/ldapadd -x -D 'uid=root,dc=ism,dc=comme,dc=ca' -W -f comme.ldif
service ldap restart


Configure nss

check existing pam config
authconfig --test


Add ldap support to nss
authconfig --enableldap --enableldapauth --disablenis --enablecache \
		  --ldapserver=ism.comme.ca --ldapbasedn=dc=comme,dc=ca --updateall


Disable ldap from nss
authconfig --disableldap --updateall

There is one comment on this page. [Display comment]

Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by WikkaWiki