Received: by 10.223.185.116 with SMTP id b49csp1014636wrg; Fri, 16 Feb 2018 10:50:30 -0800 (PST) X-Google-Smtp-Source: AH8x224Y8n4jhXmPG1mdBYqqJOxPe9kJuZVz9R6WG0PsXzkuHVIw6pXLaPNkvk9+pZ8x5ZWo2vC1 X-Received: by 2002:a17:902:7889:: with SMTP id q9-v6mr6651327pll.114.1518807030375; Fri, 16 Feb 2018 10:50:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518807030; cv=none; d=google.com; s=arc-20160816; b=yh7iOn2ideU0EfYcQYKzfHcVtZJrNIMatfKOA/ZhhcOS9oMH7eKqO1+jwbBR7Y041t VppdnXD25BGO5hHo067qMU32bvW7BKnTuThJxPHDt6bbArDoGJZnemlCDp5BU3TqgOI6 296bOSUX3HIWftlxi1emk1jtC4aDhzx7TkISFihuGpc8CHhvUe2cu0kLHqlo4HdQbkoc ugBk5L0cICZ1cz5c4n06WxB3TmyUtB+1xUsUyZLI5Tpj1A9Gzz1u3KEy5CNKtn1FxffL eNprdyOYOzsFyZdjwebMPCIO3Ntw7xDGTD36sGzYKwF9SOV8PZ04GfBSFkHu+44lDAFW vsYw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language:in-reply-to:mime-version :user-agent:date:message-id:from:references:cc:to:subject :dkim-signature:arc-authentication-results; bh=K3x2IJML6Z4wpQBAfwR2afVEEHIidnQUFimObIhIK/Y=; b=VyTKcyIjs7NGVZwkOMT1xv7gBFsQ6eeJpkev+IitSckhi4pkNY+v0ucdc1OCAcrIc9 7E1O/vPfMnR9FpCNVJTzU/1KcqYTUbpNcw4CbFWz0H1XZWzr7vuY6oHZiwVUNBFnFBMU ufOzDeudE3IUcD/B2Zu2noDsOZMqbeeZAw7UtoTCXABuAUQjYtg6wQ3Gs8k24E+EFI0F i3ULTsBr95iglsoXPFD8c9470yCXmRBaFu3rlgc3PeavCEYpLWVDUxpfEeoiaP1t9wns WMaRzYuVvm+9AiAOCFEnrtgn/hcqrlueNNc4QrGuIbVFJ1f+9XYvoJrSPl/F09J0GWg1 wksw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@pmhahn.de header.s=201711 header.b=MJZrr4UQ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g124si11222826pgc.114.2018.02.16.10.50.15; Fri, 16 Feb 2018 10:50:30 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@pmhahn.de header.s=201711 header.b=MJZrr4UQ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754176AbeBPIZB (ORCPT + 99 others); Fri, 16 Feb 2018 03:25:01 -0500 Received: from parrot.pmhahn.de ([88.198.50.102]:51478 "EHLO parrot.pmhahn.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753977AbeBPIZA (ORCPT ); Fri, 16 Feb 2018 03:25:00 -0500 Received: from [IPv6:2001:470:71e6:17:3c97:eff:fe92:d32a] (unknown [IPv6:2001:470:71e6:17:3c97:eff:fe92:d32a]) by parrot.pmhahn.de (Postfix) with ESMTPSA id 00175E79E9; Fri, 16 Feb 2018 09:24:58 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=pmhahn.de; s=201711; t=1518769499; bh=Jx0efHgbhvZw0PZoIokAFKZGUTw5/0zi6w8kVX9t1zM=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=MJZrr4UQHeypdc1Ot22W/ehQvPZTaRjzAzz8aQBEYSXp5yxX76Ga3E5G5NE17Ubdu 3g3khJSUfdodTI/JW+rdw3x2t1lgDcxgFJyPF777PTfRudpxkL610PY9bdOFYnUBcx 42cnma6UhOADvhNEgYhaBRuYf2VzXGrhdOH3StPc= Subject: Re: [PATCH] Make kernel taint on invalid module signatures configurable To: Matthew Garrett , Jessica Yu Cc: Ben Hutchings , Linux Kernel Mailing List References: <20170807195027.13192-1-mjg59@google.com> <20180215152514.rxmh7webdg2i2fct@redbean> From: Philipp Hahn Message-ID: Date: Fri, 16 Feb 2018 09:24:58 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/mixed; boundary="------------5ECF84BE8FFF0A61C433A721" Content-Language: en-GB Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is a multi-part message in MIME format. --------------5ECF84BE8FFF0A61C433A721 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Hello, Am 15.02.2018 um 20:36 schrieb Matthew Garrett: > On Thu, Feb 15, 2018 at 7:25 AM Jessica Yu wrote: >> From what I understand from Ben's post from last year >> (http://lkml.kernel.org/r/1504044122.4448.24.camel@decadent.org.uk), >> it sounds like the main issue is that Debian doesn't support their own >> centralised module signing yet, causing all of their modules to be >> automatically tainted if they enable CONFIG_MODULE_SIG, and that a new >> option like this would likely be used as a temporary "fix". Am I >> understanding correctly? > > Not entirely. There's two cases where the current situation causes problems: > > 1) Distributions that build out of tree kernel modules and don't have > infrastructure to sign them will end up with kernel taint. That's something > that can be resolved by implementing that infrastructure. > 2) End-users who build out of tree kernel modules will end up with kernel > taint and will file bugs. This cannot be fixed but will increase > distribution load anyway. Just yesterday I sent the attached email to the crypto/-maintainers as I have read some Fedora documentation about adding the UEFI SecureBoot keys to the kernel secondary trusted keyring: Sadly didn't work for me :-( If my understanding is correct and iff that would work, Debian (and others) could load their public key into Shim and then use the associated private key for singing their modules. Debian currently plans to have a Sprint for their SecureBoot process in April, which I will attend. Hopefully we will find a solution their: Philipp (also a Debian developer) --------------5ECF84BE8FFF0A61C433A721 Content-Type: message/rfc822; name="Nachricht als Anhang" Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename="Nachricht als Anhang" To: David Howells , David Woodhouse From: Philipp Hahn Subject: [linux] .system_keyring ? Organization: Univention GmbH Cc: keyrings@vger.kernel.org Message-ID: <49ef1eb6-802b-ae86-a5e4-eb29a8ef4c4c@univention.de> Date: Thu, 15 Feb 2018 12:51:50 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 8bit Hello, reading "Documentation/admin-guide/module-signing.rst": > The kernel contains a ring of public keys that can be viewed by root. They're > in a keyring called ".system_keyring" that can be seen by:: > > [root@deneb ~]# cat /proc/keys > ... > 223c7853 I------ 1 perm 1f030000 0 0 keyring .system_keyring: 1 I don't have that ".system_keyring": > cat /proc/keys > 00a8459a I------ 1 perm 1f0f0000 0 0 keyring .secondary_trusted_keys: 1 > 02b66804 I--Q--- 8 perm 3f030000 0 0 keyring _ses: 1 > 0639503a I--Q--- 3 perm 1f3f0000 0 65534 keyring _uid.0: empty > 1afb3552 I------ 2 perm 1f0b0000 0 0 keyring .builtin_trusted_keys: 1 > 3167cca3 I--Q--- 1 perm 1f3f0000 0 65534 keyring _uid_ses.0: 1 > 37b744d9 I------ 1 perm 1f030000 0 0 asymmetri Build time autogenerated kernel key: 8943e26cd249e2fcdafea805149fcf9ed5912e10: X509.rsa d5912e10 [] Grepping the Linux kernel source tree git also find no '.system_keyring' in any source file - only the name of the header file and in Documentation/. Am I missing something? If that documentation out-dated? My .config is this: > $ sed -ne 's/^config /CONFIG_/p' certs/Kconfig | ssh uefi 'grep -F -f - /boot/config-`uname -r`' > CONFIG_MODULE_SIG_KEY="certs/signing_key.pem" > CONFIG_SYSTEM_TRUSTED_KEYRING=y > CONFIG_SYSTEM_TRUSTED_KEYS="" > # CONFIG_SYSTEM_EXTRA_CERTIFICATE is not set > CONFIG_SECONDARY_TRUSTED_KEYRING=y I was looking at and I'm trying to get my UEFI keys added to the Linux keyring. I want to sign my modules with that "external" key instead of embedding the key into the Linux kernel itself. Thanks in advance. Philipp PS: I'm not subscribed to 'keyring, but LKML. -- Philipp Hahn Open Source Software Engineer Univention GmbH be open. Mary-Somerville-Str. 1 D-28359 Bremen Tel.: +49 421 22232-0 Fax : +49 421 22232-99 hahn@univention.de http://www.univention.de/ Geschäftsführer: Peter H. Ganten HRB 20755 Amtsgericht Bremen Steuer-Nr.: 71-597-02876 --------------5ECF84BE8FFF0A61C433A721--