From patchwork Fri Feb 19 18:45:13 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Alex G." X-Patchwork-Id: 1442419 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=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) 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=sqZNdXr1; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (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 4Dj0sS2d1nz9sBJ for ; Sat, 20 Feb 2021 05:46:20 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id EA6058276B; Fri, 19 Feb 2021 19:45:46 +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="sqZNdXr1"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 964348277A; Fri, 19 Feb 2021 19:45:32 +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,SPF_HELO_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-oi1-x229.google.com (mail-oi1-x229.google.com [IPv6:2607:f8b0:4864:20::229]) (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 6041F8269F for ; Fri, 19 Feb 2021 19:45:27 +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-oi1-x229.google.com with SMTP id h17so6843292oih.5 for ; Fri, 19 Feb 2021 10:45:27 -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=DnI0hs/wCI8MEy76QXeWN/xHNiRR7iT7TsTuPnkxz6E=; b=sqZNdXr1DyCni2BnuGocNAD5vIA987zKlkef3L/+S8FxXdxGDn1XOAK/IBJi64Hd+O D/HGDiN3SaWSQmVr1H3bHJIZEP2s6cmFPN8//d2hHCyS30jEeKuFhrKcynB6qlAnxhM0 Qjk1ZTtE0ryx5C/R7+HSSCc2ZsGFFbh548I21VjAonJlms56zu0+2ejR2eR4euOsMG+L RUOloj5GpwcJYo1kxLmGJ2CE+t3Z8sKw7CeSjUasic7ydPL+QePAHQP67MHUBGSiH+Pd bPAjSoa7b/aGsQgC0x8yuYALU1wsrZkABaHvuMREG605o+WRlWhHWENDeJd1aEzUW9u+ Lp9g== 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=DnI0hs/wCI8MEy76QXeWN/xHNiRR7iT7TsTuPnkxz6E=; b=B2GhWpARTJ/wNfToehok4nwm8yVlKNwyVrK6O86iXOHkO2iU+KG3HQC9vYpTEvYl96 OA9SjWOLuOSa2Ttx79t+JpP6+8tLM8nHtup5SisAmx2e24oEF754zVud1kUVKfsQVdum jgKz3QcHWkOHQsYwJgzXm0ISGM31h5RmcI8JdzQrqS/F2FMp+qBwQxBX5yzZbSWtihps ZKBzaEOj8EQtiySlw1gC4jVvdQG+rJCaNClzQ5jRLX1W5EN/FFOllI+4lFHPYDGyvgjr 0MElTnoHxvJ1FA1OBDWGRsvVgZZqm3rzGMd955iPnuJ2QRwXOEZeBiesetRFKhH6xY5b Dk0Q== X-Gm-Message-State: AOAM5300/zpxM8wbbx3vMwGcxxdXQyen0DwiSSkIfoJbXYYX4MsgT8rP j0gffHyX7ym/GOuoW9lLJfp6d2pIZVc= X-Google-Smtp-Source: ABdhPJzRNqH4K/NYSOBpsAo7Vxv8Cv4jVQAENw4H6Et6U1Qy/4/qGLy13kTwISaN8eAofFffoeHDTg== X-Received: by 2002:aca:7541:: with SMTP id q62mr7838336oic.143.1613760325900; Fri, 19 Feb 2021 10:45:25 -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 g14sm1860423oon.23.2021.02.19.10.45.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 19 Feb 2021 10:45:25 -0800 (PST) From: Alexandru Gagniuc To: u-boot@lists.denx.de, trini@konsulko.com, sjg@chromium.org Cc: Alexandru Gagniuc , marex@denx.de Subject: [PATCH v6 04/11] doc: signature.txt: Document devicetree format for ECDSA keys Date: Fri, 19 Feb 2021 12:45:13 -0600 Message-Id: <20210219184520.616270-5-mr.nuke.me@gmail.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20210219184520.616270-1-mr.nuke.me@gmail.com> References: <20210219184520.616270-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::