Android Question Still get “SMS and CALL_LOG permissions warning”

scsjc

Well-Known Member
Licensed User
Longtime User
Hi, I have the same problem that I have seen that someone else has written in the forum.

I do not understand why I get the notification of SMS and CALL_LOG, but use those permissions in the app:

upload_2019-1-7_16-9-6.png



I have added this code in the manifest, but I do not know if it is a good idea and if it will work:


B4X:
RemovePermission("android.permission.READ_CALL_LOG")
RemovePermission("android.permission.WRITE_CALL_LOG")
RemovePermission("android.permission.WRITE_SMS")
RemovePermission("android.permission.READ_SMS")

Has someone been able to solve it in any other way?
thanks :)
 

walterf25

Expert
Licensed User
Longtime User
Hi, I have the same problem that I have seen that someone else has written in the forum.

I do not understand why I get the notification of SMS and CALL_LOG, but use those permissions in the app:

View attachment 76058


I have added this code in the manifest, but I do not know if it is a good idea and if it will work:


B4X:
RemovePermission("android.permission.READ_CALL_LOG")
RemovePermission("android.permission.WRITE_CALL_LOG")
RemovePermission("android.permission.WRITE_SMS")
RemovePermission("android.permission.READ_SMS")

Has someone been able to solve it in any other way?
thanks :)
Are you using a library that maybe adds these permissions internally?

Estas usando halguna libreria que quiza usa estos permisos internamente?

Walter
 
Upvote 0

scsjc

Well-Known Member
Licensed User
Longtime User
Open the generated AndroidManifest.xml file. Do you see these permissions?

i dont see:

