Search code examples
androidandroid-permissionsandroid-9.0-pie

Phone Permission in android PIE


recently my clients are reporting some crashes about one of my apps, in that app I needed IMEI of the device to make sure the uniqueness of the users. now in Android Pie we can't access IMEI, whats the alternative now, since there are a lot of my users are signed in, I can't just change the IMEI code to another code.


Solution

  • Starting in Android Q, apps must have the READ_PRIVILEGED_PHONE_STATE privileged permission in order to access the device's non-resettable identifiers, which include both IMEI and serial number.

    Source: https://developer.android.com/preview/privacy/data-identifiers