From patchwork Fri Feb 17 17:53:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: jon X-Patchwork-Id: 6556 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4PJKF46r60z3x1h for ; Fri, 17 Feb 2023 17:54:00 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4PJKF25d2nzkR; Fri, 17 Feb 2023 17:53:58 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4PJKF246DMz2yTq; Fri, 17 Feb 2023 17:53:58 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4PJKF02QrSz2xWH for ; Fri, 17 Feb 2023 17:53:56 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4PJKDz244zzjs; Fri, 17 Feb 2023 17:53:55 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1676656435; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=FpY9ejQvYebmZtTzuR41sHYZCeRZBrEPA0J1SshZW80=; b=OgDOHDirzprHCxJ0sMH4rA8KHSFxYeXHLGDJVQ8nGqrccSZ9vO4t76Qu5LrRNfuH8NkjTi OrQBSe3yv/Qs0kCQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1676656435; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=FpY9ejQvYebmZtTzuR41sHYZCeRZBrEPA0J1SshZW80=; b=l2LeclaOY5Yi90lV5351ilyBo4s47FXj3wVJKtaYQrr8WIWwS6duKZ4K6QOgmOVLTwTmkp ZGlSjW1wQ5XipqCf/XKHZZ1pGA4QuyvMnjxZJR/QEop8IWIyQpvvHJxC0qshW1ZeDZiUjU ls6kOXAeQUux/mNeFPBF2KeL1RDkD8Sw+9MYqasFpE8pswITCYA/ET2XJBZGZyxT8Rbv/V D7OFUd2pIPBbv5Zt9afRT6qidUTBSX9d1yOTnNYuoDO9x/dzb91KdaNysX505IqtT7TIwd HXO1T1+q5fQikwzD5eaC28mTw5BCABqE+DNl1BT3hcOz5hxNRxZWG/HOGw+p6Q== From: Jon Murphy To: development@lists.ipfire.org Subject: [PATCH] log.dat: Fix an error with 'unbound' logging too much data. Date: Fri, 17 Feb 2023 11:53:37 -0600 Message-Id: <20230217175337.1276318-1-jon.murphy@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" - Make regex "non-greedy" - grab data up to first occurance of "]" and not last occurance of "]" Signed-off-by: Jon Murphy --- html/cgi-bin/logs.cgi/log.dat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/html/cgi-bin/logs.cgi/log.dat b/html/cgi-bin/logs.cgi/log.dat index 5fb1fcd5d..17dacbbf5 100644 --- a/html/cgi-bin/logs.cgi/log.dat +++ b/html/cgi-bin/logs.cgi/log.dat @@ -74,7 +74,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]:)' );