Lucene search

K
nessusThis script is Copyright (C) 2020-2021 and is owned by Tenable, Inc. or an Affiliate thereof.MANAGEENGINE_APPLICATIONS_MANAGER_CVE-2020-15394.NASL
HistoryJan 07, 2021 - 12:00 a.m.

ManageEngine Applications Manager REST API SQLi

2021-01-0700:00:00
This script is Copyright (C) 2020-2021 and is owned by Tenable, Inc. or an Affiliate thereof.
www.tenable.com
86
sql injection vulnerability
manageengine applications manager
remote attacker

CVSS2

7.5

Attack Vector

NETWORK

Attack Complexity

LOW

Authentication

NONE

Confidentiality Impact

PARTIAL

Integrity Impact

PARTIAL

Availability Impact

PARTIAL

AV:N/AC:L/Au:N/C:P/I:P/A:P

CVSS3

9.8

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

HIGH

Integrity Impact

HIGH

Availability Impact

HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

EPSS

0.007

Percentile

80.1%

The remote host is running a version of ManageEngine Applications Manager that is affected by a SQL injection vulnerability due to improper validation of user-supplied input to the ‘APIServlet’ servlet. An unauthenticated, remote attacker can exploit this, via a specially crafted HTTP message to execute arbitrary SQL statements.

#
# (C) Tenable Network Security, Inc.
#

include('compat.inc');

if (description)
{
  script_id(144793);
  script_version("1.3");
  script_set_attribute(attribute:"plugin_modification_date", value:"2021/01/08");

  script_cve_id("CVE-2020-15394");

  script_name(english:"ManageEngine Applications Manager REST API SQLi");

  script_set_attribute(attribute:"synopsis", value:
"The remote web application is affected by a SQL injection
vulnerability.");
  script_set_attribute(attribute:"description", value:
"The remote host is running a version of ManageEngine Applications
Manager that is affected by a SQL injection vulnerability due to
improper validation of user-supplied input to the 'APIServlet'
servlet. An unauthenticated, remote attacker can exploit this, via a
specially crafted HTTP message to execute arbitrary SQL statements.");
  # https://www.manageengine.com/products/applications_manager/security-updates/security-updates-cve-2020-15394.html
  script_set_attribute(attribute:"see_also", value:"http://www.nessus.org/u?87166a26");
  script_set_attribute(attribute:"solution", value:
"Upgrade to ManageEngine Applications Manager build 14740 or later.");
  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:U/RL:OF/RC:C");
  script_set_cvss3_base_vector("CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H");
  script_set_cvss3_temporal_vector("CVSS:3.0/E:U/RL:O/RC:C");
  script_set_attribute(attribute:"cvss_score_source", value:"CVE-2020-15394");

  script_set_attribute(attribute:"exploitability_ease", value:"No known exploits are available");

  script_set_attribute(attribute:"vuln_publication_date", value:"2020/09/25");
  script_set_attribute(attribute:"patch_publication_date", value:"2020/09/25");
  script_set_attribute(attribute:"plugin_publication_date", value:"2021/01/07");

  script_set_attribute(attribute:"plugin_type", value:"remote");
  script_set_attribute(attribute:"cpe", value:"cpe:/a:zohocorp:manageengine_applications_manager");
  script_end_attributes();

  script_category(ACT_ATTACK);
  script_family(english:"CGI abuses");

  script_copyright(english:"This script is Copyright (C) 2020-2021 and is owned by Tenable, Inc. or an Affiliate thereof.");

  script_dependencies("manageengine_applications_manager_detect.nasl");
  script_require_keys("installed_sw/ManageEngine Applications Manager");
  script_require_ports("Services/www", 9090);

  exit(0);
}

include('http.inc');
include('install_func.inc');

app = 'ManageEngine Applications Manager';

# Exit if app is not detected on host
get_install_count(app_name:app, exit_if_zero:TRUE);

# Exit if app is not detected on this http port
port = get_http_port(default:9090);
install = get_single_install(
  app_name : app,
  port     : port
);

id = '123456789';
data = 'resourceIds=' + id;
url  = '/AppManager/json/ApmAdminServices/checkResourceID';

res = http_send_recv3(
  method : 'POST',
  port   : port,
  item   : url,
  data   : data,
  content_type : 'application/x-www-form-urlencoded',
  exit_on_fail : TRUE
);

# Patched server requires authentication for the url
if ('provide API Key' >< res[2])
{
  dir = install['path'];
  dir = dir - '/index.do';
  install_url = build_url(port:port, qs:dir);
  audit(AUDIT_WEB_APP_NOT_AFFECTED, app, install_url);
}
# Vulnerable server doesn't require authentication for the url and
# further processes the request. The supplied resourceIds are
# reflected back in the response.
else if(id >< res[2])
{
  extra = 'Nessus was able to detect the issue by sending the' +
    ' following HTTP request to the remote host : ' +
    '\n' +
    '\n' +
    http_last_sent_request();
  security_report_v4(
    port        : port,
    severity    : SECURITY_HOLE,
    extra       : extra,
    sqli        : TRUE
  );
}
# Unexpected
else
  audit(AUDIT_RESP_BAD, port, 'an HTTP request. Response: \n' + res[2]);

CVSS2

7.5

Attack Vector

NETWORK

Attack Complexity

LOW

Authentication

NONE

Confidentiality Impact

PARTIAL

Integrity Impact

PARTIAL

Availability Impact

PARTIAL

AV:N/AC:L/Au:N/C:P/I:P/A:P

CVSS3

9.8

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

NONE

User Interaction

NONE

Scope

UNCHANGED

Confidentiality Impact

HIGH

Integrity Impact

HIGH

Availability Impact

HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

EPSS

0.007

Percentile

80.1%

Related for MANAGEENGINE_APPLICATIONS_MANAGER_CVE-2020-15394.NASL