android permission issue : apk not being accepted - android

I am submitting a new version of my app. But the developer console doesn't allow me to do so. It says that my app is not compliant with the new policies for the permission (ask for permission at runtime).
But as I can see, I don't use any dangerous permission...
My app is using the following permissions (according to the developer console) :
android.permission.ACCESS_NETWORK_STATE, android.permission.ACCESS_WIFI_STATE, android.permission.INTERNET, android.permission.WAKE_LOCK
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="fr.mehfile">
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<uses-permission android:name="com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE" tools:node="remove"/>
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" tools:node="remove"/>
<!-- Keeps the processor from sleeping when a message is received. -->
<uses-permission android:name="android.permission.WAKE_LOCK" />
<application
android:icon="#drawable/ic_launcher"
android:label="#string/app_name"
android:name=".ApplicationMz">
<activity
android:name=".view.SplashScreen"
android:configChanges="keyboardHidden"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".view.Accueil"
android:configChanges="keyboardHidden"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".view.Programs"
android:configChanges="keyboardHidden"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
</activity>
<activity
android:name=".view.Infos"
android:configChanges="keyboardHidden"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".view.NousContacter"
android:configChanges="keyboardHidden"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".view.ProgramDetail"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".view.NewsList"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".view.News"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".view.TimeTable"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".view.TimeTableTab"
android:label="#string/app_name"
android:screenOrientation="portrait"
android:theme="#android:style/Theme.NoTitleBar" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<service android:name="fr.mehfile.MyFirebaseMessagingService"
android:permission="">
<intent-filter>
<action android:name="com.google.firebase.MESSAGING_EVENT" />
</intent-filter>
</service>
</application>
</manifest>
Thanks in advance for your help.

To find where permissions might be originating, you can look at the merged manifest file using Android Studio. Open your manifest file in Android Studio and the click the "Merged" tab at the bottom of the editor. Here is a picture for context:

Related

When people install my app, they get two apps

When people install my app, they get two apps (same app, two icons). Here's my AndroidManifest.xml file
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.test.test">
<uses-permission android:name="com.android.vending.BILLING" />
<uses-permission android:name="android.permission.INTERNET" />
<permission android:name="android.permission.MEDIA_CONTENT_CONTROL" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<application
android:allowBackup="true"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name"
android:supportsRtl="true"
android:theme="#style/AppTheme">
<activity
android:name=".SplashActivity"
android:theme="#style/AppTheme.SplashScreen">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".SettingsActivity" />
<activity android:name=".HistoryActivity" />
<activity
android:name=".PaymentActivity"
android:screenOrientation="portrait" />
<activity
android:name=".PlayerActivity"
android:screenOrientation="portrait" />
<activity
android:name=".SearchActivity"
android:screenOrientation="portrait" />
<activity android:name=".VideoActivity" />
<activity
android:name=".FacebookActivity"
android:screenOrientation="portrait" />
<activity
android:name=".HomeActivity"
android:screenOrientation="portrait" />
<activity
android:name=".LibraryActivity"
android:screenOrientation="portrait" />
<activity
android:name=".LoginActivity"
android:screenOrientation="portrait" />
<activity
android:name=".BookDetailActivity"
android:screenOrientation="portrait" />
<activity
android:name=".BookActivity"
android:screenOrientation="portrait" />
<activity
android:name=".CategoryActivity"
android:screenOrientation="portrait" />
<activity
android:name=".TextActivity"
android:screenOrientation="portrait" />
<activity
android:name=".MainActivity"
android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<meta-data
android:name="preloaded_fonts"
android:resource="#array/preloaded_fonts" />
<meta-data
android:name="com.facebook.sdk.ApplicationId"
android:value="#string/facebook_app_id" />
<service android:name="com.beraldo.playerlib.PlayerService" />
<receiver
android:name=".LaunchPlayerBroadcastReceiver"
android:exported="true">
<intent-filter>
<action android:name="com.beraldo.playerlib.LAUNCH_PLAYER_ACTIVITY" />
</intent-filter>
</receiver>
<activity
android:name="com.facebook.FacebookActivity"
android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation"
android:label="#string/app_name" />
</application>
</manifest>
Any help would be greatly appreciated.
You have:
<activity
android:name=".SplashActivity"
android:theme="#style/AppTheme.SplashScreen">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
and you have:
<activity
android:name=".MainActivity"
android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
Both have the <intent-filter> that says you want those activities to have icons in the launcher. If that is not what you want, remove the <intent-filter> from one of them.

Permission not available in App settings

