Use python instead of slow shell script on verify-commits
This commit is contained in:
1 parent
e24bf1ce18
commit
e5b2cd8e75
7 files changed
+169
-161
No files matched your search
@@ -7,18 +7,18 @@ are PGP signed (nearly always merge commits), as well as a script to verify
|
||||
commits against a trusted keys list.
|
||||
|
||||
|
||||
Using verify-commits.sh safely
|
||||
Using verify-commits.py safely
|
||||
------------------------------
|
||||
|
||||
Remember that you can't use an untrusted script to verify itself. This means
|
||||
that checking out code, then running `verify-commits.sh` against `HEAD` is
|
||||
_not_ safe, because the version of `verify-commits.sh` that you just ran could
|
||||
that checking out code, then running `verify-commits.py` against `HEAD` is
|
||||
_not_ safe, because the version of `verify-commits.py` that you just ran could
|
||||
be backdoored. Instead, you need to use a trusted version of verify-commits
|
||||
prior to checkout to make sure you're checking out only code signed by trusted
|
||||
keys:
|
||||
|
||||
git fetch origin && \
|
||||
./contrib/verify-commits/verify-commits.sh origin/master && \
|
||||
./contrib/verify-commits/verify-commits.py origin/master && \
|
||||
git checkout origin/master
|
||||
|
||||
Note that the above isn't a good UI/UX yet, and needs significant improvements
|
||||
@@ -42,6 +42,6 @@ said key. In order to avoid bumping the root-of-trust `trusted-git-root`
|
||||
file, individual commits which were signed by such a key can be added to the
|
||||
`allow-revsig-commits` file. That way, the PGP signatures are still verified
|
||||
but no new commits can be signed by any expired/revoked key. To easily build a
|
||||
list of commits which need to be added, verify-commits.sh can be edited to test
|
||||
list of commits which need to be added, verify-commits.py can be edited to test
|
||||
each commit with BITCOIN_VERIFY_COMMITS_ALLOW_REVSIG set to both 1 and 0, and
|
||||
those which need it set to 1 printed.
|
||||
Reference in new issue
Block a user