Repository navigation
Use ordinary sudo: one password for ten minutes, plain update scripts - #17000
Merged
Merged
Conversation
Omarchy commands revoked sudo's timestamp on entry and exit and authenticated through a sudo -N wrapper, so every privileged step asked again: three prompts at "Create system snapshot", six for a dev link session. Ship timestamp_timeout=10, drop the revocation and the wrapper, and keep omarchy update's single authorization and keepalive. Channel switching keeps its stop for a destination older than this tree, now keyed on what the next steps need: omarchy-update-pacman, and an updater that restores the caller's PATH. Releases 4.0.5 and 4.0.6 have neither. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: Codex Medium <noreply@openai.com>
Contributor
[High impact] The PR appears safe to merge within its stated choice to restore ordinary sudo caching. SummaryRestores ordinary sudo caching and simplifies the update scripts.
|
The privileged-Bash startup check, environment scrubbing, OMARCHY_PATH source-root check and pinned PATH in omarchy-update, omarchy-refresh-pacman and omarchy-channel-set only guarded against code already running as the user, the same threat the password boundary was dropped for. They return to plain Bash as in 4.0.6, with every feature since kept; hooks and mise inherit the caller's PATH directly. The channel swap calls pacman itself again, so a refresh that installs an older release without omarchy-update-pacman cannot strand it, and the older-destination stop is no longer needed. Leaving dev drops the unlinked checkout's bin from PATH so the packaged update runs the packaged helpers. omarchy-update-stay-awake and omarchy-sudo-passwordless keep the security library: OM-SEC-12 and OM-SEC-01 guard against other accounts, not the caller. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: Codex Medium <noreply@openai.com>
omarchybot
added a commit
to Roriz/omarchy
that referenced
this pull request
Nov 1, 2026
quattro's omacom#17000 dropped sudo revocation, so cleanup_update can no longer fail to revoke: take quattro's cleanup and drop the revoke case from the cleanup test, keeping the error and signal cases that check a failed update releases the lid lock. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ryanrhughes
added a commit
to shbernal/omarchy
that referenced
this pull request
Nov 1, 2026
omacom#17000 dropped the sudo-no-update wrapper this branch sat next to, so the AUR step keeps quattro's plain yay call and adds the unset above it.
ryanrhughes
added a commit
to shbernal/omarchy
that referenced
this pull request
Nov 1, 2026
omarchy-update keeps the caller's PATH since omacom#17000, so mise's go and GOROOT stay together there. omarchy-upgrade-to-quattro still runs the AUR step with its system-first package_path.
ryanrhughes
added a commit
that referenced
this pull request
Nov 1, 2026
* Keep mise's GOROOT out of AUR package builds * Name the upgrade as the caller that pairs system PATH with mise's GOROOT omarchy-update keeps the caller's PATH since #17000, so mise's go and GOROOT stay together there. omarchy-upgrade-to-quattro still runs the AUR step with its system-first package_path. --------- Co-authored-by: Ryan Hughes <ryan@heyoodle.com>
ryanrhughes
added a commit
that referenced
this pull request
Nov 1, 2026
* Keep mise's GOROOT out of AUR package builds * Name the upgrade as the caller that pairs system PATH with mise's GOROOT omarchy-update keeps the caller's PATH since #17000, so mise's go and GOROOT stay together there. omarchy-upgrade-to-quattro still runs the AUR step with its system-first package_path. --------- Co-authored-by: Ryan Hughes <ryan@heyoodle.com> (cherry picked from commit c125859)
omarchybot
added a commit
to kvnloo/omarchy
that referenced
this pull request
Nov 1, 2026
quattro dropped OMARCHY_UPDATE_USER_PATH from the script(1) re-exec (omacom#17000), so the wrapper keeps its private mktemp log without that variable, and the docs keep quattro's shortened boot-check note beside this branch's log note. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
omarchybot
added a commit
to Ashwinhegde19/omarchy
that referenced
this pull request
Nov 1, 2026
omacom#17000 replaced the update's revoke-and-wrap sudo boundary with ordinary sudo and a ten-minute timestamp that no Omarchy command clears, and omacom#16568 moved AUR and the boot check inside the update's authorization. The cold-boundary wording this branch added is now wrong, so hooks.md takes quattro's paragraph, which already says hooks run inside the update's authorization. Two stale lines remain on quattro and are fixed here: the hook tree's "after privileged work" for post-update, which mise, AUR and the boot check all follow, and the manual's claim that update hooks run after Omarchy clears its sudo authorization and may prompt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 1, 2026
omarchybot
added a commit
to VykosMolt/omarchy
that referenced
this pull request
Nov 1, 2026
quattro now uses ordinary sudo (omacom#17000) and runs AUR updates under the update's one authorization (omacom#16568), and its hooks.md already describes that. Keep quattro's paragraph there and this branch's corrected post-update tree comment. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
omarchybot
added a commit
to VykosMolt/omarchy
that referenced
this pull request
Nov 1, 2026
Since omacom#17000 neither omarchy update nor omarchy refresh pacman clears its sudo timestamp, and AUR updates share the update's one authorization (omacom#16568), so nothing is cleared before AUR and a hook's sudo can reuse what was already asked for. It can, not does: a standalone refresh has no keepalive, so a hook that waits past the ten-minute timestamp prompts again. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: Codex Medium <noreply@openai.com>
This was referenced Nov 1, 2026
namespaceMarcello
added a commit
to namespaceMarcello/omarchy
that referenced
this pull request
Nov 2, 2026
omacom#17000 dropped the command-scoped sudo boundary: cleanup_update now ends with a plain exit, and the test fixture no longer has assert_boundary_cold. Keep the warning in cleanup_update after end_update_authorization and Stay Awake, before the exit, and drop the four assert_boundary_cold calls this branch had added. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
namespaceMarcello
added a commit
to namespaceMarcello/omarchy
that referenced
this pull request
Nov 2, 2026
omacom#17000 deleted remove-dev-env-sudo-security-test.sh, whose namespace probe this branch gated; the other two probes and the shared helper merge cleanly. No test added since maps ids with unshare without calling user_namespace_available. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
GruperTal
added a commit
to GruperTal/omarchy
that referenced
this pull request
Nov 3, 2026
Since omacom#17000 omarchy update is a plain script on the caller's PATH, so the window's English and gum stand-ins reach it as they reach installs. That changes nothing it reads: pacman was already pinned to English by omarchy-update-system-pkgs, and an unattended update asks gum nothing. The notes that said otherwise go. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
localrobot
pushed a commit
to localrobot/omarchy
that referenced
this pull request
Nov 3, 2026
…omacom#17000) * Let one sudo password last ten minutes in a terminal Omarchy commands revoked sudo's timestamp on entry and exit and authenticated through a sudo -N wrapper, so every privileged step asked again: three prompts at "Create system snapshot", six for a dev link session. Ship timestamp_timeout=10, drop the revocation and the wrapper, and keep omarchy update's single authorization and keepalive. Channel switching keeps its stop for a destination older than this tree, now keyed on what the next steps need: omarchy-update-pacman, and an updater that restores the caller's PATH. Releases 4.0.5 and 4.0.6 have neither. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: Codex Medium <noreply@openai.com> * Make update, refresh and channel switching plain scripts again The privileged-Bash startup check, environment scrubbing, OMARCHY_PATH source-root check and pinned PATH in omarchy-update, omarchy-refresh-pacman and omarchy-channel-set only guarded against code already running as the user, the same threat the password boundary was dropped for. They return to plain Bash as in 4.0.6, with every feature since kept; hooks and mise inherit the caller's PATH directly. The channel swap calls pacman itself again, so a refresh that installs an older release without omarchy-update-pacman cannot strand it, and the older-destination stop is no longer needed. Leaving dev drops the unlinked checkout's bin from PATH so the packaged update runs the packaged helpers. omarchy-update-stay-awake and omarchy-sudo-passwordless keep the security library: OM-SEC-12 and OM-SEC-01 guard against other accounts, not the caller. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: Codex Medium <noreply@openai.com> --------- Co-authored-by: David Heinemeier Hansson <david@hey.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: Codex Medium <noreply@openai.com> (cherry picked from commit 56a910b)
GruperTal
added a commit
to GruperTal/omarchy
that referenced
this pull request
Nov 4, 2026
Since omacom#17000 omarchy update is a plain script on the caller's PATH, so the window's English and gum stand-ins reach it as they reach installs. That changes nothing it reads: pacman was already pinned to English by omarchy-update-system-pkgs, and an unattended update asks gum nothing. The notes that said otherwise go. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
GruperTal
added a commit
to GruperTal/omarchy
that referenced
this pull request
Nov 5, 2026
Since omacom#17000 omarchy update is a plain script on the caller's PATH, so the window's English and gum stand-ins reach it as they reach installs. That changes nothing it reads: pacman was already pinned to English by omarchy-update-system-pkgs, and an unattended update asks gum nothing. The notes that said otherwise go. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
20 of 34 tasks
GruperTal
added a commit
to GruperTal/omarchy
that referenced
this pull request
Nov 11, 2026
Since omacom#17000 omarchy update is a plain script on the caller's PATH, so the window's English and gum stand-ins reach it as they reach installs. That changes nothing it reads: pacman was already pinned to English by omarchy-update-system-pkgs, and an unattended update asks gum nothing. The notes that said otherwise go. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
GruperTal
added a commit
to GruperTal/omarchy
that referenced
this pull request
Nov 11, 2026
Since omacom#17000 omarchy update is a plain script on the caller's PATH, so the window's English and gum stand-ins reach it as they reach installs. That changes nothing it reads: pacman was already pinned to English by omarchy-update-system-pkgs, and an unattended update asks gum nothing. The notes that said otherwise go. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
GruperTal
added a commit
to GruperTal/omarchy
that referenced
this pull request
Nov 14, 2026
Since omacom#17000 omarchy update is a plain script on the caller's PATH, so the window's English and gum stand-ins reach it as they reach installs. That changes nothing it reads: pacman was already pinned to English by omarchy-update-system-pkgs, and an unattended update asks gum nothing. The notes that said otherwise go. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
4 tasks
GruperTal
added a commit
to GruperTal/omarchy
that referenced
this pull request
Nov 19, 2026
Since omacom#17000 omarchy update is a plain script on the caller's PATH, so the window's English and gum stand-ins reach it as they reach installs. That changes nothing it reads: pacman was already pinned to English by omarchy-update-system-pkgs, and an unattended update asks gum nothing. The notes that said otherwise go. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
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.
Omarchy asked for the sudo password over and over. A fresh install's update asked three times at "Create system snapshot", and a dev link session asked six times. A password typed one command earlier never carried over to the next.
The cause is the command-scoped sudo boundary from OM-SEC-14 (#9469) and OM-SEC-22 (#10217). Commands cleared sudo's timestamp (
sudo -k) when they started and exited, and ran privileged steps through asudo -Nwrapper that authenticates without caching. The aim was to deny code Omarchy runs as the user (hooks, AUR builds, mise installers) a warm sudo cache. That code already has easier routes to root: an AUR package's install scripts and pacman hooks run as root by design, and anything running as the user can put asudoof its own on their PATH and wait for the next password. #16568 had already put AUR builds back under the update's authorization. Every major distribution caches sudo for the same reason.This goes back to ordinary sudo:
etc/sudoers.d/omarchy-sudo-timeoutsetstimestamp_timeout=10, so one password covers ten minutes in the same terminal. No Omarchy command clears it or authenticates throughsudo -N, and thesudo-no-updatewrapper is gone.omarchy-update,omarchy-refresh-pacmanandomarchy-channel-setare plain Bash scripts again, as in 4.0.6. Thebash -pstartup check, environment scrubbing,OMARCHY_PATHsource-root check and pinned PATH only guarded against code already running as the user, so they go too. Every feature added since stays: the boot check, the free-space check, the mise fallback, the update lock, regional pacman rendering, per-platform templates and dev-checkout validation. Hooks and mise inherit the caller's PATH directly.omarchy updatestill asks once up front, with a keepalive so long downloads never outlast the authorization. It runs insidescript's own pseudo-terminal, so a password typed in the calling terminal does not carry in. That is one prompt per update, as before.omarchy/omarchy-devwith a directsudo pacman -Sagain. The refresh before it can already have installed an older release without this tree's helpers, so the older-destination stop is no longer needed. Leaving dev drops the unlinked checkout'sbinfrom PATH, so the packaged update runs the packaged helpers.Two fixes that guard against other accounts stay intact, along with the security library they use:
omarchy-update-stay-awake(OM-SEC-12) keeps its private state and process-identity checks, so another account can't make update cleanup kill an arbitrary process. It only loses the timestamp clearing.omarchy-sudo-passwordless(OM-SEC-01) keeps its grant validation and fail-closed expiry. It only losessudo -N.Tests that pinned the removed boundary or entry checks are gone or narrowed to stay-awake.
channel-sudo-boundary-test.shbecomeschannel-switch-test.sh, which keeps the coverage that wasn't about the boundary.🤖 Generated by Opus 5.5 in Claude Code. Reviewed by Codex Medium.