基本思路,找到配置文件,配置需要默认允许的权限,如android:protectionLevel="dangerous"改为android:protectionLevel="normal"
1.找到文件frameworks/base/core/res/AndroidManifest.xml,修改某个权限的级别
<permission android:name="android.permission.READ_PHONE_STATE"
android:permissionGroup="android.permission-group.UNDEFINED"
android:label="@string/permlab_readPhoneState"
android:description="@string/permdesc_readPhoneState"
- android:protectionLevel="dangerous" />
+ android:protectionLevel="normal" />
<!-- Allows read access to the device's phone number(s). This is a subset of the capabilities granted by {@link #READ_PHONE_STATE} but is exposed to instant applications.
<p>Protection level: dangerous-->
<permission android:name="android.permission.RECORD_AUDIO
android:permissionGro
|