Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1433703

Summary: Double free in _ldap/servers/plugins/replication/cl5_api.c:cl5NewDBFile()
Product: Red Hat Enterprise Linux 7 Reporter: mreynolds
Component: 389-ds-baseAssignee: mreynolds
Status: CLOSED DUPLICATE QA Contact: Viktor Ashirov <vashirov>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.3CC: nhosoi, nkinder, rmeggins, vashirov
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1433697 Environment:
Last Closed: 2017-03-23 14:24:09 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1433697    
Bug Blocks:    

Description mreynolds 2017-03-19 12:14:14 UTC
+++ This bug was initially created as a clone of Bug #1433697 +++

This bug is created as a clone of upstream ticket:
https://pagure.io/389-ds-base/issue/49175

#### Issue Description
When fixing our freeipa cluster & redeploying of some replicas, I hit strange ns-slapd crashes. After little debugging & ASANning, I nailed down double-free in cl5NewDBFile error path. Patch is attached, feel free to ask me if you need more info.

#### Package Version and Platform
CentOS 7.2

$ rpm -q 389-ds-base
389-ds-base-1.3.5.10-11.x86_64

#### Steps to reproduce

1. Fill IPC semaphore table (/usr/bin/ipcs) - in my case all available semaphores were consumed by httpd
2. Try to setup replication (I installed FreeIPA replica)

#### Actual results
Crash:
$ dmesg -T
[Sat Mar 18 20:59:31 2017] traps: ns-slapd[3454] general protection ip:7f2fa2f08abd sp:7f2f787ef560 error:0 in libc-2.17.so[7f2fa2e8d000+1b7000]

#### Expected results
ns-slapd shouldn't crash, it should write errors to the log.


Fixed upstream

Comment 2 mreynolds 2017-03-21 20:14:29 UTC
Fixed upstream

Comment 3 Viktor Ashirov 2017-03-22 15:24:39 UTC
Mark, looks like it's a duplicate of https://bugzilla.redhat.com/show_bug.cgi?id=1433697

Comment 4 mreynolds 2017-03-23 14:24:09 UTC

*** This bug has been marked as a duplicate of bug 1433697 ***