[Openvas-commits] r5761 - in trunk/openvas-plugins: . scripts
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Fri Oct 30 14:42:22 CET 2009
Author: mime
Date: 2009-10-30 14:42:19 +0100 (Fri, 30 Oct 2009)
New Revision: 5761
Added:
trunk/openvas-plugins/scripts/cherokee_36874.nasl
trunk/openvas-plugins/scripts/ePo_detect.nasl
trunk/openvas-plugins/scripts/joomla_detect.nasl
trunk/openvas-plugins/scripts/landesk_detect.nasl
Modified:
trunk/openvas-plugins/ChangeLog
trunk/openvas-plugins/cve_current.txt
Log:
Added new plugins
Modified: trunk/openvas-plugins/ChangeLog
===================================================================
--- trunk/openvas-plugins/ChangeLog 2009-10-30 07:33:27 UTC (rev 5760)
+++ trunk/openvas-plugins/ChangeLog 2009-10-30 13:42:19 UTC (rev 5761)
@@ -1,3 +1,13 @@
+2009-10-30 Michael Meyer <michael.meyer at intevation.de>
+
+ * scripts/landesk_detect.nasl,
+ scripts/ePo_detect.nasl,
+ scripts/cherokee_36874.nasl:
+ Added new plugins.
+
+ * scripts/joomla_detect.nasl:
+ Added new plugin developed by Angelo Compagnucci.
+
2009-10-29 Thomas Reinke <reinke at securityspace.com>
* scripts/gather-package-list.nasl
Update for Ubuntu 9.10 support
Modified: trunk/openvas-plugins/cve_current.txt
===================================================================
--- trunk/openvas-plugins/cve_current.txt 2009-10-30 07:33:27 UTC (rev 5760)
+++ trunk/openvas-plugins/cve_current.txt 2009-10-30 13:42:19 UTC (rev 5761)
@@ -208,3 +208,4 @@
CVE-2009-3588 SecPod svn L
36830 Greenbone svn R
36833 Greenbone svn R
+36874 Greenbone svn R
Added: trunk/openvas-plugins/scripts/cherokee_36874.nasl
===================================================================
--- trunk/openvas-plugins/scripts/cherokee_36874.nasl 2009-10-30 07:33:27 UTC (rev 5760)
+++ trunk/openvas-plugins/scripts/cherokee_36874.nasl 2009-10-30 13:42:19 UTC (rev 5761)
@@ -0,0 +1,84 @@
+###############################################################################
+# OpenVAS Vulnerability Test
+# $Id$
+#
+# Cherokee Directory Traversal Vulnerability
+#
+# Authors:
+# Michael Meyer
+#
+# Copyright:
+# Copyright (c) 2009 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(100326);
+ script_bugtraq_id(36874);
+ script_version ("1.0-$Revision$");
+
+ script_name("Cherokee Directory Traversal Vulnerability");
+
+desc = "Overview:
+Cherokee is prone to a directory-traversal vulnerability because it
+fails to sufficiently sanitize user-supplied input data.
+
+Exploiting the issue may allow an attacker to obtain sensitive
+information that could aid in further attacks.
+
+Cherokee 0.5.4 and prior versions are vulnerable.
+
+References:
+http://www.securityfocus.com/bid/36874
+http://www.alobbs.com/modules.php?op=modload&name=cherokee&file=index
+http://freetexthost.com/ncyss3plli
+
+Risk factor : Medium";
+
+ script_description(desc);
+ script_summary("Determine if Cherokee Web Server version is <= 0.5.4");
+ script_category(ACT_GATHER_INFO);
+ script_family("Web Servers");
+ script_copyright("This script is Copyright (C) 2009 Greenbone Networks GmbH");
+ script_dependencies("find_service.nes","http_version.nasl");
+ script_require_ports("Services/www", 80);
+ exit(0);
+}
+
+include("http_func.inc");
+include("version_func.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("Cherokee" >< banner) {
+
+ if(!version = eregmatch(pattern:"Server: Cherokee/([0-9.]+)", string:banner))exit(0);
+ vers = version[1];
+
+ if(!isnull(vers)) {
+ if(version_is_less_equal(version: vers,test_version:"0.5.4")) {
+ security_warning(port:port);
+ exit(0);
+ }
+ }
+ }
+
+exit(0);
+
Property changes on: trunk/openvas-plugins/scripts/cherokee_36874.nasl
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Added: trunk/openvas-plugins/scripts/ePo_detect.nasl
===================================================================
--- trunk/openvas-plugins/scripts/ePo_detect.nasl 2009-10-30 07:33:27 UTC (rev 5760)
+++ trunk/openvas-plugins/scripts/ePo_detect.nasl 2009-10-30 13:42:19 UTC (rev 5761)
@@ -0,0 +1,107 @@
+###############################################################################
+# OpenVAS Vulnerability Test
+# $Id$
+#
+# ePo Detection
+#
+# Authors:
+# Michael Meyer
+#
+# Copyright:
+# Copyright (c) 2009 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:
+This host is running ePo, an platform to centrally manage security for
+systems, networks, data, and compliance solutions.
+
+Risk factor : None";
+
+if (description)
+{
+ script_id(100329);
+ script_version ("1.0-$Revision$");
+ script_name("ePo Detection");
+ script_description(desc);
+ script_summary("Checks for the presence of ePo");
+ script_category(ACT_GATHER_INFO);
+ script_family("Service detection");
+ script_copyright("This script is Copyright (C) 2009 Greenbone Networks GmbH");
+ script_dependencies("find_service.nes");
+ script_require_ports(8081);
+ exit(0);
+}
+
+include("http_func.inc");
+include("http_keepalive.inc");
+include("global_settings.inc");
+include("misc_func.inc");
+
+port = 8081;
+
+if(!get_port_state(port))exit(0);
+
+ url = string("/");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:TRUE);
+ if( buf == NULL )exit(0);
+
+ if(egrep(pattern:"ePO", string: buf, icase: TRUE) ||
+ egrep(pattern:"Log component", string: buf, icase: TRUE)) {
+
+ lines = split(buf, sep:'\n', keep:0);
+
+ cn = make_list();
+ vers = make_list();
+ con = make_list();
+ rs = make_list();
+
+ info = string("None\n\ninformation that was gathered:\n\n");
+
+ foreach line (lines) {
+ computer_name = eregmatch(string: line, pattern: "<ComputerName>([a-zA-Z0-9_-]+)</ComputerName>",icase:TRUE);
+ if(!isnull(computer_name[1]))cn = make_list(cn,computer_name[1]);
+ version = eregmatch(string: line, pattern: "<version>([0-9.]+)</version>",icase:TRUE);
+ if(!isnull(version[1]))vers = make_list(vers,version[1]);
+ connected = eregmatch(string: line, pattern: '<Log component="[0-9]+" time="([0-9]+-[0-9]+-[0-9]+T[0-9]+:[0-9]+:[0-9]+)" type="3">Agent is connecting to ePO server</Log>',icase:TRUE);
+ if(!isnull(connected[1]))con = make_list(con,connected[1]);
+ repServer = eregmatch(string: line, pattern: '<Log component="[0-9]+" time="[0-9]+-[0-9]+-[0-9]+T[0-9]+:[0-9]+:[0-9]+" type="3">Checking update packages from repository ([a-zA-Z-_0-9]+).</Log>',icase:TRUE);
+ if(!isnull(repServer[1]))rs = make_list(rs,repServer[1]);
+ }
+
+ for(a = 0; a < max_index(cn); a++) {
+ info += string("ComputerName: ", cn[a],"\nVersion: ",vers[a],"\nConnected: ", con[a],"\nRepository-Server: ",rs[a],"\n\n");
+ }
+
+ set_kb_item(name: string("www/", port, "/ePo"), value: TRUE);
+ register_service(port:port, ipproto:"tcp", proto:"ePo");
+
+ desc = ereg_replace(
+ string:desc,
+ pattern:"None$",
+ replace:info
+ );
+
+ if(report_verbosity > 0) {
+ security_note(port:port,data:desc);
+ }
+ exit(0);
+
+ }
+
+exit(0);
+
Property changes on: trunk/openvas-plugins/scripts/ePo_detect.nasl
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Added: trunk/openvas-plugins/scripts/joomla_detect.nasl
===================================================================
--- trunk/openvas-plugins/scripts/joomla_detect.nasl 2009-10-30 07:33:27 UTC (rev 5760)
+++ trunk/openvas-plugins/scripts/joomla_detect.nasl 2009-10-30 13:42:19 UTC (rev 5761)
@@ -0,0 +1,206 @@
+###############################################################################
+# OpenVAS Vulnerability Test
+# $Id$
+#
+# joomla Detection
+#
+# Authors:
+# Angelo Compagnucci
+#
+# Copyright:
+# Copyright (c) 2009 Angelo Compagnucci
+#
+# 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:
+ This host is running Joomla! a widely installed Open Source cms solution.
+
+ See also:
+ http://www.joomla.org
+
+ Risk factor : None";
+
+if (description)
+{
+ script_id(100330);
+ script_version ("1.0");
+
+ script_name("Joomla! Detection");
+
+ script_description(desc);
+ script_summary("Checks for the presence of Joomla!");
+ script_category(ACT_GATHER_INFO);
+ script_family("Web application abuses");
+ script_copyright("This script is Copyright (C) 2009 Angelo Compagnucci");
+ script_dependencie("find_service.nes", "http_version.nasl");
+ script_require_ports("Services/www", 80);
+ script_exclude_keys("Settings/disable_cgi_scanning");
+ exit(0);
+}
+
+include("http_func.inc");
+include("http_keepalive.inc");
+include("global_settings.inc");
+
+port = get_http_port(default:80);
+
+if(!get_port_state(port))exit(0);
+if(!can_host_php(port:port)) exit(0);
+
+dirs = make_list("/", "/cms", "/joomla", cgi_dirs());
+
+foreach dir (dirs) {
+
+ url = string(dir, "/index.php");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+ if( buf == NULL )continue;
+
+ if(
+ egrep(pattern: '.*meta.*joomla.*', string: buf) ||
+ egrep(pattern: '.*meta.*Joomla.*', string: buf) ||
+ egrep(pattern: '.*link.*href="/administrator/templates.*', string: buf) ||
+ egrep(pattern: '.*src="/media/system/js.*', string: buf) ||
+ egrep(pattern: '.*src="/templates/system.*', string: buf)
+ )
+ {
+ if(strlen(dir)>0) {
+ install=dir;
+ } else {
+ install=string("/");
+ }
+
+ } else {
+
+ url = string(dir, "/.htaccess");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+ if( buf == NULL )continue;
+
+ if(
+ egrep(pattern: ".*# @package Joomla.*", string: buf)
+ )
+ {
+ if(strlen(dir)>0) {
+ install=dir;
+ } else {
+ install=string("/");
+ }
+
+ } else {
+
+ url = string(dir, "/templates/system/css/editor.css");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+ if( buf == NULL )continue;
+
+ if(
+ egrep(pattern: ".*JOOMLA.*", string: buf)
+ )
+ {
+ if(strlen(dir)>0) {
+ install=dir;
+ } else {
+ install=string("/");
+ }
+
+ } else {
+
+ url = string(dir, "/includes/js/mambojavascript.js");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+ if( buf == NULL )continue;
+
+ if(
+ egrep(pattern: ".*@package Joomla.*", string: buf)
+ )
+ {
+ if(strlen(dir)>0) {
+ install=dir;
+ } else {
+ install=string("/");
+ }
+ }
+ }
+ }
+
+ }
+
+ if(install) {
+
+ vers = string("unknown");
+ lang = string("en-GB");
+
+ url = string(dir, "/");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+ language = eregmatch(string: buf, pattern: 'lang="(..-..)"');
+ if ( !isnull(language[1]) ) {
+ lang = substr(language[1],0,1) + "-" + toupper(substr(language[1],3));
+ }
+
+ url = string(dir, "/administrator/language/"+lang+"/"+lang+".xml");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+ version = eregmatch(string: buf, pattern: ".*<version>(.*)</version>.*");
+ if ( !isnull(version[1]) ) {
+ vers=version[1];
+ } else {
+
+ url = string(dir, "/components/com_user/user.xml");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+ version = eregmatch(string: buf, pattern: ".*<version>(.*)</version>.*");
+
+ if ( !isnull(version[1]) ) {
+ vers=version[1];
+ } else {
+
+ url = string(dir, "/modules/mod_login/mod_login.xml");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:FALSE);
+ version = eregmatch(string: buf, pattern: ".*<version>(.*)</version>.*");
+
+ if ( !isnull(version[1]) ) {
+ vers=version[1];
+ }
+ }
+
+ }
+
+ set_kb_item(name: string("www/", port, "/joomla"), value: string(vers," under ",install));
+ info = string("None\n\nJoomla Version (");
+ info += string(vers);
+ info += string(") with lang(");
+ info += string(lang);
+ info += string(") was detected on the remote host in the following directory(s):\n\n");
+ info += string(install, "\n");
+
+ desc = ereg_replace(
+ string:desc,
+ pattern:"None$",
+ replace:info
+ );
+
+ if(report_verbosity > 0) {
+ security_note(port:port,data:desc);
+ }
+ exit(0);
+ }
+}
+exit(0);
Property changes on: trunk/openvas-plugins/scripts/joomla_detect.nasl
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Added: trunk/openvas-plugins/scripts/landesk_detect.nasl
===================================================================
--- trunk/openvas-plugins/scripts/landesk_detect.nasl 2009-10-30 07:33:27 UTC (rev 5760)
+++ trunk/openvas-plugins/scripts/landesk_detect.nasl 2009-10-30 13:42:19 UTC (rev 5761)
@@ -0,0 +1,82 @@
+###############################################################################
+# OpenVAS Vulnerability Test
+# $Id$
+#
+# Landesk Detection
+#
+# Authors:
+# Michael Meyer
+#
+# Copyright:
+# Copyright (c) 2009 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:
+LANDesk Management Agent is running at this host.
+
+Risk factor : None";
+
+if (description)
+{
+ script_id(100328);
+ script_version ("1.0-$Revision$");
+ script_name("Landesk Detection");
+ script_description(desc);
+ script_summary("Checks for the presence of Landesk Management Agent");
+ script_category(ACT_GATHER_INFO);
+ script_family("Service detection");
+ script_copyright("This script is Copyright (C) 2009 Greenbone Networks GmbH");
+ script_dependencies("find_service.nes", "http_version.nasl");
+ script_require_ports(9595, 9593);
+ exit(0);
+}
+
+include("http_func.inc");
+include("http_keepalive.inc");
+include("global_settings.inc");
+include("misc_func.inc");
+
+port = 9593;
+port1 = 9595;
+
+if(!get_port_state(port))exit(0);
+if(!get_port_state(port1))exit(0);
+
+soc = open_sock_tcp(port1);
+if(!soc)exit(0);
+close(soc);
+
+ url = string("/");
+ req = http_get(item:url, port:port);
+ buf = http_keepalive_send_recv(port:port, data:req, bodyonly:TRUE);
+ if( buf == NULL )continue;
+
+ if(egrep(pattern: "LANDesk.*Management Agent", string: buf, icase: TRUE))
+ {
+ set_kb_item(name: string("www/", port, "/landesk"), value: TRUE);
+ register_service(port:port, ipproto:"tcp", proto:"landesk");
+ register_service(port:port1, ipproto:"tcp", proto:"landesk");
+
+ if(report_verbosity > 0) {
+ security_note(port:port);
+ security_note(port:port1);
+ }
+ exit(0);
+ }
+
+exit(0);
+
Property changes on: trunk/openvas-plugins/scripts/landesk_detect.nasl
___________________________________________________________________
Name: svn:keywords
+ Id Revision
More information about the Openvas-commits
mailing list