#5 Upstream release 3.0.0
Merged 3 years ago by churchyard. Opened 3 years ago by cheimes.
rpms/ cheimes/python-ldap release-3.0.0  into  master

file modified
+1
@@ -8,3 +8,4 @@ 

  /python-ldap-3.0.0b2.tar.gz

  /python-ldap-3.0.0b3.tar.gz

  /python-ldap-3.0.0b4.tar.gz

+ /python-ldap-3.0.0.tar.gz

@@ -1,37 +0,0 @@ 

- From e587e8a3020a2967e95278e80a98f4a86b2fd861 Mon Sep 17 00:00:00 2001

- From: Christian Heimes <cheimes@redhat.com>

- Date: Wed, 10 Jan 2018 14:53:44 +0100

- Subject: [PATCH] Ignore SASL methods in DSE test

- 

- Closes: https://github.com/python-ldap/python-ldap/issues/160

- Signed-off-by: Christian Heimes <cheimes@redhat.com>

- ---

-  Tests/t_ldapobject.py | 9 ++++++---

-  1 file changed, 6 insertions(+), 3 deletions(-)

- 

- diff --git a/Tests/t_ldapobject.py b/Tests/t_ldapobject.py

- index 27deadc..2c8ce75 100644

- --- a/Tests/t_ldapobject.py

- +++ b/Tests/t_ldapobject.py

- @@ -520,12 +520,15 @@ class Test00_SimpleLDAPObject(SlapdTestCase):

-          dse = self._ldap_conn.read_rootdse_s()

-          self.assertIsInstance(dse, dict)

-          self.assertEqual(dse[u'supportedLDAPVersion'], [b'3'])

- +        keys = set(dse)

- +        # SASL info may be missing in restricted build environments

- +        keys.discard(u'supportedSASLMechanisms')

-          self.assertEqual(

- -            sorted(dse),

- -            [u'configContext', u'entryDN', u'namingContexts', u'objectClass',

- +            keys,

- +            {u'configContext', u'entryDN', u'namingContexts', u'objectClass',

-               u'structuralObjectClass', u'subschemaSubentry',

-               u'supportedControl', u'supportedExtension', u'supportedFeatures',

- -             u'supportedLDAPVersion', u'supportedSASLMechanisms']

- +             u'supportedLDAPVersion'}

-          )

