## Policy for user executable applications.
########################################
##
## Make the specified type usable as an application domain.
##
##
##
## Type to be used as a domain type.
##
##
#
interface(`application_type',`
gen_require(`
attribute application_domain_type;
')
typeattribute $1 application_domain_type;
# start with basic domain
domain_type($1)
')
########################################
##
## Make the specified type usable for files
## that are exectuables, such as binary programs.
## This does not include shared libraries.
##
##
##
## Type to be used for files.
##
##
#
interface(`application_executable_file',`
gen_require(`
attribute application_exec_type;
')
typeattribute $1 application_exec_type;
corecmd_executable_file($1)
')
########################################
##
## Execute application executables in the caller domain.
##
##
##
## Domain allowed access.
##
##
#
interface(`application_exec',`
gen_require(`
attribute application_exec_type;
')
can_exec($1, application_exec_type)
')
########################################
##
## Create a domain which can be started by users
##
##
##
## Type to be used as a domain.
##
##
##
##
## Type of the program to be used as an entry point to this domain.
##
##
#
interface(`application_domain',`
application_type($1)
application_executable_file($2)
domain_entry_file($1,$2)
')