Matt Wright guestbook.pl Arbitrary Command Execution - Nessus

High   Plugin ID: 10099

This page contains detailed information about the Matt Wright guestbook.pl Arbitrary Command Execution Nessus plugin including available exploits and PoCs found on GitHub, in Metasploit or Exploit-DB for verifying of this vulnerability.

Plugin Overview


ID: 10099
Name: Matt Wright guestbook.pl Arbitrary Command Execution
Filename: guestbook_pl.nasl
Vulnerability Published: 1999-11-05
This Plugin Published: 1999-12-01
Last Modification Time: 2021-01-19
Plugin Version: 1.32
Plugin Type: remote
Plugin Family: CGI abuses
Dependencies: find_service1.nasl, http_version.nasl
Required KB Items [?]: Settings/ParanoidReport

Vulnerability Information


Severity: High
Vulnerability Published: 1999-11-05
Patch Published: N/A
CVE [?]: CVE-1999-1053
CPE [?]: N/A

Synopsis

Arbitrary commands may be run on the remote host.

Description

The 'guestbook.pl' is installed. This CGI has a well known security flaw that lets anyone execute arbitrary commands with the privileges of the HTTP daemon (root or nobody).

Solution

Remove the affected script.

Public Exploits


Target Network Port(s): 80
Target Asset(s): Services/www
Exploit Available: True (Metasploit Framework, Exploit-DB)
Exploit Ease: Exploits are available

Here's the list of publicly known exploits and PoCs for verifying the Matt Wright guestbook.pl Arbitrary Command Execution vulnerability:

  1. Metasploit: exploit/unix/webapp/guestbook_ssi_exec
    [Matt Wright guestbook.pl Arbitrary Command Execution]
  2. Exploit-DB: exploits/cgi/webapps/9907.rb
    [EDB-9907: The Matt Wright Guestbook.pl 2.3.1 - Server-Side Include]
  3. Exploit-DB: exploits/cgi/webapps/16914.rb
    [EDB-16914: The Matt Wright Guestbook.pl - Arbitrary Command Execution (Metasploit)]

Before running any exploit against any system, make sure you are authorized by the owner of the target system(s) to perform such activity. In any other case, this would be considered as an illegal activity.

WARNING: Beware of using unverified exploits from sources such as GitHub or Exploit-DB. These exploits and PoCs could contain malware. For more information, see how to use exploits safely.

Risk Information


CVSS V2 Vector [?]: AV:N/AC:L/Au:N/C:P/I:P/A:P/E:F/RL:U/RC:ND
CVSS Base Score:7.5 (High)
Impact Subscore:6.4
Exploitability Subscore:10.0
CVSS Temporal Score:7.1 (High)
CVSS Environmental Score:NA (None)
Modified Impact Subscore:NA
Overall CVSS Score:7.1 (High)

Go back to menu.

Plugin Source


This is the guestbook_pl.nasl nessus plugin source code. This script is Copyright (C) 1999-2021 Mathieu Perrin

#%NASL_MIN_LEVEL 70300
#
# This script was written by Mathieu Perrin <[email protected]>
#
# See the Nessus Scripts License for details
#

# Changes by Tenable:
# - Revised plugin title (4/16/009)

include('deprecated_nasl_level.inc');
include('compat.inc');

