+ case 44:
+
+ $local_sql = "CREATE TABLE object_abuse
+ (
+ objectid bigint,
+ source inet,
+ nr_abuses integer,
+ status text,
+
+ primary key (objectid, source)
+ );";
+ $dbms->query($local_sql);
+ $dbms->query("GRANT SELECT ON log_adv_daemon_email TO GROUP view, GROUP ops, GROUP admin");
+ $dbms->query("GRANT SELECT ON object_abuse TO GROUP view, GROUP ops, GROUP admin");
+ $dbms->query("GRANT INSERT ON object_abuse TO GROUP admin");
+ $dbms->query("GRANT UPDATE ON object_abuse TO GROUP ops, GROUP admin");
+ $dbms->query("GRANT DELETE ON object_abuse TO GROUP admin");
+ $dbms->query("GRANT SELECT ON object_statistics TO GROUP view, GROUP ops, GROUP admin");
+
+ $local_sql = "INSERT INTO type_of_issue (name, suggested_priority, description, active)";
+ $local_sql .= " VALUES ('abuses exceeded',5,'Abuse treshold exceeded from an IP address', true) ";
+ $dbms->query($local_sql);
+
+ case 45:
+
+ $local_sql = "CREATE TABLE service_pattern
+ (
+ service text,
+ rank int,
+ pattern text,
+ action text,
+ argument text,
+
+ primary key (service, rank)
+ )";
+ $dbms->query($local_sql);
+ $local_sql = "INSERT INTO service_pattern VALUES ('ANY', 999999, '.+', 'notify', 'unmatched log')";
+ $dbms->query($local_sql);
+ $local_sql = "INSERT INTO type_of_issue (name, suggested_priority, description, active)";
+ $local_sql .= " VALUES ('unmatched log',5,'Log entries could not be matched', true) ";
+ $dbms->query($local_sql);
+
+ case 46:
+
+ $local_sql = "CREATE TABLE log_abuse
+ (
+ logid bigint,
+ objectid bigint,
+ source inet
+ )";
+ $dbms->query($local_sql);
+
+ case 47:
+
+ $local_sql = "INSERT INTO service_pattern VALUES ('ANY', 999990, '[Ee][Rr][Rr][Oo][Rr]', 'notify', 'Error detected')";
+ $dbms->query($local_sql);
+ $local_sql = "INSERT INTO type_of_issue (name, suggested_priority, description, active)";
+ $local_sql .= " VALUES ('Error detected',5,'An Error is reported in the log', true) ";
+ $dbms->query($local_sql);
+
+ $local_sql = "INSERT INTO service_pattern VALUES ('ANY', 999991, '[Ff][Aa][Ii][Ll]', 'notify', 'Failure detected')";
+ $dbms->query($local_sql);
+ $local_sql = "INSERT INTO type_of_issue (name, suggested_priority, description, active)";
+ $local_sql .= " VALUES ('Failure detected',5,'A Failure is reported in the log', true) ";
+ $dbms->query($local_sql);
+
+ $local_sql = "INSERT INTO service_pattern VALUES ('ANY', 999992, '[Ww][Aa][Rr][Nn]', 'notify', 'Warning detected')";
+ $dbms->query($local_sql);
+ $local_sql = "INSERT INTO type_of_issue (name, suggested_priority, description, active)";
+ $local_sql .= " VALUES ('Warning detected',3,'A Warning is reported in the log', true) ";
+ $dbms->query($local_sql);
+