From 9eff14e4885b86d6f5a8b35c69ebaabd9e74df06 Mon Sep 17 00:00:00 2001 From: Muhammad Moinur Rahman Date: Fri, 24 Feb 2017 21:15:52 +0000 Subject: mail/dbmail: adopt latest fixes from git: - login_disabled option before starttls for pop3 - fix compiler warnings for GCC5 - Fix IMAP mailbox maintanence - prevent assertion in p_string_erase - improve crypt authentication, also don't segfault when spasswd is empty - simplify log_query_time duration logic - Disconnect IMAP clients if only few free FDs left - Add primary key constraint to dbmail_authlog - Rework temporary connection failures - Give sensible default for retry 120s - Add retries for binding and searching - Bump search timeout to 60s - Increase ldap timeout to 600s 10 mins - Refactor deprecated functions - Get timeout from config - Remove redundant event_assign - Remove deprecated non functioning g_mem_profile - Add definition for authldap_free - Revert inadvertent event_assign removal - Reduce failed LDAP connection for search to error - Update LDAP to non deprecated search - Clear the ldap connection - Update ldap deprecated unbind - Fix typo - Update to ldap_unbind_ext_s and remove redundant sigaction - Rebalance commit rollback - Ensure mailbox2dbmail is using Python 2 - Tidy mailbox2dbmail man page - Update description of pid file location in server man page - Boundaries fixups ordering of parts do not add newline on - Prepend headers during delivery - Allow for systems that don't use proc PR: 210274 Submitted by: fluffy --- ...patch-0021-Update-LDAP-to-non-deprecated-search | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 mail/dbmail/files/patch-0021-Update-LDAP-to-non-deprecated-search (limited to 'mail/dbmail/files/patch-0021-Update-LDAP-to-non-deprecated-search') diff --git a/mail/dbmail/files/patch-0021-Update-LDAP-to-non-deprecated-search b/mail/dbmail/files/patch-0021-Update-LDAP-to-non-deprecated-search new file mode 100644 index 000000000000..edb8beff6c50 --- /dev/null +++ b/mail/dbmail/files/patch-0021-Update-LDAP-to-non-deprecated-search @@ -0,0 +1,28 @@ +From 00ff6ae1f64337ca6e723d060ad14873f1661447 Mon Sep 17 00:00:00 2001 +From: Alan Hicks +Date: Wed, 19 Oct 2016 17:52:04 +0100 +Subject: [PATCH 21/33] Update LDAP to non deprecated search + +--- + src/modules/authldap.c | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git src/modules/authldap.c src/modules/authldap.c +index fc9db8e..11c1305 100644 +--- src/modules/authldap.c ++++ src/modules/authldap.c +@@ -282,8 +282,9 @@ static LDAPMessage * authldap_search(const gchar *query) + while (err != 0 && c++ < c_tries) { + // Loop until success or too many retries + +- err = ldap_search_s(_ldap_conn, _ldap_cfg.base_dn, _ldap_cfg.scope_int, +- query, _ldap_attrs, _ldap_attrsonly, &ldap_res); ++ // timeout must be NULL as any value times out! ++ err = ldap_search_ext_s(_ldap_conn, _ldap_cfg.base_dn, _ldap_cfg.scope_int, ++ query, _ldap_attrs, _ldap_attrsonly, NULL, NULL, NULL, LDAP_NO_LIMIT, &ldap_res); + + switch (err) { + case LDAP_SUCCESS: +-- +2.10.1 (Apple Git-78) + -- cgit v1.2.3