Android 权限分析

Android 6.0权限全面详细分析和解决方案  https://www.cnblogs.com/l2rf/p/5937490.html


系统预制应用,可以在DefaultPermissionGrantPolicy.java中授予运行时权限。

DefaultPermissionGrantPolicy.java

    public void grantDefaultPermissions(int userId) {
        if (mService.hasSystemFeature(PackageManager.FEATURE_EMBEDDED, 0)) {
            grantAllRuntimePermissions(userId);
        } else {
            grantPermissionsToSysComponentsAndPrivApps(userId);
            grantDefaultSystemHandlerPermissions(userId);
            grantDefaultPermissionExceptions(userId);
        }
    }

猜你喜欢

转载自blog.csdn.net/lin20044140410/article/details/80021119