Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 266643

Summary: net-nds/openldap-2.4.16 cannot be started with TLS
Product: Gentoo Linux Reporter: Miroslaw Mieszczak <gentoo>
Component: Current packagesAssignee: Gentoo LDAP project <ldap-bugs>
Status: RESOLVED FIXED    
Severity: normal    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: patch file mentioned in error report
new ebuild

Description Miroslaw Mieszczak 2009-04-18 12:28:14 UTC
When try to start slapd with TLS active there is error message:
main: TLS init def ctx failed: -50


Reproducible: Always




There is already bug on openldap bugzilla open:
http://www.openldap.org/its/index.cgi/Software Bugs?id=6053;page=1

and patch available:

--- openldap-2.4.16.orig/libraries/libldap/tls_g.c
+++ openldap-2.4.16/libraries/libldap/tls_g.c
@@ -354,6 +354,9 @@
                gnutls_x509_crt_t certs[VERIFY_DEPTH];
                unsigned int max = VERIFY_DEPTH;
 
+               rc = gnutls_x509_privkey_init(&key);
+               if ( rc < 0 ) return -1;
+
                /* OpenSSL builds the cert chain for us, but GnuTLS
                 * expects it to be present in the certfile. If it's
                 * not, we have to build it ourselves. So we have to
Comment 1 Miroslaw Mieszczak 2009-06-14 19:46:31 UTC
Created attachment 194696 [details, diff]
patch file mentioned in error report
Comment 2 Miroslaw Mieszczak 2009-06-14 19:47:01 UTC
Created attachment 194698 [details]
new ebuild
Comment 3 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2009-07-28 02:11:20 UTC
2.4.17 fixes this, InCVS.