Sophie

Sophie

distrib > Mageia > 6 > x86_64 > by-pkgid > f9f06df4e5e622b19228625340b32970 > files > 7

python-pycrypto-2.6.1-9.1.mga6.src.rpm

%define oname	pycrypto
%define _exclude_files_from_autoprov %{python_sitearch}/.*\\.so
%define _exclude_files_from_autoprov %{python3_sitearch}/.*\\.so
%define subrel 1

Summary:	Python interface to various crypto algorithms and protocols
Name:		python-%{oname}
Version:	2.6.1
Release:	%mkrel 9
Source0:	http://ftp.dlitz.net/pub/dlitz/crypto/pycrypto/%{oname}-%{version}.tar.gz
Source1:	http://ftp.dlitz.net/pub/dlitz/crypto/pycrypto/%{oname}-%{version}.tar.gz.asc
Patch0:		pycrypto-libm.patch
Patch1:		CVE-2013-7459.patch
Patch2:		python-crypto-2.4-optflags.patch
Patch3:		pycrypto-2.6.1-CVE-2018-6594.patch
License:	Public Domain
Group:		Development/Python
URL:		http://www.pycrypto.org
BuildRequires:	pkgconfig(python2)
BuildRequires:	gmp-devel
BuildRequires:	pkgconfig(python3)
BuildRequires:	python-tools
BuildRequires:	findutils
Obsoletes:	pycrypto =< %{version}-%{release}
Provides:	pycrypto = %{version}-%{release}

%description
The Toolkit is a collection of cryptographic algorithms and protocols,
implemented for use from Python. Among the contents of the package:

 * Hash functions: MD2, MD4, RIPEMD.
 * Block encryption algorithms: AES, ARC2, Blowfish, CAST, DES, Triple-
   DES, IDEA, RC5.
 * Stream encryption algorithms: ARC4, simple XOR.
 * Public-key algorithms: RSA, DSA, ElGamal, qNEW.
 * Protocols: All-or-nothing transforms, chaffing/winnowing.
 * Miscellaneous: RFC1751 module for converting 128-key keys into a set
   of English words, primality testing.
 * Some demo programs (currently all quite old and outdated).

%package -n python3-%{oname}
Summary:	Python 3 interface to various crypto algorithms and protocols
Group:		Development/Python


%description -n python3-%{oname}
PyCrypto is a collection of both secure hash functions (such as MD5 and
SHA), and various encryption algorithms (AES, DES, RSA, ElGamal, etc.).

This is the Python 3 build of the package.

%prep
%setup -q -n %{oname}-%{version}
%patch0 -p0 -b .libm
%patch1 -p1
%patch2 -p1
%patch3 -p0

%build
%global optflags %{optflags} -fno-strict-aliasing
%py2_build
%py3_build


%install
%py2_install
%py3_install

# Remove group write permissions on shared objects
find %{buildroot}%{python2_sitearch} -name '*.so' -exec chmod -c g-w {} \;
find %{buildroot}%{python3_sitearch} -name '*.so' -exec chmod -c g-w {} \;


%check
%{__python2} setup.py test
%{__python3} setup.py test


