Bug 1613174 - ISC dhcpd cannot start TLS session to 389-DS after updating openldap rpm
Summary: ISC dhcpd cannot start TLS session to 389-DS after updating openldap rpm
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: dhcp
Version: 7.5
Hardware: Unspecified
OS: Linux
Target Milestone: rc
: ---
Assignee: Pavel Zhukov
QA Contact: Martin Osvald 🛹
: 1590660 (view as bug list)
Depends On: 1668398 1685940
Blocks: 1663257 1630905 1630913 1660865
TreeView+ depends on / blocked
Reported: 2018-08-07 08:02 UTC by admin
Modified: 2019-09-03 10:33 UTC (History)
4 users (show)

Fixed In Version: bind-9.11.4-4.P2.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1660865 (view as bug list)
Last Closed: 2019-08-06 12:40:10 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2019:2060 None None None 2019-08-06 12:40:26 UTC

Description admin 2018-08-07 08:02:52 UTC
Description of problem: Dhcp server cannot start TLS session to 389 Directory server after updating openldap from 2.4.44-5 to newist version.
Error: Cannot start TLS session to Connect error

dhcpd version: 4.2.5-68
389-ds-base verson:

When I try manually copy old libraries (liblber, libldap, libslapi) back to updated system, dhcpd works fine with TLS to 389-DS.

Version-Release number of selected component (if applicable):2.4.44-15

How reproducible:always

Steps to Reproduce:
1.see description

Actual results: Error: Cannot start TLS session to Connect error

Expected results:

Additional info: We can disable TLS by "ldap-ssl off" option at /etc/dhcp/dhcpd.conf as a workaround.

Comment 2 Matus Honek 2018-08-08 13:46:40 UTC
This seems to me to be the very same as bug 1590660. The bug is internal-only and not within my jurisdiction any more, however it seems the issue is the dhcpd does not initialize libldap's TLS context properly. I'm changing the component to 'dhcp' so as to be handled on their side.

Comment 3 Ramesh Sahoo 2018-08-20 02:54:04 UTC
*** Bug 1590660 has been marked as a duplicate of this bug. ***

Comment 10 Pavel Zhukov 2019-01-22 16:04:40 UTC
The problem came from bind dst library [1]. it effectively breaks random numbers generation for any client but BIND [2] so SSL_connect fails with -1.
As a workaround we can call ldap_set_option(NEWCTX) from within dhcp code before isc_lib_register() to use default implementation but I'm not sure if it'll not break anything else.  At first glance it should not.

#0  dst__entropy_getdata (buf=0x7ffff7fc71c8, len=16, pseudo=pseudo@entry=isc_boolean_false) at ../../../lib/dns/dst_api.c:1918
#1  0x00007ffff775f47f in entropy_get (buf=<optimized out>, num=<optimized out>) at ../../../lib/dns/openssl_link.c:73
#2  0x00007ffff3e7cca0 in SSL_CTX_new (meth=0x7ffff40a2820 <SSLv23_method_data.18871>) at ssl_lib.c:2003
#3  0x00007ffff6dde7e1 in ldap_int_tls_init_ctx (lo=0x7ffff6ffc040 <ldap_int_global_options>, is_server=0) at tls2.c:269
#4  0x00007ffff6ddf1f6 in ldap_pvt_tls_set_option (ld=ld@entry=0x0, option=option@entry=24591, arg=arg@entry=0x7fffffffd300) at tls2.c:864
#5  0x00007ffff6dd3e8b in ldap_set_option (ld=0x0, option=option@entry=24591, invalue=invalue@entry=0x7fffffffd300) at options.c:787
#6  0x00005555555a204c in ldap_start () at ldap.c:803
#7  0x00005555555a39d5 in ldap_read_config () at ldap.c:1383
#8  0x0000555555561646 in main (argc=<optimized out>, argv=<optimized out>) at dhcpd.c:617

dst__entropy_getdata(void *buf, unsigned int len, isc_boolean_t pseudo) {
#ifdef BIND9
[ ... omitted ... ] 

	return (ISC_R_NOTIMPLEMENTED);    // <=  !!!!! FAIL !!!!

Comment 15 errata-xmlrpc 2019-08-06 12:40:10 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.