Skip to content

Commit 8d4124e

Browse files
committed
Enable sanitizing JSON request bodies in native audit log format
f86de56 enabled sanitizing JSON request body data in JSON audit log formats (the commit message is misleading). This commit supplements JSON request body sanitization to support sanitized elements in native audit log formats.
1 parent 830f0b7 commit 8d4124e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

apache2/msc_logging.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1739,7 +1739,7 @@ void sec_audit_logger_native(modsec_rec *msr) {
17391739
for(i = 0; i < tarr->nelts; i++) {
17401740
msc_arg *arg = (msc_arg *)telts[i].val;
17411741
if (arg->origin != NULL &&
1742-
strcmp(arg->origin, "BODY") != 0)
1742+
( strcmp(arg->origin, "BODY") != 0 && strcmp(arg->origin, "JSON") != 0) )
17431743
continue;
17441744

17451745
if (last_offset == 0) { /* The first time we're here. */

0 commit comments

Comments
 (0)