mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-07-12 22:13:05 +02:00
Make verify-commits POSIX-compliant
This commit is contained in:
@ -1,8 +1,9 @@
|
||||
#!/bin/sh
|
||||
INPUT=$(</dev/stdin)
|
||||
INPUT=$(cat /dev/stdin)
|
||||
VALID=false
|
||||
REVSIG=false
|
||||
IFS=$'\n'
|
||||
IFS='
|
||||
'
|
||||
for LINE in $(echo "$INPUT" | gpg --trust-model always "$@" 2>/dev/null); do
|
||||
case "$LINE" in
|
||||
"[GNUPG:] VALIDSIG "*)
|
||||
@ -13,10 +14,9 @@ for LINE in $(echo "$INPUT" | gpg --trust-model always "$@" 2>/dev/null); do
|
||||
"[GNUPG:] REVKEYSIG "*)
|
||||
[ "$BITCOIN_VERIFY_COMMITS_ALLOW_REVSIG" != 1 ] && exit 1
|
||||
while read KEY; do
|
||||
case "$LINE" in "[GNUPG:] REVKEYSIG ${KEY:24:40} "*)
|
||||
case "$LINE" in "[GNUPG:] REVKEYSIG ${KEY#????????????????????????} "*)
|
||||
REVSIG=true
|
||||
GOODREVSIG="[GNUPG:] GOODSIG ${KEY:24:40} "
|
||||
;;
|
||||
GOODREVSIG="[GNUPG:] GOODSIG ${KEY#????????????????????????} "
|
||||
esac
|
||||
done < ./contrib/verify-commits/trusted-keys
|
||||
;;
|
||||
|
Reference in New Issue
Block a user