banditoth / MAUI.Packages

A toolkit for .NET MAUI 🏝, containing useful stuff to ease development for MAUI applications.
MIT License
39 stars 3 forks source link

Android root/Jailbreak detection won't detect Rooting/cloaking/dangerous apps #13

Open ronan-burke-civ opened 5 months ago

ronan-burke-civ commented 5 months ago

I've been doing a little bit of investigation and I don't believe the check for rooting apps such as Magisk will succeed based on setting up the app according to the documentation (even if you have something like Magisk installed, the root detection will not detect it and mark the device as not rooted).

I think the following would need to be added to the setup documentation for Android:

The permission QUERY_ALL_PACKAGES permission is another option, but Google heavily restricts its usage since it gives access to sensitive data: https://support.google.com/googleplay/android-developer/answer/10158779?hl=en-GB The above <queries> list may be too overreaching as well and be rejected by Google Play review.

Pmr-precure commented 5 months ago

I just tested with a device with Magisk and it didnt detect it.

ronan-burke-civ commented 5 months ago

I just tested with a device with Magisk and it didnt detect it.

If you add the config above, does it work @Pmr-precure ? I think this might be mainly a documentation / setup issue.

Pmr-precure commented 4 months ago

I just tested with a device with Magisk and it didnt detect it.

If you add the config above, does it work @Pmr-precure ? I think this might be mainly a documentation / setup issue.

Sorry for the late answer, i didnt try with the queries, but i dont want to risk it getting rejected on play store, you think it will?

ronan-burke-civ commented 4 months ago

I think Google is likely to scrutinise QUERY_ALL_PACKAGES and reject submissions with it that don't require it for their main purpose. The smaller, fixed list is maybe more likely to pass review.

However, I think one of the options is required for more comprehensive "root detection". You should be able to test it locally before submitting to the store to see if it detects Magisk for you. Ultimately then it would be your call to decide to submit it to the Play Store or not.