B4X:
<?xml version="1.0" encoding="utf-8"?>
<manifest
    xmlns:android="http://schemas.android.com/apk/res/android"
    package="xxxxxxxxxxxxxxxxxxxxxx"
    android:versionCode="xxxx"
    android:versionName="xxxx"
    android:installLocation="auto">
  
    <uses-permission android:name="android.permission.GET_ACCOUNTS" />
    <uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT"/>
    <uses-sdk android:minSdkVersion="14" android:targetSdkVersion="26"/>
      <uses-feature android:name="android.hardware.telephony" android:required="false" />
      <uses-feature android:name="android.hardware.bluetooth" android:required="false" />
      <uses-feature android:name="android.hardware.camera" android:required="false"/>
      <uses-feature android:name="android.hardware.camera.front" android:required="false"/>
      <uses-feature android:name="android.hardware.camera.autofocus" android:required="false"/>
      <uses-feature android:name="android.hardware.camera.flash" android:required="false"/>
      <uses-feature android:name="android.hardware.wifi" android:required="false"/>
      <uses-feature android:name="android.hardware.touchscreen" android:required="false"/>
    <supports-screens android:largeScreens="true"
        android:normalScreens="true"
        android:smallScreens="true"
        android:anyDensity="true"/>
    <permission android:name="com.xxxxxxxxxxxxxxxxx.permission.C2D_MESSAGE"
      android:protectionLevel="signature" />
    <uses-permission android:name="android.permission.INTERNET"/>
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
    <uses-permission android:name="android.permission.BIND_WALLPAPER"/>
    <uses-permission android:name="android.permission.SET_WALLPAPER"/>
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
    <uses-permission android:name="android.permission.BLUETOOTH"/>
    <uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
    <uses-permission android:name="android.permission.VIBRATE"/>
    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
    <uses-permission android:name="android.permission.WAKE_LOCK"/>
    <uses-permission android:name="android.permission.CAMERA"/>
    <uses-permission android:name="android.permission.FLASHLIGHT"/>
    <uses-permission android:name="com.google.android.c2dm.permission.RECEIVE"/>
    <uses-permission android:name="com.xxxxxxxxxxxx.permission.C2D_MESSAGE"/>
    <uses-permission android:name="com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE"/>
    <application
        android:name="android.support.multidex.MultiDexApplication"
        android:icon="@drawable/icon"
        android:label="xxxxxxx"
        android:hardwareAccelerated="true"
        android:largeHeap="true"
        android:theme="@style/MyAppTheme">
      
        <provider
                    android:name="com.crashlytics.android.CrashlyticsInitProvider"
                    android:authorities="com.xxxxxxxxxxxx.crashlyticsinitprovider"
                    android:exported="false"
                    android:initOrder="100" />
        <provider
            android:name="android.support.v4.content.FileProvider"
            android:authorities="com.xxxxxxxxxxxx.provider"
            android:exported="false"
            android:grantUriPermissions="true">
            <meta-data
            android:name="android.support.FILE_PROVIDER_PATHS"
            android:resource="@xml/provider_paths"/>
        </provider>
        <activity android:name="com.google.android.gms.common.api.GoogleApiActivity"
          android:theme="@android:style/Theme.Translucent.NoTitleBar"
          android:exported="false"/>
            <meta-data
          android:name="com.google.android.gms.version"
          android:value="@integer/google_play_services_version" />
        <receiver
                    android:name="com.google.android.gms.measurement.AppMeasurementReceiver"
                    android:enabled="true"
                    android:exported="false" >
                </receiver>
      
          <service
                    android:name="com.google.android.gms.measurement.AppMeasurementService"
                    android:enabled="true"
                    android:exported="false" />
                  
         <receiver
                    android:name="com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver"
                    android:enabled="true"
                    android:exported="true"
                    android:permission="android.permission.INSTALL_PACKAGES" >
                    <intent-filter>
                        <action android:name="com.android.vending.INSTALL_REFERRER" />
                    </intent-filter>
        </receiver>
        <service
                    android:name="com.google.android.gms.measurement.AppMeasurementJobService"
                    android:enabled="true"
                    android:exported="false"
                    android:permission="android.permission.BIND_JOB_SERVICE" />
      
         <service android:name="com.google.firebase.components.ComponentDiscoveryService" >
                    <meta-data
                        android:name="com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar"
                        android:value="com.google.firebase.components.ComponentRegistrar" />
                     <meta-data
                        android:name="com.google.firebase.components:com.google.firebase.iid.Registrar"
                        android:value="com.google.firebase.components.ComponentRegistrar" />
                     <meta-data
                        android:name="com.google.firebase.components:com.google.firebase.auth.FirebaseAuthRegistrar"
                        android:value="com.google.firebase.components.ComponentRegistrar" />
        </service>
           <provider
          android:authorities="com.xxxxxxxxxxxx.firebaseinitprovider"
          android:name="com.google.firebase.provider.FirebaseInitProvider"
          android:exported="false"
          android:initOrder="100" />
        
           <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.xxxxxxxxxxxx" />
          </intent-filter>
          </receiver>
            <receiver
          android:name="com.google.firebase.iid.FirebaseInstanceIdInternalReceiver"
          android:exported="false" />
      
      
          <service
          android:name="com.google.firebase.iid.FirebaseInstanceIdService"
          android:exported="true">
          <intent-filter android:priority="-500">
          <action android:name="com.google.firebase.INSTANCE_ID_EVENT" />
          </intent-filter>
          </service>
        <service
          android:name="com.google.firebase.messaging.FirebaseMessagingService"
          android:exported="true">
          <intent-filter android:priority="-500">
          <action android:name="com.google.firebase.MESSAGING_EVENT" />
          </intent-filter>
          </service>
           <service android:name="anywheresoftware.b4a.objects.FirebaseNotificationsService">
             <intent-filter>
          <action android:name="com.google.firebase.MESSAGING_EVENT"/>
             </intent-filter>
           </service>
        <activity
                    android:name="com.google.firebase.auth.internal.FederatedSignInActivity"
                    android:excludeFromRecents="true"
                    android:exported="true"
                    android:launchMode="singleInstance"
                    android:permission="com.google.firebase.auth.api.gms.permission.LAUNCH_FEDERATED_SIGN_IN"
                    android:theme="@android:style/Theme.Translucent.NoTitleBar" />
      
                    <activity
                    android:name="com.google.android.gms.auth.api.signin.internal.SignInHubActivity"
                    android:excludeFromRecents="true"
                    android:exported="false"
                    android:theme="@android:style/Theme.Translucent.NoTitleBar" />
      
                <!--
                    Service handling Google Sign-In user revocation. For apps that do not integrate with
                    Google Sign-In, this service will never be started.
                -->
                <service
                    android:name="com.google.android.gms.auth.api.signin.RevocationBoundService"
                    android:exported="true"
                    android:permission="com.google.android.gms.auth.api.signin.permission.REVOCATION_NOTIFICATION" />
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".main"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
            <intent-filter>
               <action android:name="android.intent.action.MAIN" />
               <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
          
        </activity>
        <service android:name=".starter">
        </service>
        <receiver android:name=".starter$starter_BR">
        </receiver>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".edicion"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".preferencias"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".infocuenta"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".login"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <service android:name=".firebasemessaging">
        </service>
        <receiver android:name=".firebasemessaging$firebasemessaging_BR">
        </receiver>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".edit"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <service android:name=".downloadservice">
        </service>
        <receiver android:name=".downloadservice$downloadservice_BR">
        </receiver>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".pdfview"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".catalogo"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".muestraimagen"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".camera"
            android:label="xxxxxxx"
            android:screenOrientation="portrait"
            android:theme="@android:style/Theme.Translucent.NoTitleBar">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".cropimage"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".pdfwebview"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".condiciones"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".firmar"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".scanner"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".buscador"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".votacion"
            android:label="xxxxxxx"
            android:screenOrientation="portrait"
            android:theme="@android:style/Theme.Translucent.NoTitleBar">
        </activity>
        <activity
            android:windowSoftInputMode="stateHidden"
            android:launchMode="singleTop"
            android:name=".firmarprotecciondatos"
            android:label="xxxxxxx"
            android:screenOrientation="portrait">
        </activity>
        <service android:name=".httputils2service">
        </service>
        <receiver android:name=".httputils2service$httputils2service_BR">
        </receiver>
    </application>
