Bobcares

Resolving Bash vulnerability in Parallels Virtuozzo Containers

by | Sep 26, 2014

[UPDATE 1st Oct] – More vulnerabilities were reported since this post was originally written on Sep 26th. See the notes at the bottom.

Highly critical Bash code injection vulnerability CVE-2014-6217 was declared on 24th Sep, and a patch is not yet known to be available for Parallels Virtuozzo Containers and Parallels Cloud Servers.

If you have Virtuozzo or Parallels Cloud Server, the individual containers will have Bash; and if you haven’t expressly patched it, assume that your server is vulnerable to hack. Containers typically operate with CGI modules, and they could allow commands to be passed on to Bash, thus opening the gates to hackers.

The engineers in our Proactive Server Management Services detected this threat on 24th, and patched all our Virtuozzo and Parallels Cloud Servers with the following steps:

Login to your hardware node terminal as root, and execute the below script.

#!/bin/bash

for CONTAINER in $(vzlist -a | egrep -w -v "1|CTID" | grep run | awk '{print $1}')
do 
if [[ -f /vz/root/$CONTAINER/etc/redhat-release ]]; 
then
 if [[ -f /vz/root/$CONTAINER/usr/bin/yum ]]; 
 then 
 echo $CONTAINER; 
 vzctl exec $CONTAINER "yum -y update bash";
 else
 echo "yum missing in $CONTAINER. Try again after running, vzpkg install $CONTAINER -p yum";
 fi; 
else
 echo "$CONTAINER is not RHEL flavor. Possibly Ubuntu or Debian. Modify script to run apt-get command.";
fi
done

This script lists the containers in the hypervisor, and executes the update command to upgrade bash. In some containers yum might not be present, and you might be required to install yum before continuing.

IMPORTANT : The above script is one of the variations we use to update servers. There is NO guarantee it will work in your server. If you are not sure what these commands are and are not comfortable executing these commands as root, consult a systems administrator.

This should protect your customers from the critical CVE-2014-6217 vulnerability, however, the VPSs will need to be patched again to be fully protected once a solution is available for the related CVE-2014-7169 vulnerability. We will update this post when a patch is available. When the patch is released, just execute the above steps again.

[ UPDATE ] – Patch for CVE-2014-7169 is now available. So, in case you have already ran the commands above, re-run them again to get the final patch.

Critical vulnerabilities are a fact of web hosting. Bobcares Proactive Server Management prevents zero-day exploits by configuring servers for managed auto-upgrades.

Not sure if your servers are patched? We can check your servers for FREE, and optionally patch your servers.

Fix my server now!

IMPORTANT UPDATE : New vulnerabilities were reported after Sep 26th (after this post was written). As of Oct 1st, 6 vulnerabilities are reported. Rumors say, more vulnerabilities might be on its way. You need to keep monitoring the threat-scape and update your servers as soon as patches are available.

OR

We can keep an eye on your servers and secure it so that your servers wont be exploited by any of the Bash vulnerabilities. Check out our Bash Special Pro-active Maintenance Service below.

Protect my server!

0 Comments

Never again lose customers to poor
server speed! Let us help you.

Privacy Preference Center

Necessary

Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

PHPSESSID - Preserves user session state across page requests.

gdpr[consent_types] - Used to store user consents.

gdpr[allowed_cookies] - Used to store user allowed cookies.

PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]
PHPSESSID
WHMCSpKDlPzh2chML

Statistics

Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

_ga - Preserves user session state across page requests.

_gat - Used by Google Analytics to throttle request rate

_gid - Registers a unique ID that is used to generate statistical data on how you use the website.

smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

_ga, _gat, _gid
_ga, _gat, _gid
smartlookCookie
_clck, _clsk, CLID, ANONCHK, MR, MUID, SM

Marketing

Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

test_cookie - Used to check if the user's browser supports cookies.

1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

DV - Google ad personalisation

_reb2bgeo - The visitor's geographical location

_reb2bloaded - Whether or not the script loaded for the visitor

_reb2bref - The referring URL for the visit

_reb2bsessionID - The visitor's RB2B session ID

_reb2buid - The visitor's RB2B user ID

IDE, test_cookie, 1P_JAR, NID, DV, NID
IDE, test_cookie
1P_JAR, NID, DV
NID
hblid
_reb2bgeo, _reb2bloaded, _reb2bref, _reb2bsessionID, _reb2buid

Security

These are essential site cookies, used by the google reCAPTCHA. These cookies use an unique identifier to verify if a visitor is human or a bot.

SID, APISID, HSID, NID, PREF
SID, APISID, HSID, NID, PREF