From patchwork Tue Aug 31 02:46:54 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 504637 Delivered-To: patch@linaro.org Received: by 2002:a02:8629:0:0:0:0:0 with SMTP id e38csp2369577jai; Mon, 30 Aug 2021 19:47:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy9vL7YR+0kD3UihIHlg2rH/UQq4GzJu9u8CSvbpYJKCtV8nhT1AatiXFkZDcr2W4oOHaPd X-Received: by 2002:a17:906:a3d2:: with SMTP id ca18mr28941597ejb.10.1630378055700; Mon, 30 Aug 2021 19:47:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630378055; cv=none; d=google.com; s=arc-20160816; b=PSMRJwW9vCwbTqK5mmXqyGgaLHQWfecdHxuj0OKKkj0+E6i4kyTUiGb0DSee+niRkf WXuzlRtZD1GiAGLeWAwA76inzTFmpKKbjMikdBXQ2fQo14AOPjgg+PnxS4dBQ3qzql8I 1n5AcrJg3WgWcK/CnDBAQV5lZ5Y4g/Za2WsFM23/Yi3lnGGOEnxNhnJdoc9F95jDJsdF kNjv+fa9rP4zqe0njYcDukcFab+oR9ZFzYoiBSTA1SOcsSWQWTamcH7jdhTm5do7SUPr 3N3D1vFb36rxBcyDgO8J+4ym3ZlOTQeuaP/RaYnjjfO6gU27g6V53rOgDeY/bEtO5+9R H+Ig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature; bh=o5tAWv5ssACRPNul1zGCRWzt1lVQuf+x6EcvxXeuo4U=; b=QJLa2C1nvPFCwJ8HTxOI5AcnInGiFwzJj2ysnN/oCpgIjJXvFVcPKH32w52kaBwNNL SjzY0aL+dbIgVPPoRuTYtAYthqsV18IvPFyD9PuLYKBP5cyrbqPJdd5zGIOghSSCX/3m sl4iA+io3AREswfRPeOOjbFpdoNzsUHdLuOMNEKEBUB3AGkogPjLwxoXy753rrYd1wR1 PgiZh8wrp0uNevbd3XpHGITivwNgNRCJSUV9VbXl79jpbbZeP6mxibU8maGlKSyexhfc rH2MaoQf5aeswMMVmnbaQUynMfP8XTAooFdniFfVdNjGgo4UdwO353M48xYaUgm3jvhV ADMQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PUdmGyWZ; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id j22si62019eds.267.2021.08.30.19.47.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Aug 2021 19:47:35 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PUdmGyWZ; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 13538833DA; Tue, 31 Aug 2021 04:47:32 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="PUdmGyWZ"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 5E0BA833F4; Tue, 31 Aug 2021 04:47:30 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-pl1-x632.google.com (mail-pl1-x632.google.com [IPv6:2607:f8b0:4864:20::632]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 2670F833CF for ; Tue, 31 Aug 2021 04:47:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=takahiro.akashi@linaro.org Received: by mail-pl1-x632.google.com with SMTP id q3so9722016plx.4 for ; Mon, 30 Aug 2021 19:47:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=o5tAWv5ssACRPNul1zGCRWzt1lVQuf+x6EcvxXeuo4U=; b=PUdmGyWZ1O4/6YMmbPyy7hAQzrpE1jgE1OKvmZQ9J041hXQuTqJRdE7ojcD5YQQ26Q jm60sTj4quxE0SBdzgfwydeYN2YCvTDFy1j1uu70eAMbWeauk5MP4LQsxtxqTs7XR2XC 3aD7v0lG1DQOneceXXRuBpGxaj8X+3o9ZCgOaWD9LR0cTkUcIbhgyDvtx5eyehIjazQq Qaz0bp1RT9fOK7uZOzmfxqjMy+BMcJ6Iybwu68IP93aIWxtkHauw/2h1iuziK67hS4zT VomDfH6q1ddWNDjTaXXpiyb71ZDXltAWhwH3S8xFChCYBgHXDF1xL4lgCbrOOKfc4qNC Whuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=o5tAWv5ssACRPNul1zGCRWzt1lVQuf+x6EcvxXeuo4U=; b=QfqVgXJBDBE/FHyTGsJqeR3lLa4AKJtcgSYURX5pw+KaarLeDz2ZYrM2vQe9D+rBgm 1jkO0VJMyAhpuPsJJzPm9lpIErdIczgBKqBOFHZfks8Cj9q5MduJ+zAvkXuNKIvhQVQG flxd7E8fJzGrAEwodvqUCd0bo5fxXKHtxypL/V6Y4iqmHtxqjLLEZv6/JPnOXUrzfBJS H1oHviMQq0GGKHkPGOBK9PnQVz4Vc3hajQRH2yjUa/KehkjjGOeDibrUm012R1GFlpP6 AEGxkuB6J4n3xo/4EuOripfrGpARQRpgAe2Uhpq/8tS2WGo4nMC4HIEE6BYv7BhNAr8W jU7g== X-Gm-Message-State: AOAM533GaPnz9aOjIdfYD+hKRlSYnclrUBbJPQBOFLh0mHyGpMO098m2 jEmnMhjvGJClB1AxvJvaQbWlPg== X-Received: by 2002:a17:90a:ab07:: with SMTP id m7mr2466548pjq.27.1630378043375; Mon, 30 Aug 2021 19:47:23 -0700 (PDT) Received: from localhost.localdomain (p784a44f4.tkyea130.ap.so-net.ne.jp. [120.74.68.244]) by smtp.gmail.com with ESMTPSA id g2sm219649pfr.35.2021.08.30.19.47.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Aug 2021 19:47:22 -0700 (PDT) From: AKASHI Takahiro To: xypron.glpk@gmx.de, agraf@csgraf.de Cc: ilias.apalodimas@linaro.org, sughosh.ganu@linaro.org, masami.hiramatsu@linaro.org, u-boot@lists.denx.de, AKASHI Takahiro Subject: [PATCH v3 0/5] efi_loader: capsule: improve capsule authentication support Date: Tue, 31 Aug 2021 11:46:54 +0900 Message-Id: <20210831024659.53464-1-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean # This patch set is basically the same as v2, but removed authentication- # related pytest because the discussion about where to save a public # key is still going on. The command, mkeficapule, is independent from # the result. As I proposed and discussed in [1] and [2], I have made a couple of improvements on the current implementation of capsule update in this patch set. * add signing feature to mkeficapsule * add "--guid" option to mkeficapsule * add man page of mkeficapsule [1] https://lists.denx.de/pipermail/u-boot/2021-April/447918.html [2] https://lists.denx.de/pipermail/u-boot/2021-July/455292.html Prerequisite patches ==================== None Test ==== * locally passed the pytest which is included in this patch series on sandbox built. Todo ==== * add capsule authentication pytest Changes ======= v3 (Aug 31, 2021) * rebased on v2021.10-rc3 * remove pytest-related patches * add function descriptions in mkeficapsule.c * correct format specifiers in printf() * let main() return 0 or -1 only * update doc/develop/uefi/uefi.rst for syntax change of mkeficapsule v2 (July 28, 2021) * rebased on v2021.10-rc* * removed dependency on target's configuration * removed fdtsig.sh and others * add man page * update the UEFI document * add dedicate defconfig for testing on sandbox * add gitlab CI support * add "--guid" option to mkeficapsule (yet rather RFC) Initial release (May 12, 2021) * based on v2021.07-rc2 AKASHI Takahiro (5): tools: mkeficapsule: add firmwware image signing tools: mkeficapsule: add man page doc: update UEFI document for usage of mkeficapsule tools: mkeficapsule: allow for specifying GUID explicitly test/py: efi_capsule: align with the syntax change of mkeficapsule MAINTAINERS | 1 + doc/develop/uefi/uefi.rst | 31 +- doc/mkeficapsule.1 | 98 +++++ test/py/tests/test_efi_capsule/conftest.py | 4 +- tools/Kconfig | 7 + tools/Makefile | 8 +- tools/mkeficapsule.c | 471 +++++++++++++++++++-- 7 files changed, 554 insertions(+), 66 deletions(-) create mode 100644 doc/mkeficapsule.1 -- 2.33.0