SSD Advisory – Cisco MSE Preauthentication Remote Code Execution

Vulnerabilities Summary
Cisco Mobile Services Engine (MSE) is a platform that helps organizations increase visibility into the network, customize location-based mobile services, and strengthen security. The following advisory describes Cisco MSE Pre-Authentication Code Execution (Cisco MSE version 8.0.100.0).

Credit
An independent security researcher has reported this vulnerability to Beyond Security’s SecuriTeam Secure Disclosure program.

Vendor response
The vendor has released Mobility Services Engine patches (November 2015) to address the vulnerabilities, advisory can be found here and here

Vulnerability Details
Cisco MSE is available in both a physical or virtual appliance. The virtual appliance by default runs a network-accessible SSH server. There is an undocumented user account on the system that allows remote shell access using a static password set upon install. Using this bug in combination with a local privilege escalation vulnerability allows a remote user to gain root privileges on the appliance.

There are two configured user accounts on the appliance, the root user and another account named “oracle”. Upon install, the root user’s password is set by an administrator, oracle’s account is undocumented. During the installation of the following files:

The MSE system, the account “oracle” is created and the password is set to “XmlDba123”.

We can see in script createSampledb.sh (/opt/installers/dbinstaller/binaryrpms/extracted/utils/createSampledb.sh) that the password is set.

Using this account, we can now login to the appliance.

From here we can escalate our privileges to root by exploiting some handy SUID binaries whose origins can be seen from the post-install log file.

Having a literal SUID root copy of both chmod and chown accessible on the system allow us to escalate our privileges using a variety of techniques. One example is changing the ownership and mode of the sudoers file in order to give the oracle user passwordless sudo privileges:

https://blogs.securiteam.com/index.php/feed