Commit Graph

407 Commits

Author SHA1 Message Date
Chris PeBenito 950fc2cd7e Module version bump for netutils patch from Luis Ressel. 2016-12-11 14:59:14 -05:00
Luis Ressel d73a8bb52c netutils: Label iptstate as netutils_t
>From the package description: "IP Tables State displays states being kept
by iptables in a top-like format". The netutils_t permission set fits it
snugly.
2016-12-11 14:58:35 -05:00
cgzones d8cb498284 remove trailing whitespaces 2016-12-06 13:45:13 +01:00
Chris PeBenito 34055cae87 Bump module versions for release. 2016-10-23 16:58:59 -04:00
Chris PeBenito 1cfba86fc0 Update su for libselinux-2.5 changes.
su is linked against libselinux via pam_unix.so.  Use the selinuxutil
interface so future libselinux changes are pulled in.
2016-03-25 10:24:59 -04: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
Chris PeBenito c23353bcd8 Bump module versions for release. 2015-12-08 09:53:02 -05:00
Chris PeBenito a38c3be208 Module version bump for updated netlink sockets from Stephen Smalley 2015-05-22 08:38:53 -04:00
Stephen Smalley 58b3029576 Update netlink socket classes.
Define new netlink socket security classes introduced by kernel commit
223ae516404a7a65f09e79a1c0291521c233336e.

Note that this does not remove the long-since obsolete
netlink_firewall_socket and netlink_ip6_fw_socket classes
from refpolicy in case they are still needed for legacy
distribution policies.

Add the new socket classes to socket_class_set.
Update ubac and mls constraints for the new socket classes.
Add allow rules for a few specific known cases (netutils, iptables,
netlabel, ifconfig, udev) in core policy that require access.
Further refinement for the contrib tree will be needed.  Any allow
rule previously written on :netlink_socket may need to be rewritten or
duplicated for one of the more specific classes.  For now, we retain the
existing :netlink_socket rules for compatibility on older kernels.

Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
2015-05-22 08:29:03 -04:00
Chris PeBenito 468185f5f7 Bump module versions for release. 2014-12-03 13:37:38 -05:00
Chris PeBenito 0735f2ca4a Module version bump for misc fixes from Sven Vermeulen. 2014-12-02 10:29:59 -05:00
Sven Vermeulen 2b642954a6 New sudo manages timestamp directory in /var/run/sudo
Allow sudo (1.8.9_p5 and higher) to handle /var/run/sudo/ts if it does
not exist (given the tmpfs nature of /var/run). This is done when sudo
is run in the user prefixed domain, and requires both the chown
capability as well as the proper file transition when /var/run/sudo is
created.
2014-12-02 09:16:05 -05:00
Sven Vermeulen fbdf5f0ef8 Run grub(2)-mkconfig in bootloader domain
In order to write the grub configuration and perform the preliminary
checks, the grub-mkconfig command should run in the bootloader_t domain.
As such, update the file context definition to be bootloader_exec_t.
2014-12-02 09:16:05 -05:00
Chris PeBenito 6a24d9dba0 Module version bump for Debian arping fc entries from Laurent Bigonville. 2014-10-06 09:50:58 -04:00
Laurent Bigonville 740a1746bf Debian also ship a different arping implementation
In addition to the iputils arping implementation, Debian also ships an
other implementation which is installed under /usr/sbin/arping
2014-10-03 14:35:58 +02:00
Laurent Bigonville a9594fc684 On Debian iputils-arping is installed in /usr/bin/arping 2014-10-03 14:29:05 +02:00
Chris PeBenito 6624f9cf7a Drop RHEL4 and RHEL5 support. 2014-09-24 13:10:37 -04:00
Chris PeBenito 28b7555131 Module version bump for ping rawip socket fix from Luis Ressel. 2014-08-18 10:30:28 -04:00
Luis Ressel 792b75b70e Grant ping_t getattr on rawip_socket
If the (sadly nearly undocumented) Linux kernel feature which allows
specific user groups to send ICMP echos without CAP_NET_RAW
(configurable with the sysctl net.ipv4.ping_group_range, available since
3.0) is used, ping needs the getattr permission of the rawip_socket
class in order to work.
2014-08-18 09:48:08 -04:00
Sven Vermeulen 6e0000b725 Hide getattr denials upon sudo invocation
When sudo is invoked (sudo -i) the audit log gets quite a lot of denials
related to the getattr permission against tty_device_t:chr_file for the
*_sudo_t domain. However, no additional logging (that would hint at a
need) by sudo, nor any functional issues come up.

