summaryrefslogtreecommitdiffstats
path: root/modules-available/syslog/api.inc.php
diff options
context:
space:
mode:
Diffstat (limited to 'modules-available/syslog/api.inc.php')
-rw-r--r--modules-available/syslog/api.inc.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/modules-available/syslog/api.inc.php b/modules-available/syslog/api.inc.php
index 156bc35c..18c42c31 100644
--- a/modules-available/syslog/api.inc.php
+++ b/modules-available/syslog/api.inc.php
@@ -26,8 +26,10 @@ $longdesc = Request::post('longdesc', '', 'string');
if ($type{0} !== '.' && $type{0} !== '~') {
// Spam from IP
- $row = Database::queryFirst('SELECT Count(*) AS cnt FROM clientlog WHERE clientip = :client AND dateline + 3600 > UNIX_TIMESTAMP()', array(':client' => $ip));
- if ($row !== false && $row['cnt'] > 150) exit(0);
+ $row = Database::queryFirst('SELECT Count(*) AS cnt FROM clientlog WHERE clientip = :client AND dateline + 1800 > UNIX_TIMESTAMP()', array(':client' => $ip));
+ if ($row !== false && $row['cnt'] > 250) {
+ exit(0);
+ }
Database::exec('INSERT INTO clientlog (dateline, logtypeid, clientip, machineuuid, description, extra) VALUES (UNIX_TIMESTAMP(), :type, :client, :uuid, :description, :longdesc)', array(
'type' => $type,