Create unique labels for /dev/snd/{seq,timer}
No core android component needs access to /dev/snd/{seq,timer}, but
currently audioserver, bootanim, init, system_server and ueventd have
access. Seq and timer have been the source of many bugs in the past
[1]. Giving these files new labels without explicitly granting access
removes access from audioserver, bootanim, and system_server.
Init and ueventd still require access for /dev setup.
TODO: Explore unsetting CONFIG_SND_TIMER device kernels.
[1] https://github.com/google/syzkaller/wiki/Found-Bugs
Test: media CTS "cts-tradefed run cts -m CtsMediaTestCases" on Bullhead
and Dragon completed with no denials.
Bug: 29045223
(cherry picked from commit db4510d87a70784ce469f05180956cd057424ae2)
Change-Id: I2d069920e792ce8eef70c7b4a038b9e7000f39f5
2 files changed