mirror of
https://github.com/mvt-project/mvt.git
synced 2024-06-29 07:39:00 +00:00
Fixes bug where su binary is present but privilege is not granted to com.android.shell (#326)
This commit is contained in:
parent
013e3421c8
commit
cbd9158daf
|
@ -138,7 +138,8 @@ class AndroidExtraction(MVTModule):
|
||||||
:returns: Boolean indicating whether a `su` binary is present or not
|
:returns: Boolean indicating whether a `su` binary is present or not
|
||||||
|
|
||||||
"""
|
"""
|
||||||
return bool(self._adb_command("command -v su"))
|
result = self._adb_command("command -v su && su -c true")
|
||||||
|
return bool(result) and "Permission denied" not in result
|
||||||
|
|
||||||
def _adb_root_or_die(self) -> None:
|
def _adb_root_or_die(self) -> None:
|
||||||
"""Check if we have a `su` binary, otherwise raise an Exception."""
|
"""Check if we have a `su` binary, otherwise raise an Exception."""
|
||||||
|
|
Loading…
Reference in New Issue
Block a user