%files
%doc ChangeLog README COPYRIGHT TODO
%{python2_sitearch}/Crypto/
%{python2_sitearch}/*.egg-info

%files -n python3-%{oname}
%doc ChangeLog README COPYRIGHT TODO
%{python3_sitearch}/Crypto/
%{python3_sitearch}/*.egg-info



%changelog
* Tue Mar 13 2018 philippem <philippem> 2.6.1-9.1.mga6
  (not released yet)
+ Revision: 1208993
- fix CVE-2018-6594, mga#22693

* Wed Dec 28 2016 philippem <philippem> 2.6.1-9.mga6
+ Revision: 1078507
- Throw exception when IV is used with ECB or CTR (CVE-2013-7459) mga#20031

* Fri Feb 12 2016 umeabot <umeabot> 2.6.1-8.mga6
+ Revision: 958630
- Mageia 6 Mass Rebuild

* Wed Oct 07 2015 tv <tv> 2.6.1-7.mga6
+ Revision: 886973
- rebuild for python 3.5

* Wed Oct 15 2014 umeabot <umeabot> 2.6.1-6.mga5
+ Revision: 747192
- Second Mageia 5 Mass Rebuild

* Sat Sep 27 2014 tv <tv> 2.6.1-5.mga5
+ Revision: 729443
- rebuild for missing pythoneggs deps

* Tue Sep 16 2014 umeabot <umeabot> 2.6.1-4.mga5
+ Revision: 688244
- Mageia 5 Mass Rebuild

* Sat May 31 2014 pterjan <pterjan> 2.6.1-3.mga5
+ Revision: 628936
- Rebuild for new Python

* Tue Oct 22 2013 umeabot <umeabot> 2.6.1-2.mga4
+ Revision: 544070
- Mageia 4 Mass Rebuild

* Fri Oct 18 2013 oden <oden> 2.6.1-1.mga4
+ Revision: 509151
- 2.6.1 (fixes CVE-2013-1445)

* Tue Oct 15 2013 pterjan <pterjan> 2.6-4.mga4
+ Revision: 499167
- Rebuild to add different pythonegg provides for python 2 and 3

* Sun Sep 01 2013 philippem <philippem> 2.6-3.mga4
+ Revision: 474109
- add Python 3

* Sun Jan 13 2013 umeabot <umeabot> 2.6-2.mga3
+ Revision: 379314
- Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Sat Sep 08 2012 philippem <philippem> 2.6-1.mga3
+ Revision: 290180
- New upstream release 2.6

* Fri Jul 27 2012 luigiwalser <luigiwalser> 2.3-3.mga3
+ Revision: 274978
- add patch to fix CVE-2012-2417 (from suse via mdv)

* Thu Jan 20 2011 erwan <erwan> 2.3-2.mga1
+ Revision: 27202
- Fixing libm inclusion during fastmath compilation
- imported package python-pycrypto


* Mon Nov 01 2010 Jani Välimaa <wally@mandriva.org> 2.3-2mdv2011.0
+ Revision: 591709
- rebuild for python 2.7

* Sun Sep 12 2010 Guillaume Rousse <guillomovitch@mandriva.org> 2.3-1mdv2011.0
+ Revision: 577728
- update to new version 2.3

* Sat Aug 14 2010 Guillaume Rousse <guillomovitch@mandriva.org> 2.2-1mdv2011.0
+ Revision: 569671
- update to new version 2.2

  + Crispin Boylan <crisb@mandriva.org>
    - Fix description

* Fri Feb 12 2010 Crispin Boylan <crisb@mandriva.org> 2.1.0-1mdv2010.1
+ Revision: 505117
- New release
- Remove applied patches
- Rediff patch1

* Mon Mar 09 2009 Oden Eriksson <oeriksson@mandriva.com> 2.0.1-8mdv2009.1
+ Revision: 353219
- P2: security fix for CVE-2009-0544

* Tue Feb 17 2009 Crispin Boylan <crisb@mandriva.org> 2.0.1-7mdv2009.1
+ Revision: 341346
- Patch1: Fix python2.6 deprecation warnings

* Thu Jan 29 2009 Lev Givon <lev@mandriva.org> 2.0.1-6mdv2009.1
+ Revision: 335379
- Obsolete current release of pycrypto.

* Thu Dec 25 2008 Adam Williamson <awilliamson@mandriva.org> 2.0.1-5mdv2009.1
+ Revision: 318613
- rebuild for python 2.6

* Tue Sep 09 2008 Adam Williamson <awilliamson@mandriva.org> 2.0.1-4mdv2009.0
+ Revision: 282882
- import python-pycrypto