if (description)
{
 script_id(10099);
 script_version("1.32");
 script_set_attribute(attribute:"plugin_modification_date", value:"2021/01/19");

 script_cve_id("CVE-1999-1053");
 script_bugtraq_id(776);

 script_name(english:"Matt Wright guestbook.pl Arbitrary Command Execution");
 script_summary(english:"Checks for the presence of /cgi-bin/guestbook.pl");

 script_set_attribute(attribute:"synopsis", value:"Arbitrary commands may be run on the remote host.");
 script_set_attribute(attribute:"description", value:
"The 'guestbook.pl' is installed. This CGI has a well known security
flaw that lets anyone execute arbitrary commands with the privileges
of the HTTP daemon (root or nobody).");
 script_set_attribute(attribute:"solution", value:"Remove the affected script.");
 script_set_cvss_base_vector("CVSS2#AV:N/AC:L/Au:N/C:P/I:P/A:P");
 script_set_cvss_temporal_vector("CVSS2#E:F/RL:U/RC:ND");
 script_set_attribute(attribute:"exploitability_ease", value:"Exploits are available");
 script_set_attribute(attribute:"exploit_available", value:"true");
 script_set_attribute(attribute:"metasploit_name", value:'Matt Wright guestbook.pl Arbitrary Command Execution');
 script_set_attribute(attribute:"exploit_framework_metasploit", value:"true");

 script_set_attribute(attribute:"vuln_publication_date", value:"1999/11/05");
 script_set_attribute(attribute:"plugin_publication_date", value:"1999/12/01");

 script_set_attribute(attribute:"potential_vulnerability", value:"true");
 script_set_attribute(attribute:"plugin_type", value:"remote");
 script_end_attributes();

 script_category(ACT_GATHER_INFO);

 script_copyright(english:"This script is Copyright (C) 1999-2021 Mathieu Perrin");
 script_family(english:"CGI abuses");

 script_dependencie("find_service1.nasl", "http_version.nasl");
 script_require_keys("Settings/ParanoidReport");
 script_require_ports("Services/www", 80);

 exit(0);
}

include("audit.inc");
include("global_settings.inc");
include("http_func.inc");
include("http_keepalive.inc");

if (report_paranoia < 2) audit(AUDIT_PARANOID);

port = get_http_port(default:80, embedded:TRUE);
res = is_cgi_installed_ka(item:"guestbook.pl", port:port);
if(res)security_hole(port);


The latest version of this script can be found in these locations depending on your platform:

  • Linux / Unix:
    /opt/nessus/lib/nessus/plugins/guestbook_pl.nasl
  • Windows:
    C:\ProgramData\Tenable\Nessus\nessus\plugins\guestbook_pl.nasl
  • Mac OS X:
    /Library/Nessus/run/lib/nessus/plugins/guestbook_pl.nasl

Go back to menu.

How to Run


Here is how to run the Matt Wright guestbook.pl Arbitrary Command Execution as a standalone plugin via the Nessus web user interface (https://localhost:8834/):

  1. Click to start a New Scan.
  2. Select Advanced Scan.
  3. Navigate to the Plugins tab.
  4. On the top right corner click to Disable All plugins.
  5. On the left side table select CGI abuses plugin family.
  6. On the right side table select Matt Wright guestbook.pl Arbitrary Command Execution plugin ID 10099.
  7. Specify the target on the Settings tab and click to Save the scan.
  8. Run the scan.

Here are a few examples of how to run the plugin in the command line. Note that the examples below demonstrate the usage on the Linux / Unix platform.

Basic usage:

/opt/nessus/bin/nasl guestbook_pl.nasl -t <IP/HOST>

Run the plugin with audit trail message on the console:

/opt/nessus/bin/nasl -a guestbook_pl.nasl -t <IP/HOST>

Run the plugin with trace script execution written to the console (useful for debugging):

/opt/nessus/bin/nasl -T - guestbook_pl.nasl -t <IP/HOST>

Run the plugin with using a state file for the target and updating it (useful for running multiple plugins on the target):

/opt/nessus/bin/nasl -K /tmp/state guestbook_pl.nasl -t <IP/HOST>

Go back to menu.

References


BID | SecurityFocus Bugtraq ID: See also: Similar and related Nessus plugins:
  • 21302 - phpBB Advanced GuestBook addentry.php phpbb_root_path Parameter Remote File Inclusion
  • 10128 - SGI InfoSearch infosrch.cgi fname Parameter Arbitrary Command Execution
  • 10176 - Multiple Vendor phf CGI Arbitrary Command Execution
  • 104126 - D-Link DIR-300L/600L Remote Command Execution
  • 104129 - Linksys E1500/E2500 Authenticated Command Execution
  • 119728 - Apache Struts 2 'method:' Prefix Arbitrary Remote Command Execution
  • 124367 - WePresent file_transfer.cgi Remote Command Execution
  • 127911 - Webmin 1.890 - 1.920 Remote Command Execution (CVE-2019-15107, CVE-2019-15231)
  • 130168 - vBulletin 'widget_php' Command Execution
  • 146488 - Webmin <= 1.910 Remote Command Execution
  • 160208 - WSO2 Multiple Products File Upload Remote Command Execution (CVE-2022-29464)
  • 16189 - AWStats awstats.pl configdir Parameter Arbitrary Command Execution
  • 19555 - HP OpenView Network Node Manager Multiple Scripts Remote Command Execution
  • 19704 - TWiki 'rev' Parameter Arbitrary Command Execution
  • 21328 - AWStats migrate Parameter Arbitrary Command Execution
  • 22123 - TWiki configure Script Arbitrary Command Execution
  • 23963 - Cacti cmd.php Multiple Parameter SQL Injection Arbitrary Command Execution
  • 23966 - Ultimate PHP Board chat/login.php username Parameter Arbitrary Command Execution

Version


This page has been produced using Nessus Professional 10.1.2 (#68) LINUX, Plugin set 202205072148.
Plugin file guestbook_pl.nasl version 1.32. For more plugins, visit the Nessus Plugin Library.

Go back to menu.