mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ondrej Kozina <okozina@redhat.com>
To: Andrey Ryabinin <aryabinin@virtuozzo.com>,
	Alasdair Kergon <agk@redhat.com>,
	Mike Snitzer <snitzer@redhat.com>,
	dm-devel@redhat.com
Cc: Igor@redhat.com, Sukhih <igor@virtuozzo.com>,
	linux-kernel@vger.kernel.org,
	Mikulas Patocka <mpatocka@redhat.com>,
	Milan Broz <mbroz@redhat.com>
Subject: Re: [dm-devel] [RFC] dm-crypt: add ability to use keys from the kernel key retention service
Date: Wed, 10 Aug 2016 13:16:11 +0200	[thread overview]
Message-ID: <7aa99e52-6ad8-9da2-759f-58c47f2e5256@redhat.com> (raw)
In-Reply-To: <1470750966-13028-1-git-send-email-aryabinin@virtuozzo.com>

On 08/09/2016 03:56 PM, Andrey Ryabinin wrote:

Hi Andrey,

I'm definitely in favour of dm-crypt with support for kernel keyring 
service, but I think this patch do lack in addressing few issues:

Currently the dm-crypt guarantees that on remove ioctl command the 
volume key gets deleted from both crypto layer and device-mapper 
subsystem without exception. I believe we should stick to the guarantee. 
At least let's provide an option that would immediately invalidate the 
key passed via key description on table destruction. Or on last table 
destruction that would reach dm-crypt internal reference count on such 
key equal to zero. Each table key has at least single copy in crypto 
layer anyway... This is no big deal on live system (copy in crypto 
layer) but after proper system shutdown there should be no key in system 
memory (coldboot risk mitigation).

While it may sound contradicting my claim about guaranteed key 
destruction I'd like to be able to perform table load (imagine admin 
wants to resize dm-crypt device) without need of reuploading the key 
every time. Even when such user/admin has no access to already active 
volume key put in a keyring. IOW it doesn't matter what keyring the key 
was originally anchored in. (Re)load of table with valid key description 
should always pass).

The uspace part is about to land in cryptsetup 2.0 hopefully later this 
year. Most probably the kernel keyring will be used with other features 
of 2.0 release apart from loading dm-crypt mappings.

Last but not least: Mind me asking where do you plan to use it? In case 
we come with different implementation I'd like to reassure it'll be 
still of use to you.

Regards Ondrej

  reply	other threads:[~2016-08-10 18:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-09 13:56 Andrey Ryabinin
2016-08-10 11:16 ` Ondrej Kozina [this message]
2016-08-11 15:01   ` [dm-devel] " Andrey Ryabinin

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=7aa99e52-6ad8-9da2-759f-58c47f2e5256@redhat.com \
    --to=okozina@redhat.com \
    --cc=Igor@redhat.com \
    --cc=agk@redhat.com \
    --cc=aryabinin@virtuozzo.com \
    --cc=dm-devel@redhat.com \
    --cc=igor@virtuozzo.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mbroz@redhat.com \
    --cc=mpatocka@redhat.com \
    --cc=snitzer@redhat.com \
    /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

all inboxes | Powered by JetHome®