diff --git a/.gitignore b/.gitignore index f525d0d..ca62443 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,4 @@ /3.2.tar.gz /3.2.1.tar.gz /3.2.2.tar.gz +/3.3.0.tar.gz diff --git a/0002-Use-ssl.match_hostname-from-the-Python-stdlib.patch b/0002-Use-ssl.match_hostname-from-the-Python-stdlib.patch index d621f65..1d9540e 100644 --- a/0002-Use-ssl.match_hostname-from-the-Python-stdlib.patch +++ b/0002-Use-ssl.match_hostname-from-the-Python-stdlib.patch @@ -1,8 +1,13 @@ -From ceb275ef3c63d4324e05539242283de083bd08d6 Mon Sep 17 00:00:00 2001 -From: Randy Barlow -Date: Wed, 3 Feb 2016 22:10:28 -0500 +From e6adec8cae7c4a7840fb012c6479856caaf18aba Mon Sep 17 00:00:00 2001 +From: Randy Barlow +Date: Fri, 15 Jul 2016 10:12:16 -0400 Subject: [PATCH] Use ssl.match_hostname from the Python stdlib. +This patch removes the bundled ssl.match_hostname library as it was +vulnerable to CVE-2013-7440 and CVE-2013-2099, and wasn't needed +anyway since Fedora >= 22 has the needed module in the Python +standard library. It also adjusts imports so that they exclusively +use the code from Python. --- pymongo/errors.py | 5 +-- pymongo/pool.py | 6 +-- @@ -11,7 +16,7 @@ Subject: [PATCH] Use ssl.match_hostname from the Python stdlib. delete mode 100644 pymongo/ssl_match_hostname.py diff --git a/pymongo/errors.py b/pymongo/errors.py -index fe7b71a..0ba6006 100644 +index fb4c9e4..e8e6350 100644 --- a/pymongo/errors.py +++ b/pymongo/errors.py @@ -16,10 +16,7 @@ @@ -27,12 +32,12 @@ index fe7b71a..0ba6006 100644 class PyMongoError(Exception): diff --git a/pymongo/pool.py b/pymongo/pool.py -index 904c6b1..5fe663c 100644 +index 6e9cc75..41bef83 100644 --- a/pymongo/pool.py +++ b/pymongo/pool.py @@ -44,11 +44,7 @@ from pymongo.server_type import SERVER_TYPE # main thread, to avoid the deadlock. See PYTHON-607. - u('foo').encode('idna') + u'foo'.encode('idna') -try: - from ssl import match_hostname, CertificateError @@ -150,5 +155,5 @@ index f74df15..0000000 - raise CertificateError("no appropriate commonName or " - "subjectAltName fields were found") -- -2.7.0 +2.9.0 diff --git a/python-pymongo.spec b/python-pymongo.spec index 7936d2a..597ec09 100644 --- a/python-pymongo.spec +++ b/python-pymongo.spec @@ -5,7 +5,7 @@ } Name: python-pymongo -Version: 3.2.2 +Version: 3.3.0 Release: 1%{?dist} # All code is ASL 2.0 except bson/time64*.{c,h} which is MIT @@ -27,16 +27,14 @@ BuildRequires: python2-sphinx BuildRequires: python3-devel BuildRequires: python3-setuptools -# Mongodb must run on a little-endian CPU (see bug #630898) -ExcludeArch: ppc ppc64 %{sparc} s390 s390x - %description The Python driver for MongoDB. %package doc -Summary: Documentation for python-pymongo +BuildArch: noarch +Summary: Documentation for python-pymongo %description doc @@ -93,7 +91,7 @@ this module. %package -n python2-pymongo-gridfs Summary: Python GridFS driver for MongoDB -Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: python2-pymongo%{?_isa} = %{version}-%{release} Provides: pymongo-gridfs = %{version}-%{release} Obsoletes: pymongo-gridfs <= 2.1.1-4 %{?python_provide:%python_provide python2-pymongo-gridfs} @@ -124,19 +122,18 @@ cp -a . %{py3dir} %build -CFLAGS="%{optflags}" %{__python2} setup.py build +%py2_build pushd %{py3dir} -CFLAGS="%{optflags}" %{__python3} setup.py build +%py3_build popd pushd doc -make html +make %{?_smp_mflags} html popd %install -rm -rf %{buildroot} %{__python2} setup.py install --skip-build --root $RPM_BUILD_ROOT # Fix permissions chmod 755 %{buildroot}%{python2_sitearch}/bson/*.so @@ -270,6 +267,7 @@ exclude+='|^test_command_monitoring_spec$' exclude+='|^test_gridfs_spec$' exclude+='|^test_uri_spec$' exclude+='|^test_legacy_api$' +exclude+='|^test_sdam_monitoring_spec$' exclude+='|^test_raw_bson$' exclude+=')' pushd test @@ -278,6 +276,15 @@ popd %changelog +* Fri Jul 15 2016 Randy Barlow - 3.3.0-1 +- Update to 3.3.0 (#1356334). +- Remove the exclude arch on big endian systems, since 3.3.0 now supports them. +- Use the newer Python build macros. +- Add a skip test on another test that requires a running mongod. +- Convert the -doc subpackage into a noarch, as it should be. +- python2-pymongo-gridfs now requires python2-pymongo(isa) instead of python-pymongo(isa). +- Build the docs in parallel. + * Tue Mar 15 2016 Randy Barlow - 3.2.2-1 - Update to 3.2.2 (#1318073). diff --git a/sources b/sources index 51bd5bf..4407799 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -30f8d6b5b864f3e93b1cb092364f22f3 3.2.2.tar.gz +1de42b3e27ff20406c23fae2b99d1afa 3.3.0.tar.gz