2dc4d1cc1c
The camera HAL1 will need to pass/receive FD from various related processes (app/surfaceflinger/medaiserver) Change-Id: Ia6a6efdddc6e3e92c71211bd28a83eaf2ebd1948
31 lines
1.2 KiB
Text
31 lines
1.2 KiB
Text
# HwBinder IPC from clients to server and callbacks
|
|
binder_call(hal_camera_client, hal_camera_server)
|
|
binder_call(hal_camera_server, hal_camera_client)
|
|
|
|
# access /data/misc/camera
|
|
allow hal_camera camera_data_file:dir create_dir_perms;
|
|
allow hal_camera camera_data_file:file create_file_perms;
|
|
|
|
allow hal_camera video_device:dir r_dir_perms;
|
|
allow hal_camera video_device:chr_file rw_file_perms;
|
|
allow hal_camera camera_device:chr_file rw_file_perms;
|
|
allow hal_camera ion_device:chr_file rw_file_perms;
|
|
# Both the client and the server need to use the graphics allocator
|
|
allow { hal_camera_client hal_camera_server } hal_graphics_allocator:fd use;
|
|
|
|
# Allow fd to be passed between hal_camera related processes
|
|
allow hal_camera { appdomain -isolated_app }:fd use;
|
|
allow { appdomain -isolated_app } hal_camera:fd use;
|
|
allow hal_camera surfaceflinger:fd use;
|
|
allow mediaserver hal_camera:fd use;
|
|
|
|
###
|
|
### neverallow rules
|
|
###
|
|
|
|
# hal_camera should never execute any executable without a
|
|
# domain transition
|
|
neverallow hal_camera { file_type fs_type }:file execute_no_trans;
|
|
|
|
# hal_camera should never need network access. Disallow network sockets.
|
|
neverallow hal_camera domain:{ tcp_socket udp_socket rawip_socket } *;
|