0

I recently upgraded my (rooted) Oneplus 3 to Nougat, and Adaway - which modifys the hosts file broke.

I have been unable to get symlinking the hosts file to work because SELinux gets in the way. Unfortunately I appear to be unable to remount /system rw temporarily, presumably due to a large number of processes started from it at boot.

I believe I can hack the ROM to mount /system RW instead of RO, however I'm uncertain whether mounting /system rw or disabling SELinux is less secure. If I disable SELinux, I need to do it permanently - otherwise the hosts file is unavailable.

1 Answer 1

1

I'm not an expert, but disabling SELinux is almost certainly more insecure.

Nothing that's not already in /system should be able to write there without root in either case, or an exploit that would let malicious code remount it anyways. But disabling SELinux hamstrings Android's process sandboxing and access controls, meaning a malicious app could modify or steal data from others.

1
  • Did we have SELinux back when Android was on JB?
    – Grimoire
    Mar 31, 2017 at 12:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .