diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index c491cd4fc..35b6e9c21 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -727,8 +727,7 @@ jobs: # Create home dir via tmpfiles.d so it exists at runtime regardless # of whether bootc initialises the stateroot var from the image's /var. sudo mkdir -p "${DEP}/etc/tmpfiles.d/" - printf 'Z /var/home/bluefin-test 0700 %d %d -\nd /var/home/bluefin-test 0700 %d %d -\nd /var/home/bluefin-test/.ssh 0700 %d %d -\n' \ - "${BFT_UID}" "${BFT_UID}" \ + printf 'd /var/home/bluefin-test 0700 %d %d -\nd /var/home/bluefin-test/.ssh 0700 %d %d -\n' \ "${BFT_UID}" "${BFT_UID}" \ "${BFT_UID}" "${BFT_UID}" | \ sudo tee "${DEP}/etc/tmpfiles.d/ci-user.conf" diff --git a/docs/skills/ci-ops/e2e-workflow/references/selinux-enforcing.md b/docs/skills/ci-ops/e2e-workflow/references/selinux-enforcing.md index 33d8af4ea..84605c69b 100644 --- a/docs/skills/ci-ops/e2e-workflow/references/selinux-enforcing.md +++ b/docs/skills/ci-ops/e2e-workflow/references/selinux-enforcing.md @@ -65,6 +65,15 @@ read only by `ostree`/`bootc`, which run unconfined. Never fix a denial by relabeling the whole tree, `-F` over candidate files, `chcon` to a broad type, `setenforce 0`, or a permissive domain. +The injected `ci-user.conf` uses non-recursive `d` entries for the home and +`.ssh` directories. `d` creates them and adjusts their own mode, ownership +and SELinux label on later boots. Do not add a recursive `Z` home rule: after +the runner container is loaded, it would rewrite Podman storage below the +home on every lifecycle reboot. Run 43526643244 showed it traversing image +hardlinks and generating `systemd_tmpfiles_t` denials while reading +`/proc/sys/fs/protected_hardlinks`. Keep the AVC gate unchanged; fix the +harness traversal, not the candidate policy or the allowlist. + ## AVC collection and canary `selinux_collect_avc.sh` runs in the guest as root and prints AVC/USER_AVC