types.fc
PATCH 1/1 types.fc
Here's an update of types.fc with a some Gentoo-specific entries, against CVS. Also enclose a few entries with other distro tunables.
Signature · 8 lines
Chris PeBenito <[email protected]> Developer, Hardened Gentoo Linux Embedded Gentoo Linux Public Key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0xE6AF9243 Key fingerprint = B0E6 877A 883F A57A 8E6A CB00 BC8E E42D E6AF 9243
Index: file_contexts/types.fc
===================================================================
RCS file: /cvsroot/selinux/nsa/selinux-usr/policy/file_contexts/types.fc,v retrieving revision 1.40
types.fc +23 -0
@@ -275,6 +275,11 @@ /etc/sysconfig/firstboot -- system_u:object_r:etc_runtime_t /etc/asound\.state -- system_u:object_r:etc_runtime_t /etc/ptal/ptal-printd-like -- system_u:object_r:etc_runtime_t +ifdef(`distro_gentoo', ` +/etc/profile\.env -- system_u:object_r:etc_runtime_t +/etc/csh\.env -- system_u:object_r:etc_runtime_t +/etc/env\.d/.* -- system_u:object_r:etc_runtime_t +') /etc/ld\.so\.cache -- system_u:object_r:ld_so_cache_t /etc/ld\.so\.preload -- system_u:object_r:ld_so_cache_t /etc/yp\.conf.* -- system_u:object_r:net_conf_t
@@ -303,6 +308,9 @@ /lib(64)?/security/[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t /lib(64)?/tls/i686/cmov/[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t /lib(64)?/tls/i.86/[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t +ifdef(`distro_gentoo', ` +/lib(64)?/rcscripts/.*\.so.* -- system_u:object_r:shlib_t +') # # /sbin
@@ -327,7 +335,9 @@ /usr/share/man(/.*)? system_u:object_r:man_t /usr/share/mc/extfs/.* -- system_u:object_r:bin_t /usr/share/texmf/teTeX/bin(/.*)? system_u:object_r:bin_t +ifdef(`distro_debian', ` /usr/share/selinux(/.*)? system_u:object_r:policy_src_t +') # # /usr/bin
@@ -352,11 +362,14 @@ /usr/.*glibc.*-linux/lib(64)?/ld[^/]*\.so(\.[^/]*)* -- system_u:object_r:ld_so_t /usr/.*glibc.*-linux/lib(64)?/lib[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t +# # /usr/.*redhat-linux/lib(64)? # +ifdef(`distro_redhat', ` /usr/.*redhat-linux/lib(64)?(/.*)? system_u:object_r:lib_t /usr/.*redhat-linux/lib(64)?/ld[^/]*\.so(\.[^/]*)* -- system_u:object_r:ld_so_t /usr/.*redhat-linux/lib(64)?/lib[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t +') # # /usr/.*linux-libc.*/lib(64)?
@@ -366,6 +379,14 @@ /usr/.*linux-libc.*/lib(64)?/lib[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t # +# /usr/.*-.*-linux-gnu +# +ifdef(`distro_gentoo', ` +/usr/.*-.*-linux-gnu/bin(/.*)? system_u:object_r:bin_t +/usr/.*-.*-linux-gnu/gcc-bin/.*(/.*)? system_u:object_r:bin_t +') + +# # /usr/local # /usr/local/etc(/.*)? system_u:object_r:etc_t
@@ -493,10 +514,12 @@ # # The Sun Java development kit, RPM install # +ifdef(`distro_redhat', ` /usr/java/j2.*/bin(/.*)? system_u:object_r:bin_t /usr/java/j2.*/jre/lib(64)?/i386(/.*)? system_u:object_r:lib_t /usr/java/j2.*/jre/lib(64)?/i386(/.*)?[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t /usr/java/j2.*/plugin/i386(/.*)?/lib[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t +') # # The krb5.conf file is always being tested for writability, so
Merged, except for the ifdef around the java sdk stuff. This is not part of Fedora or RHEL (AFAIK), so I don't think that we want the ifdef.
Quoted 28 lines · Chris PeBenito
Here's an update of types.fc with a some Gentoo-specific entries, against CVS. Also enclose a few entries with other distro tunables.
Index: file_contexts/types.fc
===================================================================
RCS file:
/cvsroot/selinux/nsa/selinux-usr/policy/file_contexts/types.fc,v retrieving revision 1.40
diff -u -r1.40 types.fctypes.fc 24 Sep 2004 01:00:59 -0000 renamed from types.fc 23 Sep 2004 19:08:59 -0000 1.40 +1
-0@@ -493,10 +514,12 @@ # # The Sun Java development kit, RPM install # +ifdef(`distro_redhat', ` /usr/java/j2.*/bin(/.*)? system_u:object_r:bin_t /usr/java/j2.*/jre/lib(64)?/i386(/.*)? system_u:object_r:lib_t /usr/java/j2.*/jre/lib(64)?/i386(/.*)?[^/]*\.so(\.[^/]*)* --system_u:object_r:shlib_t
/usr/java/j2.*/plugin/i386(/.*)?/lib[^/]*\.so(\.[^/]*)* --
system_u:object_r:shlib_t
+')#
# The krb5.conf file is always being tested for writability, so
Signature · 7 lines
James Carter <[email protected]> National Security Agency -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 3 lines · James Carter
Merged, except for the ifdef around the java sdk stuff. This is not part of Fedora or RHEL (AFAIK), so I don't think that we want the ifdef.
Right, that's just the place that Sun's JDK typically installs to, not specific to Fedora or RHEL.
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Also, I don't see anything that matches /usr/.*redhat-linux/lib(64)? on FC2 or FC3 test2 (or RH8 for that matter). What version of Fedora or Red Hat Linux are they for? Are they for something that maybe I don't have installed? Or are they now obsolete and can be removed? Dan or Russell, do you know?
Index: file_contexts/types.fc
Quoted 24 lines
===================================================================
RCS file:
/cvsroot/selinux/nsa/selinux-usr/policy/file_contexts/types.fc,v retrieving revision 1.40
diff -u -r1.40 types.fctypes.fc 24 Sep 2004 01:00:59 -0000 renamed from types.fc 23 Sep 2004 19:08:59 -0000 1.40 +3
-0@@ -352,11 +362,14 @@ /usr/.*glibc.*-linux/lib(64)?/ld[^/]*\.so(\.[^/]*)* -- system_u:object_r:ld_so_t /usr/.*glibc.*-linux/lib(64)?/lib[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t +# # /usr/.*redhat-linux/lib(64)? # +ifdef(`distro_redhat', ` /usr/.*redhat-linux/lib(64)?(/.*)? system_u:object_r:lib_t /usr/.*redhat-linux/lib(64)?/ld[^/]*\.so(\.[^/]*)* -- system_u:object_r:ld_so_t /usr/.*redhat-linux/lib(64)?/lib[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t +') # # /usr/.*linux-libc.*/lib(64)?
Quoted 2 lines · Chris PeBenito
Here's an update of types.fc with a some Gentoo-specific entries, against CVS. Also enclose a few entries with other distro tunables.
Signature · 7 lines
James Carter <[email protected]> National Security Agency -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 6 lines · James Carter
Also, I don't see anything that matches /usr/.*redhat-linux/lib(64)? on
FC2 or FC3 test2 (or RH8 for that matter). What version of Fedora or
Red Hat Linux are they for? Are they for something that maybe I don't
have installed? Or are they now obsolete and can be removed? Dan or Russell, do you know?
I don't know what they are so I would remove them.
Quoted 29 lines
Index: file_contexts/types.fc
Quoted 26 lines
===================================================================
RCS file:
/cvsroot/selinux/nsa/selinux-usr/policy/file_contexts/types.fc,v retrieving revision 1.40
diff -u -r1.40 types.fctypes.fc 24 Sep 2004 01:00:59 -0000 renamed from types.fc 23 Sep 2004 19:08:59 -0000 1.40 +0
-0@@ -352,11 +362,14 @@/usr/.*glibc.*-linux/lib(64)?/ld[^/]*\.so(\.[^/]*)* -- system_u:object_r:ld_so_t /usr/.*glibc.*-linux/lib(64)?/lib[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t+#
# /usr/.*redhat-linux/lib(64)?
#
+ifdef(distro_redhat',
/usr/.*redhat-linux/lib(64)?(/.*)? system_u:object_r:lib_t/usr/.*redhat-linux/lib(64)?/ld[^/]*\.so(\.[^/]*)* -- system_u:object_r:ld_so_t /usr/.*redhat-linux/lib(64)?/lib[^/]*\.so(\.[^/]*)* -- system_u:object_r:shlib_t+')
Quoted 12 lines
Quoted 4 lines
#
# /usr/.*linux-libc.*/lib(64)?Quoted 4 lines · Chris PeBenito
Here's an update of types.fc with a some Gentoo-specific entries, against CVS. Also enclose a few entries with other distro tunables.
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.