Re: Python LDAP

2011-04-08 Thread Godefroid Chapelle
Le 07/04/11 21:04, Chris Dukes a écrit : > On Thu, Apr 07, 2011 at 07:59:55PM +0200, Godefroid Chapelle wrote: >> Hi, >> >> I am trying to access a Lotus Notes LDAP server. >> >> I got the information from the Notes admin that I should use a Base DN >> that consists of a single space. That feels ve

Re: Load Balance and Redundant LDAP config

2011-03-31 Thread Michael Ströder
Bob Brandt wrote: > I apologize if this is not the right place to ask this question... You're welcome to discuss this here. > I am looking to modify my LDAP scripts to be both Redundant and Load > Balancing! Although both things are mixed all the time these are two different goals. > Right now,

Re: ldap.controls in python-ldap 2.4

2011-03-31 Thread Michael Ströder
Michael Ströder wrote: > Since I'm working more with LDAPv3 controls now I've cleaned up sub-module > ldap.controls. Still work in progress... Now I've checked in the modifications and updated Demo/page_control.py to make use of the slightly new API. Also some related constants' names are now alig

Re: python-ldap as replication client

2011-03-23 Thread Eric Brunson
On 03/23/2011 01:11 AM, Michael Ströder wrote: > Eric Brunson wrote: >> The new code works great, thanks so much for the new features. >> >> I do have one issue, and maybe I'm just not looking in the correct >> place. The Sync Info Message returns a syncInfoValue which is a BER >> encoded ASN.1 CH

Re: python-ldap as replication client

2011-03-23 Thread Michael Ströder
Eric Brunson wrote: > The new code works great, thanks so much for the new features. > > I do have one issue, and maybe I'm just not looking in the correct > place. The Sync Info Message returns a syncInfoValue which is a BER > encoded ASN.1 CHOICE structure: > > syncInfoValue ::= CHOICE { >

Re: python-ldap as replication client

2011-03-22 Thread Eric Brunson
On 03/11/2011 11:24 AM, Michael Ströder wrote: Eric Brunson wrote: On 03/11/2011 11:00 AM, Michael Ströder wrote: Eric Brunson wrote: On 03/11/2011 05:40 AM, Michael Ströder wrote: No matter which sync protocol you implement it's very likely that you need python-LDAP from CVS HEAD (will be py

Re: Modifying multiple dns with a single function call

2011-03-18 Thread Michael Ströder
Rahul Amaram wrote: > I am looking for something like this. > > dn: cn=User1,dc=example,dc=com > changetype: modify > replace: mail > mail: us...@example.com > > dn: cn=User2,dc=example,dc=com > changetype: modify > replace: mail > mail: us...@example.com > > dn: cn=User3,dc=example,dc=com > cha

Re: Modifying multiple dns with a single function call

2011-03-18 Thread Rahul Amaram
I am looking for something like this. dn: cn=User1,dc=example,dc=com changetype: modify replace: mail mail: us...@example.com dn: cn=User2,dc=example,dc=com changetype: modify replace: mail mail: us...@example.com dn: cn=User3,dc=example,dc=com changetype: modify replace: mail mail: us...@exampl

Re: Modifying multiple dns with a single function call

2011-03-18 Thread Michael Ströder
Rahul Amaram wrote: > I would like to know if it possible to modify multiple dns at once i.e. > via a single modify_s request. Yes, if you mean (multiple) DN-valued attribute values in a single entry. No, if you mean the DNs of multiple entries. > I might need to update about 10,000 entries and

Re: python-ldap as replication client

2011-03-11 Thread Michael Ströder
Eric Brunson wrote: > On 03/11/2011 11:00 AM, Michael Ströder wrote: >> Eric Brunson wrote: >>> On 03/11/2011 05:40 AM, Michael Ströder wrote: No matter which sync protocol you implement it's very likely that you need python-LDAP from CVS HEAD (will be python 2.4) since this version

Re: python-ldap as replication client

2011-03-11 Thread Eric Brunson
On 03/11/2011 11:00 AM, Michael Ströder wrote: > Eric Brunson wrote: >> On 03/11/2011 05:40 AM, Michael Ströder wrote: >>> No matter which sync protocol you implement it's very likely that you need >>> python-LDAP from CVS HEAD (will be python 2.4) since this version contains >>> code to extract re

Re: python-ldap as replication client

2011-03-11 Thread Michael Ströder
Eric Brunson wrote: > On 03/11/2011 05:40 AM, Michael Ströder wrote: >> No matter which sync protocol you implement it's very likely that you need >> python-LDAP from CVS HEAD (will be python 2.4) since this version contains >> code to extract response controls from intermediate responses. > > I'm

Re: python-ldap as replication client

2011-03-11 Thread Eric Brunson
On 03/11/2011 05:40 AM, Michael Ströder wrote: > Jeroen van Meeuwen (Kolab Systems) wrote: >> I'm looking to implement LDAP_CONTROL_SYNC(*) capabilities to >> python-ldap's ldap.controls, and while I do have some experience in >> several areas, admittedly compared to you I'm probably the most >> un