</manifest>
 
Last edited:
Upvote 0

scsjc

Well-Known Member
Licensed User
Longtime User
Assuming that it is not in the list you posted, you should post the full manifest editor code.

B4X:
AddManifestText(
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT"/>
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="26"/>
  <uses-feature android:name="android.hardware.telephony" android:required="false" />
  <uses-feature android:name="android.hardware.bluetooth" android:required="false" />
  <uses-feature android:name="android.hardware.camera" android:required="false"/>
  <uses-feature android:name="android.hardware.camera.front" android:required="false"/>
  <uses-feature android:name="android.hardware.camera.autofocus" android:required="false"/>
  <uses-feature android:name="android.hardware.camera.flash" android:required="false"/>
  <uses-feature android:name="android.hardware.wifi" android:required="false"/>
  <uses-feature android:name="android.hardware.touchscreen" android:required="false"/>
<supports-screens android:largeScreens="true"
    android:normalScreens="true"
    android:smallScreens="true"
    android:anyDensity="true"/>)
SetApplicationAttribute(android:icon, "@drawable/icon")
SetApplicationAttribute(android:label, "$LABEL$")
SetApplicationAttribute(android:hardwareAccelerated, "true")
SetApplicationAttribute(android:largeHeap,"true")
SetManifestAttribute("android:installLocation", "auto")
AddPermission(android.permission.WRITE_EXTERNAL_STORAGE)
AddPermission(android.permission.INTERNET)
AddPermission(android.permission.ACCESS_FINE_LOCATION)
AddPermission(android.permission.ACCESS_COARSE_LOCATION)
AddPermission("android.permission.VIBRATE")
AddPermission("android.permission.CAMERA")
AddPermission("android.permission.FLASHLIGHT")


'******** crashlytics ********
AddApplicationText(
 <provider
            android:name="com.crashlytics.android.CrashlyticsInitProvider"
            android:authorities="$PACKAGE$.crashlyticsinitprovider"
            android:exported="false"
            android:initOrder="100" />
           )
CreateResource(values, com_crashlytics_build_id.xml,
<resources xmlns:tools="http://schemas.android.com/tools">
<string tools:ignore="UnusedResources,,TypographyDashes" name="com.crashlytics.android.build_id"
   translatable="false">xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx</string>
</resources>)

SetActivityAttribute(camera, android:theme, @android:style/Theme.Translucent.NoTitleBar)
SetActivityAttribute(votacion, android:theme, @android:style/Theme.Translucent.NoTitleBar)
SetApplicationAttribute(android:theme, "@style/MyAppTheme")
CreateResource(values, theme.xml,
    <resources>
        <style name="MyAppTheme" parent="@style/Theme.AppCompat.Light.DarkActionBar">
            <item name="colorPrimary">#ffffff</item>
            <item name="colorPrimaryDark">#00849d</item>
            <item name="colorAccent">#009bb8</item>
            <item name="windowNoTitle">true</item>
            <item name="windowActionBar">false</item>
            <item name="windowActionModeOverlay">true</item>
            <item name="android:statusBarColor">@android:color/transparent</item>
            <item name="android:windowDrawsSystemBarBackgrounds">true</item>
            <item name="android:navigationBarColor">#000000</item>
        </style>
    </resources>
)


'acceso paths share
AddApplicationText(
<provider
    android:name="android.support.v4.content.FileProvider"
    android:authorities="$PACKAGE$.provider"
    android:exported="false"
    android:grantUriPermissions="true">
    <meta-data
    android:name="android.support.FILE_PROVIDER_PATHS"
    android:resource="@xml/provider_paths"/>
</provider>
)
CreateResource(xml, provider_paths,
    <files-path name="name" path="shared" />
)
CreateResourceFromFile(Macro, FirebaseAnalytics.GooglePlayBase)
CreateResourceFromFile(Macro, FirebaseAnalytics.Firebase)
CreateResourceFromFile(Macro, FirebaseNotifications.FirebaseNotifications)
CreateResourceFromFile(Macro, FirebaseAnalytics.FirebaseAnalytics)
CreateResourceFromFile(Macro, FirebaseAuth.FirebaseAuth)
 
Upvote 0

scsjc

Well-Known Member
Licensed User
Longtime User
Sorry, I misread your previous post. I thought that you see the contacts permission in the manifest file.

I don't think that there is any problem in your code. It looks like a Google Play issue.
thank you :)
 
Upvote 0
Top