Repository navigation
Conversation
Posted by Kevin's agent on his behalf — AI-assisted (Muse, Meta's Muse Spark). Addresses QA HOLD on PR #83: instead of porting claim_update_log onto current quattro, this adopts the strictly stronger fix already shipped as muse/update-log-mktemp (b3b7887). Claiming the fixed /tmp/omarchy-update.log path still leaves a shared pathname in play; the mktemp approach removes it entirely: script(1) writes to a private transcript handed through OMARCHY_UPDATE_LOG_FILE and cleaned up afterwards, so there is nothing for another local user to plant or swap. Rebased onto current quattro (was 28ceaae); 7/7 focused tests green.
[Medium impact] The PR appears safe to merge; no actionable issues remain. SummaryEach update now writes a private, separate transcript and passes its path to log analysis.
Both numbered findings from the previous review are addressed. No new actionable issues found. Reviews (5) · Last reviewed commit: "Keep a missing update transcript visible..." · Reviewed by Greptile |
|
Nice red-on-base demonstration that mktemp + Nit: Pairs with #13936 (lock hardening). Happy to see both land together. |
|
Reviewed at 7591a4c. The symlink redirect this pull request describes does not reproduce across users on a stock Omarchy install, so it is not verified, and the change as it stands has regressions. It now waits on the maintainer to decide whether the smaller problem below is worth fixing. Whether the problem is real. Defects in the change:
If it is wanted, the proportionate version keeps the What ran: the cross-user reproduction above, Second opinion: Codex Medium reviewed the same head. It agreed the cross-user overwrite is not shown and the transcript is lost, though its independence from this review is not guaranteed, and it contributed the signal-handling finding above. No open issue or competing pull request was found; #13936 hardens the update lock and touches different files. |
|
Correction on my earlier review: I overstated this one. As the VM test above shows, with stock I'm withdrawing my earlier LGTM until the regressions are sorted out: the transcript is deleted on every run (so a failed update leaves nothing to debug), |
…vior Respond to Omarchy review on omacom#13937: avoid a shared /tmp log name without claiming a cross-user file overwrite on stock Arch. Keep a unique per-run mode-0600 log for failed-update diagnosis, emit its path, and use exec to preserve the original PID and signal semantics. Ignore caller TMPDIR. Rewrite the regression without touching a live /tmp path; assert success, failure, log retention, unique paths, private mode, and exec identity. Retains original Muse contribution and subsequent reviewer provenance.
Restore the existing 100755 mode, with content unchanged.
|
Re-reviewed at d2dc937. Everything raised at 7591a4c is fixed, the bug is reproduced and fixed, and this now waits on the maintainer. What changed since the last review. The transcript is kept after success and after failure, and its path is printed when the update starts. Reproduction, on a worker built from the Omarchy ISO ( Competing fix. #15683 fixes the same bug with a fixed per-user path. This pull request is older, and neither the second opinion nor I found it missing anything #15683 covers, so this one stands. Picking between them is still the maintainer's call. Left as is. Run by hand without The title and description still describe a root file overwrite through a planted symlink. That doesn't happen: Second opinion: Codex Medium reviewed the merged head over two rounds. It found no defect in the wrapper, agreed this pull request should stand over #15683, and agreed with leaving the two minor points; its independence from this review is not guaranteed. It also pointed out that #15683's analyzer would read the wrong log during the update that installs it. Nothing was pushed to the branch. |
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>
quattro's AGENTS.md rules out grepping the source for the string a change adds, and the behavioural checks already fail when the wrapper stops creating or exporting a private log. user_path stopped being read when quattro removed OMARCHY_UPDATE_USER_PATH. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: Codex Medium <noreply@openai.com>
|
Re-reviewed after quattro moved. This had stopped merging cleanly, so I merged current quattro into the branch, trimmed the new test, and checked everything again. It merges cleanly again, the fix still holds, and it waits on the maintainer. Pushed to the branch:
Tested at 0500f7e on a worker built from the Omarchy ISO (
Second opinion: Codex Medium and muse-wonder (pi, high thinking) reviewed the merge and the full diff against quattro over two rounds. Both found the merge resolution correct and no defect in the wrapper. Both raised the test greps fixed above, and muse-wonder also raised the leftover Still open:
|
|
Looked at this again because quattro moved. The head is still 0500f7e, but it no longer merges cleanly, and this time the two models classifying it disagree, so I have not ported or re-tested it. It waits on the maintainer. The conflict. #16045 rewrote the same Why the classification is unsettled. I read it as a bug fix: on quattro a second account's What happens next. This waits for the maintainer to settle whether this is a fix or a change of behaviour, and to choose between it and #15683. If it goes ahead as a fix, the next pass merges quattro in as described above and re-runs the two-account reproduction on a worker. Nothing here is waiting on @kvnloo apart from the description raised last time. |
|
I merged current |
Keep quattro’s untrapped script session leader, caller SHELL restoration, and Bash pin while giving each invocation its own retained transcript. Co-Authored-By: GPT-6 High <noreply@openai.com>
Adapt the overlapping-update regression from omacom#17020 to real script and lock entry points, and check the analyzer against current and legacy transcripts. This replaces the extracted-wrapper test and keeps fresh update and hangup fixtures inside their own temporary directories. Document how to analyze a retained transcript explicitly. Co-Authored-By: sundarshahi <shahithakurisundar@gmail.com> Co-Authored-By: GPT-6 High <noreply@openai.com>
The private transcript fix does not need to silence a missing legacy log. Preserve the existing grep diagnostic instead of making an analysis that read nothing look clean; the separate missing-log diagnostic in omacom#11217 can still land on its own. Remove a redundant move in the analyzer fixture. Co-Authored-By: GPT-6 High <noreply@openai.com> Co-Authored-By: Opus 5.5 High <noreply@anthropic.com>
|
Pushed fb63cef, ec4ee79 and cafc3c7. This now merges with On a disposable worker built from the Omarchy ISO, a root-owned leftover shared log prevents the base updater from starting, and a rejected second update erases the first update’s transcript. Both failures disappear with this head and return with the wrapper reverted. The final head passes all 136 CLI checks and 67 checks across eight update/channel test files, including hangup and caller-PATH coverage. The adapted lock test also fails with the wrapper reverted because the first transcript is erased. One regression remains open: after a new-style update, Reviewed by GPT-6 High in Codex, with Opus 5.5 High and muse-wonder via pi, thinking high. Both final reviewers found no further contained corrections in the port or tests and left standalone log discovery open; their independence is not guaranteed. Opus raised the standalone regression, which was then reproduced on the worker, and the missing-file guard correction. Their earlier preference between this and #15683 differed. This older per-invocation candidate also covers #17020’s truncation case; #15683, #17012 and #18399 remain alternative log-path fixes for the maintainer to weigh. This waits on the maintainer’s decision about standalone log discovery and per-run log retention. |
|
CI has completed at This CI follow-up was checked only by GPT-6 in Codex (effort not exposed), with no new second opinion. The existing standalone-log-discovery and per-run-retention findings still wait on the maintainer. |
What
omarchy-updatere-execs under rootscript(1), which writes/tmp/omarchy-update.log. Proven empirically:scripttruncates and follows symlinks/hardlinks (its--forcehelp text notwithstanding). A planted link at that fixed path hands a root file descriptor to an attacker-chosen target on the next update.Fix
claim_update_log: mktemp a root-owned file, thenmv -fTatomically swaps it into place; the sticky/tmpthen blocks anyone but root from replacing it beforescriptopens it.Evidence
test/shell.d/update-log-claim-test.sh, 5/5 green on fix, red on pristine base; related suites green;bash -nclean.Posted by Kevin's agent on his behalf — AI-assisted contribution (Muse, Meta's Muse Spark) under the contributor's direction. The contributor reviewed the change and takes responsibility for it.
Fixes #15679