Blame policy/modules/admin/backup.if
|
Chris PeBenito |
57f233 |
## <summary>System backup scripts</summary>
|
|
Chris PeBenito |
57f233 |
|
|
Chris PeBenito |
57f233 |
########################################
|
|
Chris PeBenito |
57f233 |
## <summary>
|
|
Chris PeBenito |
57f233 |
## Execute backup in the backup domain.
|
|
Chris PeBenito |
57f233 |
## </summary>
|
|
Chris PeBenito |
57f233 |
## <param name="domain">
|
|
Chris PeBenito |
57f233 |
## <summary>
|
|
Chris PeBenito |
57f233 |
## Domain allowed access.
|
|
Chris PeBenito |
57f233 |
## </summary>
|
|
Chris PeBenito |
57f233 |
## </param>
|
|
Chris PeBenito |
57f233 |
#
|
|
Chris PeBenito |
57f233 |
interface(`backup_domtrans',`
|
|
Chris PeBenito |
57f233 |
gen_require(`
|
|
Chris PeBenito |
57f233 |
type backup_t, backup_exec_t;
|
|
Chris PeBenito |
57f233 |
')
|
|
Chris PeBenito |
57f233 |
|
|
Chris PeBenito |
57f233 |
domain_auto_trans($1,backup_exec_t,backup_t)
|
|
Chris PeBenito |
57f233 |
allow backup_t $1:fd use;
|
|
Chris PeBenito |
57f233 |
allow backup_t $1:fifo_file rw_file_perms;
|
|
Chris PeBenito |
57f233 |
allow backup_t $1:process sigchld;
|
|
Chris PeBenito |
57f233 |
')
|
|
Chris PeBenito |
57f233 |
|
|
Chris PeBenito |
57f233 |
########################################
|
|
Chris PeBenito |
57f233 |
## <summary>
|
|
Chris PeBenito |
57f233 |
## Execute backup in the backup domain, and
|
|
Chris PeBenito |
57f233 |
## allow the specified role the backup domain.
|
|
Chris PeBenito |
57f233 |
## </summary>
|
|
Chris PeBenito |
57f233 |
## <param name="domain">
|
|
Chris PeBenito |
57f233 |
## <summary>
|
|
Chris PeBenito |
57f233 |
## The type of the process performing this action.
|
|
Chris PeBenito |
57f233 |
## </summary>
|
|
Chris PeBenito |
57f233 |
## </param>
|
|
Chris PeBenito |
57f233 |
## <param name="role">
|
|
Chris PeBenito |
57f233 |
## <summary>
|
|
Chris PeBenito |
57f233 |
## The role to be allowed the backup domain.
|
|
Chris PeBenito |
57f233 |
## </summary>
|
|
Chris PeBenito |
57f233 |
## </param>
|
|
Chris PeBenito |
57f233 |
## <param name="terminal">
|
|
Chris PeBenito |
57f233 |
## <summary>
|
|
Chris PeBenito |
57f233 |
## Domain allowed access.
|
|
Chris PeBenito |
57f233 |
## </summary>
|
|
Chris PeBenito |
57f233 |
## </param>
|
|
Chris PeBenito |
57f233 |
#
|
|
Chris PeBenito |
57f233 |
interface(`backup_run',`
|
|
Chris PeBenito |
57f233 |
gen_require(`
|
|
Chris PeBenito |
57f233 |
type backup_t;
|
|
Chris PeBenito |
57f233 |
')
|
|
Chris PeBenito |
57f233 |
|
|
Chris PeBenito |
57f233 |
backup_domtrans($1)
|
|
Chris PeBenito |
57f233 |
role $2 types backup_t;
|
|
Chris PeBenito |
57f233 |
allow backup_t $3:chr_file rw_term_perms;
|
|
Chris PeBenito |
57f233 |
')
|