policy for timidity
Timidity can be used as alsa sequencer client and run as a daemon (when started as timidity -iA). Attached policy allows this to work on a SELinux system.
Thomas
Signature · 2 lines
http://www.cip.ifi.lmu.de/~bleher/selinux/ - my SELinux pages GPG-Fingerprint: BC4F BB16 30D6 F253 E3EA D09E C562 2BAE B2F4 ABE7
# DESC timidity - MIDI to WAV converter and player
#
# Author: Thomas Bleher <[email protected]>
#
# Note: You only need this policy if you want to run timidity as a server
daemon_base_domain(timidity)can_network(timidity_t)
allow timidity_t device_t:lnk_file read;
# read /usr/share/alsa/alsa.conf
allow timidity_t usr_t:file { getattr read };
# read /etc/esd.conf and /proc/cpuinfo
allow timidity_t { etc_t proc_t }:file { getattr read };
# read libartscbackend.la - should these be shlib_t?
allow timidity_t lib_t:file { getattr read };allow timidity_t sound_device_t:chr_file { read write ioctl };
# stupid timidity won't start if it can't search its current directory. # allow this so /etc/init.d/alsasound start works from /root allow timidity_t sysadm_home_dir_t:dir search;
allow timidity_t tmp_t:dir search;
allow timidity_t tmpfs_t:file { read write };
allow timidity_t self:shm create_shm_perms;
allow timidity_t self:unix_stream_socket { connect create };
allow timidity_t devpts_t:dir search;
allow timidity_t self:capability { dac_override dac_read_search }; allow timidity_t self:process getsched;
# timidity /usr/bin/timidity -- system_u:object_r:timidity_exec_t
Quoted 3 lines · Thomas Bleher
Timidity can be used as alsa sequencer client and run as a daemon (when started as timidity -iA). Attached policy allows this to work on a SELinux system.
allow timidity_t tmpfs_t:file { read write };
That is wrong. Should be tmpfs_domain(timidity).
Also for the unix_stream_socket access I think that there's no reason not to use create_stream_socket_perms access.
Apart from that it's fine and I've put it in my tree.
Signature · 9 lines
http://www.coker.com.au/selinux/ My NSA Security Enhanced Linux packages http://www.coker.com.au/bonnie++/ Bonnie++ hard drive benchmark http://www.coker.com.au/postal/ Postal SMTP/POP benchmark http://www.coker.com.au/~russell/ My home page -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 6 lines · Russell Coker
Quoted 3 lines · Thomas Bleher
Timidity can be used as alsa sequencer client and run as a daemon (when started as timidity -iA). Attached policy allows this to work on a SELinux system.
Quoted 6 lines
allow
timidity_ttmpfs_t:file { read write };That is wrong. Should be
tmpfs_domain(timidity).Also for the
unix_stream_socketaccess I think that there's no reason not to usecreate_stream_socket_permsaccess.
Thanks for your comments!
A new version of timidity.te is attached.
Thomas
Signature · 2 lines
http://www.cip.ifi.lmu.de/~bleher/selinux/ - my SELinux pages GPG-Fingerprint: BC4F BB16 30D6 F253 E3EA D09E C562 2BAE B2F4 ABE7
# DESC timidity - MIDI to WAV converter and player
#
# Author: Thomas Bleher <[email protected]>
#
# Note: You only need this policy if you want to run timidity as a server
daemon_base_domain(timidity)can_network(timidity_t)
allow timidity_t device_t:lnk_file read;
# read /usr/share/alsa/alsa.conf
allow timidity_t usr_t:file { getattr read };
# read /etc/esd.conf and /proc/cpuinfo
allow timidity_t { etc_t proc_t }:file { getattr read };
# read libartscbackend.la - should these be shlib_t?
allow timidity_t lib_t:file { getattr read };allow timidity_t sound_device_t:chr_file { read write ioctl };
# stupid timidity won't start if it can't search its current directory. # allow this so /etc/init.d/alsasound start works from /root allow timidity_t sysadm_home_dir_t:dir search;
allow timidity_t tmp_t:dir search;tmpfs_domain(timidity)
allow timidity_t self:shm create_shm_perms;
allow timidity_t self:unix_stream_socket create_stream_socket_perms;
allow timidity_t devpts_t:dir search;
allow timidity_t self:capability { dac_override dac_read_search }; allow timidity_t self:process getsched;
Both te and fc files merged.
Quoted 18 lines · Thomas Bleher
Quoted 6 lines · Russell Coker
Quoted 3 lines · Thomas Bleher
Timidity can be used as alsa sequencer client and run as a daemon (when started as timidity -iA). Attached policy allows this to work on a SELinux system.
Quoted 6 lines
allow
timidity_ttmpfs_t:file { read write };That is wrong. Should be
tmpfs_domain(timidity).Also for the
unix_stream_socketaccess I think that there's no reason not to usecreate_stream_socket_permsaccess.Thanks for your comments!
A new version of timidity.te is attached.Thomas
Signature · 7 lines
James Carter <[email protected]> National Security Agency -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.