linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Elaine Palmer <erpalmerny@gmail.com>
To: Coiby Xu <coxu@redhat.com>, eric.snowberg@oracle.com
Cc: davem@davemloft.net, dhowells@redhat.com,
	dmitry.kasatkin@gmail.com, dwmw2@infradead.org,
	herbert@gondor.apana.org.au, jarkko@kernel.org,
	jmorris@namei.org, keyrings@vger.kernel.org,
	linux-crypto@vger.kernel.org, linux-integrity@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	linux-security-module@vger.kernel.org,
	nramas@linux.microsoft.com, pvorel@suse.cz,
	roberto.sassu@huawei.com, serge@hallyn.com, tiwai@suse.de,
	zohar@linux.ibm.com, erpalmer@linux.ibm.com
Subject: Re: [PATCH 0/7] Add CA enforcement keyring restrictions
Date: Tue, 8 Nov 2022 20:24:08 -0500	[thread overview]
Message-ID: <faa10c58-268f-ddc8-b86c-02c903e29f8a@gmail.com> (raw)
In-Reply-To: <20221104132035.rmavewmeo6ceyjou@Rk>



On 2022/11/04 9:20 AM, Coiby Xu wrote:
> Hi Eric,
>
> I wonder if there is any update on this work? I would be glad to do
> anything that may be helpful including testing a new version of code.
>
Hi Coiby,

Yes, this discussion got stuck when we couldn't agree on one of the
following options:

(A) Filter which keys from MOK (or a management system) are loaded
    onto the .machine keyring. Specifically, load only keys with
    CA+keyCertSign attributes.

(B) Load all keys from MOK (or a management system) onto the
    .machine keyring. Then, subsequently filter those to restrict
    which ones can be loaded onto the .ima keyring specifically.

The objection to (A) was that distros would have to go through
two steps instead of one to load keys. The one-step method of
loading keys was supported by an out-of-tree patch and then by
the addition of the .machine keyring.

The objection to (B) was that, because the .machine keyring is now
linked to the .secondary keyring, it expands the scope of what the
kernel has trusted in the past. The effect is that keys in MOK
have the same broad scope as keys previously restricted to
.builtin and .secondary. It doesn't affect just IMA, but the rest
of the kernel as well.

I would suggest that we can get unstuck by considering:

(C) Defining a systemd (or dracut module) to load keys onto the
    .secondary keyring

(D) Using a configuration option to specify what types of
    .machine keys should be allowed to pass through to the
    .secondary keyring.
   
    The distro could choose (A) by allowing only
    CA+keyCertSign keys.

    The distro could choose (B) by allowing any kind
    of key.

We all seemed to agree that enforcing key usage should be
implemented and that a useful future effort is to add policies
to keys and keyrings, like, "This key can only be used for
verifying kernel modules."

I hope we can come to an agreement so work can proceed and IMA
can be re-enabled.

-Elaine Palmer

  parent reply	other threads:[~2022-11-09  1:24 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-06  1:53 [PATCH 0/7] Add CA enforcement keyring restrictions Eric Snowberg
2022-04-06  1:53 ` [PATCH 1/7] KEYS: Create static version of public_key_verify_signature Eric Snowberg
2022-04-06  1:53 ` [PATCH 2/7] KEYS: X.509: Parse Basic Constraints for CA Eric Snowberg
2022-04-08 14:39   ` Mimi Zohar
2022-04-08 15:31     ` Eric Snowberg
2022-04-06  1:53 ` [PATCH 3/7] KEYS: X.509: Parse Key Usage Eric Snowberg
2022-04-08 14:39   ` Mimi Zohar
2022-04-06  1:53 ` [PATCH 4/7] KEYS: Introduce a builtin root of trust key flag Eric Snowberg
2022-04-08 14:40   ` Mimi Zohar
2022-04-08 15:27     ` Eric Snowberg
2022-04-08 16:55       ` Mimi Zohar
2022-04-08 17:34         ` Eric Snowberg
2022-04-08 18:49           ` Mimi Zohar
2022-04-08 21:59             ` Eric Snowberg
2022-04-11 15:30               ` Mimi Zohar
2022-04-14 16:36                 ` Eric Snowberg
2022-04-14 18:09                   ` Mimi Zohar
2022-04-14 21:59                     ` Eric Snowberg
2022-04-15 16:14                       ` Mimi Zohar
2022-04-06  1:53 ` [PATCH 5/7] KEYS: Introduce sig restriction that validates root of trust Eric Snowberg
2022-04-06 19:55   ` kernel test robot
2022-04-06  1:53 ` [PATCH 6/7] KEYS: X.509: Flag Intermediate CA certs as built in Eric Snowberg
2022-04-07  1:04   ` kernel test robot
2022-04-06  1:53 ` [PATCH 7/7] integrity: Use root of trust signature restriction Eric Snowberg
2022-04-06 20:45 ` [PATCH 0/7] Add CA enforcement keyring restrictions Mimi Zohar
2022-04-06 22:53   ` Eric Snowberg
2022-04-08 14:41     ` Mimi Zohar
2022-11-04 13:20 ` Coiby Xu
2022-11-04 21:06   ` Eric Snowberg
2022-11-09  1:24   ` Elaine Palmer [this message]
2022-11-09 14:25     ` Eric Snowberg
2022-11-09 14:58       ` Elaine Palmer

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=faa10c58-268f-ddc8-b86c-02c903e29f8a@gmail.com \
    --to=erpalmerny@gmail.com \
    --cc=coxu@redhat.com \
    --cc=davem@davemloft.net \
    --cc=dhowells@redhat.com \
    --cc=dmitry.kasatkin@gmail.com \
    --cc=dwmw2@infradead.org \
    --cc=eric.snowberg@oracle.com \
    --cc=erpalmer@linux.ibm.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=jarkko@kernel.org \
    --cc=jmorris@namei.org \
    --cc=keyrings@vger.kernel.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-integrity@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-security-module@vger.kernel.org \
    --cc=nramas@linux.microsoft.com \
    --cc=pvorel@suse.cz \
    --cc=roberto.sassu@huawei.com \
    --cc=serge@hallyn.com \
    --cc=tiwai@suse.de \
    --cc=zohar@linux.ibm.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;
as well as URLs for NNTP newsgroup(s).