This is an automated email from the git hooks/post-receive script.
mreynolds pushed a commit to branch 389-ds-base-1.3.10
in repository 389-ds-base.
The following commit(s) were added to refs/heads/389-ds-base-1.3.10 by this push:
new da26367 Issue 50829 - Disk monitoring rotated log cleanup causes
heap-use-after-free
da26367 is described below
commit da26367f8aacad806f1d1f1d9ba45ec052c0dd8b
Author: Mark Reynolds <mreynolds(a)redhat.com>
AuthorDate: Fri Jan 17 15:42:00 2020 -0500
Issue 50829 - Disk monitoring rotated log cleanup causes heap-use-after-free
Description: When Disk Monitoring finds that disk space is too low it starts
freeing up disk space by removing rotated logs. However the log
list struct was not properly reset after freeing all the files
in the list. This is what allowed the heap-use-after-free to
occur.
relates:
https://pagure.io/389-ds-base/issue/50829
Reviewed by: firstyear(Thanks!)
---
ldap/servers/slapd/log.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/ldap/servers/slapd/log.c b/ldap/servers/slapd/log.c
index f308a48..2a6ea86 100644
--- a/ldap/servers/slapd/log.c
+++ b/ldap/servers/slapd/log.c
@@ -3240,6 +3240,12 @@ log__delete_rotated_logs()
logp = logp->l_next;
slapi_ch_free((void **)&prev_log);
}
+
+ /* reset the log struct */
+ loginfo.log_access_logchain = NULL;
+ loginfo.log_audit_logchain = NULL;
+ loginfo.log_auditfail_logchain = NULL;
+ loginfo.log_error_logchain = NULL;
}
#define ERRORSLOG 1
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.