How to create new user for service in aosp??

nsuresh3

New member
Jul 29, 2024
1
0
1
Visit site
Hi
In Android 13 we are using .RC file to any service , but maximum our services are running with root user but its not a good practice. tell me how to create new user like system, audio, media etc ...

foo.rc ---> file
--------------------------------------------------
service foo /vendor/bin/foooo
user root
group media audio system
seclabel u:r:watchdogd:s0
 

Forum statistics

Threads
947,440
Messages
6,933,754
Members
3,160,781
Latest member
Buckruhe