Skip to content

Commit

Permalink
signimage: rename various scripts to get shorter/simpler names
Browse files Browse the repository at this point in the history
that are easier to remember/guess
  • Loading branch information
PeterPawn committed Nov 29, 2021
1 parent f568c37 commit a276313
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 561 deletions.
10 changes: 5 additions & 5 deletions signimage/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ with two empty placeholder blocks (a 512 byte) instead of this signature file.

The sample scripts and their purposes:

`generate_signing_key`
`yf_genkey`

create an own key pair to sign images - AVM uses 1024 bit RSA keys, this script may be used to create larger keys, which can't
be verified with the AVM components

`sign_image`
`yf_sign`

add a signature file to a specified TAR archive and stream the result to STDOUT

Expand All @@ -22,15 +22,15 @@ add a signature file to a specified TAR archive and stream the result to STDOUT
convert a public key file in AVM reading (one line with modulus as hexadecimal character string and another one with the public
exponent) into a well-formed PKCS8 structure in a PEM file, ready to be used by OpenSSL functions

`check_signed_image`
`yf_check_signature`

verify the signature of a signed image, the script accepts a list of possible public keys (in various formats) and tries to
decode the signature file, until the right key was found or the end of list is reached

`image_signing_files.inc`
`signimage.conf`

contains some definitions for the location and file name conventions for key files involved in this process, this file will
be included by the others to setup key file locations - has to be edited to reflect your own preferences
be included by the others to setup key file locations - read comments carefully, most times no permanent changes are needed

---

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion signimage/run_signature_tests
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ yf_bin_platform="$(uname -m)"
yf_bin_kernel="$(uname -r)"
yf_yourfritz_branch="main"
yf_signimage_directory="$yf_repo/$yf_yourfritz_branch/signimage"
yf_signimage_files="avm_pubkey_to_pkcs8 check_signed_image generate_signing_key image_signing_files.inc sign_image show_signature_problem"
yf_signimage_files="avm_pubkey_to_pkcs8 yf_check_signature yf_genkey signimage.conf yf_sign show_signature_problem"
yf_signimage_binaries="openssl"
yf_red="$(printf "\033[31m\033[1m")"
yf_yellow="$(printf "\033[33m\033[1m")"
Expand Down
4 changes: 2 additions & 2 deletions signimage/show_signature_problem
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@
#
check()
{
check_signed_image $1 -a ~/firmware_signing.asc
yf_check_signature $1 -a ~/firmware_signing.asc
}
sign()
(
[ -z "$3" ] && export YF_SIGNIMAGE_SKIP_WORKAROUNDS=1 || export -n YF_SIGNIMAGE_SKIP_WORKAROUNDS
sign_image "$1" "$2"
yf_sign "$1" "$2"
)
pack()
{
Expand Down
Loading

0 comments on commit a276313

Please sign in to comment.