From 34abc0925507281187c6710562e004607f9b0e63 Mon Sep 17 00:00:00 2001 From: Kenton Groombridge Date: Thu, 6 Jan 2022 18:24:35 -0500 Subject: [PATCH] xdg: add interface to search xdg data directories Signed-off-by: Kenton Groombridge --- policy/modules/system/xdg.if | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/policy/modules/system/xdg.if b/policy/modules/system/xdg.if index 823042414..a3c2759b7 100644 --- a/policy/modules/system/xdg.if +++ b/policy/modules/system/xdg.if @@ -635,6 +635,24 @@ interface(`xdg_relabel_all_config',` userdom_search_user_home_dirs($1) ') +######################################## +## +## Search through the xdg data home directories +## +## +## +## Domain allowed access +## +## +# +interface(`xdg_search_data_dirs',` + gen_require(` + type xdg_data_t; + ') + + allow $1 xdg_data_t:dir search_dir_perms; +') + ######################################## ## ## Watch the xdg data home directories