Expand description
agentmux-launcher --verify-update <version> <dir> <file> [installed:<version>] [unreachable:<why>]
Used by the root helper of a .deb or .rpm install (agentmux-install-update,
docs/specs/SPEC_LINUX_PACKAGE_UPGRADE_AND_REPOSITORY_2026_10_24.md §3.2): the
helper fetches the release’s envelope, signature and manifest into <dir>
(named as agentmux_common::update_manifest::file_names names them; a file the
release doesn’t have is left out) and asks this to check <file> against them with
the key this build pins, the same decision the app makes before it downloads
(SPEC_SIGNED_UPDATE_CHECKSUMS_2026_10_25.md). One pinned key and one decision, so
the shell script holds neither.
With installed:<version> it also holds the release to its upgrade floor
(SPEC_UPGRADE_FLOOR_IN_SIGNED_MANIFEST): the higher of the floor the verified
manifest signs and this build’s own, against the version the helper read from the
package database. The helper runs as root on a caller’s word, so it takes the floor
from the manifest it verified and the installed version from the database, never from
the caller; a release whose manifest signs no floor is checked as before.
Exit status: 0 verified; 10 the release predates signing and has no manifest (the helper falls back to the checksum GitHub lists, as the app does); 1 refused, with the message the person reads on stderr.
Structs§
- Request 🔒
- What
--verify-updatewas asked: the version, the folder of signed files, the package, and the optional parts.
Enums§
- Verdict
- What a check allows.
Constants§
- BUILD_
FLOOR 🔒 - The upgrade floor of the repository when this build was made (
UPGRADE_FLOOR): a floor only rises, so no later release’s is lower. The app’s check holds the same value. - EXIT_
UNSIGNED_ OLD - Exit status for a release made before signing existed, with no manifest.
Functions§
- build_
floor 🔒 BUILD_FLOORwhen it is a version.- parse_
request 🔒 - Read the words after
--verify-update.installed:<version>comes before the reason, which is one argument whose words were split apart and are put back together. - read_
capped 🔒 - A file a release publishes, if it was fetched, read with a cap.
- run_
if_ requested - Handle
--verify-updateif it is what was asked, returning the exit status. - size_
and_ 🔒hash - The size and SHA-256 of
path. - verify
- Check
fileagainst the signed manifest files indirforversion, usingkeys.unreachableis the helper’s reason when it couldn’t fetch them at all.installedis the version the package database says is installed and about to be replaced: given, the release’s upgrade floor is enforced. - verify_
replacing verify, holding the release to its upgrade floor againstinstalledwhen that is given.buildis this build’s own floor.