Re: python-ldap as replication client

2011-03-11 Thread Jeroen van Meeuwen (Kolab Systems)
Michael Ströder wrote: > Jeroen van Meeuwen (Kolab Systems) wrote: > > I'm looking to implement LDAP_CONTROL_SYNC(*) capabilities to > > python-ldap's ldap.controls, and while I do have some experience in > > several areas, admittedly compared to you I'm probably the most > > under-qualified progra

Re: python-ldap as replication client

2011-03-11 Thread Michael Ströder
Jeroen van Meeuwen (Kolab Systems) wrote: > I'm looking to implement LDAP_CONTROL_SYNC(*) capabilities to > python-ldap's ldap.controls, and while I do have some experience in > several areas, admittedly compared to you I'm probably the most > under-qualified programmer to actually do it. You're a

Re: Fwd: [pyasn1-users] ANN: pyasn1-0.0.13a & pyasn1-modules-0.0.1a released

2011-03-07 Thread Rich Megginson
On 03/07/2011 11:19 AM, Michael Ströder wrote: > Rich Megginson wrote: >> RHEL does not include pyasn1. But it is extremely useful for >> extops/controls - doing BER codec by hand is not fun. > Yupp! > >> A mid-way >> approach would be to expose the liblber ber_scanf/ber_printf and support >> fu

Re: Fwd: [pyasn1-users] ANN: pyasn1-0.0.13a & pyasn1-modules-0.0.1a released

2011-03-07 Thread Michael Ströder
Rich Megginson wrote: > RHEL does not include pyasn1. But it is extremely useful for > extops/controls - doing BER codec by hand is not fun. Yupp! > A mid-way > approach would be to expose the liblber ber_scanf/ber_printf and support > functions in python. Also an idea we already had. But I

Re: Fwd: [pyasn1-users] ANN: pyasn1-0.0.13a & pyasn1-modules-0.0.1a released

2011-03-07 Thread Rich Megginson
On 03/07/2011 10:35 AM, Michael Ströder wrote: > Rich Megginson wrote: >>On 03/06/2011 06:14 PM, Chaos Eternal wrote: >>> should we re-implement python-ldap on pyasn and get rid of depends on >>> openldap libs? >>> >> I vote no. Why would you want t

Re: Fwd: [pyasn1-users] ANN: pyasn1-0.0.13a & pyasn1-modules-0.0.1a released

2011-03-07 Thread Michael Ströder
Rich Megginson wrote: > On 03/06/2011 06:14 PM, Chaos Eternal wrote: >> >> should we re-implement python-ldap on pyasn and get rid of depends on >> openldap libs? >> > I vote no. Why would you want to do that? How would you implement > TLS/SSL? How would you

Re: Minimum version of OpenLDAP libs for python-ldap 2.4.x?

2011-03-07 Thread Rich Megginson
On 03/04/2011 12:17 PM, Michael Ströder wrote: > (Cc:-ed python-ldap-dev again) > > Chris Dukes wrote: >> On Fri, Mar 04, 2011 at 07:45:15PM +0100, Michael Ströder wrote: >>> Again it's time to think about the minimum required version of OpenLDAP libs >>> to be used for building upcoming python-lda

Re: Fwd: [pyasn1-users] ANN: pyasn1-0.0.13a & pyasn1-modules-0.0.1a released

2011-03-07 Thread Rich Megginson
On 03/06/2011 06:14 PM, Chaos Eternal wrote: should we re-implement python-ldap on pyasn and get rid of depends on openldap libs? I vote no. Why would you want to do that? How would you implement TLS/SSL? How would you implement SASL/GSSAPI? How would you keep up with openldap client

Re: Minimum version of OpenLDAP libs for python-ldap 2.4.x?

2011-03-05 Thread Michael Ströder
Zhang Huangbin wrote: > > On Mar 5, 2011, at 2:45 AM, Michael Ströder wrote: > >> Again it's time to think about the minimum required version of OpenLDAP libs >> to be used for building upcoming python-ldap 2.4.0. > > Does it mean py-ldap-2.4.0 won't support OpenLDAP-2.3.x series? Yes. > Debia

Re: Minimum version of OpenLDAP libs for python-ldap 2.4.x?

2011-03-04 Thread Zhang Huangbin
On Mar 5, 2011, at 2:45 AM, Michael Ströder wrote: > Again it's time to think about the minimum required version of OpenLDAP libs > to be used for building upcoming python-ldap 2.4.0. Does it mean py-ldap-2.4.0 won't support OpenLDAP-2.3.x series? Debian 5, RHEL/CentOS 5 ships OpenLDAP-2.3.x.

Re: Minimum version of OpenLDAP libs for python-ldap 2.4.x?

2011-03-04 Thread Michael Ströder
(Cc:-ed python-ldap-dev again) Chris Dukes wrote: > On Fri, Mar 04, 2011 at 07:45:15PM +0100, Michael Ströder wrote: >> Again it's time to think about the minimum required version of OpenLDAP libs >> to be used for building upcoming python-ldap 2.4.0. I'd vote for strictly >> requiring a fairly re

