Red Hat Bugzilla – Bug 852839
variable dn should not be used in ldbm_back_delete
Last modified: 2013-02-21 03:20:43 EST
This bug is created as a clone of upstream ticket:
char *dn = NULL;
appears to be used in several places in ldbm_back_delete - perhaps references to this variable were not changed to sdn or sdnp when the code was converted to use Slapi_DN instead of string dns?
Please add steps to reproduce /verify
The fix is pushed to origin/389-ds-base-1.2.11.
This is a potential crash bug.
1. trying to delete a tombstone entry but it turned out it is not a tombstone.
2. trying to make a tombstone entry from a tombstone.
3. deleting an entry causes a collision with other operation.
These 3 could crash the server. The first 2 are less likely happening, but the 3rd one could be in a stress.
To verify this bug, making any of these 3 would be tricky. But there is a DEBUG code which referrs the variable. The code is enabled only when --enable-debug is used to build the server AND replication log level is set.
Once, the build candidate is built and the git tag is set, I'm going to build the server with --enable-debug and run the test.
Steps to verify:
Downloaded src RPM: 389-ds-base-22.214.171.124-1.el6.src.rpm (info) (download)
... 3040242 Sep 25 13:47 389-ds-base-126.96.36.199-1.el6.src.rpm
Built from the src rpm with --enable-debug
Set up 2-way MMR; set the replication log level.
Added uid=Nuser2,dc=example,dc=com, then deleted it, which is correctly logged as follows:
[...] ldbm_back_delete - entry: uid=Nuser2,dc=example,dc=com - flags: delete 0 is_tombstone_entry 0 create 1
If 'dn' is not initialized correctly as this bug originally reported, this message should not be able to have "uid=Nuser2,dc=example,dc=com".
Hence, this bug is verified.
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.