Gentoo Archives: gentoo-commits

From: Jason Zaman <perfinion@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/hardened-refpolicy:master commit in: policy/modules/contrib/
Date: Thu, 30 Mar 2017 17:07:01
Message-Id: 1490882410.997b61a104f916f9883d5dfdc2e3510ecc7f3d61.perfinion@gentoo
1 commit: 997b61a104f916f9883d5dfdc2e3510ecc7f3d61
2 Author: Chris PeBenito <pebenito <AT> ieee <DOT> org>
3 AuthorDate: Sat Mar 25 16:31:20 2017 +0000
4 Commit: Jason Zaman <perfinion <AT> gentoo <DOT> org>
5 CommitDate: Thu Mar 30 14:00:10 2017 +0000
6 URL: https://gitweb.gentoo.org/proj/hardened-refpolicy.git/commit/?id=997b61a1
7
8 dontaudit net_admin for SO_SNDBUFFORCE
9
10 The following patch adds dontaudit rules for where the net_admin capability
11 is requested due to SO_SNDBUFFORCE. This forces the caller to use SO_SNDBUF
12 which gives the same result but possibly a smaller buffer.
13
14 From Russell Coker
15
16 policy/modules/contrib/rpcbind.te | 4 +++-
17 policy/modules/contrib/tor.te | 4 +++-
18 2 files changed, 6 insertions(+), 2 deletions(-)
19
20 diff --git a/policy/modules/contrib/rpcbind.te b/policy/modules/contrib/rpcbind.te
21 index 8e752265..abe55b18 100644
22 --- a/policy/modules/contrib/rpcbind.te
23 +++ b/policy/modules/contrib/rpcbind.te
24 @@ -1,4 +1,4 @@
25 -policy_module(rpcbind, 1.11.1)
26 +policy_module(rpcbind, 1.11.2)
27
28 ########################################
29 #
30 @@ -26,6 +26,8 @@ files_type(rpcbind_var_lib_t)
31 #
32
33 allow rpcbind_t self:capability { dac_override setgid setuid sys_tty_config };
34 +# net_admin is for SO_SNDBUFFORCE
35 +dontaudit rpcbind_t self:capability net_admin;
36 allow rpcbind_t self:fifo_file rw_fifo_file_perms;
37 allow rpcbind_t self:unix_stream_socket { accept listen };
38 allow rpcbind_t self:tcp_socket { accept listen };
39
40 diff --git a/policy/modules/contrib/tor.te b/policy/modules/contrib/tor.te
41 index a68e5d9e..3b48ba5e 100644
42 --- a/policy/modules/contrib/tor.te
43 +++ b/policy/modules/contrib/tor.te
44 @@ -1,4 +1,4 @@
45 -policy_module(tor, 1.13.1)
46 +policy_module(tor, 1.13.2)
47
48 ########################################
49 #
50 @@ -42,6 +42,8 @@ init_daemon_pid_file(tor_var_run_t, dir, "tor")
51 #
52
53 allow tor_t self:capability { chown dac_override dac_read_search fowner fsetid setgid setuid sys_tty_config };
54 +# net_admin is for SO_SNDBUFFORCE
55 +dontaudit tor_t self:capability net_admin;
56 allow tor_t self:process signal;
57 allow tor_t self:fifo_file rw_fifo_file_perms;
58 allow tor_t self:unix_stream_socket { accept listen };