作者qoooooooo123 (天边的一沱屎)
看板Linux
标题[问题] selinux 怪怪
时间Sat Aug 26 11:43:40 2017
正在练习selinux
两台虚拟机
一台安装了 httpd了
想说先 vim /etc/httpd.conf.d/userdir.conf
把 <ifmdule mod_userdir.c>
#UserDir disabled <--这个加注解
然後 userdir public_html 删除注解
接下来 systemctl stop httpd
systemctl start httpd
切回 student 使用者
mkdir public_html
vim /home/student/public_html/index.html(准备测试用的网页)
http://server19.example.com/~student/index.html
chmod 701 /home/student
exit(登出 student,回到 root)
sealert -a /var/log/audit/audit.log
setsebool -P httpd_enable_homedirs 1
在 另外一台 虚拟机yum install links
links -dump
http://server19.example.com/~student/index.html
但是出现 host not found
求解QQ
--
※ 发信站: 批踢踢实业坊(ptt.cc), 来自: 61.216.90.99
※ 文章网址: https://webptt.com/cn.aspx?n=bbs/Linux/M.1503719024.A.64A.html
1F:推 purplvampire: 检查首页目录的context设定 08/26 18:10
2F:→ qoooooooo123: 现在是出现404 not found 08/27 16:58
3F:→ ddtsatan: 问userdir.conf设定,public_html和index.html权限及标 08/30 04:38
4F:→ ddtsatan: 签? 08/30 04:38