From 57e9946fb701699668e5f06382e7f803bd68a7c4 Mon Sep 17 00:00:00 2001
From: Jiyong Park <jiyong@google.com>
Date: Wed, 29 Mar 2017 23:26:57 +0900
Subject: [PATCH] Annotate rild with socket_between_core_and_vendor_violators

Full treble targets cannot have sockets between framework and vendor
processes. In theory, this should not affect aosp_arm64_ab where only
framework binaries are built. However, /system/sepolicy has rild.te
which is now vendor binary and this causes neverallow conflict when
building aosp_arm64_ab.

So, we just temporarily annotate the rild with
socket_between_core_and_vendor_violators so that the neverallow conflict
can be avoided.

Test: choosecombo 1 aosp_arm64_ab userdebug; m -j 80 The build should
not break.

Change-Id: I260757cde96857cc3f539d5f82ca69c50653f8c7
---
 vendor/rild.te | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/vendor/rild.te b/vendor/rild.te
index 515d1b499..69c5c3983 100644
--- a/vendor/rild.te
+++ b/vendor/rild.te
@@ -2,3 +2,7 @@
 # public, but conceptually should go with this
 type rild_exec, exec_type, file_type;
 init_daemon_domain(rild)
+
+# TODO(b/36613472), TODO(b/36718031): Remove this once rild no longer
+# communicates with non-vendor components over sockets.
+typeattribute rild socket_between_core_and_vendor_violators;
-- 
GitLab