I have declared storage permission in the manifest and try to seek user permission for SDK 23 and above. But, I found an issue, I cannot see the added permission in the app settings. I have never come across such situation. Let me know where am I doing wrong. Here are the screen shots.
Manifest File:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.kinephonics">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-feature android:name="android.hardware.camera" />
<uses-feature android:name="android.hardware.camera2.full" />
<uses-feature android:name="android.hardware.camera.autofocus" />
<application
android:name=".ui.MyApplication"
android:allowBackup="true"
android:icon="#mipmap/app_icon"
android:label="#string/app_name"
android:roundIcon="#mipmap/app_icon"
android:supportsRtl="true">
<activity
android:name=".ui.LoginActivity"
android:screenOrientation="portrait"
android:theme="#style/Theme.AppCompat.Light.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:host="www.kinephonics.com"
android:scheme="http" />
</intent-filter>
</activity>
<activity
android:name=".ui.LandingPage"
android:screenOrientation="portrait"
android:theme="#style/Theme.AppCompat.Light.NoActionBar" />
<activity
android:name=".ui.SplashScreen"
android:screenOrientation="portrait"
android:theme="#style/Theme.AppCompat.Light.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".ui.InformationActivity"
android:screenOrientation="portrait"
android:theme="#style/Theme.AppCompat.Light.NoActionBar" />
<activity
android:name=".ui.PlayerActivity"
android:screenOrientation="landscape"
android:theme="#style/Theme.AppCompat.Light.NoActionBar" />
<meta-data
android:name="com.facebook.sdk.ApplicationId"
android:value="#string/facebook_app_id" />
<activity
android:name="com.facebook.FacebookActivity"
android:configChanges="keyboard|keyboardHidden|screenLayout|screenSize|orientation"
android:label="#string/app_name" />
<activity
android:name="com.facebook.CustomTabActivity"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="#string/fb_login_protocol_scheme" />
</intent-filter>
</activity>
<activity
android:name=".QuizActivity"
android:theme="#style/Theme.AppCompat.Light.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
</intent-filter>
</activity>
<activity
android:name=".ui.AppBaseActivity"
android:theme="#style/Theme.AppCompat.Light.NoActionBar" />
<activity
android:name=".ui.VideoPlayList"
android:theme="#style/Theme.AppCompat.Light.NoActionBar" />
<activity
android:name=".ui.ActivityLog"
android:theme="#style/Theme.AppCompat.Light.NoActionBar"
android:windowSoftInputMode="stateHidden" />
<activity
android:name=".ui.LockedContentActivity"
android:screenOrientation="portrait"
android:theme="#style/Theme.AppCompat.Light.NoActionBar"
android:windowSoftInputMode="stateHidden" />
<activity
android:name="com.braintreepayments.api.BraintreeBrowserSwitchActivity"
android:launchMode="singleTask">
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="com.kinephonics.braintree" />
</intent-filter>
</activity>
<activity
android:name=".ui.DictionaryActivity"
android:screenOrientation="portrait"
android:theme="#style/Theme.AppCompat.Light.NoActionBar"
android:windowSoftInputMode="stateHidden" />
</application>
</manifest>

Open button not there in google play

