From patchwork Thu Jan 7 22:33:39 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexandru Gagniuc X-Patchwork-Id: 1423528 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=QCfqXeZl; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4DBgyc5KCkz9sVt for ; Fri, 8 Jan 2021 09:34:32 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 5A028828F0; Thu, 7 Jan 2021 23:34:16 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com 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=gmail.com header.i=@gmail.com header.b="QCfqXeZl"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id DBCDC828F0; Thu, 7 Jan 2021 23:34:11 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-oo1-xc2c.google.com (mail-oo1-xc2c.google.com [IPv6:2607:f8b0:4864:20::c2c]) (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 8AAE0828E3 for ; Thu, 7 Jan 2021 23:34:01 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=mr.nuke.me@gmail.com Received: by mail-oo1-xc2c.google.com with SMTP id 9so1959950ooy.7 for ; Thu, 07 Jan 2021 14:34:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=0cIrclvqfMGJ60GhoWWA+GJSfTZG4dwuJGELTpj4fwY=; b=QCfqXeZlyMGJ8YCC3uKtVVmH2ZV/DKQH4kqMEl8g1KdzfkDYiPZ2IgbXzpNSBgGNjG l6P1i0dG4r5TLQRSP5R+JPpSO9fvA0zMMM11grpehP8qtKD/kdWq9tgOc9nz9/f3dvsk fR38f5SaFXZOA0EHW7+maRnThHyAT+LSlzTWnHkzk8AsBAHbqhr1bCBX1VHI6r78YS+i LoFS9J7VStaKt0f4eHyGZmKUEZUDjVNPAJX6zPzl9DlBDgCuS3JMaVvukglogXSEYOe8 csXaCWyn7IUolmpuPT6XATtYxMYmUWfkPGF+vog37Zz9LPGlHc9PWvbgulurmgQBAdpa SV3Q== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=0cIrclvqfMGJ60GhoWWA+GJSfTZG4dwuJGELTpj4fwY=; b=cuS/rXesKQhfdAF3AnnOUhE0+uWxvsUk+l4XdpfTyXHA8ZyMg+Pk5oO3RtKYGo9U3d BTkPU0+SybMmZHBIdzBMpkwV8iMEBGu0V9Ul69rE75ytJbDULj9/19FofiKDx6zmcvtK 5fIwy1d7ns58omymkja+Ied9ArVtonoVsdQulMdfOGxprc9HJ4bjMvIYGbHBFLBIa2EI X4l265DKqjzq3lsUHY8f/mhxxdRfx9bD+x9acx4LEHeAO55ILfgIid2ljR+F3oJA5iG8 5Jvif7+7z1quBFInuBcFF5JipED3lnDKQBGgSS4ZwebuBafpasH+STy/t0eI8VsDWj1X w/CQ== X-Gm-Message-State: AOAM530npXxIHOITDogzKE/yBRFgvKlPnwsKS13Gk+HZl2eTrP1EYA9c Ep3vI8rYlopA91QtJsuMRT5Lu6Lsffp9lA3o X-Google-Smtp-Source: ABdhPJzQYkuY0i6q2to/sJaE8nunwcIb9pFaigmd0IYig8wf/SrwudMNxm0xjzpU13lRJdjZiOdCpQ== X-Received: by 2002:a4a:da44:: with SMTP id f4mr2483272oou.84.1610058839447; Thu, 07 Jan 2021 14:33:59 -0800 (PST) Received: from nuclearis2-1.lan (c-98-195-139-126.hsd1.tx.comcast.net. [98.195.139.126]) by smtp.gmail.com with ESMTPSA id h7sm1408065otq.21.2021.01.07.14.33.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Jan 2021 14:33:59 -0800 (PST) From: Alexandru Gagniuc To: u-boot@lists.denx.de, sjg@chromium.org Cc: Alexandru Gagniuc , trini@konsulko.com, marex@denx.de, Bastian Krause , George McCollister , Jan Luebbe , Thirupathaiah Annapureddy Subject: [PATCH v3 4/6] doc: signature.txt: Document devicetree format for ECDSA keys Date: Thu, 7 Jan 2021 16:33:39 -0600 Message-Id: <20210107223341.517268-5-mr.nuke.me@gmail.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20210107223341.517268-1-mr.nuke.me@gmail.com> References: <20210107223341.517268-1-mr.nuke.me@gmail.com> 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.102.3 at phobos.denx.de X-Virus-Status: Clean Signed-off-by: Alexandru Gagniuc Reviewed-by: Simon Glass --- doc/uImage.FIT/signature.txt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/doc/uImage.FIT/signature.txt b/doc/uImage.FIT/signature.txt index a3455889ed..0139295d33 100644 --- a/doc/uImage.FIT/signature.txt +++ b/doc/uImage.FIT/signature.txt @@ -142,7 +142,7 @@ public key in U-Boot's control FDT (using CONFIG_OF_CONTROL). Public keys should be stored as sub-nodes in a /signature node. Required properties are: -- algo: Algorithm name (e.g. "sha1,rsa2048") +- algo: Algorithm name (e.g. "sha1,rsa2048" or "sha256,ecdsa256") Optional properties are: @@ -167,6 +167,11 @@ For RSA the following are mandatory: - rsa,r-squared: (2^num-bits)^2 as a big-endian multi-word integer - rsa,n0-inverse: -1 / modulus[0] mod 2^32 +For ECDSA the following are mandatory: +- ecdsa,curve: Name of ECDSA curve (e.g. "prime256v1") +- ecdsa,x-point: Public key X coordinate as a big-endian multi-word integer +- ecdsa,y-point: Public key Y coordinate as a big-endian multi-word integer + These parameters can be added to a binary device tree using parameter -K of the mkimage command::