The Dawning of Selinux Understanding
I've always had trouble with selinux. Don't get me wrong, security is very important and I try my best to get it right. However, I sometimes have trouble getting things just to work, and security can make it even more difficult. Is it not working because I haven't set it up correctly, or is the problem that I don't have the right access. It's true that security IS part of setting something up correctly, a VERY important part. However, I often have to remove any security restrictions to divide issues between functionality and access. This is a great technique to get things working, but leads to all kinds of security related problems by leaving security as an afterthough that is often forgotten or poorly layered on. Anyway, until this recent Linux installation, I have either turned of selinux or set it to warn only. On this install I've finally dug in to understand it a little better.
In particular, http://danwalsh.livejournal.com/14195.html gives a great explanation of how to set up a directory that is used by both HTTPD and Samba.
Another critical point is to use cp instead of mv when you want files to inherit the selinux context of the parent folder. http://elibrary.fultus.com/technical/index.jsp?topic=/com.fultus.redhat.... is a good reference for the selinux implications of mv and cp.

- Stephen Kelley's blog
- Login or register to post comments
- 540 reads
