Added Patch 1: Fix pip install failure in FIPS mode (rhbz#1430774)
This commit is contained in:
parent
dc8ba54d85
commit
50953dcc78
2 changed files with 39 additions and 1 deletions
29
Fix-pip-install-in-FIPS-mode.patch
Normal file
29
Fix-pip-install-in-FIPS-mode.patch
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
From 1dc2aa897ddda51503572f3f70a4818cf9a3884d Mon Sep 17 00:00:00 2001
|
||||
From: Tomas Orsava <torsava@redhat.com>
|
||||
Date: Fri, 17 Mar 2017 13:14:56 +0100
|
||||
Subject: [PATCH] Fix `pip install` in FIPS mode
|
||||
|
||||
Resolves: rhbz#1430774
|
||||
---
|
||||
pip/utils/hashes.py | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pip/utils/hashes.py b/pip/utils/hashes.py
|
||||
index 9602970..c6d7524 100644
|
||||
--- a/pip/utils/hashes.py
|
||||
+++ b/pip/utils/hashes.py
|
||||
@@ -39,7 +39,10 @@ class Hashes(object):
|
||||
gots = {}
|
||||
for hash_name in iterkeys(self._allowed):
|
||||
try:
|
||||
- gots[hash_name] = hashlib.new(hash_name)
|
||||
+ if hash_name == 'md5':
|
||||
+ gots[hash_name] = hashlib.new(hash_name, usedforsecurity=False)
|
||||
+ else:
|
||||
+ gots[hash_name] = hashlib.new(hash_name)
|
||||
except (ValueError, TypeError):
|
||||
raise InstallationError('Unknown hash name: %s' % hash_name)
|
||||
|
||||
--
|
||||
2.11.0
|
||||
|
||||
|
|
@ -17,7 +17,7 @@
|
|||
|
||||
Name: python-%{srcname}
|
||||
Version: 8.1.2
|
||||
Release: 5%{?dist}
|
||||
Release: 6%{?dist}
|
||||
Summary: A tool for installing and managing Python packages
|
||||
|
||||
Group: Development/Libraries
|
||||
|
|
@ -39,6 +39,10 @@ Source1: pip-8.1.2-tests.tar.gz
|
|||
# https://github.com/pypa/pip/issues/1351
|
||||
Patch0: allow-stripping-given-prefix-from-wheel-RECORD-files.patch
|
||||
|
||||
# Fix `pip install` failure in FIPS mode
|
||||
# Resolves: rhbz#1430774
|
||||
Patch1: Fix-pip-install-in-FIPS-mode.patch
|
||||
|
||||
%description
|
||||
Pip is a replacement for `easy_install
|
||||
<http://peak.telecommunity.com/DevCenter/EasyInstall>`_. It uses mostly the
|
||||
|
|
@ -115,6 +119,7 @@ tar -xf %{SOURCE1}
|
|||
%endif
|
||||
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
|
||||
sed -i '1d' pip/__init__.py
|
||||
|
||||
|
|
@ -226,6 +231,10 @@ py.test-%{python3_version} -m 'not network'
|
|||
%endif # with_python3
|
||||
|
||||
%changelog
|
||||
* Wed Apr 04 2018 Tomas Orsava <torsava@redhat.com> - 8.1.2-6
|
||||
- Added Patch 1: Fix `pip install` failure in FIPS mode
|
||||
Resolves: rhbz#1430774
|
||||
|
||||
* Fri Nov 18 2016 Orion Poplawski <orion@cora.nwra.com> - 8.1.2-5
|
||||
- Enable EPEL Python 3 builds
|
||||
- Use new python macros
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue