All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arno Wagner <arno@wagner.name>
To: dm-crypt@saout.de
Subject: Re: [dm-crypt] keys in memory?
Date: Fri, 14 Jan 2011 00:56:02 +0100	[thread overview]
Message-ID: <20110113235601.GA10251@tansi.org> (raw)
In-Reply-To: <375AD447-08EA-41C6-8366-C62CAE8CE5DF@nytimes.com>

(Milan: Have seen your answer, but this is something I
 feel rather strongly about, so I have to elaborate.)

On Thu, Jan 13, 2011 at 04:03:20PM -0500, Kachler, Arie wrote:
> Hi all,
> 
> When a system has been configured and it's using encrypted LUKS
> partition(s), are they keys visible in memory? 

Not necessarily directly, but the cipher key-setup is.
There is no way to avoid that with software encryption.
So it may require some days to work out how the cipher
key configuration looks in memory and it is possible
(depending on key set-up) that the original key cannot 
actually be reconstructed, but decryption will be possible
with just a mamory image. 

On Linux, the memory image is accessible under /proc/kcore.
Make a copy of that and it requires only a bit of work and
some sample encrypted data to find the keys.

> The question is relevant when deploying these types of partitions to a
> cloud provider, where the provider's hypervisor has access to all vms'
> memory. Any insight into this will be greatly appreciated.

The cloud provider has low-effort access to all your keys
in memory. It may also swap them out to disk if you are
unlucky. If you need confidentiallity, you need to control
the storage, hardware, OS, application and possibly network 
yourself, cloud computing cannot ever give you that. There 
are some efforts underway to try to change that, but what 
I saw so far has no chance of succeeding. I have so far not
seen any reasonable idea to get around this problem and I 
suspect it is fundamentally infeasible in a real clound
setting. I guess you can get grant money and publications 
with this though, if none of the reviwers understands IT 
security.

One way to explain this to a non-expert (which I guess is the
situation you are in) goes like this: 

- The cloud provider can copy, store and resume running 
  vm images without the vm user knowing. 
- The clound provider can become root on any image.
- Hence the cloud provider can copy your running VM in full, 
  including storage, can run it in some test-bed, become root in
  that test-bed and can then access any mapped decrypted partition
  at its leisure without you having the slightest chance of even 
  finding out an attack took place.
- As a consequence, the cloud provider can get at any and all 
  data processed in the clound without the data owners
  ever having a chance of noticing. These attacks do not require 
  significant effort.

That is not the whole story, of course. In some VM technologies
the above operations require a bit more effort and are not part
of the standard functionality. For example, it may be required 
add a key to the ssh trusted keys file for root and allow
ssh root login. This is a matter of minutes.

Assume you have no technological security against your cloud
provider at all. 

Arno
-- 
Arno Wagner, Dr. sc. techn., Dipl. Inform., CISSP -- Email: arno@wagner.name 
GnuPG:  ID: 1E25338F  FP: 0C30 5782 9D93 F785 E79C  0296 797F 6B50 1E25 338F
----
Cuddly UI's are the manifestation of wishful thinking. -- Dylan Evans

If it's in the news, don't worry about it.  The very definition of 
"news" is "something that hardly ever happens." -- Bruce Schneier 

  parent reply	other threads:[~2011-01-13 23:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-13 21:03 [dm-crypt] keys in memory? Kachler, Arie
2011-01-13 21:31 ` Milan Broz
2011-01-13 23:56 ` Arno Wagner [this message]
2011-01-14  8:53   ` Milan Broz
2011-01-14 15:25     ` Kachler, Arie

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=20110113235601.GA10251@tansi.org \
    --to=arno@wagner.name \
    --cc=dm-crypt@saout.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.