Re: please review encode_assertion_control()

2011-03-04 Thread Michael Ströder
Michael Ströder wrote: > Rich Megginson wrote: >> On 03/03/2011 01:28 PM, Michael Ströder wrote: >>> Could somebody please look what's wrong with >>> encode_assertion_control() in >>> Modules/ldapcontrol.c? It seg faults. >> err = >> ldap_create_assertion_control_value(NULL,assertion_filterstr,

Re: please review encode_assertion_control()

2011-03-04 Thread Michael Ströder
Rich Megginson wrote: > On 03/03/2011 01:28 PM, Michael Ströder wrote: >> Could somebody please look what's wrong with >> encode_assertion_control() in >> Modules/ldapcontrol.c? It seg faults. > err = > ldap_create_assertion_control_value(NULL,assertion_filterstr,&ctrl_val); > The NULL should b

Re: please review encode_assertion_control()

2011-03-03 Thread Rich Megginson
On 03/03/2011 01:28 PM, Michael Ströder wrote: > HI! > > (Sigh!) I'm not a C programmer. > > Could somebody please look what's wrong with encode_assertion_control() in > Modules/ldapcontrol.c? It seg faults. err = ldap_create_assertion_control_value(NULL,assertion_filterstr,&ctrl_val); The NU

Re: LDAP for Python 3.x

