Skip to contentSkip to conversation

new snort policy

DISCUSSION Russell Coker 1 participant 1 message Mar 16, 2003 SELinux security module

lore
Share & tools
lore
#0 lore raw

Someone reported some problems with the snort policy so I re-wrote it to use the daemon_domain macro. It's now smaller, simpler, and works better.

Please merge it in the CVS tree.

Signature · 4 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

#DESC Snort - Network sniffer
#
# Author: Shaun Savage <[email protected]> # Modified by Russell Coker <[email protected]> #

daemon_domain(snort)

log_domain(snort)
can_network(snort_t)
type snort_etc_t, file_type, sysadmfile;

# Create temporary files.
tmp_domain(snort)

# use iptable netlink
allow snort_t self:netlink_socket create_socket_perms;
allow snort_t self:packet_socket create_socket_perms;
allow snort_t self:capability { setgid setuid net_admin net_raw };

r_dir_file(snort_t, snort_etc_t)
allow snort_t etc_t:file { getattr read };
allow snort_t etc_t:lnk_file read;

allow snort_t self:unix_dgram_socket create_socket_perms; allow snort_t self:unix_stream_socket create_socket_perms;

# for start script
allow initrc_t snort_etc_t:file read;