Commit Graph

583 Commits

Author SHA1 Message Date
Chris PeBenito cce300b960 Module version bump for LMNR port from Laurent Bigonville. 2016-05-26 07:47:18 -04:00
Laurent Bigonville 8f6cd59aea Add llmnr/5355 (Link-local Multicast Name Resolution) 2016-05-26 07:46:03 -04:00
Chris PeBenito 599e5cf7f5 Module version bump for patches from Dominick Grift and Lukas Vrabec. 2016-03-31 08:32:18 -04:00
Lukas Vrabec 78d42e648b SELinux support for cgroup2 filesystem.
With the new "cgroup2" system added in kernel 4.5, systemd is getting
selinux denials when manipulating the cgroup hierarchy.

Pull request in systemd with cgroup2 support:
https://github.com/systemd/systemd/pull/2903

AVC when writing process numbers to move them to the right cgroup:
Mar 29 19:58:30 rawhide kernel: audit: type=1400
audit(1459295910.257:68): avc:  denied  { write } for  pid=1
comm="systemd" name="cgroup.procs" dev="cgroup2" ino=6
scontext=system_u:system_r:init_t:s0
tcontext=system_u:object_r:unlabeled_t:s0 tclass=file permissive=1

In this case new filesystem "cgroup2" need to be labeled as cgroup_t.

Signed-off-by: Lukas Vrabec <lvrabec@redhat.com>
2016-03-31 08:22:56 -04:00
Chris PeBenito f72f1a48d9 Module version bump for Debian fc entries from Laurent Bigonville. 2016-03-28 09:59:02 -04:00
Laurent Bigonville af61f22e24 Add some labels for SELinux tools path in Debian 2016-03-25 22:35:17 +01:00
Chris PeBenito 464c5df247 Reduce broad entrypoints for unconfined domains.
Entrypoints into unconfined domains, like with confined domains, should be
tightly controlled to make arbitrary code execution more difficult.
2016-03-22 15:43:30 -04:00
Chris PeBenito 5db5b62c42 Module version bump for several Arch fixes from Nicolas Iooss. 2016-03-22 15:34:53 -04:00
Chris PeBenito 84a8181a8d Merge branch 'kdevtmpfs-unlink' of https://github.com/fishilico/selinux-refpolicy-patched 2016-03-22 15:27:21 -04:00
Chris PeBenito df8488bf69 Merge branch 'dev_setattr_dlm_control-typo' of https://github.com/fishilico/selinux-refpolicy-patched 2016-03-22 15:26:42 -04:00
Nicolas Iooss 4bf3dfaeb2 Allow kdevtmpfs to unlink fixed disk devices
When a device gets removed, for example with "cryptsetup close",
kdevtmpfs (a kernel thread) removes its entry from devtmpfs filesystem:

    avc:  denied  { unlink } for  pid=48 comm="kdevtmpfs"
    name="dm-4" dev="devtmpfs" ino=144111
    scontext=system_u:system_r:kernel_t
    tcontext=system_u:object_r:fixed_disk_device_t tclass=blk_file

Allow this access on systems using systemd.
2016-03-19 11:12:28 +01:00
Nicolas Iooss 242fa9347a Fix typo in dev_setattr_dlm_control interface requirements 2016-03-19 10:54:40 +01:00
Nicolas Iooss e43b1e2ffc Do not label /usr/lib/gvfs/libgvfscommon.so as bin_t
On Arch Linux, /usr/lib/gvfs directory contains both executable files
(gvfsd, gvfs-udisks2-volume-monitor...) and libraries (libgvfscommon.so
and libgvfsdaemon.so).  As all executable files are prefixed with
"gfvs", so use this to distinguish them with the libraries.

This fixes the following AVC denials, reported from geoclue service
using a library wrongly labelled bin_t:

    avc:  denied  { read } for  pid=14872 comm="geoclue"
    name="libgvfscommon.so" dev="dm-0" ino=3152594
    scontext=system_u:system_r:geoclue_t
    tcontext=system_u:object_r:bin_t tclass=file permissive=1

    avc:  denied  { open } for  pid=14872 comm="geoclue"
    path="/usr/lib/gvfs/libgvfscommon.so" dev="dm-0" ino=3152594
    scontext=system_u:system_r:geoclue_t
    tcontext=system_u:object_r:bin_t tclass=file permissive=1

     avc:  denied  { execute } for  pid=14872 comm="geoclue"
     path="/usr/lib/gvfs/libgvfscommon.so" dev="dm-0" ino=3152594
     scontext=system_u:system_r:geoclue_t
     tcontext=system_u:object_r:bin_t tclass=file permissive=1
