scottyab / rootbeer

Simple to use root checking Android library and sample app
Apache License 2.0
2.5k stars 442 forks source link

SeLinux test is inverted #179

Closed fmcnunes closed 2 months ago

fmcnunes commented 3 years ago

Hi,

SeLinux test in file CheckForRootWorker.kt appers to be wrong:

Line 24 RootItemResult("SE linux Flag Is Enabled", Utils.isSelinuxFlagInEnabled()),

It should be:

Line 24 RootItemResult("SE linux Flag Is Enabled", ! Utils.isSelinuxFlagInEnabled()),

SeLinixFlagedEnabled() result true is a good result, means thatSecurity-Enhanced Linux (ro.build.selinux set to 1) is activated, but the sign it as a bad result.

Best regards Fernando Nunes

VD171 commented 7 months ago

Selinux is returning a false positive.

scottyab commented 2 months ago

Removed the Selinux method in 0.1.1 given it's not accessible on later versions of Android and is not "truly" an isRooted indicator. Thanks for flagging this issue.