CompTIA Linux+ XK0-006 (V8) Practice Question

A Linux web server has SELinux set to enforcing, and every time Apache (httpd_t) tries to write to a new cache directory you see AVC denials such as:

avc:  denied  { write } for  pid=2154 comm="httpd" ... tclass=dir

After reviewing the log you decide the access is legitimate and should be permitted without relaxing SELinux enforcement. Which of the following command sequences will create a loadable local policy module and immediately install it so the new rule survives a reboot?

  • cat /var/log/audit/audit.log | audit2allow && setenforce 0

  • restorecon -Rv /var/www/cache

  • cat /var/log/audit/audit.log | audit2allow -M httpd_cache && semodule -i httpd_cache.pp

  • semanage permissive -a httpd_t

CompTIA Linux+ XK0-006 (V8)
Security
Your Score:
Settings & Objectives
Random Mixed
Questions are selected randomly from all chosen topics, with a preference for those you haven’t seen before. You may see several questions from the same objective or domain in a row.
Rotate by Objective
Questions cycle through each objective or domain in turn, helping you avoid long streaks of questions from the same area. You may see some repeat questions, but the distribution will be more balanced across topics.

Check or uncheck an objective to set which questions you will receive.

Bash, the Crucial Exams Chat Bot
AI Bot