|
Chris PeBenito |
e181fe |
# Copyright (C) 2005 Tresys Technology, LLC
|
|
Chris PeBenito |
e181fe |
|
|
Chris PeBenito |
b4cd15 |
########################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_make_pseudoterminal(type)
|
|
Chris PeBenito |
8a0da1 |
#
|
|
Chris PeBenito |
8a0da1 |
define(`terminal_make_pseudoterminal',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b16c6b |
allow $1 devpts_t:filesystem associate;
|
|
Chris PeBenito |
b16c6b |
typeattribute $1 ptynode;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_make_pseudoterminal_depend',`
|
|
Chris PeBenito |
b16c6b |
attribute ptynode;
|
|
Chris PeBenito |
b16c6b |
type devpts_t;
|
|
Chris PeBenito |
b16c6b |
class filesystem associate;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
########################################
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_make_user_pseudoterminal(domain,type)
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_make_user_pseudoterminal',`
|
|
Chris PeBenito |
b16c6b |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b16c6b |
terminal_make_pseudoterminal($1)
|
|
Chris PeBenito |
b16c6b |
type_change $1 server_ptynode:chr_file $2;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_make_user_pseudoterminal_depend',`
|
|
Chris PeBenito |
b16c6b |
attribute server_ptynode;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
########################################
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_make_service_pseudoterminal(type)
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_make_service_pseudoterminal',`
|
|
Chris PeBenito |
b16c6b |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b16c6b |
terminal_make_pseudoterminal($1)
|
|
Chris PeBenito |
b16c6b |
typeattribute $1 server_ptynode;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_make_service_pseudoterminal_depend',`
|
|
Chris PeBenito |
b16c6b |
attribute server_ptynode;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
########################################
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_make_physical_terminal(domain,type)
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_make_physical_terminal',`
|
|
Chris PeBenito |
b16c6b |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b16c6b |
typeattribute $2 ttynode;
|
|
Chris PeBenito |
b16c6b |
type_change $1 tty_device_t:chr_file $2;
|
|
Chris PeBenito |
b16c6b |
# Debian login is from shadow utils and does not allow resetting the perms.
|
|
Chris PeBenito |
b16c6b |
# have to fix this!
|
|
Chris PeBenito |
b16c6b |
tunable_policy(`distro_debian',`
|
|
Chris PeBenito |
b16c6b |
type_change $1 ttyfile:chr_file $2;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_make_physical_terminal_depend',`
|
|
Chris PeBenito |
b16c6b |
attribute ttynode;
|
|
Chris PeBenito |
b16c6b |
type tty_device_t;
|
|
Chris PeBenito |
b16c6b |
')
|
|
Chris PeBenito |
b16c6b |
|
|
Chris PeBenito |
b16c6b |
########################################
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_create_private_pseudoterminal(domain,ptytype)
|
|
Chris PeBenito |
b16c6b |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_create_private_pseudoterminal',`
|
|
Chris PeBenito |
b16c6b |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
b16c6b |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
8a0da1 |
allow $1 ptmx_t:chr_file { getattr read write };
|
|
Chris PeBenito |
8a0da1 |
allow $1 devpts_t:dir { getattr search read };
|
|
Chris PeBenito |
8a0da1 |
allow $1 devpts_t:filesystem getattr;
|
|
Chris PeBenito |
960373 |
dontaudit $1 bsdpty_device_t:chr_file { getattr read write };
|
|
Chris PeBenito |
8a0da1 |
type_transition $1 devpts_t:chr_file $2;
|
|
Chris PeBenito |
8a0da1 |
')
|
|
Chris PeBenito |
8a0da1 |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_create_pseudoterminal_depend',`
|
|
Chris PeBenito |
8a0da1 |
type ptmx_t, devpts_t;
|
|
Chris PeBenito |
b16c6b |
class filesystem getattr;
|
|
Chris PeBenito |
8a0da1 |
class dir { getattr search read };
|
|
Chris PeBenito |
8a0da1 |
class chr_file { getattr read write };
|
|
Chris PeBenito |
8a0da1 |
')
|
|
Chris PeBenito |
8a0da1 |
|
|
Chris PeBenito |
8a0da1 |
########################################
|
|
Chris PeBenito |
8a0da1 |
#
|
|
Chris PeBenito |
3ce6cb |
# terminal_use_all_terminals(domain)
|
|
Chris PeBenito |
de2cee |
#
|
|
Chris PeBenito |
de2cee |
define(`terminal_use_all_terminals',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
3ce6cb |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
3ce6cb |
allow $1 devpts_t:dir { getattr search read };
|
|
Chris PeBenito |
de2cee |
allow $1 { console_device_t devtty_t ttynode ptynode }:chr_file { read write };
|
|
Chris PeBenito |
de2cee |
')
|
|
Chris PeBenito |
de2cee |
|
|
Chris PeBenito |
de2cee |
define(`terminal_use_all_terminals_depend',`
|
|
Chris PeBenito |
de2cee |
attribute ttynode, ptynode;
|
|
Chris PeBenito |
de2cee |
type console_device_t, devtty_t, devpts_t;
|
|
Chris PeBenito |
3ce6cb |
class dir { getattr search read };
|
|
Chris PeBenito |
3ce6cb |
class chr_file { read write };
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
3ce6cb |
########################################
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_use_console(domain)
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_use_console',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1,optional)
|
|
Chris PeBenito |
7bba9d |
allow $1 console_device_t:chr_file { read write };
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_use_console_depend',`
|
|
Chris PeBenito |
7bba9d |
type console_device_t;
|
|
Chris PeBenito |
7bba9d |
class chr_file { read write };
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes_depend
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
3ce6cb |
########################################
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_ignore_use_console(domain)
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_ignore_use_console',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
dontaudit $1 console_device_t:chr_file { read write };
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_ignore_use_console_depend',`
|
|
Chris PeBenito |
7bba9d |
type console_device_t;
|
|
Chris PeBenito |
3ce6cb |
class chr_file { read write };
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
3ce6cb |
########################################
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_set_console_attributes(domain)
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_set_console_attributes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1,optional)
|
|
Chris PeBenito |
7bba9d |
allow $1 console_device_t:chr_file setattr;
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_set_console_attributes_depend',`
|
|
Chris PeBenito |
7bba9d |
type console_device_t;
|
|
Chris PeBenito |
7bba9d |
class chr_file setattr;
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes_depend
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
3ce6cb |
########################################
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_list_pseudoterminals(domain)
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_list_pseudoterminals',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1,optional)
|
|
Chris PeBenito |
3ce6cb |
allow $1 devpts_t:dir { getattr search read };
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_list_pseudoterminals_depend',`
|
|
Chris PeBenito |
7bba9d |
type devpts_t;
|
|
Chris PeBenito |
3ce6cb |
class dir { getattr search read };
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes_depend
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
3ce6cb |
########################################
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_ignore_list_pseudoterminals(domain)
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_ignore_list_pseudoterminals',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
dontaudit $1 devpts_t:dir { getattr search read };
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_ignore_list_pseudoterminals_depend',`
|
|
Chris PeBenito |
7bba9d |
type devpts_t;
|
|
Chris PeBenito |
3ce6cb |
class dir { getattr search read };
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
3ce6cb |
########################################
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_use_general_pseudoterminal(domain)
|
|
Chris PeBenito |
3ce6cb |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_use_general_pseudoterminal',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
7bba9d |
allow $1 devpts_t:chr_file { read write };
|
|
Chris PeBenito |
3ce6cb |
')
|
|
Chris PeBenito |
3ce6cb |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_use_general_pseudoterminal_depend',`
|
|
Chris PeBenito |
7bba9d |
type devpts_t;
|
|
Chris PeBenito |
de2cee |
class chr_file { read write };
|
|
Chris PeBenito |
de2cee |
')
|
|
Chris PeBenito |
de2cee |
|
|
Chris PeBenito |
de2cee |
########################################
|
|
Chris PeBenito |
de2cee |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_ignore_use_general_pseudoterminal(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_ignore_use_general_pseudoterminal',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
dontaudit $1 devpts_t:chr_file { read write };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_ignore_use_general_pseudoterminal_depend',`
|
|
Chris PeBenito |
7bba9d |
type devpts_t;
|
|
Chris PeBenito |
b4cd15 |
class chr_file { read write };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
########################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_use_controlling_terminal(domain)
|
|
Chris PeBenito |
811985 |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_use_controlling_terminal',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
7bba9d |
allow $1 devtty_t:chr_file { read write };
|
|
Chris PeBenito |
811985 |
')
|
|
Chris PeBenito |
811985 |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_use_controlling_terminal_depend',`
|
|
Chris PeBenito |
7bba9d |
type devtty_t;
|
|
Chris PeBenito |
811985 |
class chr_file { read write };
|
|
Chris PeBenito |
811985 |
')
|
|
Chris PeBenito |
811985 |
|
|
Chris PeBenito |
811985 |
########################################
|
|
Chris PeBenito |
811985 |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_ignore_use_pseudoterminal_multiplexer(domain)
|
|
Chris PeBenito |
55a46d |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_ignore_use_pseudoterminal_multiplexer',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
dontaudit $1 ptmx_t:chr_file { getattr read write };
|
|
Chris PeBenito |
55a46d |
')
|
|
Chris PeBenito |
55a46d |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_ignore_use_pseudoterminal_multiplexer_depend',`
|
|
Chris PeBenito |
7bba9d |
type ptmx_t;
|
|
Chris PeBenito |
7bba9d |
class chr_file { getattr read write };
|
|
Chris PeBenito |
55a46d |
')
|
|
Chris PeBenito |
55a46d |
|
|
Chris PeBenito |
55a46d |
########################################
|
|
Chris PeBenito |
55a46d |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_get_all_private_pseudoterminal_attributes(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_get_all_private_pseudoterminal_attributes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
d0eddb |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
7bba9d |
allow $1 devpts_t:dir { getattr search read };
|
|
Chris PeBenito |
7bba9d |
allow $1 ptynode:chr_file getattr;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_get_all_private_pseudoterminal_attributes_depend',`
|
|
Chris PeBenito |
7bba9d |
attribute ptynode;
|
|
Chris PeBenito |
7bba9d |
class dir { getattr search read };
|
|
Chris PeBenito |
7bba9d |
class chr_file getattr;
|
|
Chris PeBenito |
7bba9d |
')
|
|
Chris PeBenito |
7bba9d |
|
|
Chris PeBenito |
7bba9d |
########################################
|
|
Chris PeBenito |
7bba9d |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_use_all_private_pseudoterminals(domain)
|
|
Chris PeBenito |
7bba9d |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_use_all_private_pseudoterminals',`
|
|
Chris PeBenito |
7bba9d |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
7bba9d |
allow $1 devpts_t:dir { getattr read search };
|
|
Chris PeBenito |
7bba9d |
allow $1 ptynode:chr_file { read write };
|
|
Chris PeBenito |
7bba9d |
')
|
|
Chris PeBenito |
7bba9d |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_use_all_private_pseudoterminals_depend',`
|
|
Chris PeBenito |
7bba9d |
attribute ptynode;
|
|
Chris PeBenito |
7bba9d |
class dir { getattr search read };
|
|
Chris PeBenito |
b4cd15 |
class chr_file { read write };
|
|
Chris PeBenito |
d0eddb |
')
|
|
Chris PeBenito |
d0eddb |
|
|
Chris PeBenito |
d0eddb |
########################################
|
|
Chris PeBenito |
d0eddb |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_ignore_use_all_private_pseudoterminals(domain)
|
|
Chris PeBenito |
d0eddb |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_ignore_use_all_private_pseudoterminals',`
|
|
Chris PeBenito |
d0eddb |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
dontaudit $1 ptynode:chr_file { read write };
|
|
Chris PeBenito |
d0eddb |
')
|
|
Chris PeBenito |
d0eddb |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_ignore_use_all_private_pseudoterminals_depend',`
|
|
Chris PeBenito |
7bba9d |
attribute ptynode;
|
|
Chris PeBenito |
d0eddb |
class chr_file { read write };
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
########################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_get_general_physical_terminal_attributes(domain)
|
|
Chris PeBenito |
7bba9d |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_get_general_physical_terminal_attributes',`
|
|
Chris PeBenito |
7bba9d |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
7bba9d |
allow $1 tty_device_t:chr_file getattr;
|
|
Chris PeBenito |
7bba9d |
')
|
|
Chris PeBenito |
7bba9d |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_get_general_physical_terminal_attributes_depend',`
|
|
Chris PeBenito |
7bba9d |
type tty_device_t;
|
|
Chris PeBenito |
7bba9d |
class chr_file getattr;
|
|
Chris PeBenito |
7bba9d |
')
|
|
Chris PeBenito |
7bba9d |
|
|
Chris PeBenito |
7bba9d |
########################################
|
|
Chris PeBenito |
7bba9d |
#
|
|
Chris PeBenito |
7bba9d |
# terminal_set_general_physical_terminal_attributes(domain)
|
|
Chris PeBenito |
7bba9d |
#
|
|
Chris PeBenito |
7bba9d |
define(`terminal_set_general_physical_terminal_attributes',`
|
|
Chris PeBenito |
7bba9d |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
7bba9d |
allow $1 tty_device_t:chr_file setattr;
|
|
Chris PeBenito |
7bba9d |
')
|
|
Chris PeBenito |
7bba9d |
|
|
Chris PeBenito |
7bba9d |
define(`terminal_set_general_physical_terminal_attributes_depend',`
|
|
Chris PeBenito |
7bba9d |
type tty_device_t;
|
|
Chris PeBenito |
7bba9d |
class chr_file setattr;
|
|
Chris PeBenito |
7bba9d |
')
|
|
Chris PeBenito |
7bba9d |
|
|
Chris PeBenito |
7bba9d |
########################################
|
|
Chris PeBenito |
7bba9d |
#
|
|
Chris PeBenito |
de2cee |
# terminal_reset_physical_terminal_labels(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
de2cee |
define(`terminal_reset_physical_terminal_labels',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
de2cee |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
de2cee |
allow $1 ttynode:chr_file relabelfrom;
|
|
Chris PeBenito |
de2cee |
allow $1 tty_device_t:chr_file relabelto;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
de2cee |
define(`terminal_reset_physical_terminal_labels_depend',`
|
|
Chris PeBenito |
de2cee |
attribute ttynode;
|
|
Chris PeBenito |
de2cee |
type tty_device_t;
|
|
Chris PeBenito |
de2cee |
class chr_file { relabelfrom relabelto };
|
|
Chris PeBenito |
b4cd15 |
devices_list_device_nodes_depend
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b4cd15 |
########################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
de2cee |
# terminal_use_general_physical_terminal(domain)
|
|
Chris PeBenito |
de2cee |
#
|
|
Chris PeBenito |
de2cee |
define(`terminal_use_general_physical_terminal',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
de2cee |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
de2cee |
allow $1 tty_device_t:chr_file { read write };
|
|
Chris PeBenito |
de2cee |
')
|
|
Chris PeBenito |
de2cee |
|
|
Chris PeBenito |
de2cee |
define(`terminal_use_general_physical_terminal_depend',`
|
|
Chris PeBenito |
de2cee |
type tty_device_t;
|
|
Chris PeBenito |
de2cee |
class chr_file { read write };
|
|
Chris PeBenito |
de2cee |
')
|
|
Chris PeBenito |
de2cee |
|
|
Chris PeBenito |
de2cee |
########################################
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
de2cee |
# terminal_ignore_use_general_physical_terminal(domain)
|
|
Chris PeBenito |
de2cee |
#
|
|
Chris PeBenito |
de2cee |
define(`terminal_ignore_use_general_physical_terminal',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
de2cee |
dontaudit $1 tty_device_t:chr_file { read write };
|
|
Chris PeBenito |
de2cee |
')
|
|
Chris PeBenito |
de2cee |
|
|
Chris PeBenito |
de2cee |
define(`terminal_ignore_use_general_physical_terminal_depend',`
|
|
Chris PeBenito |
de2cee |
type tty_device_t;
|
|
Chris PeBenito |
de2cee |
class chr_file { read write };
|
|
Chris PeBenito |
de2cee |
')
|
|
Chris PeBenito |
de2cee |
|
|
Chris PeBenito |
de2cee |
########################################
|
|
Chris PeBenito |
de2cee |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_get_all_private_physical_terminal_attributes(domain)
|
|
Chris PeBenito |
ee5772 |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_get_all_private_physical_terminal_attributes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
7bba9d |
allow $1 ttynode:chr_file getattr;
|
|
Chris PeBenito |
ee5772 |
')
|
|
Chris PeBenito |
ee5772 |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_get_all_private_physical_terminal_attributes_depend',`
|
|
Chris PeBenito |
7bba9d |
attribute ttynode;
|
|
Chris PeBenito |
7bba9d |
class chr_file getattr;
|
|
Chris PeBenito |
ee5772 |
')
|
|
Chris PeBenito |
ee5772 |
|
|
Chris PeBenito |
ee5772 |
########################################
|
|
Chris PeBenito |
ee5772 |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_ignore_get_all_private_physical_terminal_attributes(domain)
|
|
Chris PeBenito |
b4cd15 |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_ignore_get_all_private_physical_terminal_attributes',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
dontaudit $1 ttynode:chr_file getattr;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
b4cd15 |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_ignore_get_all_private_physical_terminal_attributes_depend',`
|
|
Chris PeBenito |
7bba9d |
attribute ttynode;
|
|
Chris PeBenito |
7bba9d |
class chr_file getattr;
|
|
Chris PeBenito |
b4cd15 |
')
|
|
Chris PeBenito |
a2d824 |
|
|
Chris PeBenito |
a2d824 |
########################################
|
|
Chris PeBenito |
a2d824 |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_use_all_private_physical_terminals(domain)
|
|
Chris PeBenito |
a2d824 |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_use_all_private_physical_terminals',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
de2cee |
devices_list_device_nodes($1)
|
|
Chris PeBenito |
7bba9d |
allow $1 ttynode:chr_file { read write };
|
|
Chris PeBenito |
a2d824 |
')
|
|
Chris PeBenito |
a2d824 |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_use_all_private_physical_terminals_depend',`
|
|
Chris PeBenito |
7bba9d |
attribute ttynode;
|
|
Chris PeBenito |
de2cee |
class chr_file { read write };
|
|
Chris PeBenito |
de2cee |
')
|
|
Chris PeBenito |
de2cee |
|
|
Chris PeBenito |
de2cee |
########################################
|
|
Chris PeBenito |
de2cee |
#
|
|
Chris PeBenito |
b16c6b |
# terminal_ignore_use_all_private_physical_terminals(domain)
|
|
Chris PeBenito |
de2cee |
#
|
|
Chris PeBenito |
b16c6b |
define(`terminal_ignore_use_all_private_physical_terminals',`
|
|
Chris PeBenito |
bd202f |
requires_block_template(`$0'_depend)
|
|
Chris PeBenito |
7bba9d |
dontaudit $1 ttynode:chr_file { read write };
|
|
Chris PeBenito |
de2cee |
')
|
|
Chris PeBenito |
de2cee |
|
|
Chris PeBenito |
b16c6b |
define(`terminal_ignore_use_all_private_physical_terminals_depend',`
|
|
Chris PeBenito |
7bba9d |
attribute ttynode;
|
|
Chris PeBenito |
de2cee |
class chr_file { read write };
|
|
Chris PeBenito |
a2d824 |
')
|