]> git.ipfire.org Git - people/stevee/ipfire-2.x.git/commitdiff
log.dat: Fix an error with 'unbound' logging too much data.
authorJon Murphy <jon.murphy@ipfire.org>
Fri, 17 Feb 2023 17:53:37 +0000 (11:53 -0600)
committerPeter Müller <peter.mueller@ipfire.org>
Sun, 5 Mar 2023 15:01:31 +0000 (15:01 +0000)
- Make regex "non-greedy"
- grab data up to first occurance of "]" and not last occurance of "]"

Signed-off-by: Jon Murphy <jon.murphy@ipfire.org>
html/cgi-bin/logs.cgi/log.dat

index bf71b3c9f6f9118aec17cadcdb1a96e69b03d021..fbc83f48dd0fdba038c997a3c13d14ba367ce77a 100644 (file)
@@ -75,7 +75,7 @@ my %sections = (
         'suricata' => '(suricata: )',
         'squid' => '(squid\[.*\]: |squid: )',
         'ssh' => '(sshd(?:\(.*\))?\[.*\]: )',
-        'unbound' => '(unbound: \[.*:.*\])(.*:.*$)',
+        'unbound' => '(unbound: \[.*?\])(.*:.*$)',
         'urlfilter bl' => '(installpackage\[urlfilter\]: )',
         'wireless' => '(hostapd:|kernel: ath.*:|kernel: wifi[0-9]:)'
         );