What is the meaning of "avc: denied { read } for name..." line in logcat? [duplicate]
Asked Answered
S

1

17

I am wondering about avc: denied messages in my logcat.

W/RenderThread: type=1400 audit(0.0:631436): avc: denied { read } for name="perf_ioctl" dev="proc" ino=4026533695 scontext=u:r:untrusted_app_25:s0:c512,c768 tcontext=u:object_r:proc:s0 tclass=file permissive=0

What is the meaning of this?

Semirigid answered 8/7, 2018 at 11:2 Comment(1)
resolved issue? Please post nswer if yes!Indus
M
13

It's depends of SELinux restrictions. You cannot do so much to avoid it.

In easy words: it means that there is "someone" that has tried to "{read}" something but SELinux stops it because that App wasn't found in the "trusted" list of SELinux. Usually some specific and dangerous locations of the System are restricted from installed Apps, so SELinux stops to read/wrote/execute things in/from that locations.

(1) An Enforcing SELinux writes that Log AND denied the access. (2) A Permissive SELinux writes that Log BUT allow the access. (3) A Disabled SELinux do NOT writes the log AND allow the access.

To avoid it you should rebuild the ROM after changed specific files about SELinux where you have to add your App in the "trusted zone".

You can install a different Kernel with a different SELinux settings.

Meridithmeriel answered 8/7, 2018 at 11:21 Comment(5)
the is an apk on xda named selinux switcher forum.xda-developers.com/t/… it lets you managed it from android; other wise there is a command native to phones that you can run in terminal but I don't remember the path and name; and it might not ship with all vendors. In both cases you need a rooted device..Barber
Why would I being seeing this on an emulator running in Windows? No Linux involved...Evolutionist
@Evolutionist Logcat shows Android's log and Android runs on Unix platform............Meridithmeriel
@Meridithmeriel I thought of that, but how do I fix it in a Windows environment?Evolutionist
It's an Android Warning message aboout Unix SELinux context....Windows is not involved there, so there isn't anything you can "fix" in/from Windows. You need to rebuild Android's Kernel/ROM using a different SELinux config files and then you can fix it.Meridithmeriel

© 2022 - 2024 — McMap. All rights reserved.