back to labs
SELinux Port Label
MediumRHCSA Prep10-15 minThe brief
The storefront vhost in /etc/httpd/conf.d/shop.conf was moved to a non-standard TCP port. On an enforcing box httpd now fails to start, because SELinux only lets httpd bind ports labeled http_port_t. Find the port the vhost listens on and label it http_port_t for TCP in the persistent SELinux policy, without touching any other port label. This lab machine's kernel has SELinux disabled, so nothing is enforced live; grading reads the persistent SELinux policy store, which is what an enforcing box loads at boot.
What you'll do
- Find the port a service is configured to use
- Label a port for a service type with semanage port
- Change only the port that needs it
Hands-on lab: you work on a real Linux box in your browser, graded on the machine's actual state.
