pkgmeek: fixed the cat_signature() subroutine
This commit is contained in:
parent
8401b2aa25
commit
3337d49093
@ -490,7 +490,7 @@ check_signature() { # called from $PKGMK_ROOT in the case "when"="pre-Pkgfile",
|
||||
}
|
||||
|
||||
cat_signature() {
|
||||
local ordered f key pub
|
||||
local ordered si key pub
|
||||
[ -e "$PKGMK_ROOT/.footprint" ] || warning "Footprint not found, signature will be incomplete."
|
||||
for key in ~/.ssh/*.sec /etc/ports/*.sec; do
|
||||
[ -e "$key" ] || continue # workaround for brain-dead shell globbing
|
||||
@ -500,8 +500,8 @@ cat_signature() {
|
||||
for f in "$PKGMK_ROOT/Pkgfile" "$PKGMK_ROOT/.footprint"; do
|
||||
[ -e $f ] && ordered+=( "$f" )
|
||||
done
|
||||
for f in "${source[@]}"; do ordered+=("${_local_[$f]}"); done
|
||||
sha256sum --tag "${ordered[@]}" \
|
||||
for ((si=0; si < ${#source[@]}; si++)); do ordered+=("${_local_[$si]}"); done
|
||||
sha256sum --tag "${ordered[@]}" \
|
||||
| sed 's|^SHA256 (.*/\(.*\))\(.* = .*\)|SHA256 (\1)\2|' \
|
||||
| "$PKGMK_SIGNIFY" -S -e -x - -q -s "$key" -m - \
|
||||
| sed "s|${key/%.sec/.pub}|$pub|"
|
||||
|
Loading…
Reference in New Issue
Block a user