XF - Android - SMS and Call Log Permissions violation. (Not in manifest)

MCvelMCvel USMember ✭✭✭

I have an app built in Xamarin.Forms and I'm in the middle of publishing to the stores,

iOS version is already approved.
Android, ** approved **then **removed ** by:

Violation of the Permissions policy
SMS and Call Log Permissions are subject to additional restrictions.....

and they have these options:
Option 1) If your app does not require access to Call Log or SMS permissions:
Option 2) If your app’s use case is not eligible but you require additional time to make the necessary changes to your app
Option 3) If your app is a default handler, or you believe your app qualifies for an exception

the weird thing here is, I don't request any of those permissions at all, my app neither send/receive sms, or read/write call logs or perform calls and I don't have anything regarding these permissions in my Manifest nor the merged Manifest

what I do have in my Android Manifest is the following:

        <permission android:name="com.myapp.xamarin.permission.C2D_MESSAGE" android:protectionLevel="signature" />
            <uses-permission android:name="android.permission.USE_FINGERPRINT" />
            <uses-permission android:name="com.samsung.android.providers.context.permission.WRITE_USE_APP_FEATURE_SURVEY" />
            <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
            <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
            <uses-permission android:name="android.permission.WAKE_LOCK" />
                <uses-permission android:name="com.myapp.xamarin.permission.C2D_MESSAGE" />
            <uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
            <uses-permission android:name="android.permission.INTERNET" />
            <uses-permission android:name="android.permission.GET_ACCOUNTS" tools:node="remove" />
            <application android:label="My App Name" android:icon="@drawable/icon">
                <receiver android:name="com.google.firebase.iid.FirebaseInstanceIdInternalReceiver" android:exported="false" />
                <receiver android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver" android:exported="true" android:permission="com.google.android.c2dm.permission.SEND">
                    <intent-filter>
                        <action android:name="com.google.android.c2dm.intent.RECEIVE" />
                        <action android:name="com.google.android.c2dm.intent.REGISTRATION" />
                        <category android:name="com.myapp.xamarin" />
                    </intent-filter>
                </receiver>
                <meta-data android:name="com.google.firebase.messaging.default_notification_icon" android:resource="@drawable/icon_pn" />
            </application>

so, yes, I'm using Xamarin.Firebase to perform push notifications in my app, so, I don't know if internally is requesting those permissions or something,
or how the 'GET_ACCOUNTS' permissions is added after the manifest merge,

I already tried, removing manually all those permissions from the manifest, following this: https://support.hockeyapp.net/kb/client-integration-android/hockeyapp-for-android-sdk#4-7-1-removing-external-storage-permission

which basically is adding this in the manifest:
<uses-permission android:name="android.permission.READ_SMS" tools:node="remove" />

does anyone have any idea on how to approach this issue, I've also been looking into the documentation of all 3rd party libraries that I have, to see if there's something regarding these permissions but no luck so far,

any idea, comment will be much appreciated,

thanks folks!

Best Answer

  • MCvelMCvel US ✭✭✭
    Accepted Answer

    Nevermind!, I was able to fix it,
    I removed the line
    <uses-permission android:name="android.permission.GET_ACCOUNTS" />
    from the Manifest file,

    and also remove it from the AssemblyInfo.cs

    [assembly: UsesPermission(Android.Manifest.Permission.ReceiveWapPush)]
    [assembly: UsesPermission(Name = "android.permission.GET_ACCOUNTS")]
    

    cheers!

Answers

  • MCvelMCvel USMember ✭✭✭
    Accepted Answer

    Nevermind!, I was able to fix it,
    I removed the line
    <uses-permission android:name="android.permission.GET_ACCOUNTS" />
    from the Manifest file,

    and also remove it from the AssemblyInfo.cs

    [assembly: UsesPermission(Android.Manifest.Permission.ReceiveWapPush)]
    [assembly: UsesPermission(Name = "android.permission.GET_ACCOUNTS")]
    

    cheers!

  • jezhjezh Member, Xamarin Team Xamurai

    Congrats, and thanks for your sharing the solution.

Sign In or Register to comment.