I just published my first app and when I downloaded it, there is an uninstall button, No open button and no logo has been generated. i have tried looking it up online. But have not been able to find anything helpful. Please help.
`
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.READ_INTERNAL_STORAGE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:allowBackup="true"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name"
android:theme="#style/AppTheme" >
<meta-data android:name="com.google.android.gms.version"
android:value="#integer/google_play_services_version"/>
<activity
android:name="com.phoenix.andaz.MainActivity"
android:label="#string/app_name"
android:screenOrientation="portrait"
>
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
<action android:name="android.intent.action.SEND" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="audio/mp3"/>
<data android:mimeType="text/plain"/>
</intent-filter>
</activity>
<activity android:name="com.phoenix.andaz.AK"
android:label="#string/app_name"
android:screenOrientation="portrait"> </activity>
<activity android:name="com.phoenix.andaz.SK"
android:label="#string/app_name"
android:screenOrientation="portrait"> </activity>
<activity android:name="com.phoenix.andaz.ShK"
android:label="#string/app_name"
android:screenOrientation="portrait"> </activity>
<activity android:name="com.phoenix.andaz.Player"
android:label="#string/app_name"
android:screenOrientation="portrait">
</activity>
<activity android:name="com.google.ads.AdActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"
android:theme="#android:style/Theme.Translucent">
</activity>
</application>
No app is going to know how to launch any of your activities. Most are private to your app, and MainActivity has a very broken <intent-filter>.
Here is my guess as to the manifest entry you should have for that activity:
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.SEND" />
<category android:name="android.intent.category.DEFAULT" />
<data android:mimeType="audio/mp3"/>
<data android:mimeType="text/plain"/>
</intent-filter>
</activity>
This says "either match MAIN/LAUNCHER or match SEND/DEFAULT/one of the MIME types".

Eclipse showing No launcher Activity found

This is my android Manifest.xml.
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="uk.co.halfninja.wallpaper.parallax">
<uses-sdk android:minSdkVersion="7" />
<uses-feature android:name="android.software.live_wallpaper" />
<application
android:label="#string/app_name"
android:icon="#drawable/icon">
<service
android:label="#string/app_name"
android:name=".ParallaxWallpaper"
android:permission="android.permission.BIND_WALLPAPER">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<meta-data android:name="android.service.wallpaper" android:resource="#xml/wallpaper" />
</service>
<activity
android:label="#string/wallpaper_settings"
android:name=".ParallaxWallpaperSettings"
android:theme="#android:style/Theme.Black.NoTitleBar"
android:exported="true">
</activity>
</application>
</manifest>
Still Eclipse showing the result
ParallaxWallpaper] No Launcher activity found!
ParallaxWallpaper] The launch will only sync the application package on the device!
ParallaxWallpaper] Performing sync
ParallaxWallpaper] Automatic Target Mode: Unable to detect device compatibility. Please select a target device.
Please let me Know where am i doing the mistake, and what would be the solution...???
Move the intent-filter tag from service to activity
These lines should be in Activity tag
<application
android:label="#string/app_name"
android:icon="#drawable/icon">
<activity
android:label="#string/wallpaper_settings"
android:name=".ParallaxWallpaperSettings"
android:theme="#android:style/Theme.Black.NoTitleBar" android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<service
android:label="#string/app_name"
android:name=".ParallaxWallpaper"
android:permission="android.permission.BIND_WALLPAPER">
</service>
<meta-data android:name="android.service.wallpaper" android:resource="#xml/wallpaper" />
</application>
make activity as launcher you have made service as launcher. like that
<activity
android:label="#string/wallpaper_settings"
android:name=".ParallaxWallpaperSettings"
android:theme="#android:style/Theme.Black.NoTitleBar"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

my application has stopped unexpectedly in android please try again

I have an error in my android code:
case R.id.bSQLOpenView:
Intent i = new Intent("com.fps.say.SQLView");
startActivity(i);
break;
and my logcat says there's no activity found to handle intent..
I already declared my class at AndroidManifest.xml why do i still get this error.
this is my manifest.xml
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.fps.say"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk android:minSdkVersion="10" />
<uses-permission android:name="android.permission.SET_WALLPAPER"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.WAKE_LOCK"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<application
android:icon="#drawable/ic_launcher"
android:label="#string/app_name" >
<activity
android:name=".Splash"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".Menu"
android:label="#string/app_name" >
<intent-filter>
<action android:name="com.fps.say.MENU" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".SayActivity"
android:label="#string/app_name" >
<intent-filter>
<action android:name="com.fps.say.SAYACTIVITY" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".TextPlay"
android:label="#string/app_name" >
<intent-filter>
<action android:name="com.fps.say.TEXTPLAY" />
</intent-filter>
</activity>
<activity
android:name=".Email"
android:label="#string/app_name" >
<intent-filter>
<action android:name="com.fps.say.EMAIL" />
</intent-filter>
</activity>
<activity
android:name=".Camera"
android:label="Camera Application"
android:screenOrientation="portrait">
<intent-filter>
<action android:name="com.fps.say.CAMERA" />
</intent-filter>
</activity>
<activity
android:name=".AboutUs"
android:label="#string/app_name"
android:theme="#android:style/Theme.Dialog">
<intent-filter>
<action android:name="com.fps.say.ABOUTUS" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".Prefs"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.PREFS" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity
android:name=".Data"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.DATA" />
</intent-filter>
</activity>
<activity
android:name=".GFX"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.GFX" />
</intent-filter>
</activity>
<activity
android:name=".GFXSurface"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.GFXSURFACE" />
</intent-filter>
</activity>
<activity
android:name=".OpenedClass"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.OPENEDCLASS" />
</intent-filter>
</activity>
<activity
android:name=".SoundStuff"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.SOUNDSTUFF" />
</intent-filter>
</activity>
<activity
android:name=".Slider"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.SLIDER" />
</intent-filter>
</activity>
<activity
android:name=".Tabs"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.TABS" />
</intent-filter>
</activity>
<activity
android:name=".SimpleBrowser"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.SIMPLEBROWSER" />
</intent-filter>
</activity>
<activity
android:name=".SharedPrefs"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.SHAREDPREFS" />
</intent-filter>
</activity>
<activity
android:name=".InternalData"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.INTERNALDATA" />
</intent-filter>
</activity>
<activity
android:name=".ExternalData"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.EXTERNALDATA" />
</intent-filter>
</activity>
<activity
android:name=".SQLView"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.SQLVIEW" />
</intent-filter>
</activity>
<activity
android:name=".SQLiteExample"
android:label="#string/app_name">
<intent-filter>
<action android:name="com.fps.say.SQLITEEXAMPLE" />
</intent-filter>
</activity>
</application>
</manifest>
There are several possible ways to run an activity.
Here's the method I use:
Intent i = new Intent (this, YourTargetActivity.class);
startActivity(i);
The this corresponds to your current activity.
Using such a call gives you the convenience to have your IDE autocomplete the desired activity name.
Dubble check the name of the class
Dubble check the name which should be mentioned in the manifest file
Perform a clean-build
Intent i = new Intent(this,SQLVIEW.class);

Categories

Resources