public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Michael Opdenacker <michael-lists@free-electrons.com>
To: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Option to clear allocated kernel memory before freeing it?
Date: Mon, 19 Jun 2006 16:48:10 +0200	[thread overview]
Message-ID: <4496B92A.3010907@free-electrons.com> (raw)

Hello,

Would it make sense to implement a kernel option that would clear kernel 
memory before freeing it (by kfree or free_page(s))?

Unless I'm missing something, uncleared memory previously used for 
kernel allocations could later be recycled for user allocations, making 
it possible for a user program to access sensitive driver data if it's 
lucky.

Tough clearing memory should be efficient (thanks to the use of 
memset(), optimized for each platform), there would of course be a 
significant performance hit. However, this could be acceptable for 
systems with strong security requirements...

What do you think? If this idea makes sense, I'll be glad to help in 
implementing it.

    Thanks in advance,

    Cheers,

    Michael.

-- 
Michael Opdenacker, Free Electrons
Free Embedded Linux Training Materials
on http://free-electrons.com/training
(More than 1000 pages!)


             reply	other threads:[~2006-06-19 14:48 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-19 14:48 Michael Opdenacker [this message]
2006-06-19 15:32 ` Option to clear allocated kernel memory before freeing it? Chase Venters
2006-06-19 15:51 ` linux-os (Dick Johnson)
2006-06-19 20:12   ` Michael Opdenacker

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=4496B92A.3010907@free-electrons.com \
    --to=michael-lists@free-electrons.com \
    --cc=linux-kernel@vger.kernel.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