Jed Parsons wrote:
>
>> Which LDAP server are you using? You can switch off this behaviour
>> with OpenLDAP. See man 5 slapd.conf, allow .
>
> I don't have anything other than user access. Good to know about this
> feature, though.
In case you're programming for different LDAP servers it's good
> Which LDAP server are you using? You can switch off this behaviour
> with OpenLDAP. See man 5 slapd.conf, allow .
I don't have anything other than user access. Good to know about this
feature, though.
You've been very helpful - I really appreciate it.
Can you recommend any favorite books
Jed Parsons wrote:
>
> As an addendum, I discovered one little gotcha, namely that this:
>
> l.bind_s(username, password, ldap.AUTH_SIMPLE)
>
> throws an ldap.INVALID_CREDENTIALS error if the password contains the
> wrong text, but works if the password is empty. I guess this is
> tantamoun
Hi, Michael,
Thanks very much for your response. I think I can work it out now.
>> authenticated = False
> ^^^
> Identiation is wrong here.
Yes, sorry about that - doesn't always work on this email client :(
As an addendum, I discovered one little gotcha, namely that this:
Jed Parsons wrote:
>
> import ldap
> l = ldap.open('our.ldap.server')
> try:
> l.bind_s(username, password, ldap.AUTH_SIMPLE)
> authenticated = True
> except:
> authenticated = False
^^^
Identiation is wrong here.
Also I'd recommend to catch the ldap.LDAP
Title: RE: ldap usage
Looks like the top of my message got garbled
I was trying to say that I'm using ldap for the first time,
trying to write a script that authenticates a user against
our ldap server. etc. The rest came through.
Hope that makes more sense now :)
j
-Ori
Hi,
authenticates a user against our ldap server.: User types in name and
password, and module sees if name and password check out right with the
ldap server.
I see that it's pretty straightforward to do this with:
import ldap
l = ldap.open('our.ldap.server')
try:
l.