Hence the dontaudit call.

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2014-04-04 16:07:43 -04:00
Chris PeBenito 10ff4d0fa3 Bump module versions for release. 2014-03-11 08:16:57 -04:00
Chris PeBenito 4dbe95d58b Module version bump for bootloader fc fixes from Luis Ressel. 2014-03-03 09:07:00 -05:00
Luis Ressel f8eb4e3b3b Label grub2-install as bootloader_exec_t 2014-03-03 08:45:10 -05:00
Luis Ressel c2a9b89c5f Generalize grub2 pattern
GRUB2 helper programs can be named either grub2-* or grub-*, depending
on distro and configuration.
2014-03-03 08:44:41 -05:00
Chris PeBenito 58db129761 Update modules for file_t merge into unlabeled_t. 2014-01-16 11:24:25 -05:00
Chris PeBenito b339b85001 Module version bump for patches from Dominick Grift. 2013-12-06 09:49:41 -05:00
Chris PeBenito 872ece4bcf Whitespace fix in usermanage. 2013-12-06 08:16:10 -05:00
Dominick Grift 6042255ede usermanage: Run /etc/cron\.daily/cracklib-runtime in the crack_t domain in Debian
Signed-off-by: Dominick Grift <dominick.grift@gmail.com>
2013-12-06 08:14:29 -05:00
Chris PeBenito fa50eb742f Module version bump for ping capabilities from Sven Vermeulen. 2013-09-26 10:47:32 -04:00
Sven Vermeulen 56c43144d7 Allow ping to get/set capabilities
When ping is installed with capabilities instead of being marked setuid,
then the ping_t domain needs to be allowed to getcap/setcap.

Reported-by: Luis Ressel <aranea@aixah.de>
Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2013-09-26 10:46:33 -04:00
Sven Vermeulen 6fb9a34679 Get grub2-install to work properly
The grub2-install application runs a few grub2-* commands. Two of those,
grub2-bios-setup and grub2-probe, need read/write access to the (fixed) disks.

Mark those two applications as bootloader_exec_t (as is the case with the "grub"
legacy command in the past) allows the commands to continue.

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2013-08-26 08:32:53 -04:00
Chris PeBenito d174521a64 Bump module versions for release. 2013-04-24 16:14:52 -04:00
Chris PeBenito 7c1cbfd97d Module version bump for chfn fixes from Sven Vermeulen. 2013-04-04 15:22:08 -04:00
Sven Vermeulen 62e395b90b chfn_t reads in file context information and executes nscd
The chsh application (which runs in the chfn_t domain) requires read access on
the file context definitions. If not, the following error occurs:

Changing the login shell for root
Enter the new value, or press ENTER for the default
	Login Shell [/bin/zsh]: /bin/bash
chsh: failure while writing changes to /etc/passwd

The following AVC denials are shown:

Jan 23 20:23:43 lain kernel: [20378.806719] type=1400 audit(1358969023.507:585):
avc:  denied  { search } for  pid=18281 comm="chsh" name="selinux" dev="dm-0"
ino=23724520 scontext=staff_u:sysadm_r:chfn_t
tcontext=system_u:object_r:selinux_config_t tclass=dir

In permissive mode, this goes up to:

Jan 23 20:22:15 lain kernel: [20290.691128] type=1400 audit(1358968935.217:566):
avc:  denied  { open } for  pid=18195 comm="chsh"
path="/etc/selinux/strict/contexts/files/file_contexts" dev="dm-0" ino=23726403
scontext=staff_u:sysadm_r:chfn_t tcontext=staff_u:object_r:file_context_t
tclass=file

Hence, adding in seutil_read_file_contexts().

A second error is that chsh, if available, wants to execute nscd:

Changing the login shell for root
Enter the new value, or press ENTER for the default
        Login Shell [/bin/sh]: /bin/bash
chsh: cannot execute /usr/sbin/nscd: Permission denied
chsh: nscd exited with status 126
chsh: Failed to flush the nscd cache.
chsh: cannot execute /usr/sbin/nscd: Permission denied
chsh: nscd exited with status 126
chsh: Failed to flush the nscd cache.
chsh: cannot execute /usr/sbin/nscd: Permission denied
chsh: nscd exited with status 126
chsh: Failed to flush the nscd cache.

