From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 516DC1387E8 for ; Fri, 8 Aug 2014 08:50:51 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 832F1E096A; Fri, 8 Aug 2014 08:50:49 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8C9C9E0963 for ; Fri, 8 Aug 2014 08:50:48 +0000 (UTC) Received: from spoonbill.gentoo.org (spoonbill.gentoo.org [81.93.255.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id ADB9134013A for ; Fri, 8 Aug 2014 08:50:47 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by spoonbill.gentoo.org (Postfix) with ESMTP id 72A341881B for ; Fri, 8 Aug 2014 08:50:46 +0000 (UTC) From: "Sven Vermeulen" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sven Vermeulen" Message-ID: <1407487455.a6a300d4692eb06f7de55d413099b844e142a7b2.swift@gentoo> Subject: [gentoo-commits] proj/hardened-refpolicy:testing commit in: policy/modules/kernel/ X-VCS-Repository: proj/hardened-refpolicy X-VCS-Files: policy/modules/kernel/files.if X-VCS-Directories: policy/modules/kernel/ X-VCS-Committer: swift X-VCS-Committer-Name: Sven Vermeulen X-VCS-Revision: a6a300d4692eb06f7de55d413099b844e142a7b2 X-VCS-Branch: testing Date: Fri, 8 Aug 2014 08:50:46 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: ab5d1975-ce07-4f61-a74d-9c5c30332dc0 X-Archives-Hash: c3628a6a6671a3bc04c997b9b44c24c9 commit: a6a300d4692eb06f7de55d413099b844e142a7b2 Author: Sven Vermeulen siphos be> AuthorDate: Fri Aug 8 08:44:15 2014 +0000 Commit: Sven Vermeulen gentoo org> CommitDate: Fri Aug 8 08:44:15 2014 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/hardened-refpolicy.git;a=commit;h=a6a300d4 Introduce files_relabel_all_pidfiles This interface can be used by domains needing wide relabel privileges towards the *_var_run_t and var_run_t types. --- policy/modules/kernel/files.if | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/policy/modules/kernel/files.if b/policy/modules/kernel/files.if index efd7836..33076ed 100644 --- a/policy/modules/kernel/files.if +++ b/policy/modules/kernel/files.if @@ -6781,3 +6781,24 @@ interface(`files_manage_all_non_security_file_types',` manage_sock_files_pattern($1, non_security_file_type, non_security_file_type) ') +######################################### +## +## Allow relabeling from and to any pidfile associated type +## +## +## +## Domain allowed access. +## +## +# +interface(`files_relabel_all_pidfiles',` + gen_require(` + attribute pidfile; + ') + + allow $1 pidfile:dir list_dir_perms; + + relabel_dirs_pattern($1, pidfile, pidfile) + relabel_files_pattern($1, pidfile, pidfile) + relabel_lnk_files_pattern($1, pidfile, pidfile) +') From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 4FDF913877A for ; Fri, 8 Aug 2014 08:48:25 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 87632E0917; Fri, 8 Aug 2014 08:48:24 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 1BB7AE0946 for ; Fri, 8 Aug 2014 08:48:24 +0000 (UTC) Received: from spoonbill.gentoo.org (spoonbill.gentoo.org [81.93.255.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 079FA33FF36 for ; Fri, 8 Aug 2014 08:48:23 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by spoonbill.gentoo.org (Postfix) with ESMTP id 484EC1881A for ; Fri, 8 Aug 2014 08:48:21 +0000 (UTC) From: "Sven Vermeulen" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sven Vermeulen" Message-ID: <1407487455.a6a300d4692eb06f7de55d413099b844e142a7b2.swift@gentoo> Subject: [gentoo-commits] proj/hardened-refpolicy:master commit in: policy/modules/kernel/ X-VCS-Repository: proj/hardened-refpolicy X-VCS-Files: policy/modules/kernel/files.if X-VCS-Directories: policy/modules/kernel/ X-VCS-Committer: swift X-VCS-Committer-Name: Sven Vermeulen X-VCS-Revision: a6a300d4692eb06f7de55d413099b844e142a7b2 X-VCS-Branch: master Date: Fri, 8 Aug 2014 08:48:21 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: a5182f5d-ac05-4a57-8a51-9eab90dae1ad X-Archives-Hash: 379dd2557041e02eef72aeaccc38e82b Message-ID: <20140808084821.u9kPUAv2EEddE_xeAfKVO4Y6dDaJg44bRoHcWg1X0Ts@z> commit: a6a300d4692eb06f7de55d413099b844e142a7b2 Author: Sven Vermeulen siphos be> AuthorDate: Fri Aug 8 08:44:15 2014 +0000 Commit: Sven Vermeulen gentoo org> CommitDate: Fri Aug 8 08:44:15 2014 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/hardened-refpolicy.git;a=commit;h=a6a300d4 Introduce files_relabel_all_pidfiles This interface can be used by domains needing wide relabel privileges towards the *_var_run_t and var_run_t types. --- policy/modules/kernel/files.if | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/policy/modules/kernel/files.if b/policy/modules/kernel/files.if index efd7836..33076ed 100644 --- a/policy/modules/kernel/files.if +++ b/policy/modules/kernel/files.if @@ -6781,3 +6781,24 @@ interface(`files_manage_all_non_security_file_types',` manage_sock_files_pattern($1, non_security_file_type, non_security_file_type) ') +######################################### +## +## Allow relabeling from and to any pidfile associated type +## +## +## +## Domain allowed access. +## +## +# +interface(`files_relabel_all_pidfiles',` + gen_require(` + attribute pidfile; + ') + + allow $1 pidfile:dir list_dir_perms; + + relabel_dirs_pattern($1, pidfile, pidfile) + relabel_files_pattern($1, pidfile, pidfile) + relabel_lnk_files_pattern($1, pidfile, pidfile) +')