-          self.assertEqual(

-              self._ldap_conn.get_naming_contexts(),

- -- 

- 2.14.3

- 

@@ -1,53 +0,0 @@ 

- From b18b8ad1a5d826a54cff8e3656eb4b8bc9678692 Mon Sep 17 00:00:00 2001

- From: Christian Heimes <cheimes@redhat.com>

- Date: Wed, 10 Jan 2018 14:35:24 +0100

- Subject: [PATCH] Use correct types for BER en/decode

- 

- ber_scanf() and ber_printf() "i" format uses ber_int_t. lber_types.h

- defines the type as int but Python code assumes the type to be unsigned

- long:

- 

- typedef LBER_INT_T ber_int_t;

- 

- The code was working fine on little endian machines but broke on big

- endian machines. ber_int_t is now correctly parsed as signed int.

- 

- Signed-off-by: Christian Heimes <cheimes@redhat.com>

- ---

-  Modules/ldapcontrol.c | 6 +++---

-  1 file changed, 3 insertions(+), 3 deletions(-)

- 

- diff --git a/Modules/ldapcontrol.c b/Modules/ldapcontrol.c

- index 9522d57..ec50625 100644

- --- a/Modules/ldapcontrol.c

- +++ b/Modules/ldapcontrol.c

- @@ -242,7 +242,7 @@ encode_rfc2696(PyObject *self, PyObject *args)

-      BerElement *ber = 0;

-      struct berval cookie, *ctrl_val;

-      Py_ssize_t cookie_len;

- -    unsigned long size;

- +    int size = 0; /* ber_int_t is int */

-      ber_tag_t tag;

-  

-      if (!PyArg_ParseTuple(args, "is#:encode_page_control", &size,

- @@ -300,7 +300,7 @@ decode_rfc2696(PyObject *self, PyObject *args)

-      struct berval ldctl_value;

-      ber_tag_t tag;

-      struct berval *cookiep;

- -    unsigned long count = 0;

- +    int count = 0;  /* ber_int_t is int */

-      Py_ssize_t ldctl_value_len;

-  

-      if (!PyArg_ParseTuple(args, "s#:decode_page_control",

- @@ -320,7 +320,7 @@ decode_rfc2696(PyObject *self, PyObject *args)

-          goto endlbl;

-      }

-  

- -    res = Py_BuildValue("(kO&)", count, LDAPberval_to_object, cookiep);

- +    res = Py_BuildValue("(iO&)", count, LDAPberval_to_object, cookiep);

-      ber_bvfree(cookiep);

-  

-   endlbl:

- -- 

- 2.14.3

- 

file modified
+6 -10
@@ -1,5 +1,5 @@ 

  ### Abstract ###

- %global prerelease b4

+ # global prerelease b4

  

  # Fix for https://bugzilla.redhat.com/show_bug.cgi?id=1520990

  # openldap does not re-register nss shutdown callbacks after nss_Shutdown is
@@ -12,18 +12,13 @@ 

  

  Name: python-ldap

  Version: 3.0.0

- Release: 0.5.%{?prerelease}%{?dist}

+ Release: 1%{?dist}

  License: Python

  Group: System Environment/Libraries

  Summary: An object-oriented API to access LDAP directory servers

  URL: http://python-ldap.org/

  Source0: https://files.pythonhosted.org/packages/source/p/%{name}/%{name}-%{version}%{?prerelease}.tar.gz

  

- # Workaround for https://github.com/python-ldap/python-ldap/issues/160

- Patch0: 0001-Ignore-SASL-methods-in-DSE-test.patch

- # https://github.com/python-ldap/python-ldap/issues/161

- Patch1: 0001-Use-correct-types-for-BER-en-decode.patch

- 

  ### Build Dependencies ###

  BuildRequires: openldap-devel >= %{openldap_version}

  BuildRequires: openssl-devel
@@ -84,8 +79,6 @@ 

  %prep

  %setup -qc

  pushd %{name}-%{version}%{?prerelease}

- %patch0 -p1

- %patch1 -p1

  popd

  

  mv %{name}-%{version}%{?prerelease} python3
@@ -157,6 +150,9 @@ 

  %{python3_sitearch}/python_ldap-%{version}%{?prerelease}-py%{python3_version}.egg-info

  

  %changelog

+ * Wed Mar 21 2018 Christian Heimes <cheimes@redhat.com> - 3.0.0-1

+ - New upstream release 3.0.0

+ 

  * Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.0.0-0.5.b4

  - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild

  
@@ -300,7 +296,7 @@ 

  * Wed May 17 2006 Matthew Barnes <mbarnes@redhat.com> - 2.2.0-2

  - Put back the epoch line... happy beehive?

  

- * Tue May 15 2006 Matthew Barnes <mbarnes@redhat.com> - 2.2.0-1

+ * Mon May 15 2006 Matthew Barnes <mbarnes@redhat.com> - 2.2.0-1

  - Update to 2.2.0

  - Update python-ldap-2.0.6-rpath.patch and rename it to

    python-ldap-2.2.0-dirs.patch.

file modified
+1 -1
@@ -1,1 +1,1 @@ 

- SHA512 (python-ldap-3.0.0b4.tar.gz) = 11432638a16b6e7180ed2f8f4d9a5ec65e892e2f0b9fcd0a61ace066372a15ac113c943e3f21f371ea53592f20cec0c91d42370754cba48f16cc5f970e1768f6

+ SHA512 (python-ldap-3.0.0.tar.gz) = 707780b9bf2c75451ab13a7e435b89a425a539a206b6faa54d3ab2332d0c46a9df6aeda3ba4b6344b9212c3031d83b2e08249995088f0fcef7a4859964f757d6