pkgmeek: accommodate verbose output from signify
This commit is contained in:
parent
a9fb36fff0
commit
ab4a9ee6fd
@ -446,7 +446,7 @@ parse_signify_output() { # chomps the output of check_signature()
|
|||||||
*"Pkgfile verification failed")
|
*"Pkgfile verification failed")
|
||||||
signerr=-1; error "Signature missing! Unable to authenticate the Pkgfile."
|
signerr=-1; error "Signature missing! Unable to authenticate the Pkgfile."
|
||||||
;;
|
;;
|
||||||
*"verification failed")
|
*"verification failed"*)
|
||||||
signerr=1; error "Signature file corrupted or unreadable."
|
signerr=1; error "Signature file corrupted or unreadable."
|
||||||
;;
|
;;
|
||||||
*"FAIL")
|
*"FAIL")
|
||||||
@ -464,6 +464,7 @@ check_signature() { # called from $PKGMK_ROOT in the case "when"="pre-Pkgfile",
|
|||||||
local reqfiles=(Pkgfile); local s=0; local when="$1";
|
local reqfiles=(Pkgfile); local s=0; local when="$1";
|
||||||
local SIGNIFY_ARGS=(-C -x "$PKGMK_ROOT/.signature")
|
local SIGNIFY_ARGS=(-C -x "$PKGMK_ROOT/.signature")
|
||||||
|
|
||||||
|
[ "$PKGMK_PUBLICKEY" ] || PKGMK_PUBLICKEY="$(get_repo_key public)"
|
||||||
if [ -f "$PKGMK_ROOT/.signature" ]; then
|
if [ -f "$PKGMK_ROOT/.signature" ]; then
|
||||||
[ "$when" = "pre-Pkgfile" ] || reqfiles=(.footprint)
|
[ "$when" = "pre-Pkgfile" ] || reqfiles=(.footprint)
|
||||||
while [ "$when" = "pre-build" ] && (( s < ${#_local_[@]} )); do
|
while [ "$when" = "pre-build" ] && (( s < ${#_local_[@]} )); do
|
||||||
@ -473,8 +474,7 @@ check_signature() { # called from $PKGMK_ROOT in the case "when"="pre-Pkgfile",
|
|||||||
for FILE in "${reqfiles[@]}"; do
|
for FILE in "${reqfiles[@]}"; do
|
||||||
[ -e "$FILE" ] || ln -sf "$PKGMK_ROOT/$FILE" .
|
[ -e "$FILE" ] || ln -sf "$PKGMK_ROOT/$FILE" .
|
||||||
done
|
done
|
||||||
[ "$PKGMK_PUBLICKEY" ] && [ -r "$PKGMK_PUBLICKEY" ] && \
|
[ -r "$PKGMK_PUBLICKEY" ] && SIGNIFY_ARGS+=(-p "$PKGMK_PUBLICKEY")
|
||||||
SIGNIFY_ARGS+=(-p "$PKGMK_PUBLICKEY")
|
|
||||||
/usr/bin/signify "${SIGNIFY_ARGS[@]}" "${reqfiles[@]}" 2>&1
|
/usr/bin/signify "${SIGNIFY_ARGS[@]}" "${reqfiles[@]}" 2>&1
|
||||||
else
|
else
|
||||||
[ "$when" = "pre-Pkgfile" ] && echo "Pkgfile verification failed"
|
[ "$when" = "pre-Pkgfile" ] && echo "Pkgfile verification failed"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user