summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--peripheral/libwireless/sepolicy/file_contexts3
-rw-r--r--peripheral/libwireless/sepolicy/mwirelessd.te1
2 files changed, 4 insertions, 0 deletions
diff --git a/peripheral/libwireless/sepolicy/file_contexts b/peripheral/libwireless/sepolicy/file_contexts
index 5334e34..87f648f 100644
--- a/peripheral/libwireless/sepolicy/file_contexts
+++ b/peripheral/libwireless/sepolicy/file_contexts
@@ -1,2 +1,5 @@
/data/misc/wireless(/.*)? u:object_r:wireless_data_file:s0
/system/bin/wireless_daemon u:object_r:mwirelessd_exec:s0
+
+# Label the socket to communicate with wireless_daemon
+/data/misc/wireless/socket_daemon u:object_r:mwirelessd_socket:s0
diff --git a/peripheral/libwireless/sepolicy/mwirelessd.te b/peripheral/libwireless/sepolicy/mwirelessd.te
index 2753a05..19a066e 100644
--- a/peripheral/libwireless/sepolicy/mwirelessd.te
+++ b/peripheral/libwireless/sepolicy/mwirelessd.te
@@ -20,5 +20,6 @@ allow mwirelessd wireless_data_file:file create_file_perms;
allow mwirelessd wireless_data_file:sock_file create_file_perms;
allow mwirelessd self:capability { setuid setgid sys_module };
+allow mwirelessd mwirelessd_socket:sock_file unlink;
dontaudit mwirelessd property_socket:sock_file create_file_perms;