Skip to content

Commit

Permalink
vince: sepolicy: Allow system server access to keylayouts on vendor
Browse files Browse the repository at this point in the history
  • Loading branch information
Demon000 authored and waiser86 committed Apr 8, 2019
1 parent 7468979 commit 3950d40
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sepolicy/file.te
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ type fingerprint_data_file, data_file_type, file_type;
type fingerprint_persist_file, file_type;
type sysfs_fpc_dev, sysfs_type, fs_type;

# Input devices
type idc_file, file_type, vendor_file_type;
type keylayout_file, file_type, vendor_file_type;

# Rild
type rild_file, file_type, vendor_file_type;

Expand Down
4 changes: 4 additions & 0 deletions sepolicy/file_contexts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@
# IR
/dev/peel_ir u:object_r:lirc_device:s0

# Input devices
/(vendor|system/vendor)/usr/idc(/.*)? u:object_r:idc_file:s0
/(vendor|system/vendor)/usr/keylayout(/.*)? u:object_r:keylayout_file:s0

# Location
/data/vendor/location/xtra/socket_hal_xtra u:object_r:location_socket:s0

Expand Down
4 changes: 4 additions & 0 deletions sepolicy/system_server.te
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,7 @@ allow system_server proc_touchpanel:dir search;
allow system_server proc_touchpanel:file rw_file_perms;

allow system_server sysfs_vibrator:file read;

# Input devices
r_dir_file(system_server, idc_file);
r_dir_file(system_server, keylayout_file);

0 comments on commit 3950d40

Please sign in to comment.