From 9afcfe2eb0d9c16a3f658e3e0cae005b6502e7c8 Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Jan 22 2018 01:18:27 +0000 Subject: Fix for libxcrypt - do not assume "crypt()" function is provided by glibc; #1536881 --- diff --git a/community-mysql-libxcrypt.patch b/community-mysql-libxcrypt.patch new file mode 100644 index 0000000..177f9bc --- /dev/null +++ b/community-mysql-libxcrypt.patch @@ -0,0 +1,38 @@ +Do not assume, that "crypt" function is provided by glibc; #1536881 + +--- mysql-5.7.21/include/my_global.h 2017-12-28 04:46:26.000000000 +0100 ++++ mysql-5.7.21/include/my_global.h_patched 2018-01-22 01:01:42.450315852 +0100 +@@ -49,6 +49,9 @@ + #include + #include /* Recommended by debian */ + #include ++#if defined(HAVE_CRYPT_H) ++#include ++#endif + + #ifdef HAVE_SYS_SOCKET_H + #include + + +--- mysql-5.7.21/configure.cmake 2017-12-28 04:46:26.000000000 +0100 ++++ mysql-5.7.21/configure.cmake_patched 2018-01-22 01:00:09.955057755 +0100 +@@ -493,6 +493,7 @@ CHECK_INCLUDE_FILES (fnmatch.h HAVE_FNMA + CHECK_INCLUDE_FILES (sys/un.h HAVE_SYS_UN_H) + CHECK_INCLUDE_FILES (vis.h HAVE_VIS_H) # Used by libedit + CHECK_INCLUDE_FILES (sasl/sasl.h HAVE_SASL_SASL_H) # Used by memcached ++CHECK_INCLUDE_FILES (crypt.h HAVE_CRYPT_H) + + # For libevent + CHECK_INCLUDE_FILES(sys/devpoll.h HAVE_DEVPOLL) + + +--- mysql-5.7.21/config.h.cmake 2017-12-28 04:46:26.000000000 +0100 ++++ mysql-5.7.21/config.h.cmake_patched 2018-01-22 01:51:02.522570765 +0100 +@@ -62,6 +62,7 @@ + #cmakedefine HAVE_SYS_UN_H 1 + #cmakedefine HAVE_VIS_H 1 + #cmakedefine HAVE_SASL_SASL_H 1 ++#cmakedefine HAVE_CRYPT_H 1 + + /* Libevent */ + #cmakedefine HAVE_DEVPOLL 1 diff --git a/community-mysql.spec b/community-mysql.spec index 91177ca..8481c8e 100644 --- a/community-mysql.spec +++ b/community-mysql.spec @@ -134,6 +134,7 @@ Patch52: %{pkgnamepatch}-sharedir.patch Patch70: %{pkgnamepatch}-5.7.9-major.patch Patch71: %{pkgnamepatch}-openssl11.patch Patch72: %{pkgnamepatch}-tirpc.patch +Patch73: %{pkgnamepatch}-libxcrypt.patch # Patches taken from boost 1.59 Patch115: boost-1.58.0-pool.patch @@ -421,6 +422,7 @@ by any other package than mysql-connector-odbc. %endif %patch71 -p1 %patch72 -p1 +%patch73 -p1 # Patch Boost pushd boost/boost_1_59_0 @@ -994,6 +996,8 @@ fi - Add support for libtirpc - Fix for various CVEs listed on http://www.oracle.com/technetwork/security-advisory/cpujan2018-3236628.html +- Add fix for libxcrypt - do not assume "crypt()" function is provided by glibc + Resolves: #1536881 * Sat Jan 20 2018 Björn Esser - 5.7.20-5 - Rebuilt for switch to libxcrypt