From ad10d10849214dc47f7e7fa1af04d95a47b1ff9a Mon Sep 17 00:00:00 2001 From: Stephen Smalley <sds@tycho.nsa.gov> Date: Tue, 18 Mar 2014 10:45:15 -0400 Subject: [PATCH] DO NOT MERGE: partial backport of 08461cb03948e911090a4ab32954ccac67d6409e Original change: Allow netd-spawned domains to use inherited netd unix_dgram_socket. Resolves denials such as: avc: denied { read write } for pid=4346 comm="hostapd" path="socket:[7874]" dev="sockfs" ino=7874 scontext=u:r:hostapd:s0 tcontext=u:r:netd:s0 tclass=unix_dgram_socket avc: denied { read write } for pid=4348 comm="dnsmasq" path="socket:[7874]" dev="sockfs" ino=7874 scontext=u:r:dnsmasq:s0 tcontext=u:r:netd:s0 tclass=unix_dgram_socket Change-Id: Iebbbf8f9f31b56ec5b158dda93101472c25e638d Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov> --- hostapd.te | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hostapd.te b/hostapd.te index efa3a8d53..f4a8fea03 100644 --- a/hostapd.te +++ b/hostapd.te @@ -15,8 +15,10 @@ allow hostapd wifi_data_file:sock_file { create setattr write unlink }; allow hostapd netd:fd use; allow hostapd netd:udp_socket { read write }; +allow hostapd netd:fifo_file { read write }; +# TODO: Investigate whether these inherited sockets should be closed on exec. allow hostapd netd:netlink_kobject_uevent_socket { read write }; allow hostapd netd:netlink_nflog_socket { read write }; allow hostapd netd:netlink_route_socket { read write }; allow hostapd netd:unix_stream_socket { read write }; -allow hostapd netd:fifo_file { read write }; +allow hostapd netd:unix_dgram_socket { read write }; -- GitLab