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

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Fri Sep 23 07:59:10 CEST 2011


Author: mattm
Date: 2011-09-23 07:59:08 +0200 (Fri, 23 Sep 2011)
New Revision: 11674

Modified:
   trunk/openvas-manager/ChangeLog
   trunk/openvas-manager/src/omp.c
Log:
	* src/omp.c (omp_xml_handle_end_element): Only send observers when the
	user owns the task.

Modified: trunk/openvas-manager/ChangeLog
===================================================================
--- trunk/openvas-manager/ChangeLog	2011-09-22 20:36:08 UTC (rev 11673)
+++ trunk/openvas-manager/ChangeLog	2011-09-23 05:59:08 UTC (rev 11674)
@@ -1,5 +1,10 @@
 2011-09-22  Matthew Mundell <matthew.mundell at greenbone.net>
 
+	* src/omp.c (omp_xml_handle_end_element): Only send observers when the
+	user owns the task.
+
+2011-09-22  Matthew Mundell <matthew.mundell at greenbone.net>
+
 	* doc/db.png: Really update from SQL.
 
 2011-09-22  Matthew Mundell <matthew.mundell at greenbone.net>

Modified: trunk/openvas-manager/src/omp.c
===================================================================
--- trunk/openvas-manager/src/omp.c	2011-09-22 20:36:08 UTC (rev 11673)
+++ trunk/openvas-manager/src/omp.c	2011-09-23 05:59:08 UTC (rev 11674)
@@ -5466,7 +5466,7 @@
                      G_MARKUP_ERROR_UNKNOWN_ELEMENT,
                      "Error");
         break;
-      
+
       case CLIENT_GET_INFO:
           {
             if (send_element_error_to_client ("get_info", element_name,
@@ -16881,7 +16881,9 @@
                                  name,
                                  comment,
                                  owner,
-                                 observers,
+                                 strcmp (owner, current_credentials.username)
+                                   ? observers
+                                   : "",
                                  config_uuid ? config_uuid : "",
                                  config ? config : "",
                                  escalator_uuid ? escalator_uuid : "",
@@ -17338,7 +17340,11 @@
                                             name,
                                             comment,
                                             owner,
-                                            observers,
+                                            strcmp
+                                              (owner,
+                                               current_credentials.username)
+                                              ? ""
+                                              : observers,
                                             config_uuid ? config_uuid : "",
                                             config ? config : "",
                                             task_config_in_trash (index),
@@ -17440,7 +17446,7 @@
         get_tasks_data_reset (get_tasks_data);
         set_client_state (CLIENT_AUTHENTIC);
         break;
-      
+
       case CLIENT_GET_INFO:
         {
           gchar *result;



More information about the Openvas-commits mailing list