From ba38ae853f43e28788408a6daa7e62e8e5ea32f7bd00197448f9e30815f3e0e7 Mon Sep 17 00:00:00 2001 From: Jan Matejek Date: Thu, 7 Sep 2017 14:49:40 +0000 Subject: [PATCH] Accepting request 521999 from home:vitezslav_cizek:branches:devel:languages:python - Disable memleak tests to fix build with OpenSSL 1.1 (bsc#1055478) * add skip_openssl_memleak_test.patch OBS-URL: https://build.opensuse.org/request/show/521999 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-cryptography?expand=0&rev=69 --- python-cryptography.changes | 6 ++++++ python-cryptography.spec | 2 ++ skip_openssl_memleak_test.patch | 16 ++++++++++++++++ 3 files changed, 24 insertions(+) create mode 100644 skip_openssl_memleak_test.patch diff --git a/python-cryptography.changes b/python-cryptography.changes index 5696a8b..efbe2ea 100644 --- a/python-cryptography.changes +++ b/python-cryptography.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Sep 7 11:18:35 UTC 2017 - vcizek@suse.com + +- Disable memleak tests to fix build with OpenSSL 1.1 (bsc#1055478) + * add skip_openssl_memleak_test.patch + ------------------------------------------------------------------- Thu Aug 3 23:14:49 UTC 2017 - michael@stroeder.com diff --git a/python-cryptography.spec b/python-cryptography.spec index f48a753..7a44065 100644 --- a/python-cryptography.spec +++ b/python-cryptography.spec @@ -31,6 +31,7 @@ Source3: https://files.pythonhosted.org/packages/source/c/cryptography_ve Source4: https://files.pythonhosted.org/packages/source/c/cryptography_vectors/cryptography_vectors-%{version}.tar.gz.asc # PATCH-FIX-SLE disable-uneven-sizes-tests.patch bnc#944204 Patch1: disable-uneven-sizes-tests.patch +Patch2: skip_openssl_memleak_test.patch BuildRequires: %{python_module asn1crypto >= 0.21.0} BuildRequires: %{python_module cffi >= 1.4.1} BuildRequires: %{python_module devel} @@ -87,6 +88,7 @@ functions. tar xvzf %{SOURCE3} %patch1 -p1 +%patch2 -p1 %build export CFLAGS="%{optflags} -fno-strict-aliasing" diff --git a/skip_openssl_memleak_test.patch b/skip_openssl_memleak_test.patch new file mode 100644 index 0000000..b80c87c --- /dev/null +++ b/skip_openssl_memleak_test.patch @@ -0,0 +1,16 @@ +diff --git a/tests/hazmat/backends/test_openssl_memleak.py b/tests/hazmat/backends/test_openssl_memleak.py +index 6e92e34..3280c47 100644 +--- a/tests/hazmat/backends/test_openssl_memleak.py ++++ b/tests/hazmat/backends/test_openssl_memleak.py +@@ -118,9 +118,8 @@ def assert_no_memory_leaks(s, argv=[]): + + + def skip_if_memtesting_not_supported(): +- return pytest.mark.skipif( +- not Binding().lib.Cryptography_HAS_MEM_FUNCTIONS, +- reason="Requires OpenSSL memory functions (>=1.1.0)" ++ return pytest.mark.skip( ++ reason="Our FIPS openssl startup code invokes CRYPTO_malloc() which prevents later debugging via CRYPTO_set_mem_functions()" + ) + +