chore(buglog): bug-1868 fixed (7864a3da); log remaining root /tmp symlink opens

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Rongsong Shen 2026-09-26 07:55:23 +00:00
parent 7864a3dab7
commit 5f53211f9d
Signed by untrusted user: rshen
GPG key ID: 80533536B0EB651C

View file

@ -28111,9 +28111,9 @@
},
{
"id": "bug-1868",
"status": "open",
"status": "fixed",
"status_updated": "2026-09-26",
"status_note": "found while fixing bug-1508; fix: O_NOFOLLOW (+ unlink/O_EXCL or a root-owned per-job dir) when creating the output file",
"status_note": "7864a3da: xcecd_create_job_output() unlinks then creates with O_EXCL|O_NOFOLLOW|O_CLOEXEC.",
"timestamp": "2026-09-26T07:40:17Z",
"error_message": "uv_proc_exec (worker/src/uv_proc.c) creates each task's output file /tmp/job_<jobid>_task<N>.out as root with O_WRONLY|O_CREAT|O_TRUNC and no O_NOFOLLOW/O_EXCL: a local user who pre-plants a symlink at a predictable future job's output name makes the root worker truncate and write job output into the symlink target",
"file": "src/worker/src/uv_proc.c",
@ -28131,6 +28131,28 @@
],
"occurrences": 1,
"last_seen": "2026-09-26T07:40:17Z"
},
{
"id": "bug-1869",
"status": "open",
"status_updated": "2026-09-26",
"status_note": "fix: O_NOFOLLOW on both, or move these files under a root-owned directory (e.g. the worker's log dir / /run)",
"timestamp": "2026-09-26T07:55:23Z",
"error_message": "Other root-owned opens of fixed /tmp names in the worker daemon follow symlinks: process_worker_manager.c opens /tmp/xcecd_worker.log O_WRONLY|O_CREAT|O_APPEND (xcecd_worker's stdout/stderr appended through a planted symlink into any file), and xcecd_prepare_restart() (xcecd.c) opens /tmp/.xcecd.restarting O_CREAT|O_WRONLY (creates an empty root-owned file at a dangling symlink's target)",
"file": "src/worker/src/process_worker_manager.c, src/worker/src/xcecd.c",
"root_cause": "Same class as bug-1868: fixed, predictable names in world-writable /tmp opened by root without O_NOFOLLOW/O_EXCL; only the host's fs.protected_symlinks sysctl mitigates. Found while fixing bug-1868; left out of that fix's scope.",
"fix": "",
"tags": [
"security",
"worker",
"symlink",
"tmp"
],
"related_bugs": [
"bug-1868"
],
"occurrences": 1,
"last_seen": "2026-09-26T07:55:23Z"
}
]
}