What is heartbleed? Simply put, the bug with the cutest design I’ve ever seen (check out that site and minimalist logo ;). On a serious note, heartbleed is no joke, it is a major bug affecting SSL/TLS implementations of OpenSSL, the de-facto standard for secure SSL communication on the internet. Now that I have patched all my servers, checked and re-checked everything, and have some time to breathe, I would like to share my thoughts and possibly help you if you have not yet taken any actions and are yet wondering how to proceed.

Is it that catastrophic?

Yes, indeed. OpenSSL is used by most common secure internet services found today. Popular web servers Apache and NginX are affected, which means, according to a report from Netcraft, over 66% of the servers out there. At the time of disclosure, 17% of the considered “secure” sites of the web were deemed vulnerable to this bug. Even worse is the fact that this bug was introduced in OpenSSL in December 2011 and has been out in the wild since OpenSSL release 1.0.1 on 14th of March 2012. OpenSSL 1.0.1g released on 7th of April 2014 fixes the bug.

But what does it do?

Rahul Sasi has made an excellent work analyzing the vulnerability and getting a proof of concept script. For those not technically oriented, here is a quick explanation. The bug originates from heartbeat, an extension to SSL/TLS communication protocol (thus the name of heartbleed). Secure communications involve a process of authentication from both ends, so they can be sure who are they talking to. This process is called a handshake and creates a secure session that allows them to maintain this secure channel open. This channel must be re-negociated and kept alive frequently, which is a costly process involving a communication overload. This is where the heartbeat extension comes in, allowing to keep this secure session open without needing a expensive re-negociation process. Unfortunately, there was a bug in the heartbeat code that would allow to surpass the limits of a network request, allowing a client to have access to the memory of the server or viceversa. Simply put, an attacker could access sensitive information, including secure certificates, keys, credit card information, passwords, credentials, etc.

How does it affect me as a user?

For a start, you should assume that most of the services you use could have been compromised. The bug allows a malicious client to extract information from the servers of services you use, but it also allows someone to impersonate a service and extract information from your machine when you connect to that service. This implies that you should change all of your passwords. Really? are you mad? No, I’m afraid I’m not. Better safe than sorry. It may not look really dangerous for you, but services such as Wunderlist and IFTTT are already login out their users and suggesting them to change their passwords, and there is an unofficial site with a list of services that have been hit by the bug and whose providers recommend changing your passwords. You will most probably find in that list a service you use on a daily basis, such as Facebook or GMail.


❤️ Enjoying this post so far?

If you find this content useful, consider showing your appreciation by buying me a coffee using the button below 👇.

Buy me a coffeeBuy me a coffee

My personal recommendation: change your passwords. But make sure that the site has already fixed the bug!

How does affect me as an administrator?

If you run a web server or have any other kind of internet service using OpenSSL, you would have probably taken some action by the time you are reading this. If not, you can check if your site is vulnerable here. The first thing you need to do is to stop temporarily all services susceptible of being affected (i.e: all services using OpenSSL like web servers, mail, S-FTP, etc), and update as soon as possible to OpenSSL 1.0.1g at least. If you are using linux, most distributions have released a fix or patch (Debian wheezy stable fixes the bug in 1.0.1e-2+deb7u6).

After updating, you should change all your certificates and keys. If you are using certificates provided by a CA, you would need to contact them requesting them to renew them and revoke the old ones. Some CAs are charging a fee for this, others aren’t. Then, you can restart all of your services. Sometimes, the update process will not properly restart all involved processes, and you need to restart them by hand. In Debian, you can use the following command:

grep -l 'libssl.*deleted' /proc/*/maps | tr -cd 0-9\\n | xargs -r ps u

to list any running services that still use the vulnerable version of OpenSSL. If you run authentication services including user credentials, you should proceed as if they have been potentially leaked, and warn your users to change their passwords.

How do I know if I have been affected?

As you can read in heartbleed.com: “Exploitation of this bug leaves no traces of anything abnormal happening to the logs.”, so the short answer is: you can’t. The long answer is: you should behave as if you had been affected.

What about Mac and iPhone/iPad users?

As usual, Apple has yet to come with an official announcement about how the heartbleed bug affects their systems. But meanwhile, let me give you some insights on how are you affected as an OS X or iOS user.

OS X users shouldn’t be worried about the heartbleed bug affecting their computers. Luckily, Apple deprecated OpenSSL on OS X in December of 2012, so the last openSSL version included in OS X is 0.9.8y, which is not affected by the bug. You can easily check this out by spawning a terminal (⌘-Space, type terminal, hit enter) and typing the following command:

OpenSSL> version
OpenSSL 0.9.8y 5 Feb 2013

iOS users can breathe a sigh of relief also. iOS doesn’t come with OpenSSL and Apple actively dissuades developers from using it while developing iOS Apps. Besides, tests indicate that Apple sites like apple.com and iCloud.com are not vulnerable or affected by the bug.

However, this doesn’t mean you are off the hook. You need to follow the recommendations depicted above for all users, specially changing your passwords and making sure your web service providers have fixed their systems.

Last, but not least, if you need me to fix heartbleed in your site, contact me. I am a freelance developer with extensive experience in security.