From: Russell Coker <russell@coker.com.au>
To: SE Linux <selinux@tycho.nsa.gov>
Subject: init.te
Date: Sun, 11 Jul 2004 17:45:51 +1000 [thread overview]
Message-ID: <200407111745.51356.russell@coker.com.au> (raw)
[-- Attachment #1: Type: text/plain, Size: 770 bytes --]
There should never be a sock_file or fifo_file object labelled as sbin_t or
bin_t, so there is no benefit in granting init_t such access.
I can't think of any reason for granting init_t access to exec_type (except
possibly a gross error in some other part of policy), and booting a rawhide
machine without such access does not give any audit messages.
I have drastically reduced the access of init_t to sbin_t, bin_t, and removed
access to exec_type, the patch is attached.
Steve, please put this in the CVS.
--
http://www.coker.com.au/selinux/ My NSA Security Enhanced Linux packages
http://www.coker.com.au/bonnie++/ Bonnie++ hard drive benchmark
http://www.coker.com.au/postal/ Postal SMTP/POP benchmark
http://www.coker.com.au/~russell/ My home page
[-- Attachment #2: init.diff --]
[-- Type: text/x-diff, Size: 1029 bytes --]
diff -ru /usr/src/se/policy/domains/program/init.te ./domains/program/init.te
--- /usr/src/se/policy/domains/program/init.te 2004-06-17 15:10:38.000000000 +1000
+++ ./domains/program/init.te 2004-07-11 17:37:09.000000000 +1000
@@ -70,11 +70,8 @@
allow init_t self:fifo_file rw_file_perms;
# Permissions required for system startup
-allow init_t bin_t:dir { read getattr lock search ioctl };
-allow init_t bin_t:{ file lnk_file sock_file fifo_file } { read getattr lock ioctl };
-allow init_t exec_type:{ file lnk_file } { read getattr lock ioctl };
-allow init_t sbin_t:dir { read getattr lock search ioctl };
-allow init_t sbin_t:{ file lnk_file sock_file fifo_file } { read getattr lock ioctl };
+allow init_t { bin_t sbin_t }:dir r_dir_perms;
+allow init_t { bin_t sbin_t }:{ file lnk_file } { read getattr lock ioctl };
# allow init to fork
allow init_t self:process { fork sigchld };
@@ -136,4 +133,4 @@
')
r_dir_file(init_t, sysfs_t)
-r_dir_file( init_t, selinux_config_t)
+r_dir_file(init_t, selinux_config_t)
next reply other threads:[~2004-07-11 7:45 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-11 7:45 Russell Coker [this message]
2004-07-12 13:28 ` init.te Stephen Smalley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200407111745.51356.russell@coker.com.au \
--to=russell@coker.com.au \
--cc=selinux@tycho.nsa.gov \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.