Merge in SecAuditLog2 from trunk. (trac #102)

This commit is contained in:
brectanus
2007-04-25 21:16:51 +00:00
parent 424a51c0f7
commit 1a9954c2a3
5 changed files with 106 additions and 2 deletions

View File

@@ -886,5 +886,16 @@ void sec_audit_logger(modsec_rec *msr) {
if (text == NULL) return;
nbytes = strlen(text);
if (msr->txcfg->debuglog_level >= 9) {
msr_log(msr, 9, "Audit Log: Writing %d bytes to primary concurrent index", nbytes);
}
apr_file_write_full(msr->txcfg->auditlog_fd, text, nbytes, &nbytes_written);
/* Write to the secondary audit log if we have one */
if (msr->txcfg->auditlog2_fd != NULL) {
if (msr->txcfg->debuglog_level >= 9) {
msr_log(msr, 9, "Audit Log: Writing %d bytes to secondary concurrent index", nbytes);
}
apr_file_write_full(msr->txcfg->auditlog2_fd, text, nbytes, &nbytes_written);
}
}