Supply-chain hardening, what is left after #1679: signed setup lists, unpinned Linux deps, list validation in the Python builder #2045
Labels
No labels
accessibility
autorelease: pending
autorelease: tagged
bug
dependencies
documentation
duplicate
enhancement
github_actions
good first issue
help wanted
invalid
question
testing wanted
wontfix
No milestone
No assignees
1 participant
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Hookshot#2045
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The idea
Follow-up to #1679, which was closed when #1792 (the
Updater.csdigest check) shipped in 2.1.0-rc.1. That fixed one item of the list; this issue keeps the ones that are still open, checked again atf8efe05. Static review only, nothing was run.Since #1679, three items are done, thank you:
Updater.csverifies the asset digest (#1792), releases are built and uploaded by CI withactions/attest-build-provenance, and the release tooling no longer runsnpm install(release-please).Still open (medium)
hookshot-setup.txt/hookshot-linux.txt, downloaded from the same release as the parts, and theUpdater.csdigest comes from GitHub's release metadata. Both protect against a broken download, not against a release changed by someone with the account or a write token. The attestations now exist, but the setup and the updaters do not check them. Suggestion: sign the lists (minisign/ed25519, public key compiled into the setup and the Linux updater), and/or Authenticode-signHookshotBuilder.exe.scripts/linux/deps.shchecks a SHA-256 for almost everything, but not for dav1d (:135) nor the Vulkan-Headers, SPIRV-Headers and VulkanMemoryAllocator tag archives (:171). dav1d is compiled and linked into the game executable the AppImage ships, and a tag archive can change at its source.builder/py/hookshot_builder/setup_parts.py(read_manifest,:113) takestag,dest,frm,toandshaas they come, whilesetup.cpasses them throughlist_name_okand checks the checksum's form. With atagthat is an absolute path or has..,rmtree(work)/rmtree(final)(:215-216) delete that folder before any checksum is looked at.:179also matches the checksum as a substring ofparts.txt. It needs a tampered list (item 1), so this is about the port following the C setup's rules.Still open (low)
setup.c:158(mem_sink):m->p = realloc(m->p, ...)loses the old pointer on failure, and the list has no size limit.setup.c:652-663(and:183-192): the BCrypt return values are not checked, so the hash handle is used uninitialised if they fail.setup.c:328-331: the tag read fromcurrent.txtbuilds a path without going throughlist_name_ok. A local file, so low risk; for consistency.linux_update.py:439reads each part fully into memory. urllib also follows https→http redirects; the hash check covers that, but a redirect handler that refuses them would make it explicit.deps.sh:102:pip installpins versions but does not use--require-hashes; that Python goes inside the AppImage.scripts/release_upload.sh:56,:83:gh release upload --clobberlets a published file be replaced with no trace. GitHub's immutable releases would close this for version tags.Runner.cs:19: when the package'stools\python\python.exeis missing, the builder starts whateverpythonWindows finds first. Stopping with the "restore it from quarantine" messageCheckalready has would be safer.Anything else
There is still no
SECURITY.md; turning on GitHub's private vulnerability reporting would give future reports a private channel. Not covered by the review:third_party/and the shader recompiler undergpu/vk/eden.More reports of this, collected here:
github-sync referenced this issue2026-11-12 06:22:54 +00:00