When you create the linux file node, such as “dev/nfccard0”, you must add the selinux policy for it, or the application can not get the permit to access. this is an example for the system_server to accecc the dev/nfccard0 file node. we c
When you create the linux file node, such as “dev/nfccard0”, you must add the selinux policy for it, or the application can not get the permit to access.
this is an example for the system_server to accecc the dev/nfccard0 file node.
we can do the following three things to mak the system work smoothly.
1 define the file type
in the file.te add the below line
type nfccard_device,dev_type
2 define the file context
in the file_context.te add the below line
/dev/nfccard0 u:object_r:nfccard_devicd:s0
3 allow the system_server to access it.
Allow system_server nfccard_device:chr_file rw_file_perms
Or
Allow system_server nfccard_device:chr_file {read write open getattr ioctl}
there are many file type , {socket, binder, property,etc}, we must do carefully to avoid influence the system.
每个人都需要一台速度更快、更稳定的 PC。随着时间的推移,垃圾文件、旧注册表数据和不必要的后台进程会占用资源并降低性能。幸运的是,许多工具可以让 Windows 保持平稳运行。
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号