Repository navigation
java/audit-publication: audit a published release from the outside - #5
Merged
Merged
Conversation
The gate proves the package was complete when it was frozen. Nothing proved afterwards that Central published it, that the release still holds it, or that the run the tag names made it. java-llama.cpp did these checks by hand after 6.0.0 (its docs/post-release-check.md). This adds the checks that are not specific to one repository. actionlib.java.audit runs on a checkout of the tag with the release files downloaded: - run and jobs: one successful run on the tag, at its commit, on the default branch. Nothing failed, and the skipped jobs are exactly the other channel's (by display name, read from the workflow). - assets: exactly the files release-assets.json and the POMs promise, each signed. - central: every Central file and signature is served by repo1 with the GitHub bytes (published .sha256/.sha1, signatures byte for byte). Absent files are polled, since Central publishes asynchronously. - signatures: the release key comes from a public keyserver over HTTPS into a throwaway keyring, and one subkey signed everything. - provenance: gh attestation verify, pinned to the tag and the workflow; every file is a subject of that run with its digest. - bytecode: class-file floors per file pattern, including an AAR's classes.jar. - next: the default branch is at the next minor -SNAPSHOT (a warning only). Configured in the new post-release section of actions-config.json. Run against java-llama.cpp v6.0.0, every check passes: 60 files and 60 signatures from one subkey, 118 Central files with the release's bytes, 120 files attested by run 40239731871. The next check warns (main is still at 6.0.0). 19 tests. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AJGh28Gu8pLWYbTCqG1LZf
…ease from root A repository adopts the audit after some of its releases, so the tag of an older release carries no post-release configuration. The settings (signing key, bytecode floors) and the repository's identity now come from the current directory, the repository running the audit. The contract, the POMs and the publish workflow come from --root (input `root`), a checkout of the tag. One workflow can then audit java-llama.cpp 6.0.0 with today's settings. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AJGh28Gu8pLWYbTCqG1LZf
5 of 7 tasks
This was referenced Oct 26, 2026
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.
The publication gate proves a package was complete when it was frozen. Nothing proved afterwards that Central published it, that the release still holds it, or that the tag's run made it. After 6.0.0, java-llama.cpp ran those checks by hand (its docs/post-release-check.md). This adds the repository-neutral checks as
java/audit-publication; the code islib/actionlib/java/audit.py.runjobscheck-snapshot,publish-snapshotand its three consumers, by their display names from the workflow at the tagassetsrelease-assets.jsonand the POMs at the tag promise, each with its.asccentral.sha256(else.sha1), signatures byte for byte, no second download. Absent files are polled forwait-minutessignaturesprovenancegh attestation verifyof one file, pinned torefs/tags/<tag>and the publish workflow; every release file is a subject of that run's statement with its digestbytecodeclasses.jarscanned too; a rule that scanned nothing fails, and a corrupt jar is a finding, not a crashnext-SNAPSHOT(only ever a warning)Configuration: the new
post-releasesection of.github/actions-config.jsonholdssigning-key(the primary fingerprint),bytecodeandworkflow. It is read from the workspace; the contract, the POMs and the workflow come fromroot, a checkout of the tag. So a release made before a repository adopted the audit can still be audited with today's settings (second commit).Run against java-llama.cpp v6.0.0 (real release, real Central, real attestations), all 8 checks pass:
D5C0…D767ofEA6E…48ED2packagejob also attests the native libraries)nextwarns:mainwas still at 6.0.0docs/publication.mdgains "After the release: the audit", with the trigger:workflow_runon the publish workflow.release: publisheddoes not work, because a release created with the workflow token starts no workflow.Tests: 157 green on Windows and Linux, 19 of them new; each check is covered with the failure it exists for.
runscripts: 0 problems.Still open: a run on a GitHub runner. java-llama.cpp#573 pins this branch's head (
630e3a9) in its newpost-release.yml. After the merge: tag a release (v1.1.0: a new action, nothing changes for existing callers) and move that pin.🤖 Generated with Claude Code
https://claude.ai/code/session_01AJGh28Gu8pLWYbTCqG1LZf