I used
//Analytics
compile 'com.google.firebase:firebase-core:9.2.1'
// Crash
compile 'com.google.firebase:firebase-crash:9.2.1'
and obtained those guys in my generated manifest:
<!-- Required permission for App measurement to run. -->
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<!-- Optional permission for App measurement to run. -->
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
Then we have the following block
<permission
android:name="my.package.name.permission.C2D_MESSAGE"
android:protectionLevel="signature" />
<uses-permission android:name="my.package.name.permission.C2D_MESSAGE" />
My questions:
If I use only Firebase Analytics and Crash and don't need any messaging functional, is it Ok to remove the second block as follows:
<uses-permission android:name="my.package.name.permission.C2D_MESSAGE" tools:node="remove" />
What does it mean "Optional permission for App measurement to run" in the first block? Is it safe to remove that too?