1# nfc subsystem
2type nfc_hal_pn54x, domain;
3type nfc_hal_pn54x_exec, exec_type, file_type;
4
5# may be started by init
6init_daemon_domain(nfc_hal_pn54x)
7
8allow nfc_hal_pn54x nfc_hal_pn54x_exec:file rx_file_perms;
9
10# hwbinder access
11hwbinder_use(nfc_hal_pn54x)
12
13# call into NFC process (callbacks)
14binder_call(nfc_hal_pn54x, nfc)
15
16# Set NFC properties
17set_prop(nfc_hal_pn54x, nfc_prop)
18
19# NFC device access.
20allow nfc_hal_pn54x nfc_device:chr_file rw_file_perms;
21
22# Data file accesses.
23allow nfc_hal_pn54x nfc_vendor_data_file:dir create_dir_perms;
24allow nfc_hal_pn54x nfc_vendor_data_file:notdevfile_class_set create_file_perms;
25
26allow nfc_hal_pn54x sysfs_nfc_power_writable:file rw_file_perms;
27allow nfc_hal_pn54x sysfs:file write;
28
29# TODO: added to match above sysfs rule. Remove me?
30allow nfc_hal_pn54x sysfs_usb:file write;
31