From 2cb1563f63386b35a69e460051aa9b4a2851d104 Mon Sep 17 00:00:00 2001 From: ftimme <ft@falkotimme.com> Date: Wed, 30 May 2012 07:30:44 -0400 Subject: [PATCH] - Added (clickable) placeholders to client messaging function. - Added check so that the client password isn't inserted into the message (for security reasons). --- server/mods-available/monitor_core_module.inc.php | 19 +++++++++++++++++-- 1 files changed, 17 insertions(+), 2 deletions(-) diff --git a/server/mods-available/monitor_core_module.inc.php b/server/mods-available/monitor_core_module.inc.php index ec85bed..fa1b189 100644 --- a/server/mods-available/monitor_core_module.inc.php +++ b/server/mods-available/monitor_core_module.inc.php @@ -120,6 +120,13 @@ global $app; /* + * This monitoring is expensive, so do it only every 15 minutes + */ + $min = @date('i'); + if ($min % 15 != 0) return; + + + /* * First we get the Monitoring-data from the tools */ $res = $this->_tools->monitorEmailQuota(); @@ -406,6 +413,9 @@ * First we get the Monitoring-data from the tools */ $res = $this->_tools->monitorSystemUpdate(); + + //* Ensure that output is encoded so that it does not break the serialize + $res['data']['output'] = htmlentities($res['data']['output']); /* * Insert the data into the database @@ -692,6 +702,9 @@ * First we get the Monitoring-data from the tools */ $res = $this->_tools->monitorISPCCronLog(); + + //* Ensure that output is encoded so that it does not break the serialize + $res['data']['output'] = htmlentities($res['data']['output']); /* * Insert the data into the database @@ -794,8 +807,10 @@ private function _delOldRecords($type, $serverId) { global $app; - $now = time(); - $old = $now - (4 * 60); // 4 minutes + // $now = time(); + // $old = $now - (4 * 60); // 4 minutes + $old = 'UNIX_TIMESTAMP() - 240'; + /* * ATTENTION if i do NOT pay attention of the server id, i delete all data (of the type) * of ALL servers. This means, if i have a multiserver-environment and a server has a -- Gitblit v1.9.1