2016-03-19 10:39:17 +01:00
Nicolas Iooss 4b1cd5b369 Label some user session DBus services as bin_t 2016-03-19 10:39:17 +01:00
Nicolas Iooss 2cedfc0ada Label gedit plugins properly on Arch Linux 2016-03-19 10:39:17 +01:00
Nicolas Iooss 55f64a8112 Label system-config-printer applet properly on Arch Linux
It is used by system-config-printer, as shown by these AVC denials:

    avc:  denied  { execute } for  pid=1061 comm="system-config-p"
    name="applet.py" dev="dm-0" ino=9568316
    scontext=sysadm_u:sysadm_r:sysadm_t tcontext=system_u:object_r:usr_t
    tclass=file permissive=1

    avc:  denied  { execute_no_trans } for  pid=1061
    comm="system-config-p"
    path="/usr/share/system-config-printer/applet.py" dev="dm-0"
    ino=9568316 scontext=sysadm_u:sysadm_r:sysadm_t
    tcontext=system_u:object_r:usr_t tclass=file permissive=1
2016-03-19 10:39:17 +01:00
Nicolas Iooss 90599ef760 Label TexLive scripts bin_t
These scripts can be run by users.
2016-03-19 10:39:17 +01:00
Chris PeBenito 1240e0ab7b Module version bump for efivarfs patches from Dan Walsh, Vit Mojzis, and Laurent Bigonville 2016-02-03 08:49:39 -05:00
Vit Mojzis 17bd45dab9 Add interface to allow reading files in efivarfs - contains Linux Kernel configuration options for UEFI systems (UEFI Runtime Variables) 2016-02-03 13:33:43 +01:00
Dan Walsh 498df2c5b9 Add label for efivarfs 2016-02-03 13:24:43 +01:00
Chris PeBenito 4a0e5fffc7 Module version bump for patches from Nicolas Iooss and Grant Ridder. 2016-02-02 09:35:30 -05:00
Nicolas Iooss 82cdf3b724 Label /sys/kernel/debug/tracing filesystem
tracefs filesystem is automounted in /sys/kernel/debug/tracing directory
since Linux 4.1.  Label this filesystem properly.

Linux commit:
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=f76180bc07abc399977bfbe8c43bf58c4570e893
2016-02-02 09:33:34 -05:00
Grant Ridder 976af3482a Add redis-sentinel port to redis network_port def 2016-02-02 09:33:34 -05:00
Nicolas Iooss c82a479ed8 Fix interface descriptions when duplicate ones are found
Distinct interfaces should have different comments
2016-01-19 00:17:34 +01:00
Nicolas Iooss 29d543da4c Fix typos in comments from corenetwork module 2016-01-19 00:17:05 +01:00
Chris PeBenito 24e6175132 Module version bump for systemd PrivateNetwork patch from Nicolas Iooss 2016-01-11 13:26:55 -05:00
Nicolas Iooss 25bc2d5c1d Allow systemd services to use PrivateNetwork feature
systemd creates a new network namespace for services which are using
PrivateNetwork=yes.

