81 lines
1.7 KiB
Plaintext
81 lines
1.7 KiB
Plaintext
## <summary>fake-hwclock - Control fake hardware clock.</summary>
|
|
|
|
########################################
|
|
## <summary>
|
|
## Execute a domain transition to run fake-hwclock.
|
|
## </summary>
|
|
## <param name="domain">
|
|
## <summary>
|
|
## Domain allowed to transition.
|
|
## </summary>
|
|
## </param>
|
|
#
|
|
interface(`fakehwclock_domtrans',`
|
|
refpolicywarn(`$0($*) has been deprecated')
|
|
|
|
gen_require(`
|
|
type fakehwclock_t, fakehwclock_exec_t;
|
|
')
|
|
|
|
corecmd_search_bin($1)
|
|
domtrans_pattern($1, fakehwclock_exec_t, fakehwclock_t)
|
|
')
|
|
|
|
########################################
|
|
## <summary>
|
|
## Execute fake-hwclock in the fake-hwclock domain,
|
|
## and allow the specified role
|
|
## the fake-hwclock domain.
|
|
## </summary>
|
|
## <param name="domain">
|
|
## <summary>
|
|
## Domain allowed to transition.
|
|
## </summary>
|
|
## </param>
|
|
## <param name="role">
|
|
## <summary>
|
|
## Role allowed access.
|
|
## </summary>
|
|
## </param>
|
|
#
|
|
interface(`fakehwclock_run',`
|
|
refpolicywarn(`$0($*) has been deprecated')
|
|
|
|
gen_require(`
|
|
attribute_role fakehwclock_roles;
|
|
')
|
|
|
|
fakehwclock_domtrans($1)
|
|
roleattribute $2 fakehwclock_roles;
|
|
')
|
|
|
|
########################################
|
|
## <summary>
|
|
## All the rules required to
|
|
## administrate an fake-hwclock environment.
|
|
## </summary>
|
|
## <param name="domain">
|
|
## <summary>
|
|
## Domain allowed to transition.
|
|
## </summary>
|
|
## </param>
|
|
## <param name="role">
|
|
## <summary>
|
|
## Role allowed access.
|
|
## </summary>
|
|
## </param>
|
|
#
|
|
interface(`fakehwclock_admin',`
|
|
gen_require(`
|
|
type fakehwclock_t, fakehwclock_backup_t, fakehwclock_initrc_exec_t;
|
|
type fakehwclock_unit_t;
|
|
')
|
|
|
|
admin_process_pattern($1, fakehwclock_t)
|
|
|
|
init_startstop_service($1, $2, fakehwclock_t, fakehwclock_initrc_exec_t, fakehwclock_unit_t)
|
|
|
|
files_search_etc($1)
|
|
admin_pattern($1, fakehwclock_backup_t)
|
|
')
|