2011-03-02 Thread Dusan Stefanik
Hi Michael, I will try do it. Dusan On 01/03/11 at 09:15pm, Michael Ströder wrote: > Dusan Stefanik wrote: > > I decided to take python-ldap-2.3.13 few days ago and I made som changes to > > get it work on python3. > > Now I have working version for python3 (tested on Ubuntu 10.4 LTS x64 and

Re: LDAP for Python 3.x

2011-03-02 Thread Michael Ströder
Dusan Stefanik wrote: > I decided to take python-ldap-2.3.13 few days ago and I made som changes to > get it work on python3. > Now I have working version for python3 (tested on Ubuntu 10.4 LTS x64 and > Debian Squeeze x64). > > You can try it. It can be start point for new branche of python-lda

Re: 2.4.0 patches need review

2011-03-02 Thread Rich Megginson
On 02/21/2011 02:29 PM, Michael Ströder wrote: > HI! > > I've committed a larger patch contributed by Rich Megginson fixing SF#2829057 > [1] and adding generic support LDAPv3 extended operations. Many thanks to him. > > I've done some tests for [1] by successfully using the LDAP persistent search >

Re: 2.4.0 patches need review

2011-03-02 Thread Rich Megginson
On 03/01/2011 01:13 PM, Michael Ströder wrote: > Rich Megginson wrote: >> About the arguments and return values to result4 - with the current code >> I have to do something like this: >> >> rtype, rdata, rmsgid, decoded_serverctrls, extop_rspoid, >> extop_rspval = srv.result4(msgid, 0, -1, 1)

Re: 2.4.0 patches need review

2011-03-01 Thread Michael Ströder
Rich Megginson wrote: > About the arguments and return values to result4 - with the current code > I have to do something like this: > > rtype, rdata, rmsgid, decoded_serverctrls, extop_rspoid, > extop_rspval = srv.result4(msgid, 0, -1, 1) > > That is, I only want the decoded_serverctrls, but

Re: LDAP for Python 3.x

2011-02-23 Thread Dusan Stefanik
Hi, I decided to take python-ldap-2.3.13 few days ago and I made som changes to get it work on python3. Now I have working version for python3 (tested on Ubuntu 10.4 LTS x64 and Debian Squeeze x64). You can try it. It can be start point for new branche of python-ldap-py3. I made only few tes

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-08 Thread Michael Wood
Hi On 7 February 2011 19:29, Rich Megginson wrote: > On 02/05/2011 01:42 PM, Michael Wood wrote: >> >> Hi >> >> On 4 February 2011 17:35, Rich Megginson  wrote: >>> >>> On 02/03/2011 11:59 PM, Michael Wood wrote: On 4 February 2011 08:32, James Andrewartha    wrote: >> >> [...] > >>

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-07 Thread Rich Megginson
On 02/05/2011 01:42 PM, Michael Wood wrote: > Hi > > On 4 February 2011 17:35, Rich Megginson wrote: >> On 02/03/2011 11:59 PM, Michael Wood wrote: >>> On 4 February 2011 08:32, James Andrewarthawrote: > [...] Debian uses GnuTLS because OpenSSL has the non-GPL compatible advertising

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-05 Thread Michael Wood
Hi On 4 February 2011 17:35, Rich Megginson wrote: > On 02/03/2011 11:59 PM, Michael Wood wrote: >> >> On 4 February 2011 08:32, James Andrewartha  wrote: [...] >>> Debian uses GnuTLS because OpenSSL has the non-GPL compatible >>> advertising clause, and libldap is linked into many GPL applicatio

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-04 Thread Rich Megginson
On 02/04/2011 09:15 AM, Michael Ströder wrote: > Rich Megginson wrote: >> OpenLDAP 2.4.23 supports Mozilla NSS (triple licensed >> GPLv2+/LGPLv2+/MPL) for crypto >> Fedora 14 and later use this instead of OpenSSL > I see some benefits using Mozilla NSS especially with LDAP clients. But I > wonder w

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-04 Thread Michael Ströder
Rich Megginson wrote: > OpenLDAP 2.4.23 supports Mozilla NSS (triple licensed > GPLv2+/LGPLv2+/MPL) for crypto > Fedora 14 and later use this instead of OpenSSL I see some benefits using Mozilla NSS especially with LDAP clients. But I wonder whether we could use it from python-ldap via OpenLDAP j

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-04 Thread Michael Ströder
Michael Wood wrote: > I do hold out some hope that issues like this in GnuTLS (or in > the software using GnuTLS?) can get fixed, though. The issues with GnuTLS are known since years now I suspect that everybody setting up a serious (Open-)LDAP deployment just builds with OpenSSL and ther

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-04 Thread Rich Megginson
On 02/03/2011 11:59 PM, Michael Wood wrote: > On 4 February 2011 08:32, James Andrewartha wrote: >> On 04/02/11 03:31, Michael Ströder wrote: >>> Michael Wood wrote: On 3 February 2011 18:16, Rich Megginson wrote: > On 02/03/2011 04:34 AM, Michael Wood wrote: >> e.g. Ubuntu Lucid Lyn

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-03 Thread Michael Wood
On 4 February 2011 08:32, James Andrewartha wrote: > On 04/02/11 03:31, Michael Ströder wrote: >> Michael Wood wrote: >>> On 3 February 2011 18:16, Rich Megginson wrote: On 02/03/2011 04:34 AM, Michael Wood wrote: > e.g. Ubuntu Lucid Lynx with libldap2-dev version 2.4.21-0ubuntu5.3 and >

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-03 Thread James Andrewartha
On 04/02/11 03:31, Michael Ströder wrote: > Michael Wood wrote: >> On 3 February 2011 18:16, Rich Megginson wrote: >>> On 02/03/2011 04:34 AM, Michael Wood wrote: e.g. Ubuntu Lucid Lynx with libldap2-dev version 2.4.21-0ubuntu5.3 and python-ldap 2.3.10-1ubuntu1. >> [..] >> But I thought

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-03 Thread Michael Wood
Hi 2011/2/3 Michael Ströder : > Michael Wood wrote: >> On 3 February 2011 18:16, Rich Megginson wrote: >>> On 02/03/2011 04:34 AM, Michael Wood wrote: e.g. Ubuntu Lucid Lynx with libldap2-dev version 2.4.21-0ubuntu5.3 and python-ldap 2.3.10-1ubuntu1. >> [..] >> But I thought it was wort

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-03 Thread Michael Ströder
Michael Wood wrote: > On 3 February 2011 18:16, Rich Megginson wrote: >> On 02/03/2011 04:34 AM, Michael Wood wrote: >>> e.g. Ubuntu Lucid Lynx with libldap2-dev version 2.4.21-0ubuntu5.3 and >>> python-ldap 2.3.10-1ubuntu1. > [..] > But I thought it was worth a try to recompile OpenLDAP and link

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-03 Thread Michael Wood
Hi On 3 February 2011 18:16, Rich Megginson wrote: > On 02/03/2011 04:34 AM, Michael Wood wrote: >> Hi >> >> I'm trying to do a search against Samba 4's LDAP server and it works, >> but the bind and search are both successful, everything hangs when I >> try to unbind from the LDAP server.  If any

Re: python-ldap hanging for 15 minutes under certain conditions

2011-02-03 Thread Rich Megginson
On 02/03/2011 04:34 AM, Michael Wood wrote: > Hi > > I'm trying to do a search against Samba 4's LDAP server and it works, > but the bind and search are both successful, everything hangs when I > try to unbind from the LDAP server. If anyone could enlighten me I > would be grateful. > > I've run i

Re: How to find groups(CN) which contains specific words?

2010-12-15 Thread Michael Ströder
Zhang Huangbin wrote: > On Nov 15, 2010, at 1:16 PM, Jahidul Hasan wrote: >> I need to find those groups name which contains the word "ABC", is it >> possible ? >> >> base_dn = 'CN=ABC,OU=Common,DC=test,DC=com' >> ldapConn.search_s(base_dn, ldap.SCOPE_SUBTREE) >> >> Can I use %ABC% ? Not in base_d

Re: How to find groups(CN) which contains specific words?

2010-12-14 Thread Michele Marcionelli
Hello Jahid try with "(cn=*abc*)". This works fine with ldapsearch. Kind regards, Michele On Nov 15, 2010, at 6:16 , Jahidul Hasan wrote: > Hi > > I need to find those groups name which contains the word "ABC", is it > possible ? > > base_dn = 'CN=ABC,OU=Common,DC=test,DC=com' > ldapConn.sea

Re: How to find groups(CN) which contains specific words?

2010-12-14 Thread Zhang Huangbin
On Nov 15, 2010, at 1:16 PM, Jahidul Hasan wrote: > I need to find those groups name which contains the word "ABC", is it > possible ? > > base_dn = 'CN=ABC,OU=Common,DC=test,DC=com' > ldapConn.search_s(base_dn, ldap.SCOPE_SUBTREE) > > Can I use %ABC% ? LDAP search filter can be wild-card, use

Re: AIX 6.1 install trouble.

2010-09-30 Thread Chris Dukes
Tom, I'm now going to assume that you don't actually know anything about linkers or shared libraries, nor about reading error messages to gain more detail debugging. The -Wl,-bnoquiet came from actually reading your error output and seeing ld: 0711-345 Use the -bloadmap or -bnoquiet option to obt

Re: AIX 6.1 install trouble.

2010-09-30 Thread Michael Ströder
Tom Baxter wrote: > Thank you both for the quick reply. I changed my setup.cfg to > include openssl see below. I also verified that the IBM openssl > package was installed. Attached is the output from the single gcc > call. As said I don't have any experience building on AIX. But from my underst

Re: AIX 6.1 install trouble.

2010-09-30 Thread Tom Baxter
Thank you both for the quick reply. I changed my setup.cfg to include openssl see below. I also verified that the IBM openssl package was installed. Attached is the output from the single gcc call. lslpp -L | grep ssl openssl.base0.9.8.1100C FOpen Secure Socket Layer

Re: AIX 6.1 install trouble.

2010-09-30 Thread Chris Dukes
Manually rerun that last 'gcc' with a -Wl,-bnoquiet added to see the source of the objects depending on SSL symbols. I suspect that your ldap library is linked against OpenSSL. I recommend installing either IBM's LPP of OpenSSL, or the RPM from www.perzl.org Here is the spec file I used to build

Re: AIX 6.1 install trouble.

2010-09-30 Thread Michael Ströder
Tom Baxter wrote: > Hello, I am having trouble install python-ldap on an AIX 6.1 host. I > have compiled the openldap libraries and am trying to install without > any extras like SSL/crypt. Below is my setup.cfg, attached is the out > put from "python setup.py build". > Any guidance would be gr

Re: Installing python-ldap 2.3.12 fails

2010-09-21 Thread Michael Ströder
l Message Subject: Re: python-ldap-2.3.12: Compile error on CentOS 5.5, i386 Date: Wed, 11 Aug 2010 20:42:56 +0200 From: Michael Ströder To: Zhang Huangbin CC: Python Developer List Zhang Huangbin wrote: > > On Aug 9, 2010, at 11:43 PM, Michael Ströder wrote: > >> Find a ne

Re: ldaps and Active Directory

2010-09-03 Thread Michael Ströder
Josh wrote: >> Patrick A. Treptau wrote: >>> I am pulling my hair out trying to connect via ldaps to one of our AD >>> controllers. >>> >>> host = "ldaps://ad_host:636" >> >> You should always use the fully-qualified which is in the CN of the server >> certificate's subject DN. > > Patrick isn't

Re: ldaps and Active Directory

2010-09-03 Thread Josh
> Patrick A. Treptau wrote: > > I am pulling my hair out trying to connect via ldaps to one of our AD > > controllers. > > > > host = "ldaps://ad_host:636" > > You should always use the fully-qualified which is in the CN of the server > certificate's subject DN. Patrick isn't the only one runni

Re: Non-ascii passwords

2010-08-27 Thread Michael Ströder
Marc Brevoort wrote: > I've inherited a little authentication module which uses > python-ldap (v1.92, 2005/11/03). For the most of it, it works > fine, but when a user has decided to use non-ascii characters > in their password, they will be blocked access and the > authentication log shows a messa

Re: Error to add objectClass to entries

2010-08-20 Thread Steeve BARBEAU
I've found the solution. I use this method : >>> mod_attrs = [( ldap.MOD_ADD, 'uidNumber', '1000' )] >>> l.modify_s('uid=francis,ou=users,dc=example,dc=com', mod_attrs) I had began with this method, but my error was to keep number as integer and not as string. Thx Steeve Barbeau http://steeve-b

Re: Error to add objectClass to entries

2010-08-20 Thread Chaos Eternal
you cannot alter/change stuctral objectClass of an existing entry On 20 Aug 2010 4:08 PM, "Steeve BARBEAU" wrote: Hi, I'm new to this mailing list and I've a question concerning python-ldap. I want to add some objectClass and attributes to existing entries but I have this error : ldap.OTHER: {'

Re: python-ldap-2.3.12: Compile error on CentOS 5.5, i386

2010-08-11 Thread Zhang Huangbin
On Aug 12, 2010, at 2:42 AM, Michael Ströder wrote: > > Looks like an older OpenLDAP release. Please try the patch below. > > Ciao, Michael. > > Index: Modules/constants.c > === > RCS file: /cvsroot/python-ldap/python-ldap/Modules/

Re: python-ldap-2.3.12: Compile error on CentOS 5.5, i386

2010-08-11 Thread Michael Ströder
Zhang Huangbin wrote: > > On Aug 9, 2010, at 11:43 PM, Michael Ströder wrote: > >> Find a new release of python-ldap: >> >> http://pypi.python.org/pypi/python-ldap/2.3.12 > > Compile error on CentOS 5.5, i386: > [..] > Modules/constants.c: In function ‘LDAPinit_constants’: > Modules/constants.c

Re: sasl bind issues

2010-07-25 Thread Uma Sridharan
Yes that is correct. Using simple bind seems to have solved the problem though.. 2010/7/18 Michael Ströder > Uma Sridharan wrote: > > > > Here is a sample code that works the first time I run the loop and fails > > the second time with the following error. can someone let me know if the > > cred

Re: sasl bind issues

2010-07-19 Thread Michael Ströder
Uma Sridharan wrote: > > Here is a sample code that works the first time I run the loop and fails > the second time with the following error. can someone let me know if the > credentials are cached by the library or what could be wrong? Any help > is greatly appreciated. > > ldap.INVALID_CREDENTI

Re: bad filter

2010-07-01 Thread Anil
I've used this type of wild card search+compare before, all with Solaris's ldapsearch, never complained. Let me change this to not use a wild card like that. Thanks. 2010/7/1 Michael Ströder : > Anil wrote: >> I pass a filter string such as this to search(), but I keep getting >> BAD SEARCH FILTE

Re: bad filter

2010-07-01 Thread Michael Ströder
Anil wrote: > I pass a filter string such as this to search(), but I keep getting > BAD SEARCH FILTER error. > "(|(last-login-time<=100101*)(!(last-login-time=*)))" Using <= with * in the assertion value looks bogus to me. > The same thing works when using it with ldapsearch command. Does not wo

Re: _ldap.so: undefined symbol: gnutls_alert_send

2010-05-03 Thread Michael Ströder
Jean-Sébastien Mansart wrote: > > I've got this error with a Zope/Plone site : > Traceback (most recent call last): > [..] > ImportError: > /home/zope/z_sgec/buildout-cache/eggs/python_ldap-2.3.11-py2.4-linux-i686.egg/_ldap.so: > undefined symbol: gnutls_alert_send > > I have install gnutls1.3, r

Re: ldap.open() SSL patch

2010-04-19 Thread Adam Tauno Williams
On Mon, 2010-04-19 at 12:12 -0300, ygormu...@dcc.ufba.br wrote: > Michael Ströder : > > Just raising DeprecationWarning exception breaks existing code. I have to > > reject your patch. ;-) > I understand. > > I've checked in a solution which only outputs a warning (just like > > md5.py does > > i

Re: ldap.open() SSL patch

2010-04-19 Thread ygormutti
Michael Ströder : > Just raising DeprecationWarning exception breaks existing code. I have to > reject your patch. ;-) I understand. > I've checked in a solution which only outputs a warning (just like > md5.py does > in recent Python releases). So old code should still work. I agree that thi