In the implementation, systemd uses a socketpair as a storage buffer for
the namespace reference file descriptor (c.f.
https://github.com/systemd/systemd/blob/v228/src/core/namespace.c#L660).
One end of this socketpair is locked (hence the need of "lock" access to
self:unix_dgram_socket for init_t) while systemd opens
/proc/self/ns/net, which lives in nsfs.

While at it, add filesystem_type attribute to nsfs_t.
2016-01-11 13:17:16 -05:00
Chris PeBenito 619b4adf78 Add a type and genfscon for nsfs. 2016-01-11 09:02:39 -05:00
Chris PeBenito cc248fc976 Module version bump for syslog and systemd changes from Laurent Bigonville 2016-01-06 09:22:11 -05:00
Chris PeBenito 5922346539 Merge branch 'systemd-1' of git://github.com/bigon/refpolicy into bigon-systemd-1 2016-01-06 09:13:47 -05:00
Chris PeBenito 2c465410d9 Add neverallow for mac_override capability. It is not used by SELinux. 2016-01-06 09:09:36 -05:00
Chris PeBenito 994f605a2c Module version bump for Xorg and SSH patches from Nicolas Iooss. 2016-01-05 13:38:19 -05:00
Nicolas Iooss 3505a51d76 Label OpenSSH files correctly on Arch Linux
On Arch Linux, OpenSSH installs these binary files in /usr/lib/ssh:

* sftp-server (labeled with ssh_keysign_exec_t type in refpolicy)
* ssh-askpass (symlink to x11-ssh-askpass)
* ssh-keysign
* ssh-pkcs11-helper
* x11-ssh-askpass (from x11-ssh-askpass package)

Label all these files but sftp-server as bin_t.
2016-01-05 13:22:52 -05:00
Laurent Bigonville c0e95ed326 On Debian, systemd binaries are installed in / not /usr
On Debian, systemd binaries are installed in / not /usr, add an
equivalence for this.
2015-12-14 22:52:47 +01:00
Chris PeBenito 2b972fefd1 Module version bump for vm overcommit sysctl interfaces from Laurent Bigonville. 2015-12-14 10:04:14 -05:00
Laurent Bigonville 4340b9f8a4 Add interfaces to read/write /proc/sys/vm/overcommit_memory 2015-12-14 10:02:53 -05:00
Chris PeBenito 6b1b2e3965 Module version bumps for 2 patches from Dominick Grift. 2015-12-10 15:46:13 -05:00
Dominick Grift 6d6370c98a kernel: implement sysctl_vm_overcommit_t for /proc/sys/vm/overcommit_memory
Whoever requires this type first gets to create the interfaces to operate on this object

Signed-off-by: Dominick Grift <dac.override@gmail.com>
2015-12-10 14:10:16 -05:00
Chris PeBenito c23353bcd8 Bump module versions for release. 2015-12-08 09:53:02 -05:00
Chris PeBenito b94f45d760 Revise selinux module interfaces for perms protected by neverallows.
Use the allow rules on the relevant attributes in selinux.te, rather than
only using the attribute to pass the neverallows.

Closes #14
2015-11-04 15:10:29 -05:00
Chris PeBenito 17694adc7b Module version bump for systemd additions. 2015-10-23 14:53:14 -04:00
Chris PeBenito bdfc7e3eb0 Add sysfs_types attribute.
Collect all types used to label sysfs entries.
2015-10-23 10:17:46 -04:00
Chris PeBenito f7286189b3 Add systemd units for core refpolicy services.
Only for services that already have a named init script.

Add rules to init_startstop_service(), with conditional arg until
all of refpolicy-contrib callers are updated.
2015-10-23 10:17:46 -04:00
Chris PeBenito 579849912d Add supporting rules for domains tightly-coupled with systemd. 2015-10-23 10:17:46 -04:00
Chris PeBenito 3639880cf6 Implement core systemd policy.
Significant contributions from the Tresys CLIP team.

Other changes from Laurent Bigonville.
2015-10-23 10:16:59 -04:00
Chris PeBenito 4d28cb714f Module version bump for patches from Jason Zaman/Matthias Dahl. 2015-10-12 09:31:18 -04:00
Jason Zaman b3a95b4aeb Add overlayfs as an XATTR capable fs
The module is called "overlay" in the kernel
2015-10-12 09:13:53 -04:00
Chris PeBenito cfaeb62603 Module version bump for vfio device from Alexander Wetzel. 2015-09-15 08:39:21 -04:00
Alexander Wetzel 9ae4033beb adds vfio device support to base policy
Signed-off-by: Alexander Wetzel <alexander.wetzel@web.de>
2015-09-15 08:17:31 -04:00
Chris PeBenito 1d51a2f4c4 Module version bump for APR build script labeling from Luis Ressel. 2015-08-11 08:46:41 -04:00