Heartbleed Bug SSL Vulnerability – Everything You Need To Know

Outsmart Malicious Hackers


Introduction

So the Internet has been exploding this week due to the Heartbleed Bug in OpenSSL which effects a LOT of servers and websites and is being hailed by some as the worst vulnerability in the history of the Internet thus far.

Heartbleed Bug

The main info on the bug can be found at http://heartbleed.com/. In basic terms, it allows you to grab 64kb chunks of whatever is stored in RAM on the server as long as it’s using a vulnerable version of OpenSSL with Heartbeat enabled.

The Heartbleed Bug is a serious vulnerability in the popular OpenSSL cryptographic software library. This weakness allows stealing the information protected, under normal conditions, by the SSL/TLS encryption used to secure the Internet. SSL/TLS provides communication security and privacy over the Internet for applications such as web, email, instant messaging (IM) and some virtual private networks (VPNs).

Who needs the NSA when we have this eh?

So ya this is really serious, a scanner was released before anyone had chance to patch it and huge sites like Yahoo! Mail were vulnerable and exposing user passwords to anyone who used Heartbleed against it.

Everyone scrambled to fix it fast though, which is good – as it’s a major vulnerability. As can be seen in this picture, the plain text user passwords for Yahoo! mail were being leaked.

Hashing is irrelevant in this case, as the hash and hash comparison are done on the server side, so the plain text password is stored in memory at some point.

Yahoo! Heartbleed

The bad part of it is that there’s no way to tell if it’s been exploited as there’s no crash, no damage, it just spits out the data to whoever runs the exploit.

There’s a good analysis of the actual code involved here:

Diagnosis of the OpenSSL Heartbleed Bug

What Should I Do?

Well you need to check if any of the servers you manage or run are using a vulnerable version of OpenSSL, from my experience if you are still on Ubuntu 10.04 LTS you are safe from this, as it uses OpenSSL 0.9.8 without heartbeat functionality.

If you are using Ubuntu 12.04 LTS (any subversion) then you ARE vulnerable and need to update ASAP.

IF you want to scan your servers you can grab the scanning script here:

heartbleed.py

There are also a couple of online scanners you can use (just beware of false positives).

http://rehmann.co/projects/heartbeat/
http://filippo.io/Heartbleed/

On the server side, you can check your OpenSSL version with:

openssl version -a

Don’t pay attention to the version or date, but look at the build date – it should be AFTER April 7th.

Something like this would be a vulnerable version:

OpenSSL 1.0.1 14 Mar 2012
built on: Wed Jan 8 20:45:51 UTC 2014

After updating it should look like:

OpenSSL 1.0.1 14 Mar 2012
built on: Mon Apr 7 20:33:29 UTC 2014

How Do I Fix It?

For the majority of people, someone else probably hosts your sites and infrastructure, so you don’t need to worry that much – just change your passwords if you’re paranoid and make sure you enable 2 factor auth for anything that supports it.

Services like the Linode Nodebalancer with SSL termination have been updated, but do bear in mind your secret key could have been leaked (although, logically that’s pretty unlikely).

Linode – Heartbleed

On Ubuntu 12.04 it’s as simple as doing aptitude update; aptitude safe-upgrade -y; and then restarting all relevant services, or simply rebooting.

Ensure the build date is at minimum 2014-04-07.

If you want to check what services are using OpenSSL you can do:

lsof -n | grep ssl | grep DEL

That fixes the bug, but remember it doesn’t change the fact that your secret keys/passwords could have been leaked, there has also been reports of 2FA session tokens being leaked among other stuff.

So to be secure, you really need to revoke all your SSL certificates, regenerate a new private key and csr, and regenerate your SSL certs.

And of course, change all your passwords.

More Reading

Amazon Linux AMIs are updated.
Why Heartbleed is the most dangerous security flaw on the web
Critical crypto bug exposes Yahoo Mail, other passwords Russian roulette-style
Hacker News – The Heartbleed Bug
Reddit – The Heartbleed Bug

Posted in: Cryptography, Exploits/Vulnerabilities, Networking Hacking

, , , ,


Latest Posts:


BootStomp - Find Bootloader Vulnerabilities BootStomp – Find Android Bootloader Vulnerabilities
BootStomp is a Python-based tool, with Docker support that helps you find two different classes of bootloader vulnerabilities and bugs.
Google Chrome Marking ALL Non-HTTPS Sites Insecure July 2018 Google Chrome Marking ALL Non-HTTPS Sites Insecure July 2018
Google is ramping up its campaign against HTTP only sites and is going to mark ALL Non-HTTPS sites insecure in July 2018 with the release of Chrome 68.
altdns - Subdomain Recon Tool With Permutation Generation altdns – Subdomain Recon Tool With Permutation Generation
Altdns is a subdomain recon tool in Python that allows for the discovery of subdomains that conform to patterns. The tool takes in words that could be present in subdomains under a domain (such as test, dev, staging) as well as takes in a list of subdomains that you know of.
0-Day Flash Vulnerability Exploited In The Wild 0-Day Flash Vulnerability Exploited In The Wild
So another 0-Day Flash Vulnerability is being exploited in the Wild, a previously unknown flaw which has been labelled CVE-2018-4878 and it affects 28.0.0.137 and earlier versions
dorkbot - Command-Line Tool For Google Dorking dorkbot – Command-Line Tool For Google Dorking
dorkbot is a modular command-line tool for Google dorking, which is performing vulnerability scans against a set of web pages returned by Google search queries in a given Google Custom Search Engine.
USBPcap - USB Packet Capture For Windows USBPcap – USB Packet Capture For Windows
USBPcap is an open-source USB Packet Capture tool for Windows that can be used together with Wireshark in order to analyse USB traffic without using a Virtual Machine.


One Response to Heartbleed Bug SSL Vulnerability – Everything You Need To Know

  1. Dominick April 18, 2014 at 7:15 am #

    Thanks for all the help on trying to make sure we stay protected from this huge bug! Keep updating us with more ways to protect ourselves!