Question
Apache UserDir access under SELinux enforcing on AlmaLinux 9
Ari Indigo
0 reputation · 19 Jan 2025, 14:15 UTC
100.4K views0
<p>Apache HTTPD UserDir on AlmaLinux 9 should serve requests to "~/public_html" while SELinux remains in enforcing mode under the targeted policy.</p>
<p>The "httpd_read_user_content" boolean governs whether httpd can read content labeled "user_home_t", but it applies globally and is not tied to individual "VirtualHost" or "UserDir" directives. It is uncertain whether enabling it permits access to every home directory or only to paths labeled "httpd_user_content_t", and whether access can be bounded to selected virtual hosts without custom policy modules.</p>
<p>Should the boolean be enabled server-wide, or is there a supported way to scope user-directory access to specific VirtualHost directives? Does enabling it grant Apache read access to all "user_home_t" directories, or only to directories labeled "httpd_user_content_t"? What behavior is expected when a UserDir document root lacks the "httpd_user_content_t" label while the boolean is disabled?</p>