public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
From: Joshua Kinard <kumba@gentoo.org>
To: Gentoo-dev <gentoo-dev@lists.gentoo.org>
Subject: [gentoo-dev] Akamai secure memory allocator for OpenSSL?
Date: Sun, 13 Apr 2014 16:42:16 -0400	[thread overview]
Message-ID: <534AF6A8.6070001@gentoo.org> (raw)


So one of the side-discussions happening after Heartbleed was the fact that
OpenSSL has its own memory allocator code that effectively mitigates any C
library-provided exploit mitigations (as discussed on the openbsd-misc ML at
[1] and Ted Unangst's blogs at [2] and [3]).  This is partially why there's
so much "interesting" data to be sniffed from a server's memory via the
heartbleed response packets -- that memory wasn't really initialized to
random data or zero'd upon malloc(), nor garbage-collected upon free().

Taking place over on the openssl-users ML, someone from Akamai posted a new
secure memory allocator patch[4][5] that they have been using in production
for about a decade.  That patch was cleaned up, diff'ed against
openssl-1.0.1g, and posted to openssl-dev here:
https://marc.info/?l=openssl-dev&m=139733477712798&q=p5

It basically provides a secure memory area protected by guard pages for
sensitive data, like RSA private keys, so that if another Heartbleed-like
event occurs, things won't be as bad.  Hopefully...

Is this something we want to look at adding to our openssl copy via an
optional USE flag (default off)?

Refs:
1. http://marc.info/?l=openbsd-misc&m=139698608410938&w=2
2. http://www.tedunangst.com/flak/post/heartbleed-vs-mallocconf
3. http://www.tedunangst.com/flak/post/analysis-of-openssl-freelist-reuse
4. http://marc.info/?l=openssl-users&m=139723710923076&w=2
5. http://marc.info/?l=openssl-users&m=139723972124003&w=2

-- 
Joshua Kinard
Gentoo/MIPS
kumba@gentoo.org
4096R/D25D95E3 2011-03-28

"The past tempts us, the present confuses us, the future frightens us.  And
our lives slip away, moment by moment, lost in that vast, terrible in-between."

--Emperor Turhan, Centauri Republic


             reply	other threads:[~2014-04-13 20:44 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-13 20:42 Joshua Kinard [this message]
2014-04-14  0:17 ` [gentoo-dev] Akamai secure memory allocator for OpenSSL? Patrick Lauer
2014-04-14  1:27   ` Joshua Kinard
2014-04-14  8:48 ` Tiziano Müller
2014-04-14 21:12   ` Rémi Cardona
2014-04-21 19:19   ` Toralf Förster

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=534AF6A8.6070001@gentoo.org \
    --to=kumba@gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox