57869a681e
module tag
126 lines
3.1 KiB
Plaintext
126 lines
3.1 KiB
Plaintext
## <module name="miscfiles">
|
|
## <summary>Miscelaneous files.</summary>
|
|
|
|
########################################
|
|
## <interface name="miscfiles_rw_man_cache">
|
|
## <description>
|
|
## Allow process to create files and dirs in /var/cache/man
|
|
## and /var/catman/
|
|
## </description>
|
|
## <parameter name="domain">
|
|
## Type type of the process performing this action.
|
|
## </parameter>
|
|
## </interface>
|
|
#
|
|
define(`miscfiles_rw_man_cache',`
|
|
gen_require(`
|
|
type catman_t;
|
|
class dir create_dir_perms;
|
|
class file create_file_perms;
|
|
')
|
|
|
|
files_search_var($1)
|
|
allow $1 catman_t:dir create_dir_perms;
|
|
allow $1 catman_t:file create_file_perms;
|
|
')
|
|
|
|
########################################
|
|
## <interface name="miscfiles_read_fonts">
|
|
## <description>
|
|
## Allow process to read fonts files
|
|
## </description>
|
|
## <parameter name="domain">
|
|
## Type type of the process performing this action.
|
|
## </parameter>
|
|
## </interface>
|
|
#
|
|
define(`miscfiles_read_fonts',`
|
|
gen_require(`
|
|
type fonts_t;
|
|
class dir r_dir_perms;
|
|
class file r_file_perms;
|
|
')
|
|
|
|
files_search_usr($1)
|
|
libs_search_lib($1)
|
|
|
|
# cjp: fonts can be in either of the above dirs
|
|
allow $1 fonts_t:dir r_dir_perms;
|
|
allow $1 fonts_t:file r_file_perms;
|
|
')
|
|
|
|
########################################
|
|
## <interface name="miscfiles_read_localization">
|
|
## <description>
|
|
## Allow process to read localization info
|
|
## </description>
|
|
## <parameter name="domain">
|
|
## Type type of the process performing this action.
|
|
## </parameter>
|
|
## </interface>
|
|
#
|
|
define(`miscfiles_read_localization',`
|
|
gen_require(`
|
|
type locale_t;
|
|
class dir r_dir_perms;
|
|
class lnk_file r_file_perms;
|
|
class file r_file_perms;
|
|
')
|
|
|
|
files_search_etc($1)
|
|
# FIXME: $1 read etc_t:lnk_file here
|
|
files_search_usr($1)
|
|
allow $1 locale_t:dir r_dir_perms;
|
|
allow $1 locale_t:lnk_file r_file_perms;
|
|
allow $1 locale_t:file r_file_perms;
|
|
|
|
# why?
|
|
libs_read_lib($1)
|
|
')
|
|
|
|
########################################
|
|
## <interface name="miscfiles_legacy_read_localization">
|
|
## <description>
|
|
## Allow process to read legacy time localization info
|
|
## </description>
|
|
## <parameter name="domain">
|
|
## Type type of the process performing this action.
|
|
## </parameter>
|
|
## </interface>
|
|
#
|
|
define(`miscfiles_legacy_read_localization',`
|
|
gen_require(`
|
|
type locale_t;
|
|
class file execute;
|
|
')
|
|
|
|
miscfiles_read_localization($1)
|
|
allow $1 locale_t:file execute;
|
|
')
|
|
|
|
########################################
|
|
## <interface name="miscfiles_read_man_pages">
|
|
## <description>
|
|
## Allow process to read manpages
|
|
## </description>
|
|
## <parameter name="domain">
|
|
## Type type of the process performing this action.
|
|
## </parameter>
|
|
## </interface>
|
|
#
|
|
define(`miscfiles_read_man_pages',`
|
|
gen_require(`
|
|
type man_t;
|
|
class dir r_dir_perms;
|
|
class file r_file_perms;
|
|
class lnk_file r_file_perms;
|
|
')
|
|
|
|
files_search_usr($1)
|
|
allow $1 man_t:dir r_dir_perms;
|
|
allow $1 man_t:file r_file_perms;
|
|
allow $1 man_t:lnk_file r_file_perms;
|
|
')
|
|
|
|
## </module>
|