馬上加入Android 台灣中文網,立即免費下載應用遊戲。
您需要 登錄 才可以下載或查看,沒有帳號?註冊
x
package com.madhead.tos.plugins.acs;
import android.os.Build;
import java.io.File;
public class Root
{
private static String LOG_TAG = Root.class.getName();
public static boolean checkRootMethod1()
{
String str = Build.TAGS;
return (str != null) && (str.contains("test-keys"));
}
public static boolean checkRootMethod2()
{
try
{
boolean bool = new File("/system/app/Superuser.apk").exists();
if (bool)
return true;
}
catch (Exception localException)
{
}
return false;
}
public static boolean checkRootMethod3()
{
return new ExecShell().executeCommand(ExecShell.SHELL_CMD.check_su_binary) != null;
}
public static boolean isDeviceRooted()
{
if (checkRootMethod1());
while ((checkRootMethod2()) || (checkRootMethod3()))
return true;
return false;
}
}
這樣不就有root會增加被鎖的機率? |
|