Repository navigation
Conversation
Contributor
[Low impact] The PR appears safe to merge. SummaryFixes the cross-UID test setup for different
Reviews (1) · Last reviewed commit: "Stop the stay-awake cross-UID probe fail..." · Reviewed by Greptile |
Collaborator
|
I read the diff and the surrounding namespace setup. My review (GPT-6 in Codex; reasoning effort not exposed) classifies this as a test bug, but the configured second classifier returned no usable classification, so classification remains unsettled. Tests were not run and no code was changed. Verification is waiting for the classification check to be resolved. |
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.
What changes
The two-UID fallback probe in
update-stay-awake-security-test.shrebuilds its fixture inside a user and mount namespace. It mounts a fresh tmpfs on/tmp, then runsmkdir -m 755 "$fixture"at the pathmktemp -dgave the test. That only works whenTMPDIRis unset or exactly/tmp:TMPDIRnested under/tmp(a build or sandbox directory): the fresh tmpfs has none of the parent directories, somkdirfails withNo such file or directory.TMPDIRoutside/tmp(~/tmp,/var/tmp/…, an agent's scratch directory): the tmpfs doesn't hide the fixture, somkdirfails withFile exists.Either way,
set -eends the probe, and the file reportsnot ok - two-UID fallback probe failed after its capability check. That reads as a security failure when nothing is wrong.mkdir -prebuilds a nested path inside the namespace's/tmp.TMPDIRoutside/tmpskips the probe with its reason, next to the existing skip for missing namespace support.Deleting the existing directory or extracting the fixture over it would be wrong. Outside
/tmpthe namespace shares the host's mount at that path, so it would touch the real directory instead of an isolated copy.Verification
TMPDIRquattro/tmp/tmp/<nested>No such file or directory, fails/var/tmp/<dir>File exists, failsThis doesn't overlap #14790, which changes line 523 of the same file.
Screenshots
No visible change: test only.