lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 7 Mar 2019 13:02:58 +0000
From:   Franck Lenormand <franck.lenormand@....com>
To:     Jan Lübbe <jlu@...gutronix.de>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linux-security-module@...r.kernel.org" 
        <linux-security-module@...r.kernel.org>,
        "keyrings@...r.kernel.org" <keyrings@...r.kernel.org>
CC:     Horia Geanta <horia.geanta@....com>,
        Silvano Di Ninno <silvano.dininno@....com>,
        "agk@...hat.com" <agk@...hat.com>,
        "snitzer@...hat.com" <snitzer@...hat.com>,
        "dm-devel@...hat.com" <dm-devel@...hat.com>,
        "dhowells@...hat.com" <dhowells@...hat.com>,
        "jmorris@...ei.org" <jmorris@...ei.org>,
        "serge@...lyn.com" <serge@...lyn.com>,
        David Gstir <david@...ma-star.at>
Subject: RE: [RFC PATCH 0/2] Create CAAM HW key in linux keyring and use in
 dmcrypt

> -----Original Message-----
> From: Jan Lübbe <jlu@...gutronix.de>
> Sent: Wednesday, March 6, 2019 5:48 PM
> To: Franck Lenormand <franck.lenormand@....com>; linux-
> kernel@...r.kernel.org; linux-security-module@...r.kernel.org;
> keyrings@...r.kernel.org
> Cc: Horia Geanta <horia.geanta@....com>; Silvano Di Ninno
> <silvano.dininno@....com>; agk@...hat.com; snitzer@...hat.com; dm-
> devel@...hat.com; dhowells@...hat.com; jmorris@...ei.org;
> serge@...lyn.com; David Gstir <david@...ma-star.at>
> Subject: Re: [RFC PATCH 0/2] Create CAAM HW key in linux keyring and use in
> dmcrypt
> 
> Hi Franck,
> 
> thanks for working on this!
> 
> On Fri, 2019-03-01 at 17:09 +0100, Franck LENORMAND wrote:
> > The creation of such structures and its use was not exposed to
> > userspace so it was complicated to use and required custom
> > development. We would like to ease this using interface which are known
> and used:
> >  - Linux key retention service : Allow to generate or load keys in a
> >         keyring which can be used by applications.
> >  - dm-crypt : device mapper allowing to encrypt data.
> >
> > The capacity to generate or load keys already available in the Linux
> > key retention service does not allows to exploit CAAM capabilities
> > hence we need to create a new key_type. The new key type "caam_tk"
> allows to:
> >  - Create a black key from random
> >  - Create a black key from a red key
> >  - Load a black blob to retrieve the black key
> 
> On 2018-07-23, Udit Agarwal <udit.agarwal@....com> sent a series which
> seems related to this:
> [PATCH v2 1/2] security/keys/secure_key: Adds the secure key support based
> on CAAM.
> [PATCH v2 2/2] encrypted_keys: Adds support for secure key-type as master
> key.
> 
> Is this series intended to continue that work and cover the same uses- cases?
> 
> If I remember correctly, the CAAM also supports marking blobs to allow or
> disallow exporting the encapsulated key from the hardware. Or is this
> unneeded and we could encrypt/decrypt other (less critical) key material
> against the tk(cbc(aes)) CAAM key via the keyring mechanisms?
> 
> Best regards,
> Jan
> --
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 |
> https://emea01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fww
> w.pengutronix.de%2F&amp;data=02%7C01%7Cfranck.lenormand%40nxp.co
> m%7C29ab89e99f9040e30aa908d6a2537967%7C686ea1d3bc2b4c6fa92cd99c
> 5c301635%7C0%7C0%7C636874876732153093&amp;sdata=byKD4SmYfzMTs
> FK6cX5L81%2B9hxxqTbnOLf7%2BAJgXylU%3D&amp;reserved=0  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

Hello Jan,

The current series is aimed to change which key type is acceptable in dm-crypt. Without
this change, the key type cannot be integrated properly.

About the key type implementation:
The implementation of the key type is an improvement related to the work of Udit Agarwal.

The transform tk(cbc(aes)) is intended to receive key material whose format can change
hence the "tagging" to handle it properly. It could, for example, handle plain keys, black keys or blobs as key material and this material would be stored in keyring.

Regards,
Franck

Powered by blists - more mailing lists