Similar to most other user admin utilities, we grant it the rights to run nscd.

Changes since v1
- Removed seutil_dontaudit_search_config() call

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2013-04-04 14:25:55 -04:00
Chris PeBenito be2e70be8d Module version bump for fixes from Dominick Grift. 2013-01-03 10:53:34 -05:00
Dominick Grift 79e1e4efb9 NSCD related changes in various policy modules
Use nscd_use instead of nscd_socket_use. This conditionally allows
nscd_shm_use

Remove the nscd_socket_use from ssh_keygen since it was redundant
already allowed by auth_use_nsswitch

Had to make some ssh_keysign_t rules unconditional else
nscd_use(ssh_keysign_t) would not build (nested booleans) but that does
not matter, the only actual domain transition to ssh_keysign_t is
conditional so the other unconditional ssh_keygen_t rules are
conditional in practice

Signed-off-by: Dominick Grift <dominick.grift@gmail.com>
2013-01-03 10:43:10 -05:00
Chris PeBenito e1ab3f885b Module version bump for misc updates from Sven Vermeulen. 2013-01-03 10:32:41 -05:00
Sven Vermeulen 517f37fd26 Introduce exec-check interfaces for passwd binaries and useradd binaries
Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2013-01-03 10:32:41 -05:00
Chris PeBenito b30c5df388 Module version bump for logging and tcpdump fixes from Sven Vermeulen. 2012-11-27 09:57:13 -05:00
Sven Vermeulen 9241902062 tcpdump chroots into /var/lib/tcpdump
When invoking tcpdump, the application creates a netlink_socket and then chroots
into /var/lib/tcpdump.

Without the right to create a netlink_socket:
tcpdump: Can't open netlink socket 13:Permission denied

Without the right on dac_read_search and sys_chroot:
tcpdump: Couldn't chroot/chdir to '/var/lib/tcpdump': Permission denied

See also https://bugs.gentoo.org/show_bug.cgi?id=443624

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2012-11-27 09:12:17 -05:00
Chris PeBenito 35bb8cbf62 Module version bump for arping setcap from Dominick Grift. 2012-10-30 14:28:53 -04:00
Dominick Grift 7ef9402705 Arping needs setcap to cap_set_proc
rhbz#869615

Signed-off-by: Dominick Grift <dominick.grift@gmail.com>
2012-10-30 14:19:37 -04:00
Chris PeBenito afdb509245 Module version bump for changes from Dominick Grift and Sven Vermeulen. 2012-10-09 11:01:42 -04:00
Dominick Grift a63f5143ce Changes to the bootloader policy module
Add bootloader_exec() for kdumpgui

Signed-off-by: Dominick Grift <dominick.grift@gmail.com>
2012-10-09 10:26:15 -04:00
Chris PeBenito 3516535aa6 Bump module versions for release. 2012-07-25 14:33:06 -04:00
Chris PeBenito 00dc68d969 Module version bump for shadow utils updates from Sven Vermeulen. 2012-05-11 11:46:26 -04:00
Sven Vermeulen 2f28a01206 Allow groupadd/passwd to read selinux config and context files
Recent shadow utils require listing of SELinux config as well as read the file context information.

See also
- https://bugs.gentoo.org/show_bug.cgi?id=413061
- https://bugs.gentoo.org/show_bug.cgi?id=413065

Changes since v1
- use correct domain (passwd_t)

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2012-05-11 08:50:38 -04:00
Chris PeBenito 8e00a439ef Module verion bump for simplify file contexts based on file context path substitutions, from Sven Vermeulen. 2012-05-10 10:36:06 -04:00
Chris PeBenito aac94b0e40 Whitespace fixes from fc.subs changes. 2012-05-10 10:33:54 -04:00
Sven Vermeulen b55726771e Simplify .fc in light of file_contexts.subs_dist
Now that we have file_contexts.subs_dist, translations that were put in the file context definition files can now be
cleaned up.

Differences from v1:
- removes a few duplicate entries in the libraries.fc file, and
- removes the contrib references

Signed-off-by: Sven Vermeulen <sven.vermeulen@siphos.be>
2012-05-10 10:09:00 -04:00