[Openvas-commits] r12896 - in trunk/openvas-manager: . src

scm-commit at wald.intevation.org scm-commit at wald.intevation.org
Thu Feb 23 10:43:38 CET 2012


Author: mattm
Date: 2012-02-23 10:43:38 +0100 (Thu, 23 Feb 2012)
New Revision: 12896

Modified:
   trunk/openvas-manager/ChangeLog
   trunk/openvas-manager/src/manage_sql.c
Log:
	* src/manage_sql.c (create_tables): Add note about overlapping ranges.

Modified: trunk/openvas-manager/ChangeLog
===================================================================
--- trunk/openvas-manager/ChangeLog	2012-02-23 09:36:58 UTC (rev 12895)
+++ trunk/openvas-manager/ChangeLog	2012-02-23 09:43:38 UTC (rev 12896)
@@ -1,3 +1,7 @@
+2012-02-23  Matthew Mundell <matthew.mundell at greenbone.net>
+
+	* src/manage_sql.c (create_tables): Add note about overlapping ranges.
+
 2012-02-22  Matthew Mundell <matthew.mundell at greenbone.net>
 
 	* src/manage_sql.c (create_port_range): If the new range overlaps any

Modified: trunk/openvas-manager/src/manage_sql.c
===================================================================
--- trunk/openvas-manager/src/manage_sql.c	2012-02-23 09:36:58 UTC (rev 12895)
+++ trunk/openvas-manager/src/manage_sql.c	2012-02-23 09:43:38 UTC (rev 12896)
@@ -952,6 +952,9 @@
   sql ("CREATE INDEX IF NOT EXISTS nvts_by_name ON nvts (name);");
   sql ("CREATE INDEX IF NOT EXISTS nvts_by_family ON nvts (family);");
   sql ("CREATE TABLE IF NOT EXISTS overrides (id INTEGER PRIMARY KEY, uuid UNIQUE, owner INTEGER, nvt, creation_time, modification_time, text, hosts, port, threat, new_threat, task INTEGER, result INTEGER, end_time);");
+  /* Overlapping port ranges will cause problems, at least for the port
+   * counting.  OMP CREATE_PORT_LIST and CREATE_PORT_RANGE check for this,
+   * but whoever creates a predefined port list must check this manually. */
   sql ("CREATE TABLE IF NOT EXISTS port_lists (id INTEGER PRIMARY KEY, uuid UNIQUE, owner INTEGER, name, comment);");
   sql ("CREATE TABLE IF NOT EXISTS port_lists_trash (id INTEGER PRIMARY KEY, uuid UNIQUE, owner INTEGER, name, comment);");
   sql ("CREATE TABLE IF NOT EXISTS port_ranges (id INTEGER PRIMARY KEY, uuid UNIQUE, port_list INTEGER, type, start, end, comment, exclude);");



More information about the Openvas-commits mailing list