From 533bbd93f72c1d515dc2599696fde4a6fff3537c Mon Sep 17 00:00:00 2001 From: sebres Date: Mon, 2 Nov 2026 16:52:48 +0100 Subject: [PATCH] remove unneeded (default) include, improved grp-regex (with negative lookahead for msg and remote_ip tokens) --- config/filter.d/authelia.conf | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/config/filter.d/authelia.conf b/config/filter.d/authelia.conf index f5394aeb..dae96d14 100644 --- a/config/filter.d/authelia.conf +++ b/config/filter.d/authelia.conf @@ -8,11 +8,6 @@ # logtype = json (structured JSON format) # -[INCLUDES] - -# Load customizations if any available -after = authelia.local - [Definition] # Log format: "file" (standard key-value text) or "json" @@ -27,12 +22,12 @@ journalmatch = _SYSTEMD_UNIT=authelia.service [lt_file] datepattern = {^LN-BEG}time="{DATE}"\s+ -grp = (?:\w+=("(?:[^\\"]|\\.)*"|\S+)\s+)* +grp = (?:(?!msg|remote_ip)\w+=("(?:[^\\"]|\\.)*"|\S+)\s+)* failregex = ^\s*%(grp)smsg="Unsuccessful \S+ authentication attempt by user '(?:[^\\']|\\.)*'[^"]*" %(grp)sremote_ip= [lt_json] datepattern = "time":"{DATE}" -grp = (?:"\w+":("(?:[^\\"]|\\.)*"|\S+),\s*)* +grp = (?:"(?!msg|remote_ip)\w+":("(?:[^\\"]|\\.)*"|\S+),\s*)* failregex = ^{%(grp)s"msg":"Unsuccessful \S+ authentication attempt by user '(?:[^\\']|\\.)*'[^"]*",%(grp)s"remote_ip":"" ^{%(grp)s"remote_ip":"",%(grp)s"msg":"Unsuccessful \S+ authentication attempt by user '(?:[^\\']|\\.)*'[^"]*"