user8237869
user8237869

Reputation: 33

Do I need to explicitly grant various internet/network Manifest permissions for these conditions?

In my app I have the following relevant components:

-My app uses Google AdMob advertisement banners

-My app allows you to import / export data using the media Intent chooser, which may involve letting the user choose some online service such as Gmail, Google Drive, etc.

-My app occasionally displays hyperlinks and buttons in certain places that opens the user's browser and goes to the designated site.

Does any of this require special permission in the Manifest?

Upvotes: 3

Views: 1977

Answers (4)

3c71
3c71

Reputation: 4511

As I couldn't find a proper answer here (existing are contradicting), I did my home work and tested with a real app.

  • AdMob, when adding the dependency to the SDK, both INTERNET and READ_NETWORK_STATE permissions are automatically added to the Manifest of the generated or built APK. I have no INTERNET permission anywhere in my project, but the gerenated APK does. Removing the SDK, the permission is gone.

  • Loading content from other apps does not require INTERNET permission, even if those apps are receiving the content from internet.

  • Opening URL in a device's browser does not require INTERNET either, it's the browser which needs it.

To answer the OP, one does not need to add any special permission in Manifest to do any of the 3 above mentioned features.

However note that INTERNET permission is automatically added by the dependency on AdMob's SDK.

Upvotes: 4

Aishwarya Upadhyay
Aishwarya Upadhyay

Reputation: 19

No you don't need to. Check out this quick start guide and see there is no mention of adding those permissions. https://developers.google.com/admob/android/quick-start

I have a similar app running on android P and no permissions are required. So cheers. Also do remember that you need to use dummy ID while testing ad mobs.

Upvotes: 1

Rodrigo Gontijo
Rodrigo Gontijo

Reputation: 587

-My app uses Google AdMob advertisement banners - In the official site of AdMob, nothing related to the internet permission, as you can see here

-My app allows you to import / export data using the media Intent chooser, which may involve letting the user choose some online service such as Gmail, Google Drive, etc. if you want to import data, you need to set the permission!

-My app occasionally displays hyperlinks and buttons in certain places that opens the user's browser and goes to the designated site. - I guess it does not need internet permission, but i´m not shure.

Upvotes: 0

Wesnie
Wesnie

Reputation: 24

You will need to use the following permission in the manifest:

<uses-permission android:name="android.permission.INTERNET" /> 

Upvotes: 0

Related Questions