Skip to content
Snippets Groups Projects
  • Hector Dearman's avatar
    3fa4ac55
    Allow adb root to send config to perfetto · 3fa4ac55
    Hector Dearman authored
    The perfetto binary (the frontend to traced) reads an input config
    from stdin. This CL adds allows perfetto to read the config
    from adb shell when the user is rooted
    
    Sample denials:
    avc: denied { read } for comm="perfetto" path="pipe:[92340]"
    dev="pipefs" ino=92340 scontext=u:r:perfetto:s0 tcontext=u:r:su:s0
    tclass=fifo_file permissive=0
    avc: denied { read } for comm="perfetto" path="pipe:[92491]"
    dev="pipefs" ino=92491 scontext=u:r:perfetto:s0 tcontext=u:r:su:s0
    tclass=fifo_file permissive=0
    
    Test: adb root
    adb shell
    echo 'duration_ms: 1000;' > /sdcard/config
    cat /sdcard/config | perfetto --txt -c - -d
    
    Change-Id: I12042dfa9a2c262cec907f0231ce2184f46d1be8
    3fa4ac55
    History
    Allow adb root to send config to perfetto
    Hector Dearman authored
    The perfetto binary (the frontend to traced) reads an input config
    from stdin. This CL adds allows perfetto to read the config
    from adb shell when the user is rooted
    
    Sample denials:
    avc: denied { read } for comm="perfetto" path="pipe:[92340]"
    dev="pipefs" ino=92340 scontext=u:r:perfetto:s0 tcontext=u:r:su:s0
    tclass=fifo_file permissive=0
    avc: denied { read } for comm="perfetto" path="pipe:[92491]"
    dev="pipefs" ino=92491 scontext=u:r:perfetto:s0 tcontext=u:r:su:s0
    tclass=fifo_file permissive=0
    
    Test: adb root
    adb shell
    echo 'duration_ms: 1000;' > /sdcard/config
    cat /sdcard/config | perfetto --txt -c - -d
    
    Change-Id: I12042dfa9a2c262cec907f0231ce2184f46d1be8