All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Simon Glass <sjg@chromium.org>
Cc: U-Boot Mailing List <u-boot@lists.denx.de>
Subject: Re: [PATCH V2 10/13] iot2050: Add script for signing artifacts
Date: Wed, 5 Oct 2022 18:16:47 +0200	[thread overview]
Message-ID: <7f31e54e-0877-4ca8-de3d-3e28d2f4ff14@siemens.com> (raw)
In-Reply-To: <4a901065-d2e9-7d30-9737-63d3cdc6d462@siemens.com>

On 05.10.22 18:04, Jan Kiszka wrote:
> On 05.10.22 17:58, Simon Glass wrote:
>> Hi Jan,
>>
>> On Wed, 5 Oct 2022 at 02:36, Jan Kiszka <jan.kiszka@siemens.com> wrote:
>>>
>>> From: Jan Kiszka <jan.kiszka@siemens.com>
>>>
>>> There are many ways to get a signed firmware for the IOT2050 devices,
>>> namely for the parts under user-control. This script documents one way
>>> of doing it, given a signing key. Augment the board documentation with
>>> the required procedure around it.
>>>
>>> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
>>> ---
>>>  doc/board/siemens/iot2050.rst | 52 +++++++++++++++++++++++++++++++++++
>>>  tools/iot2050-sign-fw.sh      | 51 ++++++++++++++++++++++++++++++++++
>>>  2 files changed, 103 insertions(+)
>>>  create mode 100755 tools/iot2050-sign-fw.sh
>>
>> Please use binman for this. You can create  new entry type for your
>> needs. We want to avoid adding arch-specific scripts with no tests.
> 
> We will need a script in the foreseeable future, even when binman should
> be fixed /wrt replace - see how the certs need to be set up.

...and 'binman replace' is still broken:

# source/tools/binman/binman replace -i flash.bin -f tispl.bin_signed blob@0x180000
binman: Error 1 running 'mkimage -t -F /tmp/binman.ip2gc0oy/fit@0x380000.fit': Usage: mkimage -l image
          -l ==> list image header information
       mkimage [-x] -A arch -O os -T type -C comp -a addr -e ep -n name -d data_file[:data_file...] image
          -A ==> set architecture to 'arch'
          -O ==> set operating system to 'os'
          -T ==> set image type to 'type'
          -C ==> set compression type 'comp'
          -a ==> set load address to 'addr' (hex)
          -e ==> set entry point to 'ep' (hex)
          -n ==> set image name to 'name'
          -d ==> use image data from 'datafile'
          -x ==> set XIP (execute in place)
       mkimage [-D dtc_options] [-f fit-image.its|-F] fit-image
          -D => set options for device tree compiler
          -f => input filename for FIT source
Signing / verified boot options: [-k keydir] [-K dtb] [ -c <comment>] [-r]
          -k => set directory containing private keys
          -K => write public keys to this .dtb file
          -c => add comment in signature node
          -F => re-sign existing FIT image
          -r => mark keys used as 'required' in dtb
       mkimage -V ==> print version information and exit

Jan

-- 
Siemens AG, Technology
Competence Center Embedded Linux


  reply	other threads:[~2022-10-05 16:16 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-05  8:33 [PATCH V2 00/13] IOT2050-related enhancements Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 01/13] env: Complete generic support for writable list Jan Kiszka
2022-10-27  7:49   ` Stefan Herbrechtsmeier
2022-10-27 12:38     ` Jan Kiszka
2022-10-28  8:34       ` Stefan Herbrechtsmeier
2022-10-05  8:33 ` [PATCH V2 02/13] env: Couple networking-related variable flags to CONFIG_NET Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 03/13] tools: Add script for converting public key into device tree include Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 04/13] board: siemens: iot2050: Split the build for PG1 and PG2 Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 05/13] arm: dts: iot2050: Use the auto generator nodes for fdt Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 06/13] iot2050: Update firmware layout Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 07/13] iot2050: Add watchdog start to bootcmd Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 08/13] iot2050: Add CONFIG_ENV_FLAGS_LIST_STATIC Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 09/13] arm: dts: iot2050: Allow verifying U-Boot proper by SPL Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 10/13] iot2050: Add script for signing artifacts Jan Kiszka
2022-10-05 15:58   ` Simon Glass
2022-10-05 16:04     ` Jan Kiszka
2022-10-05 16:16       ` Jan Kiszka [this message]
2022-10-05  8:33 ` [PATCH V2 11/13] arm: dts: iot2050: Optionally embed OTP programming data into image Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 12/13] doc: iot2050: Add a note about the watchdog firmware Jan Kiszka
2022-10-05  8:33 ` [PATCH V2 13/13] board: siemens: iot2050: use the named gpio to control the user-button Jan Kiszka
2022-10-26  7:28 ` [PATCH V2 00/13] IOT2050-related enhancements Jan Kiszka
2022-10-26 13:54   ` Tom Rini
2022-10-26 14:03     ` Marek Vasut
2022-10-26 15:55       ` Jan Kiszka
2022-10-26 21:02         ` Marek Vasut
2022-10-27  4:32           ` Jan Kiszka

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=7f31e54e-0877-4ca8-de3d-3e28d2f4ff14@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=sjg@chromium.org \
    --cc=u-boot@lists.denx.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.