Tracking down Heartbleed across several TLS services in the data centre
Summary
In April 2014 Manuel Schmitt reports that manitu automatically scanned most IP addresses in its own data centre for the OpenSSL bug Heartbleed and warned affected customers by mail. The scan covered HTTPS, IMAPS and POP3S as well as SMTP, submission, IMAP and POP3 with STARTTLS. In most of the replies, only the restart of the affected service after the update was missing.
What Heartbleed was
Heartbleed, officially CVE-2014-0160, was located in the implementation of the TLS heartbeat extension defined in RFC 6520. According to the OpenSSL security advisory, a bounds check was missing, and OpenSSL returned up to 64 kilobytes of memory per heartbeat. An attacker could repeat this any number of times.
OpenSSL 1.0.1 up to and including 1.0.1f was affected; the bug entered the code in December 2011 and had been in circulation since OpenSSL 1.0.1 in March 2012. OpenSSL 1.0.1g fixed it on 7 April 2014. It was found independently by Neel Mehta of Google Security and a team at Codenomicon.
Why an update alone is not enough
Running services keep the old library in memory until they are restarted; that is exactly what many manitu customers had missed. Codenomicon's Heartbleed page also lists private keys as exposed: recovery means patching, revoking the certificates and issuing new keys. According to Codenomicon, traffic already intercepted remains at risk anyway.
Ideas
- A TLS bug affects not only HTTPS but also mail protocols with direct TLS or STARTTLS.
- An installed update has no effect as long as vulnerable processes have not been restarted.
- Providers can use their own network view to alert customers proactively about exposed services.
- Up to 64 kilobytes of memory leaked per heartbeat, repeatable at will.
- After Heartbleed, keys must be replaced and certificates revoked.
Insights
- Vulnerability management only ends at running processes and renewed secrets.
- A coordinated scan turns general security advisories into concrete exposure.
Facts
- The scan covered HTTPS, IMAPS, POP3S as well as SMTP, submission, IMAP and POP3 with STARTTLS.
- In many replies, a missing service restart was the cause.
- OpenSSL 1.0.1 to 1.0.1f was vulnerable; 1.0.1g fixed the bug on 7 April 2014.
- The heartbeat extension is defined in RFC 6520 of February 2012.
- Heartbleed is tracked as CVE-2014-0160.
References
- Manuel Schmitt on Hostblogger: original article (German)
- Codenomicon: The Heartbleed Bug
- RFC 6520: TLS and DTLS Heartbeat Extension (2012)
- OpenSSL Security Advisory, 7 April 2014
Recommendations
- Inventory all processes that have loaded an affected library, for example with needrestart or lsof.
- Restart services after the update and rotate potentially exposed keys and sessions.
- Check mail, VPN and management services with TLS as well as web servers.
Read the original article on Hostblogger
Found a mistake or have something to add? Get in touch.
Links to the original source and the Web Archive open in a new tab.