Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be available on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 733077 - OpenLDAP 2.4.23 segfaults when using back-sql
Summary: OpenLDAP 2.4.23 segfaults when using back-sql
Alias: None
Product: Fedora
Classification: Fedora
Component: openldap
Version: 15
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Jan Vcelak
QA Contact: Fedora Extras Quality Assurance
Depends On: 727533
TreeView+ depends on / blocked
Reported: 2011-08-24 16:04 UTC by Jan Vcelak
Modified: 2013-03-04 01:29 UTC (History)
4 users (show)

Fixed In Version: openldap-2.4.24-5.fc15
Doc Type: Bug Fix
Doc Text:
Clone Of: 727533
Last Closed: 2011-11-17 23:42:36 UTC
Type: ---

Attachments (Terms of Use)

Description Jan Vcelak 2011-08-24 16:04:04 UTC
Only F15 affected, F16+ is fixed.

+++ This bug was initially created as a clone of Bug #727533 +++

Created attachment 516308 [details]
The patch that fixes this issue.

Description of problem:
The bug makes openldap with back-sql unusable at least since version 2.4.22. 
Whenever a user tries to authenticate the server segfaults. The issue is described here:

and a fix has been provided in OpenLDAP 2.4.26. Please either release 2.4.26 in the yum repositories OR include the attached patch which fixes this issue.

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

How reproducible:
Set up OpenLDAP 2.4.23 with back-sql and then run ldapwhoami with one of the users from the database (not the Manager user from the slapd.conf).

Actual results:
The slapd daemon segfaults.

Expected results:
The DN of the authenticated user, and (of course) slapd not segfaulting.

Additional info:
I provided a patch in the attachment which works if applied to 2.4.23 (the current version in the repository). The patch is an adapted version of Howard Chu's commit in the OpenLDAP GIT repository:

It was meant to be applied on 2.4.25. I adapted it to work with 2.4.23.

An update to 2.4.26 would of course also be a solution.

--- Additional comment from jvcelak@redhat.com on 2011-08-09 19:12:22 CEST ---

It can be reproduced, the fix works and is included upstream. Thank you for your report.

--- Additional comment from jvcelak@redhat.com on 2011-08-09 19:16:55 CEST ---

Created attachment 517450 [details]
configuration files for quick setup

Ondrej (QA), I'm attaching some configuration files I used when setting up OpenLDAP back_sql + PostgreSQL.

I always managed to reproduce the segfault with:
# ldapsearch -x -b "o=sql,c=RU" +

--- Additional comment from jvcelak@redhat.com on 2011-08-15 10:24:50 CEST ---

Resolved in openldap-2.4.23-17.el6

Comment 1 Fedora Update System 2011-08-24 19:39:31 UTC
openldap-2.4.24-4.fc15 has been submitted as an update for Fedora 15.

Comment 2 Fedora Update System 2011-08-26 19:04:28 UTC
Package openldap-2.4.24-4.fc15:
* should fix your issue,
* was pushed to the Fedora 15 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing openldap-2.4.24-4.fc15'
as soon as you are able to.
Please go to the following url:
then log in and leave karma (feedback).

Comment 3 Fedora Update System 2011-09-12 19:02:37 UTC
openldap-2.4.24-5.fc15 has been submitted as an update for Fedora 15.

Comment 4 Fedora Update System 2011-11-17 23:42:36 UTC
openldap-2.4.24-5.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.

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