diff --git a/0002-openldap-its8727-plug-ber-leaks.patch b/0002-openldap-its8727-plug-ber-leaks.patch new file mode 100644 index 0000000..9b1ec2d --- /dev/null +++ b/0002-openldap-its8727-plug-ber-leaks.patch @@ -0,0 +1,26 @@ +From 11320a9156e1306c251b27443439dc2e1db0107b Mon Sep 17 00:00:00 2001 +From: Howard Chu +Date: Tue, 17 Jan 2017 11:35:54 +0000 +Subject: ITS#8727 plug ber leaks + + +diff --git a/libraries/libldap/request.c b/libraries/libldap/request.c +index 31145432f..7d2d7a458 100644 +--- a/libraries/libldap/request.c ++++ b/libraries/libldap/request.c +@@ -315,6 +315,7 @@ ldap_send_server_request( + LDAP_MUTEX_UNLOCK( &ld->ld_options.ldo_mutex ); + if ( rc == -1 ) { + ld->ld_errno = LDAP_ENCODING_ERROR; ++ ber_free( ber, 1 ); + LDAP_CONN_UNLOCK_IF(m_noconn); + return rc; + } +@@ -334,6 +335,7 @@ ldap_send_server_request( + rc = -1; + } + if ( rc ) { ++ ber_free( ber, 1 ); + LDAP_CONN_UNLOCK_IF(m_noconn); + return rc; + } diff --git a/openldap2.changes b/openldap2.changes index afe8c58..794e09e 100644 --- a/openldap2.changes +++ b/openldap2.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Jan 4 14:13:47 UTC 2019 - Michael Ströder + +- added back-ported fix for OpenLDAP ITS#8727 + (file 0002-openldap-its8727-plug-ber-leaks.patch) + ------------------------------------------------------------------- Thu Dec 20 09:35:55 UTC 2018 - Michael Ströder diff --git a/openldap2.spec b/openldap2.spec index 27713d6..1f641cb 100644 --- a/openldap2.spec +++ b/openldap2.spec @@ -58,6 +58,7 @@ Source16: sysconfig.openldap Source17: openldap_update_modules_path.sh Source18: openldap2.conf Patch1: 0001-ITS-8866-slapo-unique-to-return-filter-used-in-diagn.patch +Patch2: 0002-openldap-its8727-plug-ber-leaks.patch Patch3: 0003-LDAPI-socket-location.dif Patch5: 0005-pie-compile.dif Patch7: 0007-Recover-on-DB-version-change.dif @@ -255,6 +256,7 @@ gzip -k %{S:203} # Unpack and patch OpenLDAP 2.4 %setup -q -a 9 -n openldap-%{version_main} %patch1 -p1 +%patch2 -p1 %patch3 -p1 %patch5 -p1 %patch7 -p1