Cisco FXOS Software CLI Command Injection Vulnerability (cisco-sa-20200226-fpwr-cmdinj)

2020-03-06T00:00:00
ID CISCO-SA-20200226-FPWR-CMDINJ.NASL
Type nessus
Reporter This script is Copyright (C) 2020 and is owned by Tenable, Inc. or an Affiliate thereof.
Modified 2020-03-06T00:00:00

Description

According to its self-reported version, Cisco Firepower Extensible Operating System (FXOS) is affected by a command injection vulnerability in its command line interface component due to insufficient validation of arguments passed to a specific command. An authenticated, local attacker can exploit this, by issuing specially crafted commands to an affected host, to execute arbitrary commands as root on the host.

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

                                        
                                            #TRUSTED 5eb06e9be3be989addbd3c0fdab87bb9a3e2624aa2dc39a155a49358b107f04fb0070259a1f8113d4f064f9b170c479641132d35e9990e1a28655fb0bd4952a7016aaeddd32517d241874584942300ab5680c7e99b068457d06dd30238684ff9533bb4a7ad0a11a25e0c30d4e60ed32995312bba346ae96c3c324af4001ef7b10aaef201ee822f565adfcdaa55d7441b2dcc24203c40f0799f10169270943563117234e15c5049d3c3f05d1de2f06040c13527c2fa019e5cfb558c5c69a1c54eee53fabc36d74f1aa6d604e3ceb8f0ff554dd3b5b3694d5cbef05fe332393447551b1c00cfa8166c68af059200ab606585d123eab2aa3b33722d65cea94d1f63e9f7a1ba611043e93667212dd9bcfffee05ed717e261be0c847a1b1ab67f666fdd798974bfd14df1847697e4627b444d5958e4e8aca11c11fa5940be04e449c6e60361eb0d34a9a3ed580a990d59c63678438e17092176ded0dd53112e3247e5692a832120ee9407c6011510ac835f40eba28b7797d0efd1fdda2a7c7f624fca8573ac1a219eb6bdbe2b28bf5f663c4560855332f785395308918aa16bcf4feb96ade42b8a4ff4f667a3ef90fe1e1146f5fcd6e9d36c164e6b3859e8a560358c40e5ca2e736fe264dbdde79875e8f5a2352f01231ef14bf09938921f5839361cf53fac6937a5873ff1e39b5c99b157d23e676b9b1594ed6893fab68307db7192
#
# (C) Tenable Network Security, Inc.
#

include('compat.inc');

if (description)
{
  script_id(134233);
  script_version("1.4");
  script_set_attribute(attribute:"plugin_modification_date", value:"2020/03/10");

  script_cve_id("CVE-2020-3169");
  script_xref(name:"CISCO-BUG-ID", value:"CSCvo42633");
  script_xref(name:"CISCO-SA", value:"cisco-sa-20200226-fpwr-cmdinj");
  script_xref(name:"IAVA", value:"2020-A-0085");

  script_name(english:"Cisco FXOS Software CLI Command Injection Vulnerability (cisco-sa-20200226-fpwr-cmdinj)");

  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, Cisco Firepower 
  Extensible Operating System (FXOS) is affected by a command injection vulnerability in its command line interface 
  component due to insufficient validation of arguments passed to a specific command. An authenticated, local attacker 
  can exploit this, by issuing specially crafted commands to an affected host, to execute arbitrary commands as root
  on the host. 

  Please see the included Cisco BIDs and Cisco Security Advisory for more information.");
  # https://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-20200226-fpwr-cmdinj
  script_set_attribute(attribute:"see_also", value:"http://www.nessus.org/u?f935994d");
  script_set_attribute(attribute:"see_also", value:"https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvo42633");
  script_set_attribute(attribute:"solution", value:
"Upgrade to the relevant fixed version referenced in Cisco bug ID 
  CSCvo42633");
  script_set_cvss_base_vector("CVSS2#AV:L/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:L/AC:L/PR:H/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-3169");

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

  script_set_attribute(attribute:"vuln_publication_date", value:"2020/02/26");
  script_set_attribute(attribute:"patch_publication_date", value:"2020/02/26");
  script_set_attribute(attribute:"plugin_publication_date", value:"2020/03/06");

  script_set_attribute(attribute:"plugin_type", value:"local");
  script_set_attribute(attribute:"cpe", value:"cpe:/o:cisco:fxos");
  script_set_attribute(attribute:"stig_severity", value:"II");
  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_enumerate_firepower.nbin", "cisco_asa_firepower_version.nasl");
  script_require_keys("installed_sw/FXOS");

  exit(0);
}

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

product_info = cisco::get_product_info(name:'FXOS');
product_info['model'] = product_info['Model'];

if( isnull(product_info['model']) || product_info['model'] !~ "^(41|93)[0-9]{2}$" )
  audit(AUDIT_HOST_NOT, 'affected');

vuln_ranges = [
  {'min_ver' : '2.2',  'fix_ver': '2.2.2.97'},
  {'min_ver' : '2.3',  'fix_ver': '2.3.1.144'},
  {'min_ver' : '2.4',  'fix_ver': '2.4.1.234'}
];

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

reporting = make_array(
  'port'     , 0,
  'severity' , SECURITY_HOLE,
  'version'  , product_info['version'],
  'bug_id'   , 'CSCvo42633'
);

cisco::check_and_report(
  product_info:product_info,
  workarounds:workarounds,
  workaround_params:workaround_params,
  reporting:reporting,
  vuln_ranges:vuln_ranges
);