selinux-refpolicy/policy/modules/services/aptcacher.if

66 lines
1.4 KiB
Plaintext
Raw Normal View History

## <summary>apt-cacher, cache for Debian APT repositories.</summary>
########################################
## <summary>
## Execute acngtool in the acngtool domain.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed to transition.
## </summary>
## </param>
#
interface(`aptcacher_domtrans_acngtool',`
gen_require(`
type acngtool_t, acngtool_exec_t;
')
corecmd_search_bin($1)
domtrans_pattern($1, acngtool_exec_t, acngtool_t)
')
########################################
## <summary>
## Execute acngtool in the acngtool domain, and
## allow the specified role the acngtool domain.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed to transition.
## </summary>
## </param>
## <param name="role">
## <summary>
## Role allowed access.
## </summary>
## </param>
#
interface(`aptcacher_run_acngtool',`
gen_require(`
attribute_role acngtool_roles;
')
aptcacher_domtrans_acngtool($1)
roleattribute $2 acngtool_roles;
')
########################################
## <summary>
## Connect to aptcacher using a unix
## stream socket.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
#
interface(`aptcacher_stream_connect',`
gen_require(`
type aptcacher_t, aptcacher_runtime_t;
')
files_search_runtime($1)
stream_connect_pattern($1, aptcacher_runtime_t, aptcacher_runtime_t, aptcacher_t)
')