57 lines
1.1 KiB
Text
57 lines
1.1 KiB
Text
## <summary>policy for wireguard</summary>
|
|
|
|
########################################
|
|
## <summary>
|
|
## Execute wireguard_exec_t in the wireguard domain.
|
|
## </summary>
|
|
## <param name="domain">
|
|
## <summary>
|
|
## Domain allowed to transition.
|
|
## </summary>
|
|
## </param>
|
|
#
|
|
interface(`wireguard_domtrans',`
|
|
gen_require(`
|
|
type wireguard_t, wireguard_exec_t;
|
|
')
|
|
|
|
corecmd_search_bin($1)
|
|
domtrans_pattern($1, wireguard_exec_t, wireguard_t)
|
|
')
|
|
|
|
######################################
|
|
## <summary>
|
|
## Execute wireguard in the caller domain.
|
|
## </summary>
|
|
## <param name="domain">
|
|
## <summary>
|
|
## Domain allowed access.
|
|
## </summary>
|
|
## </param>
|
|
#
|
|
interface(`wireguard_exec',`
|
|
gen_require(`
|
|
type wireguard_exec_t;
|
|
')
|
|
|
|
corecmd_search_bin($1)
|
|
can_exec($1, wireguard_exec_t)
|
|
')
|
|
|
|
########################################
|
|
## <summary>
|
|
## Read wireguard fifo files.
|
|
## </summary>
|
|
## <param name="domain">
|
|
## <summary>
|
|
## Domain to not audit.
|
|
## </summary>
|
|
## </param>
|
|
#
|
|
interface(`wireguard_read_fifo_files',`
|
|
gen_require(`
|
|
type wireguard_t;
|
|
')
|
|
|
|
allow $1 wireguard_t:fifo_file read_fifo_file_perms;
|
|
')
|