ci: verify Node.js toolchain downloads in build-qemu#4527
Open
safeengineauto wants to merge 1 commit intolovell:mainfrom
Open
ci: verify Node.js toolchain downloads in build-qemu#4527safeengineauto wants to merge 1 commit intolovell:mainfrom
safeengineauto wants to merge 1 commit intolovell:mainfrom
Conversation
Added SHA256 checksums for multiple Node.js versions in CI workflow.
Owner
|
Thanks for the PR, I'm unsure this added complexity is necessary. I'm aware checksums are often used by OS-level package managers when dependencies might be distributed via non-secure HTTP, however we're always fetching Node.js binaries via HTTPS so the risk of in-flight tampering is much lower. Perhaps we can experiment with OS-provided Node.js packages when running under QEMU emulation? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR hardens the
build-qemuworkflow by verifying downloaded Node.js toolchain tarballs before extraction.Currently the job downloads the Node.js tarball and pipes it directly into
tar. This change downloads the tarball to disk, verifies it against the expected SHA-256 from upstreamSHASUMS256.txt, and only extracts it after verification succeeds.This affects the four QEMU-built platform packages:
linux-armlinux-s390xlinux-ppc64linux-riscv64This is release-chain hardening, not a fix for a known vulnerability.
Changes
nodejs_sha256to eachbuild-qemumatrix entry./tmp.sha256sum -c.curl --show-error --fail --location.Notes
The SHA-256 values were taken from the corresponding upstream
SHASUMS256.txtfiles for the exact Node.js versions already used by the workflow.I kept the change limited to
build-qemuand did not change dependency installation, action pinning, base images, or release logic.