-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Verify gpg signatures as part of bump-stage0 #88739
Verify gpg signatures as part of bump-stage0 #88739
Conversation
Rustup's lack of using |
SequoiaPGP is GPL 2.0, which as far as I understand makes any binary which integrates it covered by GPL 2.0, which would be functionally a license change for Please correct me if I've misunderstood anything though. |
Using it as executable instead of library would be possible I think. In that case the rustup executable doesn't become covered by GPL AFAIK, only the sequoia-pgp executable. |
Yes the licence concern remains. I was going to talk with Sequoia about that once I was confident the rest was sorted. We actually have a PR from them to try and start the process so I'll probably put a checklist on there and licence terms will be part of that. |
Could/should the release team use a much-simpler signature protocol, for instance a plain SHA256-ed25519 signature as done in OpenBSD's
I realise this is widely out of this PR's scope, but if licensing & distribution issues are the blocker, it might make sense to instead head directly towards the better/safer option. |
My argument against things like |
Hey all, after a quick chat with @Mark-Simulacrum we came to an agreement to investigate other ways to improve the supply chain security of Rust than this specific PR. Closing it. Regarding ways to sign Rust distributions, I'd love to (also?) get other signature algorithms implemented, but this is probably not the right place to do so. If you all are interested in continuing a discussion on that we can probably figure out a place to do so. |
Those capabilities are entirely unnecessary in this usecase. You might note for instance that the current OpenPGP signing key is simply embedded in the repository. |
This PR is a followup to #88362 to perform signature verification as part of
bump-stage0
, ensuring the manifests accessed by the tool are signed with the release team's gpg key. This grants us the advantages of signature verification without the need of performing it as part ofx.py
, as the pinned checksums used byx.py
will be verified bybump-stage0
before they're committed.With this PR an attacker wanting to compromise the boostrap compiler undetected would also need to compromise the signing key and wait for someone else (human or automation) to update the pinned checksums. This does not add any extra protection against an attacker submitting a PR updating the pinned checksums, as they would just avoid performing the signature verification.
The
pgp
crate was chosen compared tosequoia-pgp
both because of licensing reasons (Sequoia is GPL) and because Sequoia relies on C dependencies (the nettle crypto library). Rustup also uses thepgp
crate.r? @Mark-Simulacrum