Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
As a student, I work on a project to authenticate users while they acces internet. I am testing Squid authentication to an LDAP server and I have the following problem :
From Squid server where I installed ldap-utils, I have the following result
ok, when I try this, I get another error message (about TLS). That makes me think I should study the squid_ldap_auth command. In our project, it' another student who works on the squid side. I'm gonna dig with him (cheking syntax and so on ...) and I will tell you about the results.
ok, when I try this, I get another error message (about TLS). That makes me think I should study the squid_ldap_auth command. In our project, it' another student who works on the squid side. I'm gonna dig with him (cheking syntax and so on ...) and I will tell you about the results.
thanks again,
olivier
You should better look the ldap side. Check sladp.conf, if it allows anonymous bind, or if it uses tls and so on
I tried the command to authenticate on a known working LDAP server and I get the following result (I modified the root name for confidentiality purpose) :
Code:
lpasr@Ubuntu-lpasr:~$ /usr/lib/squid/ldap_auth -b "ou=people,dc=example,dc=com" -f "uid=%s" -h 10.11.4.241 -d
b21115679 azerty
user filter 'uid=b21115679', searchbase 'ou=people,dc=example,dc=com'
attempting to authenticate user 'uid=b21115679,ou=people,dc=example,dc=com'
ERR Success
I don't understand what it means (except that it doesn't work ...)
It means that it tries to authenticate as the user b21115679 (i.e. dn=uid=b21115679,ou=people,dc=example,dc=com) with the given password and it fails
Try once again to use also the admin credentials (-D "..." -w ...) to do the search, cause chances are that anonymous searches are forbidden. This can be verified looking for any "access to ..." line(s) in slapd.conf
Or you can watch the ldap logs and see if you get anything, when trying to authenticate through ldap_auth
BTW why are you using /usr/lib/squid/ldap_auth and not /usr/lib/squid/squid_ldap_auth? Are these the same for ubuntu?
The anonymous searches are enabled as I can use ldapsearch without authenticating and it works. Right now, I can't use the admin credentials because I don't know them. I hope to join the people managing the LDAP server and have some help (until now, the guy was not available). I can't look at slapd.conf either for the same reason.
To answer your last question, I tried first to use squid_ldap_auth but I get a "command not found" so I switched to ldap_auth that works.
ok, I finally solved the problem with the following command :
Code:
lpasr@Ubuntu-lpasr:~$ /usr/lib/squid/ldap_auth -b "ou=people,dc=example,dc=com" -f "uid=%s" -h 10.11.4.241 -d -v 3
b21115679 azerty
user filter 'uid=b21115679', searchbase 'ou=people,dc=example,dc=com'
attempting to authenticate user 'uid=b21115679,ou=people,dc=example,dc=com'
OK
It seems that the default is not LDAPv3 for the command (at least, /usr/lib/squid/ldap_auth).
Now, I need to know how to configure slapd.conf on my test LDAP server to make anonymous accesses work.
Eventually, I need to replicate partly the LDAP server (10.11.4.241) so people can authenticate locally ...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.