shared library and selinux
Stephen Smalley
sds at epoch.ncsc.mil
Wed Apr 28 17:43:49 UTC 2004
On Wed, 2004-04-28 at 13:29, J. Scott Amort wrote:
> Thanks! I suspect, however, that this will cause problems for anyone
> not running an selinux enabled system. Is there a conditional test for
> selinux that could also be added to the makefile? Thanks for any info.
selinuxenabled is a utility for that purpose, but you can't assume that
it is installed on non-Fedora systems; usage would be if selinuxenabled;
then restorecon ...; fi.
Alternatively, you could do something similar to what is done in
/etc/rc.d/rc.sysinit to test for SELinux; checking for selinuxfs in
/proc/mounts is typically sufficient (unless you also want to treat
permissive/no-policy mode as the same as no-SELinux).
--
Stephen Smalley <sds at epoch.ncsc.mil>
National Security Agency
More information about the test
mailing list