Re: ldap.open() SSL patch

2010-04-18 Thread Michael Ströder
ygormu...@dcc.ufba.br wrote: > Michael Ströder : > >> Yes, you're right. I would accept such a patch. ;-) >> >> At least it's documented: >> >> http://www.python-ldap.org/doc/html/ldap.html#ldap.open > > I was using ldap.open because there are many code samples where it's > still used, in the tub

Re: ldap.open() SSL patch

2010-04-17 Thread ygormutti
Michael Ströder : Yes, you're right. I would accept such a patch. ;-) At least it's documented: http://www.python-ldap.org/doc/html/ldap.html#ldap.open I was using ldap.open because there are many code samples where it's still used, in the tubes. The new patch is attached. I hope to cont

Re: ldap.open() SSL patch

2010-04-17 Thread Michael Ströder
ygormu...@dcc.ufba.br wrote: > Michael Ströder : > >> Using ldap.open() is deprecated for quite a while now. python-ldap >> applications still using this function should be fixed. > > In this case, I think ldap.open() must raise a DeprecationWarning. Don't > you? Yes, you're right. I would accep

Re: ldap.open() SSL patch

2010-04-17 Thread ygormutti
Michael Ströder : > Using ldap.open() is deprecated for quite a while now. python-ldap > applications still using this function should be fixed. In this case, I think ldap.open() must raise a DeprecationWarning. Don't you? -- Ygor Mutti (http://icaju.com - @Mamutti) --

