Repository navigation
Conversation
…rate job - ilammy/setup-nasm downloads NASM from a mutable branch of its repository, and only then from nasm.us, without checking the download, so its pinned commit doesn't pin the NASM that assembles the released Windows libraries. A local composite action, .github/actions/setup-nasm, downloads NASM 2.16.01 from nasm.us instead and checks it against a pinned SHA-256. - The `test` job of boring.yaml installed the macOS Linux cross-toolchain from a Homebrew tap, which can't be pinned. It now downloads the v15.2.0 release tarball and checks its SHA-256, like the Windows cross-toolchain. - The `precompile` job had `id-token: write` and `attestations: write` to attest the libraries, so every step in it, including compilers and third-party actions, could mint OIDC tokens. A new `attest` job downloads the libraries and attests them, and `precompile` only gets `contents: read`.
There was a problem hiding this comment.
Code Review
This pull request introduces a new GitHub Action to set up NASM on Windows by downloading it, verifying its SHA-256 checksum, and adding it to the path. A review comment suggests passing the file path directly to sha256sum instead of using stdin redirection (<) to prevent potential CRLF translation issues on Windows.
PR HealthPublish ✔️
Documentation at https://github.com/dart-lang/ecosystem/wiki/Publishing-automation. This check can be disabled by tagging the PR with Changelog Entry ✔️
Changes to files need to be accounted for in their respective changelogs. This check can be disabled by tagging the PR with Breaking changes ✔️
This check can be disabled by tagging the PR with API leaks ✔️The following packages contain symbols visible in the public API, but not exported by the library. Export these symbols or remove them from your publicly visible API.
This check can be disabled by tagging the PR with Unused Dependencies ✔️
For details on how to fix these, see dependency_validator. This check can be disabled by tagging the PR with License Headers ✔️
All source files should start with a license header. Unrelated files missing license headers
This check can be disabled by tagging the PR with Coverage ✔️
This check for test coverage is informational (issues shown here will not fail the PR). This check can be disabled by tagging the PR with |
Avoids any text-mode stdin handling on Windows.
With a path argument, GNU sha256sum escapes the backslashes of a Windows path such as D:\a\_temp and prefixes its output with `\`, so the hash didn't match.
Package publishingIf you have publishing permissions, you can use the links below to publish the changes after merging this PR.
Documentation at https://github.com/dart-lang/ecosystem/wiki/Publishing-automation. |
Note
This PR was generated by an AI coding agent (Jetski) on behalf of @mosuem.
Supply-chain hardening for
package:boring's CI. None of it depends on how the prebuilt libraries are distributed. This is the first PR in a stack; #2866 (bundling the libraries in the published package) builds on it.ilammy/setup-nasm, which downloads NASM from a mutable branch of its repository without checking the download, with a local composite action,.github/actions/setup-nasm. It downloads NASM 2.16.01 directly from nasm.us and verifies a pinned SHA-256 (matching Scoop's manifest). It's used inboring.yamland inboring_binaries.yaml, which builds the released Windows libraries.brew install messense/macos-cross-toolchains/...tap in thetestjob ofboring.yamlwith a direct download of thev15.2.0release tarball (arm64/x86_64) and a SHA-256 check, like the Windows cross-toolchain.precompilepermissions:precompileruns compilers and other build tools, so it no longer getsid-token: write/attestations: write. A newattestjob, which only downloads thebinaries-*artifacts, attests their provenance beforereleaseuploads them.gh attestation verify <file> --repo dart-lang/toolskeeps working.