Skip to content

kuma v45.2.0

Choose a tag to compare

@github-actions github-actions released this 10 Nov 16:50
· 47 commits to main since this release
  • Doctor's report carries facts, not escapes. The strings doctor formats into its report — receipt binary names and versions, the handler half of a mime default — come from files a user-level process can write, and doctor runs under sudo: a control character in one was a terminal escape arriving in root's terminal. Every user-controlled string is stripped to plain before it is formatted in; UTF-8 names pass, control characters keep nothing.

  • dev install only executes what you built. Three hardening fixes on the dev surface, all from the same audit. Receipt-controlled binary names are now bare filenames or the receipt reads as absent — a name with a / or .. in it (the receipt is a user-editable file) would have walked the retire path join outside ~/.local/bin. The checkout's target/ must be owned by the invoking account: the verification executes the build output it stages, and kuma dev install ~/some-cloned-repo would otherwise run a stranger's binaries before any check names it — the refusal says so, and the verb's help now states the boundary too. And the staged .new copy is re-hashed against the receipt before the rename, so a source changed between verify and copy fails the install loudly instead of staging bytes the receipt vouches for falsely.

  • The local declaration is what its owner wrote, provably. Two authority-resolution fixes in state.rs. An unreadable declaration used to read as an absent one (.ok() made "cannot be read" and "not there" the same answer), so a root converger could silently fall back to the baked list — the nano incident's shape, one directory-permission away. A declaration that exists but cannot be read is now an authority error, loud like a declaration that does not parse. And the declaration's mode and ownership are checked before its text becomes the opinion root executes: group- or world-writable (any local account's rewrite), or owned by anyone but the primary account, is refused as another account's opinion.

  • The boot path stops paying for weather it can read. Three trims from the audit, plus one boundary guard. The offline boot's six flatpak retries now cost one busctl read each instead of a full vendor flail — NetworkManager's own connectivity verdict gates the script, a machine whose network arrives minutes after boot still converges through the retry ladder, and an unreadable verdict proceeds (convergence is the machine's contract; the daily gate's opposite rule governs currency). The greeter check's settle dropped from five seconds to three — three is past greetd's own RestartSec=2 cadence, which is what makes the second sample an independent draw, and every second past that was healthy-boot latency paid on every boot — and the greeter wrapper's socket poll is bash builtins now, where ls | head forked two processes every hundred milliseconds. Both convergers' xargs calls take -d '\n': the parse is positional regardless of content, so the boundary no longer leans on the upstream charset validator alone.

  • The session's units take the same medicine the daemons wrote down. Three unit-policy changes from the audit. The shell's unit said Restart=always / RestartSec=1 with no start limit — a shell wedged at startup respawn-spun every second forever, each attempt a full GPU/allocator initialization, while holding the logind lock-listener role. It now carries the exact lesson the daemon units' comments record (StartLimitIntervalSec=60, StartLimitBurst=5, RestartSec=5). The two session daemons (kuma-nostrd, nip46-relay) take MemoryMax=256M — the first memory ceilings in the image: a daemon that runs for weeks beside a signing key now fails a leak loudly instead of quietly eating the session (the heavy jobs — restic, flatpak — stay uncapped until their ceilings are sized, because a cap too low breaks legitimate multi-GB deltas). And the brew timer's calendar moved from daily to 01:00, ending the resume-time double storm where Persistent-fired catch-ups of both convergers ran as competing network and IO jobs against the same home.

  • The daemon's queues are bounded, the relay's REQs replace. The four-axis pre-release audit (performance, resource usage, memory leaks, security) found the leak posture strong everywhere except one shape: std::mpsc channels the inbound side had bounded and the other directions hadn't. kuma-nostrd's outbound relay queue was unbounded (channel::<(Event, Fan)> per road) and the relay socket had a read timeout but no write timeout — a road whose peer died or stalled mid-write grew its queue at the bunker's publish rate for as long as the outage lasted, the daemon's one plausible OOM path on a process that runs for weeks. Both roads are closed with the idiom the inbound side already runs: a sync_channel bound (OUTBOUND_CAP 1000) with try_send-shed at the producer — a shed answer is a requester's timeout, the same end an unbounded queue gave everyone eventually, without the RSS — and a ten-second write timeout beside the read timeout, so a stalled peer tears its road down into the ordinary backoff. The status channel got the same bound (STATUS_CAP 100): nothing drains it until someone asks for status, so a relay flapping unwatched for weeks wrote messages nobody consumed, and the drain's newest-state-per-URL rule makes a shed transition free. In nip46-relay, a new REQ with a subscription id already in use now replaces the old filter (NIP-01's replace rule — without it, a client that re-REQs in a loop grew its Vec one entry a time for the life of the connection), and the connection maps' cleanup moved into a Leaving drop guard that also unwinds through a poisoned lock, so a panic inside a connection's serve loop can no longer leak its subscriptions and outbound queue.

  • The release road builds the siblings once, and the nightly gets a ledger. Two road changes from the 45.2 plan. First (#74's Option A): every job that boots a disk was re-running the kumaui sibling compile — vendored gpui, release mode, no cache, ~100 minutes — for binaries another job of the same commit had already built an hour earlier, and the tag road paid it four times. ci now has a siblings job, once per head, uploading the fifteen files the compose's staging gate resolves beside the running kuma (kuma, the five shells, the nostr trio, the entries and icons); ci's six heavy jobs download it from their own run, and the tag road's four boot jobs wait for ci's run of the same commit and download from there (actions: read is the whole added scope). The road's target is ~1h15, down from ~3h10. Second: ci's boot legs skip on push, which made a first-boot unit bug on main invisible until a tag spent its road discovering it — 45.1.0's brew and home-subvol reds were both that class. The heavy battery's daily scheduled run now keeps a ledger: one issue, opened red with the run link, commented on each further red, closed green — one thread, because a nightly that opens a fresh issue a day is a wall of noise no one reads either.

  • kuma dev install — the dev loop's promotion step, with a receipt. The container-build-and-stage loop (build in kuma-dev-gcc, land binaries in ~/.local/bin, restart the session pieces by hand) never had a record: a machine carrying four binaries from three different commits is how the 44.9.0 story happened, and nothing on the machine could answer "what is dev-built here, from what, and is any of it stale". The verb verifies before it moves — every checkout's tree must be committed (a dirty tree is a stamp no commit describes) and every target/release binary that answers --version must answer for that checkout's HEAD (the same stamp gate the image's staging runs, caught before it matters) — then stages atomically (.new + mv, so a running shell or daemon keeps working) and writes a receipt at ~/.local/share/kuma/dev-install.json. The receipt is a lease, not enforcement: the image is always the authority, and the lease retires itself on the next kuma upgrade or kuma update once the image reaches the version the dev install was staged around — the machines where it matters most are the ones whose next command is the upgrade that ends it — and the retirement is complete: the nostr daemon's override goes with the binaries, so a daemon the dev install adopted runs the image's binary again. kuma doctor grades the lease (executes nothing): a binary the receipt names that is gone, staged bytes the receipt did not record, a home binary shadowing the image's with no receipt to tell its story, and a lease the image has already caught up to, are the states where the receipt says one thing and the machine another.

  • The machine converges to its declaration, wherever that declaration lives. The provenance gap the nano incident exposed: the convergers read the lists the image baked, so a fetch-lane owner editing their own ~/.config/kuma/kuma.toml was editing a file nothing read — and a release adoption converged away formulae the machine's own declaration had installed. The convergers now ask kuma sync --print-flatpaks / --print-brews, which resolves the declared primary account's local declaration and falls back to the image's baked list when no local opinion exists. The ruling's edge rules are exact: an absent key is no opinion (the baked list governs), a named key governs even when empty — brew = [] means converge away, because silence is not a zero. A local declaration that fails to parse stops convergence loudly instead of falling back: converging to the baked list because of a typo is the incident one level deeper. kuma check now reports which declaration governs each axis and whether this file's opinion is the one the converger follows (the divergence report, in prose and in the convergence key of its JSON), and doctor grades a mime default whose handler no longer resolves — the one dangling promise a converged-away flatpak leaves behind.

  • The convergence deferral has a ceiling. The daily brew and flatpak runs already defer on a low battery or a metered connection; now a deferral older than 72 hours runs anyway. A deferral is a decision about now — none of those reasons ages into an excuse, and a laptop that lives in a bag or on a hotspot would otherwise never converge again, its browser silently going stale while the timer stays green. The skip stamp's oldest line is the deferral clock — a proceed clears the stamp, every deferral adds its own — so the cap needs no new state, and a forced run rewrites the stamp to the one line kuma doctor reads out: converged, and why it had to be forced. The 72 hours is kuma's own, like the 20% battery threshold — three daily skips is the shape of "parked", not a knob anyone asked to turn. Snapshots are untouched: the snapshot timer has never been gated, and a snapshot on battery costs one copy-on-write mkdir.

  • Snapshot example defaults tightened. The examples' snapshot retention is now hourly, keep 6 recent plus 2 dailies (was 24 plus a week of dailies) — the defaults are what a stranger gets when they copy the example and never tune it, and 24 hours of coverage is the floor worth shipping, not a ceiling. Machines that declared their own values keep them; machines running the defaults adopt the new ones on the next image — the converger re-bakes what the image carries, so the tightened retention is self-healing doing its job.

Static x86_64 binary, no runtime dependencies.

$ curl -LO https://github.com/Letdown2491/kumaOS/releases/download/v45.2.0/kuma-x86_64-unknown-linux-musl
$ chmod +x kuma-x86_64-unknown-linux-musl && sudo mv kuma-x86_64-unknown-linux-musl /usr/local/bin/kuma

The image build stages the layer's three binaries from beside
the running kuma on every compose, nostr or not, so they
install to the same place:

$ curl -LO https://github.com/Letdown2491/kumaOS/releases/download/v45.2.0/kuma-nostrd-x86_64-unknown-linux-musl
$ curl -LO https://github.com/Letdown2491/kumaOS/releases/download/v45.2.0/kuma-nostr-x86_64-unknown-linux-musl
$ curl -LO https://github.com/Letdown2491/kumaOS/releases/download/v45.2.0/nip46-relay-x86_64-unknown-linux-musl
$ chmod +x kuma-nostrd-x86_64-unknown-linux-musl kuma-nostr-x86_64-unknown-linux-musl nip46-relay-x86_64-unknown-linux-musl
$ sudo mv kuma-nostrd-x86_64-unknown-linux-musl /usr/local/bin/kuma-nostrd
$ sudo mv kuma-nostr-x86_64-unknown-linux-musl /usr/local/bin/kuma-nostr
$ sudo mv nip46-relay-x86_64-unknown-linux-musl /usr/local/bin/nip46-relay

Verify it came from this workflow:

$ cosign verify-blob \
    --bundle kuma-x86_64-unknown-linux-musl.bundle \
    --certificate-identity-regexp '^https://github.com/Letdown2491/kumaOS/.+@refs/tags/' \
    --certificate-oidc-issuer https://token.actions.githubusercontent.com \
    kuma-x86_64-unknown-linux-musl

The image this release publishes verifies with the committed
public key — the same key every kuma machine's own policy
enforces on update:

$ curl -sSLO https://github.com/Letdown2491/kumaOS/raw/v45.2.0/cosign.pub
$ cosign verify --key cosign.pub ghcr.io/letdown2491/kuma:niri-45.2.0

The moving tag is the convenience and the digest is the proof;
the verify response prints the digest it checked, and the same
command against that digest pins the bytes:

$ cosign verify --key cosign.pub ghcr.io/letdown2491/kuma@sha256:<digest the verify above printed>

Built from 8f7e52ee4db354b3312d4c60c7983bdd217acc74.

The installer media on this page verifies the same way:

$ cosign verify-blob \
    --bundle kuma-x86_64.iso.bundle \
    --certificate-identity-regexp '^https://github.com/Letdown2491/kumaOS/.+@refs/tags/' \
    --certificate-oidc-issuer https://token.actions.githubusercontent.com \
    kuma-x86_64.iso