Re: ldap.open() SSL patch

2010-04-17 Thread Michael Ströder
ygormu...@dcc.ufba.br wrote: > I'm a member of GrudeSL (Free Software Development Group) at UFBA > (Federal University of Bahia). We were trying to integrate our new > Django site authentication with the existing LDAP server, so we ran > for python-ldap and I can say it does its job very well

Re: ldif.py won't parse with 'python -tt'

2010-03-29 Thread Michael Ströder
John Morrissey wrote: > ldif.py won't parse with the python option '-tt', which enforces consistent > whitespace. It's a simple fix of replacing the handful of tabs with spaces. Thanks for reporting that. Should be fixed in HEAD now. Ciao, Michael. ---

Re: [SPAM] Re: CONNECTING FROM A SERVERS POOL

2010-03-29 Thread Michael Ströder
HI! For simple synchronous operations there is ldap.ldapobject.ReconnectLDAPObject which does automatic re-connect when ldap.SERVER_DOWN is raised within a *operation_s() method (synchronous operations). You could use that as a starting point to implement connecting to another server in a pool

Re: [SPAM] Re: CONNECTING FROM A SERVERS POOL

2010-03-29 Thread Yeargan, Yancey
Hmm.. I do not know enough about the SimpleLDAPObject code. Perhaps a python-ldap developer can provide more information (but I think they will recommend that you not use SimpleLDAPObject). Assigning to self may not work as you expect. I do not think you will be able to replace the SimpleLDAPOb

