shared-httpd mod_whp_symlink PR check / Symlink-Module-Probe (pull_request) Successful in 1m15s
- Remove the WHPSymlinkWalk post-walk lstat prototype (check-then-use race by construction; WHPOwnerGuard is the race-free mechanism): hook, directive, per-dir member, header docs. The directive is now an unknown command. - Probe test: WHP_SYMTEST_REQUIRE=1 turns every SKIP into a FAIL (no docker, no image, container does not start) and a minimum assertion count is enforced. New assertions: bare `Options All` keeps Apache semantics (Indexes on, MultiViews off, same-owner symlink followed, cross-tenant refused) plus None/+MultiViews controls (106 assertions). - CI: new pull_request workflow shared-httpd-symlink-pr.yaml (builds amd64 locally, no push/secrets, runs the probe test); build-push.yaml Build-Shared-httpd runs the probe test against the amd64 digest it just pushed, before the arm64 build and tag assembly, so a failure publishes no tag. Test script added to the shellcheck set; wiring tests added. - docs/shared-httpd-symlink-module.md: behaviour, local run, CI. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0185ukXi4YX5FxJGqhi6qab6
23 lines
1.2 KiB
Plaintext
23 lines
1.2 KiB
Plaintext
# mod_whp_symlink (src/mod_whp_symlink/) - shared-httpd tenant symlink safety.
|
|
# Loaded from conf.modules.d/99-whp-symlink.conf. WHP's server-scope drop-in
|
|
# (conf.d/vhosts/000-whp-security.conf) may override any of these.
|
|
<IfModule whp_symlink_module>
|
|
# Tenant .htaccess `Options FollowSymLinks|All|Includes|ExecCGI` is
|
|
# rewritten before the core parses it (FollowSymLinks -> SymLinksIfOwnerMatch,
|
|
# Includes -> IncludesNOEXEC, ExecCGI dropped), so stock CMS files
|
|
# (CodeIgniter 4, Joomla, OpenCart, Magento) stop answering 500 and no
|
|
# tenant can switch owner-unchecked symlinks back on. Bare `Options All`
|
|
# keeps Apache's meaning minus the unsafe parts: it becomes
|
|
# `Indexes SymLinksIfOwnerMatch` (All includes Indexes and excludes
|
|
# MultiViews, so Indexes stays on and MultiViews stays off).
|
|
WHPHtaccessOptionsRemap On
|
|
|
|
# Owner check on the file descriptor actually served (the Bluehost/cPanel
|
|
# SymlinkProtect idea, as a filter): closes the check-then-open symlink
|
|
# race of SymLinksIfOwnerMatch and the swapped-docroot case. Ships in Log
|
|
# mode: flip to On (in WHP's drop-in) once the fleet log shows no
|
|
# legitimate mismatches.
|
|
WHPOwnerGuardRoot /mnt/users/
|
|
WHPOwnerGuard Log
|
|
</IfModule>
|