[Bug 1464090] Re: Please backport python-ldap3 0.9.4.2-1 (universe) from utopic
Tim Landscheidt
tim at tim-landscheidt.de
Mon Sep 14 21:28:25 UTC 2015
Tested with:
| #!/usr/bin/python3
|
| import re
|
| import ldap3
|
| if __name__ == '__main__':
| # Get user name and password.
| with open('/etc/ldap.conf', 'r') as f:
| for line in f.readlines():
| if line == '\n':
| continue
| m = re.match('^([^ ]+) +(.*?) *\n$', line)
| if m.group(1) == 'binddn':
| binddn = m.group(2)
| elif m.group(1) == 'bindpw':
| bindpw = m.group(2)
|
| # Connect to LDAP server.
| server = ldap3.Server('ldap-eqiad.wikimedia.org')
| conn = ldap3.Connection(server, read_only=True,
| user=binddn, password=bindpw)
| conn.bind()
| conn.start_tls()
|
| # Query.
| conn.search('ou=hosts,dc=wikimedia,dc=org',
| '(puppetVar=instanceproject=%s)' % 'tools',
| ldap3.SEARCH_SCOPE_WHOLE_SUBTREE,
| attributes=ldap3.ALL_ATTRIBUTES)
| for responseitem in conn.response:
| print(repr(responseitem))
for python3-ldap3 and amending the shebang line and the print call for
python-ldap3 (Python 2).
** Changed in: trusty-backports
Status: New => Confirmed
** Description changed:
Please backport python-ldap3 0.9.4.2-1 (universe) from utopic to
precise, trusty.
Reason for the backport:
========================
Cf. https://phabricator.wikimedia.org/T101824.
Testing:
========
Mark off items in the checklist [X] as you test them, but please leave the checklist so that backporters can quickly evaluate the state of testing.
You can test-build the backport in your PPA with backportpackage:
$ backportpackage -u ppa:<lp username>/<ppa name> -s utopic -d precise python-ldap3
$ backportpackage -u ppa:<lp username>/<ppa name> -s utopic -d trusty python-ldap3
* precise:
[ ] Package builds without modification
[ ] python-ldap3 installs cleanly and runs
[ ] python3-ldap3 installs cleanly and runs
* trusty:
[X] Package builds without modification
- [ ] python-ldap3 installs cleanly and runs
- [ ] python3-ldap3 installs cleanly and runs
+ [X] python-ldap3 installs cleanly and runs
+ [X] python3-ldap3 installs cleanly and runs
No reverse dependencies
--
You received this bug notification because you are a member of Ubuntu
Backporters, which is subscribed to Precise Backports.
Matching subscriptions: ubuntu-backporters
https://bugs.launchpad.net/bugs/1464090
Title:
Please backport python-ldap3 0.9.4.2-1 (universe) from utopic
To manage notifications about this bug go to:
https://bugs.launchpad.net/precise-backports/+bug/1464090/+subscriptions
More information about the ubuntu-backports
mailing list