LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-06-2019, 12:26 AM   #1
james000
Member
 
Registered: Sep 2018
Posts: 149

Rep: Reputation: 2
LDAP password not accepting on client


Hi,

I have a Openldap server running on RHEL 7.2. I created one new RHEL 7.2 client and added it on server side and did client side config too.
On server side, I added this new client and I can see this new client on server side with below command
Code:
[root@ldapmaster1 ~]# ldapsearch -Y EXTERNAL -H ldapi:/// -b "dc=pp,dc=qq,dc=rr,dc=ss" "cn=client21"
On client side, here is config
Code:
[root@client21 ~]# authconfig --enableldap --enableldapauth --ldapserver="ldapmaster1-data.pp.qq.rr.ss" --ldapbasedn="dc=pp,dc=qq,dc=rr,dc=ss" --update
[root@client21 ~]# 
[root@client21 ~]# cat /etc/openldap/ldap.conf
#
# LDAP Defaults
#

# See ldap.conf(5) for details
# This file should be world readable but not world writable.

#BASE   dc=example,dc=com
#URI    ldap://ldap.example.com ldap://ldap-master.example.com:666

#SIZELIMIT      12
#TIMELIMIT      15
#DEREF          never

TLS_CACERTDIR /etc/openldap/cacerts

# Turning this off breaks GSSAPI used with krb5 when rdns = false
SASL_NOCANON    on
URI ldap://ldapmaster1-data.pp.qq.rr.ss/
BASE dc=pp,dc=qq,dc=rr,dc=ss
[root@client21 ~]#
[root@ia-dav-nms1 ~]# cat /etc/nsswitch.conf | egrep "passwd|shadow|group|sudoers" | grep -v "#"
passwd:     files ldap
shadow:     files ldap
group:      files ldap
netgroup:   files ldap
sudoers:    ldap
[root@ia-dav-nms1 ~]#
When I try to login with my credential (non-root), it denied password. On LDAP master side I see with tcpdump that client's IP is hitting on server. But password not accepting. Same password is working on other clients.
Please suggest, how it should be fixed, what am I missing?
Thanks

Last edited by james000; 04-06-2019 at 12:29 AM.
 
Old 04-06-2019, 02:24 PM   #2
tyler2016
Member
 
Registered: Sep 2018
Distribution: Debian, CentOS, FreeBSD
Posts: 243

Rep: Reputation: Disabled
Have you installed nss-pam-ldapd?

Are you able to resolve UIDs? I.e. can you chown a file to a user that is in LDAP but not your password file?

What does your OpenLDAP ACL look like? I don't see where you configured a proxy account. What does your /etc/nslcd.conf look like? Maybe your configuration isn't allowing anonymous binds.

I am assuming your LDAP entries for users and groups have the posixAccount and posixGroup classes? Keep in mind the posixAccount class is Auxiliary and the posixGroup class is structural.

Can you post an LDIF of one of your users as well as your /etc/pam.d/password-auth? By default, there is a module that forces you to use UIDs of at least a 1000 for LDAP users.

I wrote a few guides covering this on my website. If answering my questions doesn't get it working, they might be able to help you. The first is how to minimally configure OpenLDAP for OS authentication, the second is how to setup CentOS 7 to authenticate to it. They should work if you installed OpenLDAP from the repos. I usually install it from source so I can control the TLS library (I have seen the TLS library OpenLDAP is linked to change with package updates, breaking the TLS configuration).

https://tylersguides.com/guides/conf...uthentication/
https://tylersguides.com/guides/conf...tion-centos-7/

If you opt to install from source, here is how I do it:

https://tylersguides.com/guides/inst...urce-centos-7/

Last edited by tyler2016; 04-06-2019 at 02:29 PM.
 
1 members found this post helpful.
Old 04-06-2019, 07:44 PM   #3
james000
Member
 
Registered: Sep 2018
Posts: 149

Original Poster
Rep: Reputation: 2
Your guides are amazing. I cleared config and did reconfiguration and it worked. Thanks much for sharing
 
Old 04-07-2019, 05:23 AM   #4
tyler2016
Member
 
Registered: Sep 2018
Distribution: Debian, CentOS, FreeBSD
Posts: 243

Rep: Reputation: Disabled
You're welcome. Glad I could help.
 
  


Reply

Tags
linux, openldap



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
ubuntu ldap clients cannot login after ldap password is changed from the ldap server nitinm Ubuntu 8 08-20-2020 07:32 AM
OpenLDAP - Difference between etc/ldap.conf and etc/ldap/ldap.conf ramkrishnan Linux - Server 1 07-09-2018 02:01 PM
[SOLVED] CentOS 7 rsyslogd not accepting logs from client machines dcsst28 Linux - Server 2 01-16-2015 10:48 PM
Difference between /etc/ldap.conf vs. /etc/ldap/ldap.conf fahadaziz Linux - Server 8 07-14-2010 05:12 AM
sshd not accepting password Ionized Linux - Networking 2 08-06-2002 12:01 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:30 PM.

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