Comment 1 for bug 1752683

Revision history for this message
Rafael David Tinoco (rafaeldtinoco) wrote :

I have found the cause of why the race condition happened and was able to verify that apache2 upstream version (ldap module) also suffers from the same issue. Instead of re-describing the problem here I'll give you the URLs of where I'm working upstream:

This bug was already opened in 2015:

https://bz.apache.org/bugzilla/show_bug.cgi?id=58483

And again in 2016:

https://bz.apache.org/bugzilla/show_bug.cgi?id=60296

My notes are here:

https://bz.apache.org/bugzilla/show_bug.cgi?id=60296#c7

And actually the notes were the ones that helped me finding all the upstream bits for this particular bug. As you can see in apache upstream bug, an engineer from EA.COM proposed a small patch solving the external lock need that I also identified. He has also reported this in debian project:

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=814980#15

I sent my findings upstream as a new comment to the existing bug in apache2 project because I wanted to check on what was going to be done by the maintainer, since there are multiple ways of solving this (internal and/or external lock), and I could help in any of them.

Maintainer responded:

https://bz.apache.org/bugzilla/show_bug.cgi?id=60296#c8

Saying that he has already fixed this behaviour:

2 Changes with Apache 2.5.1
3
4 *) mod_ldap: Avoid possible crashes, hangs, and busy loops due to
5 improper merging of the cache lock in vhost config.
6 PR 43164 [Eric Covener]

by changing an external (to rmm allocator logic) lock that wasn't working. The lock was being copied in a callback after it was being used, causing the race condition because there was no external (to rmm) lock and rmm lock wasn't being used.