From f969317863bd72cbd3476da771acdd5e0d2f22e3 Mon Sep 17 00:00:00 2001 From: Ultra2D Date: Fri, 4 Mar 2016 16:14:47 +0100 Subject: [PATCH] Human readable program, and append event ID to message --- includes/syslog.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/includes/syslog.php b/includes/syslog.php index a84a79a49..9dce07106 100644 --- a/includes/syslog.php +++ b/includes/syslog.php @@ -111,6 +111,15 @@ function process_syslog($entry, $update) { } unset($matches); + } + else if ($os == 'procurve') { + $matches = array(); + if (preg_match('/^(?P[A-Za-z]+): {2}(?P.*)/', $entry['msg'], $matches)) { + $entry['msg'] = $matches['msg']. " [". $entry['program']. "]"; + $entry['program'] = $matches['program']; + } + unset($matches); + }//end if if (!isset($entry['program'])) {