filesystem: introduce fs_cgroup_filetrans interface

This commit is contained in:
Jason Zaman 2017-06-05 00:33:44 +08:00 committed by Chris PeBenito
parent 2749bddae8
commit b93c403dd7
1 changed files with 36 additions and 0 deletions

View File

@ -942,6 +942,42 @@ interface(`fs_mounton_cgroup', `
allow $1 cgroup_t:dir mounton;
')
########################################
## <summary>
## Create an object in a cgroup tmpfs filesystem, with a private
## type using a type transition.
## </summary>
## <param name="domain">
## <summary>
## Domain allowed access.
## </summary>
## </param>
## <param name="private type">
## <summary>
## The type of the object to be created.
## </summary>
## </param>
## <param name="object">
## <summary>
## The object class of the object being created.
## </summary>
## </param>
## <param name="name" optional="true">
## <summary>
## The name of the object being created.
## </summary>
## </param>
#
interface(`fs_cgroup_filetrans',`
gen_require(`
type cgroup_t, tmpfs_t;
')
allow $2 tmpfs_t:filesystem associate;
filetrans_pattern($1, cgroup_t, $2, $3, $4)
fs_search_sysfs($1)
')
########################################
## <summary>
## Do not audit attempts to read