Audit Log Creates Invalid JSON
Bug #1642375 reported by
Matthew B
This bug report is a duplicate of:
Bug #1548745: audit_log json is not escaping characters properly.
Edit
Remove
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Percona Server moved to https://jira.percona.com/projects/PS |
New
|
Undecided
|
Unassigned |
Bug Description
The audit_log plugin does not produce valid JSON strings when <tab> is contained in the query. Please add the following patch to filter/escape tab in JSON output.
diff --git a/audit_log.c b/audit_log.c
index 39078fa..4c3224d 100644
--- a/audit_log.c
+++ b/audit_log.c
@@ -224,6 +224,7 @@ void json_escape(const char *in, size_t *inlen, char *out, size_t *outlen)
{ '"', 2, "\\\"" },
{ '\r', 2, "\\r" },
{ '\n', 2, "\\n" },
+ { '\t', 2, "\\t" },
{ 0, 0, NULL }
};
tags: | added: audit |
To post a comment you must log in.