fcontext command:
when you use selinux policy, you work with tool fcontext
how to check:
(for example: you have to change the apache directory:)
from /var/web/html to /var/web
(config apache file to /var/web)
echo "i_am_groot" >> /var/web/index.html
curl localhost/index.html -- 403 output
-- check the selinux:
- how to check fcontext
fcontext --list | grep httpd_sys_content
-- how to add fcontext
fconntex -a -t httpd_sys_context_t '/var/web(/.*)?'
after that
try curl localhost/index.html
and check again fcontext --list (you will see new file)
Žiadne komentáre:
Zverejnenie komentára