From 5751a33f270c97cf629d97a2c16d846ad5af6210 Mon Sep 17 00:00:00 2001 From: Sven Vermeulen Date: Tue, 30 Oct 2012 22:51:54 +0100 Subject: [PATCH] Introduce files_manage_all_pids interface This interface will be used by domains that need to manage the various pidfile content (*_var_run_t). Signed-off-by: Sven Vermeulen --- 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 54c6dbd02..7c4b4ae33 100644 --- a/policy/modules/kernel/files.if +++ b/policy/modules/kernel/files.if @@ -6189,6 +6189,27 @@ interface(`files_dontaudit_getattr_all_pids',` dontaudit $1 pidfile:file getattr; ') +######################################## +## +## Create, read, write and delete all +## var_run (pid) content +## +## +## +## Domain alloed access. +## +## +# +interface(`files_manage_all_pids',` + gen_require(` + attribute pidfile; + ') + + manage_dirs_pattern($1, pidfile, pidfile) + manage_files_pattern($1, pidfile, pidfile) + manage_lnk_files_pattern($1, pidfile, pidfile) +') + ######################################## ## ## Do not audit attempts to write to daemon runtime data files.