Add claude-desktop, tracked from Anthropic's signed apt index - #274
Add claude-desktop, tracked from Anthropic's signed apt index#274evindor wants to merge 3 commits into
Conversation
Anthropic ships the Claude desktop app for Linux only as a .deb from their own apt repository, and their docs point Arch users at the CLI instead. This unpacks that .deb and nothing else. Tracked from the vendor repository rather than the AUR for the same reason as openai-codex-desktop -- releases land several times a week -- and for one more: Anthropic signs their apt index, so .omarchy/upstream.sh can refuse any checksum that signature does not cover. The trust chain runs from a key committed beside the hook and pinned by fingerprint, through the InRelease it signs, to the Packages index that InRelease hashes, to the .deb hashes Packages carries. A break anywhere fails the sync rather than proposing an unvouched checksum. Committing the key rather than fetching it makes rotation a reviewed change here instead of something the server can do to us. min_release_age is 24h, so an unattended sync will not ship a release upstream has not had a day to pull; the hook dates releases from the pool's Last-Modified and falls back past a quarantined one. The .deb's maintainer scripts are not reproduced: they register an apt repository, install an AppArmor profile gated on Ubuntu's userns restriction, and register a GNOME Shell search provider. Two symlinks map Debian's virtiofsd and OVMF paths onto Arch's. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Chromium cannot reliably infer the Secret Service password-store backend from a Hyprland session even when GNOME Keyring is already providing it, so the app intermittently decides no keyring is available, declines to persist the sign-in, and shows a toast saying so. hermes-desktop hit the same thing; this is the same fix (246eea9), by flag rather than env var because that is what this app reads. Replace the /usr/bin/claude-desktop symlink with a launcher that names gnome-libsecret. An explicit --password-store from the caller wins, KDE is left to the app's own kwalletd6 handling, and CLAUDE_DESKTOP_PASSWORD_STORE overrides the choice. libsecret is already a dependency. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
e8e8dce to
e65e0f8
Compare
gpg --batch --verify exits 0 on a clearsigned document that carries unsigned text outside the armour, and the SHA256 lookup takes the first match in the file, so anyone able to serve InRelease could prepend a block naming whatever Packages hash they liked and the sync would carry it through to the PKGBUILD -- the one thing the pinned key is there to prevent. Writing the signed plaintext out with --decrypt and reading that back gets only the bytes the signature covers, and fails closed when there is no valid signature at all rather than falling through to the served text. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Reviewed, and the mechanics are in better shape than most packages of this kind — but the trust chain had a hole in exactly the place the PR body says it does not. I proved it, fixed it, and pushed The signature chain was bypassableThe claim is that no checksum reaches the PKGBUILD without Anthropic's signature. As opened, that did not hold. I tested it against Anthropic's real Anyone able to serve
and the fixed hook still produces the right answer against the live index — The rest of the chain is sound, and I walked all of it on a worker rather than reading it: the committed key is a single key whose fingerprint is One weaker link left, worth knowing rather than fixing: What it installs, and wherePayload is confined to No file conflicts: Arch's
Smaller things
The decision, which is not mine
Pushed: Second opinion: codex at xhigh reviewed this independently and rated the Waiting on the maintainer for the hosting decision, and on you for the smaller items. |
What
Adds
claude-desktop, Anthropic's official Claude desktop app (Chat, Cowork, and Claude Code), tracked from Anthropic's own Debian repository.Anthropic ships the Linux app only as a
.debfrom their apt repository, and their docs send Arch users to the CLI instead. This package unpacks that.deband nothing else — no patching, no rebuilding, no bundled extras.Why not the AUR
Same reasoning as
openai-codex-desktop: releases land several times a week (six in the last three weeks), and tracking the vendor's index directly keeps up without waiting on an AUR maintainer.There is a second reason here. Anthropic signs their apt index, so this package can do something the AUR route can't: refuse to accept a checksum that Anthropic hasn't signed.
How the checksums are trusted
.omarchy/upstream.shwalks a chain that starts at a key committed in this repo:Every checksum that reaches the PKGBUILD arrives under Anthropic's own signature. A break anywhere fails the sync instead of proposing a checksum nobody vouched for. Verified failing closed against: a fingerprint that doesn't match the anchor, a substituted key, a missing key, and an attacker-modified
Packagesserved under a genuineInRelease.The key is committed rather than fetched, so rotating it is a reviewed change to this package rather than something the server can do to us. Its fingerprint
31DDDE24DDFAB679F42D7BD2BAA929FF1A7ECACEwas cross-checked against four independent sources: the published install docs,downloads.claude.ai/claude-desktop/key.asc, theInReleasesignature itself, and the copy embedded in the.deb's ownpostinst.min_release_age: "24h"is set, so an automated sync will not ship a release that upstream hasn't had a day to pull. The hook reportspublished_atfrom the pool'sLast-Modified, and falls back to the newest release that has already cleared the window rather than stalling on a fresh one.What is dropped from the .deb
The
.deb's maintainer scripts are not reproduced. They do three Debian-specific things, none of which applies here:The payload itself is confined to
/usrand carries one setuid binary,chrome-sandbox— Chromium's sandbox helper, shipped 4755 the way every Chromium-based package does.Keyring on Hyprland
Chromium cannot reliably infer the Secret Service password-store backend from a Hyprland session even when GNOME Keyring is already providing it, so the app intermittently decides no keyring is available, refuses to persist the sign-in, and shows "Your sign-in won't be saved on this device". This is the same thing
hermes-desktophit, and 246eea9 is the same fix — by flag rather than env var, because that is what this app reads.The
.debships/usr/bin/claude-desktopas a symlink to the Electron binary; this replaces it with a launcher that namesgnome-libsecret. Three cases are left alone: an explicit--password-storefrom the caller, KDE (the app appends--password-store=kwalletd6itself and carries fallback logic for a KWallet with no wallet), andCLAUDE_DESKTOP_PASSWORD_STORE=none.libsecretis already a dependency.I hit this on a fresh install: the toast appeared, yet the keyring was healthy the whole time —
gnome-keyringrunning, owningorg.freedesktop.secrets, collection unlocked, and aClaude Safe Storageitem created one second after first launch. "Not reliably" is exactly right; it is a race, not an absent keyring.Cowork
Cowork boots its agent in a QEMU VM. Upstream ships that stack under
Recommends:, which apt installs by default, so it is a hard dependency here to give the same working-out-of-the-box Cowork that Debian and Ubuntu users get. Happy to moveqemu-system-x86/edk2-ovmftooptdependsif you'd rather not pull a virtualisation stack onto every machine —virtiofsddoes need to stay a real dependency, since the app resolves it from the system before its own bundled copy.Two symlink shims map Debian's firmware and
virtiofsdpaths onto Arch's. aarch64 needs no firmware shim;edk2-aarch64already installs at the path the app opens.Testing
bin/sync-upstream self-testpasses.bin/sync-upstream claude-desktopreports correctly against the checked-in pin, and rewritespkgver,pkgreland both checksum arrays correctly when the pin is behind./usr, the expected setuidchrome-sandbox, the two shims, and the launcher.--password-storespellings,CLAUDE_DESKTOP_PASSWORD_STOREset andnone, KDE and Plasma, and an unsetXDG_CURRENT_DESKTOP.1.40609.1checksums were verified by hand against the signed index and against a downloaded.deb.I don't have aarch64 hardware, so that build is unverified beyond the checksums coming from the signed index.
Follow-up, if this merges
This only makes the package installable (
omarchy pkg add claude-desktop). It does not add a menu entry — Install → AI lists ChatGPT Desktop, Dictation, Grok Bot, LM Studio and Ollama, and Claude would still be missing from it.That belongs in
omacom/omarchyrather than here, and needs no new script — the Grok Bot / LM Studio shape covers it, since unlike ChatGPT there is nothing to launch throughuwsm-app:com.anthropic.Claudeis the desktop-id the package installs, andis the glyph the default-agent menu already uses for Claude. It has to land after this one, since both thewhenguard and the action name a package that does not exist yet. Happy to open that separately once this is in, or to drop it if you would rather Claude Desktop stay install-by-name only.🤖 Generated with Claude Code