[Date Prev][Date Next] [Chronological] [Thread] [Top]

(ITS#6172) Crash with baseObject in back-sql



Full_Name: Michael Karcher
Version: 2.4.11
OS: Debian Linux (squeeze)
URL: ftp://ftp.openldap.org/incoming/Michael-Karcher-090614.diff.1
Submission from: (NULL) (87.123.80.3)


slapd gets terminated by libc with an "invalid free" error message when using
the baseObject configuration option (whether with or without file) at the time
of the first query.

This is caused by freeing an entry using "free" that has been allocated using
"entry_dup". This does not match (any more?). Essentially what the code was
trying to to is to duplicate the sql_baseObject to bsi_e. The fix I suggest adds
a function "entry_dup_to" to slapd so that backends can do this operation
cleanly without having to create a temporary dynamic object there is no obvious
clean way to get rid of.

I provide a patch to fix that problem. As it is mostly rearranging things, I
don't think that patch is copyrightable.