Merge "Set up access control rule for aocxd" into main

This commit is contained in:
Bowen Lai 2025-01-19 19:15:30 -08:00 committed by Android (Google) Code Review
commit f23d87650d
4 changed files with 22 additions and 1 deletions

View file

@ -1,4 +1,6 @@
BOARD_VENDOR_SEPOLICY_DIRS += device/google/gs-common/aoc/sepolicy
BOARD_VENDOR_SEPOLICY_DIRS += \
device/google/gs-common/aoc/sepolicy \
device/google/gs-common/aoc/sepolicy/allowlist
PRODUCT_PACKAGES += dump_aoc \
aocd \

View file

@ -0,0 +1,11 @@
# set up rule to control the access to aocxd
neverallow {
domain
-hwservicemanager
-servicemanager
-vndservicemanager
-system_suspend_server
-dumpstate
-hal_audio_default
-aocxdallowdomain
} aocxd:binder { call transfer };

View file

@ -0,0 +1,6 @@
# Aocx AIDL service
allow aocxdallowdomain aocx:service_manager find;
binder_call(aocxdallowdomain, aocxd)
# Allow aocxd asynchronous callback to aocxdallowdomain
binder_call(aocxd, aocxdallowdomain)

View file

@ -0,0 +1,2 @@
# Allow domain to access aocx HAL API
attribute aocxdallowdomain;