Cisco NX-OS Software Cisco Discovery Protocol Remote Code Execution Vulnerability (cisco-sa-20200205-nxos-cdp-rce) - Nessus

High   Plugin ID: 133604

This page contains detailed information about the Cisco NX-OS Software Cisco Discovery Protocol Remote Code Execution Vulnerability (cisco-sa-20200205-nxos-cdp-rce) Nessus plugin including available exploits and PoCs found on GitHub, in Metasploit or Exploit-DB for verifying of this vulnerability.

Plugin Overview


ID: 133604
Name: Cisco NX-OS Software Cisco Discovery Protocol Remote Code Execution Vulnerability (cisco-sa-20200205-nxos-cdp-rce)
Filename: cisco-sa-20200205-nxos-cdp-rce.nasl
Vulnerability Published: 2020-02-05
This Plugin Published: 2020-02-10
Last Modification Time: 2020-04-01
Plugin Version: 1.7
Plugin Type: combined
Plugin Family: CISCO
Dependencies: cisco_nxos_version.nasl
Required KB Items [?]: Host/Cisco/NX-OS/Device, Host/Cisco/NX-OS/Model, Host/Cisco/NX-OS/Version, Settings/ParanoidReport

Vulnerability Information


Severity: High
Vulnerability Published: 2020-02-05
Patch Published: 2020-02-05
CVE [?]: CVE-2020-3119
CPE [?]: cpe:/o:cisco:nx-os

Synopsis

The remote device is missing a vendor-supplied security patch

Description

According to its self-reported version, the Cisco NX-OS System Software is affected by a remote code execution vulnerability within the Cisco Discovery Protocol due to improper validation of input. An unauthenticated, adjacent attacker can exploit this to bypass authentication and execute arbitrary commands with root privileges.

Please see the included Cisco BIDs and Cisco Security Advisory for more information.

Solution

Upgrade to the relevant fixed version referenced in Cisco bug ID CSCvr09175 and/or CSCvr09531.

Public Exploits


Target Network Port(s): N/A
Target Asset(s): N/A
Exploit Available: True (GitHub)
Exploit Ease: Exploits (PoCs) are available

Here's the list of publicly known exploits and PoCs for verifying the Cisco NX-OS Software Cisco Discovery Protocol Remote Code Execution Vulnerability (cisco-sa-20200205-nxos-cdp-rce) vulnerability:

  1. GitHub: https://github.com/epi052/CiscoNotes
    [CVE-2020-3119]
  2. GitHub: https://github.com/routetonull/opencheck
    [CVE-2020-3119]

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 Score Source [?]: CVE-2020-3119
CVSS V2 Vector: AV:A/AC:L/Au:N/C:C/I:C/A:C/E:U/RL:OF/RC:C
CVSS Base Score:8.3 (High)
Impact Subscore:10.0
Exploitability Subscore:6.5
CVSS Temporal Score:6.1 (Medium)
CVSS Environmental Score:NA (None)
Modified Impact Subscore:NA
Overall CVSS Score:6.1 (Medium)
CVSS V3 Vector: CVSS:3.0/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H/E:U/RL:O/RC:C
CVSS Base Score:8.8 (High)
Impact Subscore:5.9
Exploitability Subscore:2.8
CVSS Temporal Score:7.7 (High)
CVSS Environmental Score:NA (None)
Modified Impact Subscore:NA
Overall CVSS Score:7.7 (High)
STIG Severity [?]: I
STIG Risk Rating: High

Go back to menu.

Plugin Source


This is the cisco-sa-20200205-nxos-cdp-rce.nasl nessus plugin source code. This script is Copyright (C) 2020 and is owned by Tenable, Inc. or an Affiliate thereof.

#TRUSTED 3a665e7a5a1559ceb9def750ecd3e3356678f36231a0ddf8380a2448957d210fbae0456a35d2fe9c5a627d945eb56d363ca374a1d4557dbfb277fc5e127868117131e0658e63d644935a098b7da2db7adc682eefa9cecdc422bbd56fc9700dc7e68fce806965bc4ea53e177ca385f186700dc947b54540b3cee899583230ae7acab6381c914e9a25e0c184141e668225d8c70dc56d9572808e14c6cb0811101ad493409f8e763cb3a876f623aca8c085721a45b05d07e3d3e11aedb20e32bb2703886de21b47273f21bd2585bdc666ea23438c413e0a34ec1b866c70f9980e1fe3ed44dab2fc332428aad89b143423d5cae02548c62ed7c4227f9c09e45e30e67e0973f5ecb20d73ca6dbb70ca0c0d303e6b60bc497a13fbb48b0111dbedbcb7f476783176268229240431f92025fccd2e715eda378b5e59280cdeebd1c0742c85ed59c7bac49ddaebd139599b4eb26f959a6178781435898f089c8145d9fbcdf82d0d80ec10fc8deb6f5ed3a190429f8177e38ba43e0a3793555d6b9f91aebde080093a47770157a6ae2858ec108afa6ee8b248aab69855a06470764aa2518352e2c344969f0ad7178d70ec21bda8241471c4603254c91bc6d5ed73ff51e87735be19006a86f93384a18d516744e5dd5f0f8c4a1131bcdc4106b2e65e397c713b33f7dc4660c8633033d303fc26c91772f33232386829a9997cefdf8bbdb976
#
# (C) Tenable Network Security, Inc.
#