[SPAM] Re: CONNECTING FROM A SERVERS POOL

2010-03-29 Thread Alberto Luengo Cabanillas (Pexego)
Yeargan, Yancey wrote: I think it is as simple as using multiple URL values separated with spaces. For example: ldap.initalize("url1 url2 url3") The underlying LDAP code will automatically try each URL until one succeeds or they all fail. Yancey Hi Yeargan. Thanks for the quick reply but

Re: python-ldap and kerberos

2010-03-25 Thread Michael Ströder
Pascal, it seems you're not described to the python-ldap-dev list so your posting was delayed in the list maintainer's queue... Pascal wrote: > I'm on an M$AD and I'm trying python-ldap from a LINUX host with Python 2.6.4. > All is ok, I can search_s after a bind_s. > The problem is the plain tex

Re: edirectory question

2010-03-12 Thread Mike Dewhirst
Thanks all - much appreciated Mike On 13/03/2010 2:17am, Michael Ströder wrote: > Yeargan, Yancey wrote: >> >> Your question is really about Novell eDirectory, not the Python LDAP module; > > That's definitely related to Novell eDirectory. > > I vaguely remember that some eDirectory allowed sear

Re: edirectory question

2010-03-12 Thread Michael Ströder
Yeargan, Yancey wrote: > > Your question is really about Novell eDirectory, not the Python LDAP module; That's definitely related to Novell eDirectory. I vaguely remember that some eDirectory allowed searching with an empty search root. Not sure but worth a short test. Ciao, Michael. -

Re: ldap.DECODING_ERROR in ldap.dn.str2dn with python2.4 on amd64

2010-03-12 Thread Michael Ströder
Arvid Requate wrote: > we had a problem with ldap.dn.str2dn showing instable behavior and throwing > ldap.DECODING_ERROR in python2.4 Debian Lenny (amd64). > It seems that using PyArg_ParseTuple with format string "z#" and saving the > length of the string directly into the berval member bv_len d

Re: edirectory question

2010-03-11 Thread Yeargan, Yancey
Your question is really about Novell eDirectory, not the Python LDAP module; so I will provide a brief answer here and you may contact me directly for more eDirectory information. However, I would first make sure that the LDAP search base parameter is set to either "o=central" or "o=suburbs".

Re: Question: Mac OS 10.6 and Python 2.6

2010-03-05 Thread John Cody
> > > > This is a known problem when using a non-Apple supplied Python install: > > http://bugs.python.org/issue6957 > > The bug has more details, but the basic workaround is to install the 10.4 > SDK (it's an optional package when installing Xcode) and using GCC 4.0 > instead of the default 4.2. >

Re: Contributing Mac OS X packages to PyPI

2010-03-04 Thread Ben Gollmer
On Mar 4, 2010, at 3:40 PM, Michael Ströder wrote: > Ben Gollmer wrote: >> I have built universal binary packages for Python-LDAP 2.3.10 on both >> Mac OS X 10.5 (Python 2.5) and 10.6 (Python 2.6). Is it possible to add >> these to the PyPI page, to go along with the Windows installers? They >> ca

Re: Contributing Mac OS X packages to PyPI

2010-03-04 Thread Michael Ströder
Ben Gollmer wrote: > I have built universal binary packages for Python-LDAP 2.3.10 on both > Mac OS X 10.5 (Python 2.5) and 10.6 (Python 2.6). Is it possible to add > these to the PyPI page, to go along with the Windows installers? They > can be very useful for users that don't have Xcode / gcc ins

Re: Question: Mac OS 10.6 and Python 2.6

2010-03-04 Thread Ben Gollmer
On Mar 2, 2010, at 11:41 AM, John Cody wrote: > I've got the 2.3.11 release of python-ldap, latest version of XCode, and > Python 2.6.2 installed. > > I run: $ sudo python setup.py build > and I get the following output. > /Developer/SDKs/MacOSX10.4u.sdk/usr/include/stdarg.h:4:25: error: stdarg

Re: Question: Mac OS 10.6 and Python 2.6

