|
Chris PeBenito |
0fbfa5 |
#DESC XFS - X Font Server
|
|
Chris PeBenito |
0fbfa5 |
#
|
|
Chris PeBenito |
0fbfa5 |
# Authors: Stephen Smalley <sds@epoch.ncsc.mil> and Timothy Fraser
|
|
Chris PeBenito |
0fbfa5 |
# Russell Coker <russell@coker.com.au>
|
|
Chris PeBenito |
0fbfa5 |
# X-Debian-Packages: xfs
|
|
Chris PeBenito |
0fbfa5 |
#
|
|
Chris PeBenito |
0fbfa5 |
|
|
Chris PeBenito |
0fbfa5 |
#################################
|
|
Chris PeBenito |
0fbfa5 |
#
|
|
Chris PeBenito |
0fbfa5 |
# Rules for the xfs_t domain.
|
|
Chris PeBenito |
0fbfa5 |
#
|
|
Chris PeBenito |
0fbfa5 |
# xfs_t is the domain of the X font server.
|
|
Chris PeBenito |
0fbfa5 |
# xfs_exec_t is the type of the xfs executable.
|
|
Chris PeBenito |
0fbfa5 |
#
|
|
Chris PeBenito |
0fbfa5 |
daemon_domain(xfs)
|
|
Chris PeBenito |
0fbfa5 |
|
|
Chris PeBenito |
0fbfa5 |
# for /tmp/.font-unix/fs7100
|
|
Chris PeBenito |
0fbfa5 |
ifdef(`distro_debian', `
|
|
Chris PeBenito |
0fbfa5 |
type xfs_tmp_t, file_type, sysadmfile, tmpfile;
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t tmp_t:dir search;
|
|
Chris PeBenito |
0fbfa5 |
file_type_auto_trans(xfs_t, initrc_tmp_t, xfs_tmp_t, sock_file)
|
|
Chris PeBenito |
0fbfa5 |
', `
|
|
Chris PeBenito |
0fbfa5 |
tmp_domain(xfs, `', `{dir sock_file}')
|
|
Chris PeBenito |
0fbfa5 |
')
|
|
Chris PeBenito |
0fbfa5 |
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t { etc_t etc_runtime_t }:file { getattr read };
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t proc_t:file { getattr read };
|
|
Chris PeBenito |
0fbfa5 |
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t self:process setpgid;
|
|
Chris PeBenito |
0fbfa5 |
can_ypbind(xfs_t)
|
|
Chris PeBenito |
0fbfa5 |
|
|
Chris PeBenito |
0fbfa5 |
# Use capabilities.
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t self:capability { setgid setuid };
|
|
Chris PeBenito |
0fbfa5 |
|
|
Chris PeBenito |
0fbfa5 |
# Bind to /tmp/.font-unix/fs-1.
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t xfs_tmp_t:unix_stream_socket name_bind;
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t self:unix_stream_socket create_stream_socket_perms;
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t self:unix_dgram_socket create_socket_perms;
|
|
Chris PeBenito |
0fbfa5 |
|
|
Chris PeBenito |
0fbfa5 |
# Read /usr/X11R6/lib/X11/fonts/.* and /usr/share/fonts/.*
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t fonts_t:dir search;
|
|
Chris PeBenito |
0fbfa5 |
allow xfs_t fonts_t:file { getattr read };
|
|
Chris PeBenito |
0fbfa5 |
|
|
Chris PeBenito |
0fbfa5 |
# Unlink the xfs socket.
|
|
Chris PeBenito |
0fbfa5 |
allow initrc_t xfs_tmp_t:dir rw_dir_perms;
|
|
Chris PeBenito |
0fbfa5 |
allow initrc_t xfs_tmp_t:dir rmdir;
|
|
Chris PeBenito |
0fbfa5 |
allow initrc_t xfs_tmp_t:sock_file { read getattr unlink };
|
|
Chris PeBenito |
0fbfa5 |
allow initrc_t fonts_t:dir create_dir_perms;
|
|
Chris PeBenito |
0fbfa5 |
allow initrc_t fonts_t:file create_file_perms;
|
|
Chris PeBenito |
0fbfa5 |
|