Gentoo Archives: gentoo-commits

From: Sven Vermeulen <swift@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/hardened-refpolicy:swift commit in: policy/modules/contrib/
Date: Sat, 10 Oct 2015 12:11:20
Message-Id: 1440702511.4896ffe78b0ad5ce485f252084c40853323945dd.swift@gentoo
1 commit: 4896ffe78b0ad5ce485f252084c40853323945dd
2 Author: Jason Zaman <jason <AT> perfinion <DOT> com>
3 AuthorDate: Mon Aug 24 15:10:08 2015 +0000
4 Commit: Sven Vermeulen <swift <AT> gentoo <DOT> org>
5 CommitDate: Thu Aug 27 19:08:31 2015 +0000
6 URL: https://gitweb.gentoo.org/proj/hardened-refpolicy.git/commit/?id=4896ffe7
7
8 git: allow git_system_t to listen on tcp_sockets
9
10 git_session_t already has these permissions but they are missing on
11 git_system_t. Instead add the perms on the git_daemon attribute which
12 covers both system and session daemons.
13
14 policy/modules/contrib/git.te | 3 +--
15 1 file changed, 1 insertion(+), 2 deletions(-)
16
17 diff --git a/policy/modules/contrib/git.te b/policy/modules/contrib/git.te
18 index 1ca8c24..517d513 100644
19 --- a/policy/modules/contrib/git.te
20 +++ b/policy/modules/contrib/git.te
21 @@ -103,8 +103,6 @@ userdom_user_home_content(git_user_content_t)
22 # Session policy
23 #
24
25 -allow git_session_t self:tcp_socket { accept listen };
26 -
27 userdom_search_user_home_dirs(git_session_t)
28
29 corenet_all_recvfrom_netlabel(git_session_t)
30 @@ -266,6 +264,7 @@ tunable_policy(`git_cgi_use_nfs',`
31 #
32
33 allow git_daemon self:fifo_file rw_fifo_file_perms;
34 +allow git_daemon self:tcp_socket { accept listen };
35
36 list_dirs_pattern(git_daemon, git_user_content_t, git_user_content_t)
37 read_files_pattern(git_daemon, git_user_content_t, git_user_content_t)