2010-03-02 Thread John Cody
I've got the 2.3.11 release of python-ldap, latest version of XCode, and Python 2.6.2 installed. I run: $ sudo python setup.py build and I get the following output. extra_compile_args: extra_objects: include_dirs: /usr/include /usr/include/sasl library_dirs: /usr/lib libs: ldap_r lber sasl2 ssl c

Re: Question: Mac OS 10.6 and Python 2.6

2010-03-02 Thread Michael Ströder
Torsten Kurbad wrote: > Exactly What kind of problem are you encountering while trying to > build on 10.6? Note that recent release 2.3.11 contains fixes for backward-compability to build with OpenLDAP 2.3 libs. You probably need that when building for Mac OS X. Ciao, Michael. --

Re: Question: Mac OS 10.6 and Python 2.6

2010-03-02 Thread Torsten Kurbad
Hi John, > I was wondering if anyone has been successful building > packages for python-ldap for Mac OS X 10.6 and Python 2.6. a bit outdated, but you might have a look at http://svn.iwm-kmrc.de/download/distribution/contrib/python_ldap-2.3.9-py2.6-macosx-10.3-fat.egg This .egg was built on OS

Re: python_ldap 2.3.11 broken on pypi

2010-02-26 Thread Michael Ströder
Tobias Schmidt wrote: > could it be that the latest release of python_ldap (2.3.11) is broken on > pypi? It didn't work inside my buildout and I could not open the archive > after downloading it manually. > > Error message: > > gzip: stdin: unexpected end of file > tar: Child returned status 1

Re: Anyone using LDAPObject.manage_dsa_it()?

2010-02-26 Thread Michael Ströder
Michael Ströder wrote: > For some time there has been a warning in the docs about > LDAPObject.manage_dsa_it() soon vanishing from python-ldap once full support > for LDAPv3 controls is implemented. Since we have that for quite some time now > this inherently broken method should be removed. > > A

Re: ldap.ldapobject.SmartLDAPObject removed

2010-02-08 Thread Andreas Büsching
Hi Michael, Am Freitag 05 Februar 2010 13:34:32 schrieb Michael Ströder: > Michael Ströder wrote: > > Well, SmartLDAPObject is not well tested nor documented and should > > probably be removed anyway... > > [..] > > Well, tls_cacertfile is simply not used in SmartLDAPObject.__init__(). > > The rea

Re: start_tls = 2 is ignored with LDAP URIs starting with LDAP://

2010-02-04 Thread Michael Ströder
Andreas, sorry for my late reply. I'm quite busy at the moment. Andreas Büsching wrote: > I've found a strange behaviour of python-ldap when working with TLS encrypted > connections. I'm not sure if this is a problem of the python bindings or of > libldap or in my head ;-) > > In my first scen

Re: start_tls = 2 is ignored with LDAP URIs starting with LDAP://

2010-02-02 Thread Andreas Büsching
Hi, Has anyone an idea? thanx in advance Andreas Am Freitag 08 Januar 2010 09:39:40 schrieb Andreas Büsching: > I've found a strange behaviour of python-ldap when working with TLS > encrypted connections. I'm not sure if this is a problem of the python > bindings or of libldap or in my head ;-)

Re: ldaps and Active Directory

2010-02-01 Thread Michael Ströder
Patrick A. Treptau wrote: > I am pulling my hair out trying to connect via ldaps to one of our AD > controllers. > > host = "ldaps://ad_host:636" You should always use the fully-qualified which is in the CN of the server certificate's subject DN. > #openssl s_client -CAfile path/to/cert.crt -co

Re: How can i add a booleanMatch type attribute

2010-01-31 Thread Zhang Huangbin
On Jan 31, 2010, at 10:58 PM, Michael Ströder wrote: > Zhang Huangbin wrote: >> How can i add a booleanMatch type attribute with py-ldap? > > Simply like any other attribute provided your attribute value is TRUE or > FALSE. Successed with modlist: ('amavisLocal', ['TRUE']), Thanks :) -- Be

Re: DSML writer

2010-01-31 Thread Michael Ströder
Adam Tauno Williams wrote: > I noticed that python-ldap contains some DSML support; only the XML > produced is invalid [I believe this is caused by its attempt to create > 'pretty' output]. Could you please point me to the details which parts of the XML produced are invalid. Ciao, Michael.

Re: How can i add a booleanMatch type attribute

2010-01-31 Thread Michael Ströder
Zhang Huangbin wrote: > How can i add a booleanMatch type attribute with py-ldap? Simply like any other attribute provided your attribute value is TRUE or FALSE. > Refer to python-ldap-2.3.10/Demo/ldapcontrols.py, i use below code to add new > attribute: > > > l = ldap.initialize('ldap://l

Re: How get get more search results than the server’ s sizelimit?

2010-01-18 Thread Michael Ströder
Dave Kirby wrote: > 2010/1/18 Michael Ströder : > Dave Kirby wrote: > [snip] >>> but according to the python-ldap >>> docs controls are not supported for the search functions even though >>> they are for other functions. >> >> Which version of python-ldap and docs are you referring to? >> > > I wa

  1   2   3   4   5   6   7   >