include('compat.inc');

if (description)
{
  script_id(133604);
  script_version("1.7");
  script_set_attribute(attribute:"plugin_modification_date", value:"2020/04/01");

  script_cve_id("CVE-2020-3119");
  script_xref(name:"CISCO-BUG-ID", value:"CSCvr09175");
  script_xref(name:"CISCO-BUG-ID", value:"CSCvr09531");
  script_xref(name:"CISCO-SA", value:"cisco-sa-20200205-nxos-cdp-rce");
  script_xref(name:"IAVA", value:"2020-A-0068");

  script_name(english:"Cisco NX-OS Software Cisco Discovery Protocol Remote Code Execution Vulnerability (cisco-sa-20200205-nxos-cdp-rce)");

  script_set_attribute(attribute:"synopsis", value:
"The remote device is missing a vendor-supplied security patch");
  script_set_attribute(attribute:"description", value:
"According to its self-reported version, the Cisco NX-OS System Software is affected by a remote code execution
vulnerability within the Cisco Discovery Protocol due to improper validation of input. An unauthenticated, adjacent
attacker can exploit this to bypass authentication and execute arbitrary commands with root privileges.

Please see the included Cisco BIDs and Cisco Security Advisory for more information.");
  # https://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-20200205-nxos-cdp-rce
  script_set_attribute(attribute:"see_also", value:"http://www.nessus.org/u?9811503b");
  script_set_attribute(attribute:"see_also", value:"https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvr09175");
  script_set_attribute(attribute:"see_also", value:"https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvr09531");
  script_set_attribute(attribute:"solution", value:
"Upgrade to the relevant fixed version referenced in Cisco bug ID CSCvr09175 and/or CSCvr09531.");
  script_set_cvss_base_vector("CVSS2#AV:A/AC:L/Au:N/C:C/I:C/A:C");
  script_set_cvss_temporal_vector("CVSS2#E:U/RL:OF/RC:C");
  script_set_cvss3_base_vector("CVSS:3.0/AV:A/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-3119");

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

  script_set_attribute(attribute:"vuln_publication_date", value:"2020/02/05");
  script_set_attribute(attribute:"patch_publication_date", value:"2020/02/05");
  script_set_attribute(attribute:"plugin_publication_date", value:"2020/02/10");

  script_set_attribute(attribute:"potential_vulnerability", value:"true");
  script_set_attribute(attribute:"plugin_type", value:"combined");
  script_set_attribute(attribute:"cpe", value:"cpe:/o:cisco:nx-os");
  script_set_attribute(attribute:"stig_severity", value:"I");
  script_end_attributes();

  script_category(ACT_GATHER_INFO);
  script_family(english:"CISCO");

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

  script_dependencies("cisco_nxos_version.nasl");
  script_require_keys("Host/Cisco/NX-OS/Version", "Host/Cisco/NX-OS/Model", "Host/Cisco/NX-OS/Device", "Settings/ParanoidReport");

  exit(0);
}

include('audit.inc');
include('cisco_workarounds.inc');
include('ccf.inc');

product_info = cisco::get_product_info(name:'Cisco NX-OS Software');



cbi = '';

if ('Nexus' >< product_info.device)
{
  if (product_info.model =~ "^3[0-9]{3}")
    cbi = 'CSCvr09175';
  else if (product_info.model =~ "^9[0-9]{3}")
    cbi = 'CSCvr09175, CSCvr09531';
}
if (empty_or_null(cbi))
  audit(AUDIT_HOST_NOT, 'an affected model');

if (report_paranoia < 2)
  audit(AUDIT_PARANOID);

version_list=make_list(
  '7.0(3)I7(1)',
  '7.0(3)I7(2)',
  '7.0(3)I7(3)',
  '7.0(3)I7(4)',
  '7.0(3)I7(5)',
  '7.0(3)I7(5a)',
  '7.0(3)I7(3z)',
  '7.0(3)I7(6)',
  '7.0(3)I7(6z)',
  '7.0(3)I7(7)',
  '7.0(3)IA7(1)',
  '7.0(3)IA7(2)',
  '7.0(3)IM7(2)',
  '9.2(1)',
  '9.2(2)',
  '9.2(2t)',
  '9.2(3)',
  '9.2(3y)',
  '9.2(4)',
  '9.2(2v)',
  '9.3(1)',
  '9.3(1z)',
  '14.0(1h)',
  '14.0(2c)',
  '14.0(3d)',
  '14.0(3c)',
  '14.1(1i)',
  '14.1(1j)',
  '14.1(1k)',
  '14.1(1l)',
  '14.1(2g)',
  '14.1(2m)',
  '14.1(2o)',
  '14.1(2s)',
  '14.1(2u)',
  '14.1(2w)',
  '14.2(1i)'
);

workarounds = make_list(CISCO_WORKAROUNDS['cdp']);
workaround_params = make_list();

reporting = make_array(
  'port'     , 0,
  'severity' , SECURITY_HOLE,
  'version'  , product_info.version,
  'bug_id'   , cbi
);

cisco::check_and_report(
  product_info:product_info,
  workarounds:workarounds,
  workaround_params:workaround_params,
  reporting:reporting,
  vuln_versions:version_list,
  switch_only:TRUE
);

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

  • Linux / Unix:
    /opt/nessus/lib/nessus/plugins/cisco-sa-20200205-nxos-cdp-rce.nasl
  • Windows:
    C:\ProgramData\Tenable\Nessus\nessus\plugins\cisco-sa-20200205-nxos-cdp-rce.nasl
  • Mac OS X:
    /Library/Nessus/run/lib/nessus/plugins/cisco-sa-20200205-nxos-cdp-rce.nasl

Go back to menu.

How to Run


Here is how to run the Cisco NX-OS Software Cisco Discovery Protocol Remote Code Execution Vulnerability (cisco-sa-20200205-nxos-cdp-rce) 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 CISCO plugin family.
  6. On the right side table select Cisco NX-OS Software Cisco Discovery Protocol Remote Code Execution Vulnerability (cisco-sa-20200205-nxos-cdp-rce) plugin ID 133604.
  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 cisco-sa-20200205-nxos-cdp-rce.nasl -t <IP/HOST>

Run the plugin with audit trail message on the console:

/opt/nessus/bin/nasl -a cisco-sa-20200205-nxos-cdp-rce.nasl -t <IP/HOST>

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

/opt/nessus/bin/nasl -T - cisco-sa-20200205-nxos-cdp-rce.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 cisco-sa-20200205-nxos-cdp-rce.nasl -t <IP/HOST>

Go back to menu.

References


IAVA | Information Assurance Vulnerability Alert:
  • 2020-A-0068
Cisco Bug ID: Cisco Security Advisory: See also: Similar and related Nessus plugins:
  • 107004 - Cisco ASA Remote Code Execution and Denial of Service Vulnerability (cisco-sa-20180129-asa1) (destructive check)
  • 69953 - Management Center for Cisco Security Agents Remote Code Execution (cisco-sa-20110216-csa)
  • 79271 - Cisco Email Security Appliance Telnet Remote Code Execution (cisco-sa-20120126-ironport)
  • 79272 - Cisco Content Security Management Appliance Telnet Remote Code Execution (cisco-sa-20120126-ironport)
  • 79273 - Cisco Web Security Appliance Telnet Remote Code Execution (cisco-sa-20120126-ironport)
  • 106630 - Cisco Firepower Threat Defense (FTD) Adaptive Security Appliance Remote Code Execution and Denial of Service Vulnerability (cisco-sa-20180129-asa1)
  • 106484 - Cisco ASA Remote Code Execution and Denial of Service Vulnerability (cisco-sa-20180129-asa1)
  • 108722 - Cisco IOS Software Smart Install Remote Code Execution Vulnerability
  • 108723 - Cisco IOS XE Software Smart Install Remote Code Execution Vulnerability
  • 126640 - Cisco Data Center Network Manager Arbitrary File Upload and Remote Code Execution Vulnerability
  • 133603 - Cisco IOS XR Software Cisco Discovery Protocol Remote Code Execution Vulnerability (cisco-sa-20200205-iosxr-cdp-rce)
  • 160400 - Cisco Identity Services Log4j Engine Remote Code Execution (cisco-sa-apache-log4j-qRuKNEbd)
  • 137901 - Cisco IOS Software One Platform Kit Remote Code Execution Vulnerability (cisco-sa-ios-nxos-onepk-rce-6Hhyt4dC)
  • 137902 - IOS XE Software One Platform Kit Remote Code Execution Vulnerability (cisco-sa-ios-nxos-onepk-rce-6Hhyt4dC)
  • 137903 - Cisco NX-OS Software One Platform Kit Remote Code Execution Vulnerability (cisco-sa-ios-nxos-onepk-rce-6Hhyt4dC)
  • 79584 - Cisco TelePresence Conductor Bash Remote Code Execution (Shellshock)
  • 78596 - Cisco TelePresence Video Communication Server Bash Remote Code Execution (Shellshock)

Version


This page has been produced using Nessus Professional 10.1.2 (#68) LINUX, Plugin set 202205072148.
Plugin file cisco-sa-20200205-nxos-cdp-rce.nasl version 1.7. For more plugins, visit the Nessus Plugin Library.

Go back to menu.