Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
Posts: 1,168
Registered: ‎03-20-2013
My Device: Red LE Developer Z10
My Carrier: Fido

Application Internet permission

I have a user that is having trouble with my application. They were running it on a Q10 with a BB10.1 OS on it, and for some reason NOTHING worked after the initial load, including even the main application menu being missing. Since my app is running on hundreds of Q10s on various BB10 versions I suspected her OS installation was broken. Unstalling my app and reinstalling didn't help.

 

Her carrier (Orange France) just rolled out BB10.2.0.424 and I suggested she update and try clean installing my app. When she did so all the UI functions magically started working properly, and the main application menu appeared and functioned as it should. The problem now is that my app has absolutely no Internet access. Even DNS lookups don't work. I believe the access_internet permission for my app is not set on her device. The challenge is that there is no way to enable this afte the fact, and BB10 remembers permissions from the first installation so even uninstalling/reinstalling won't help.

 

I have never understood why not all the permissions my app needs are listed on the app permissions page in BB10 settings. My app requires:

 

  • Device Identifying Information (read_device_identifying_information)
  • Internet (access_internet)
  • Notebooks (access_pimdomain_notebooks)
  • Post Notifications (post_notification)
  • Run When Backgrounded (run_when_backgrounded)
  • Shared Files (access_shared)

...but after installation the only permissions listed in device settings are:

 

  • Device Identifying Information (read_device_identifying_information)
  • Notebooks (access_pimdomain_notebooks)
  • Shared Files (access_shared)

Of course this means I can't check if the Internet permission for my app is set on her device, neither can it be changed in any case. Does anyone have any idea what to do in a case like this?

 



Developer of Built for BlackBerry certified multiFEED RSS/Atom feed reader and aggregator.  multiFEED Icon

Play nice: Clicking Like Button on posts that helped you not only encourages others to continue sharing their experience, but also improves your own rating on this board. Also, don't forget to accept a post if it solves your problem or answers your question.
Developer
Posts: 6,152
Registered: ‎07-05-2012
My Device: Playbook, Dev Alpha C, Z10 LE, Z30
My Carrier: Orange

Re: Application Internet permission

The general consensus from previous discussions is to check for 'needed' permissions and then offer the user an explanation of why the permission needs to be turned on together with a button taking them to the program settings page (i.e. invoke settings).

 

Your check could be as simple as pinging an address and looking for a response.

 

 

 

 

 


If you've been helped click on Like Button, if you've been saved buy the app. Smiley Happy

Developer of stokLocker, Sympatico and Super Sentences.
Developer
Posts: 1,168
Registered: ‎03-20-2013
My Device: Red LE Developer Z10
My Carrier: Fido

Re: Application Internet permission

Understood, but that is not the problem. Perhaps I didn't explain clearly enough. The problem is that once an application is installed, Internet is not one of the permissions that can be controlled in Settings->Security and Privacy->Application Permissions. What I need to figure out is how the user can enable internet access for my app after it is already installed. As I'm sure you know, after initial installation BlackBerry 10 retains the permission settings even if the app in uninstalled so it doesn't ask a user for permissions when reinstalled.

 

As stated in my OP, my app requests six permissions, but as you can see from this screen cap (when this image gets approved) it only allows you to change three of them later on, and Internet is not one of them.

 

IMG_00000363.png

 

I want to tell the user they need to enable the Internet permission, but settings doesn't allow that. Short of a hard reinstall of BB10, how would you get the OS to forget the settings for an app so that when reinstalled the user is asked to approve permissions again.

 

Also, why are access_internetpost_notification, and run_when_backgrounded not included in the list of permissions a user has control over after installation?

 


BBSJdev wrote:

The general consensus from previous discussions is to check for 'needed' permissions and then offer the user an explanation of why the permission needs to be turned on together with a button taking them to the program settings page (i.e. invoke settings).

 

Your check could be as simple as pinging an address and looking for a response.

 

 

 

 

 






Developer of Built for BlackBerry certified multiFEED RSS/Atom feed reader and aggregator.  multiFEED Icon

Play nice: Clicking Like Button on posts that helped you not only encourages others to continue sharing their experience, but also improves your own rating on this board. Also, don't forget to accept a post if it solves your problem or answers your question.
Developer
Posts: 6,152
Registered: ‎07-05-2012
My Device: Playbook, Dev Alpha C, Z10 LE, Z30
My Carrier: Orange

Re: Application Internet permission

[ Edited ]

All good questions. Smiley Happy

I did miss what you were trying to say and maybe I still am but...

 

If the user can't access the permission how have they turned it off?

Isn't this a global control setting accessed from Networks and Connections. 

 

Funnily enough this permission setting shows up in Settings for Android apps but is not accessible.

 

[Edit] The other two missing permissions you mention can also be controlled by settings elsewhere so I would think that's the reason.

 


If you've been helped click on Like Button, if you've been saved buy the app. Smiley Happy

Developer of stokLocker, Sympatico and Super Sentences.
Developer
Posts: 1,168
Registered: ‎03-20-2013
My Device: Red LE Developer Z10
My Carrier: Fido

Re: Application Internet permission

As I said in my OP, I suspect the problems the user had installing my app on their corrupted BB10.1 OS may have borked the permissions, or possibly, they refused the requested permissions because they didn't understand them. I actually have always listed required permissions and the reason they are needed on my app's BBW page, but some don't read them I guess, and others still don't understand. In any case, I believe the Internet permission was not granted on initial installation of my app, and now there doesn't seem to be any way to enable it after the fact.

 

I hadn't noticed it before, but you are correct, Android apps do indeed show this permssion, but the toggles are disabled. None of the native apps on my device list Internet as a settable permission, however.

 

The Internet setting in Network Connections just turns access on or off for ALL apps. However, each application has its own access_internet permission, which must be enabled the app to talk to the Internet either by WiFi or mobile network (at least I think it does, I've never tried building an app without that permission requested in bar-descriptor.xml). The description for this permission is "Allows this app to use Wi-fi, wired, or other connections to a destination that is not local on the user's device." I can't easily confirm it now, but I believe that this permission is displayed in the permission request when the app is initially installed, but doesn't appear in permission settings later on.


BBSJdev wrote:

All good questions. Smiley Happy

I did miss what you were trying to say and maybe I still am but...

 

If the user can't access the permission how have they turned it off?

Isn't this a global control setting accessed from Networks and Connections. 

 

Funnily enough this permission setting shows up in Settings for Android apps but is not accessible.

 

[Edit] The other two missing permissions you mention can also be controlled by settings elsewhere so I would think that's the reason.

 






Developer of Built for BlackBerry certified multiFEED RSS/Atom feed reader and aggregator.  multiFEED Icon

Play nice: Clicking Like Button on posts that helped you not only encourages others to continue sharing their experience, but also improves your own rating on this board. Also, don't forget to accept a post if it solves your problem or answers your question.
Developer
Posts: 6,152
Registered: ‎07-05-2012
My Device: Playbook, Dev Alpha C, Z10 LE, Z30
My Carrier: Orange

Re: Application Internet permission

I created a new app just to test and it didn't show up for me, are you sure they just don't have it turned off globally?

If you've been helped click on Like Button, if you've been saved buy the app. Smiley Happy

Developer of stokLocker, Sympatico and Super Sentences.
Developer
Posts: 1,168
Registered: ‎03-20-2013
My Device: Red LE Developer Z10
My Carrier: Fido

Re: Application Internet permission

Well, she can download my app for installation, so I'm guessing not, but I am nearly 3000 miles from my user, so it is difficult to troubleshoot something like this via email. As I said earlier, my app runs fine on hundreds of other Q10s, so it HAS to be something about her device. The good news is she is very cooperative in trying to solve this, she seems to really want to be able to run multiFEED. 

 

 


BBSJdev wrote:
I created a new app just to test and it didn't show up for me, are you sure they just don't have it turned off globally?





Developer of Built for BlackBerry certified multiFEED RSS/Atom feed reader and aggregator.  multiFEED Icon

Play nice: Clicking Like Button on posts that helped you not only encourages others to continue sharing their experience, but also improves your own rating on this board. Also, don't forget to accept a post if it solves your problem or answers your question.
Retired
Posts: 749
Registered: ‎12-16-2008
My Device: BlackBerry Z30
My Carrier: Bell

Re: Application Internet permission

You could try changing the package name and creating a new release build for her to try.

Paul Bernhardt
Application Development Consultant
BlackBerry
@PBernhardt

Did this answer your question? Please accept this post as the solution.
Found a bug? Report it to the Developer Issue Tracker
Developer
Posts: 1,168
Registered: ‎03-20-2013
My Device: Red LE Developer Z10
My Carrier: Fido

Re: Application Internet permission

I thought of that but then she has to have a debug token or sideload it. Neither one is suitable for a casual user.

 


PBernhardt wrote:

You could try changing the package name and creating a new release build for her to try.






Developer of Built for BlackBerry certified multiFEED RSS/Atom feed reader and aggregator.  multiFEED Icon

Play nice: Clicking Like Button on posts that helped you not only encourages others to continue sharing their experience, but also improves your own rating on this board. Also, don't forget to accept a post if it solves your problem or answers your question.
Retired
Posts: 749
Registered: ‎12-16-2008
My Device: BlackBerry Z30
My Carrier: Bell

Re: Application Internet permission

No it's not, depends on what you perceive as her level of technical competence. It would let us determine for sure if it's actually a permission issue or not though.

 

Otherwise, I'm not sure you can actually make that permission show up anywhere. Creating a new version of the app with different permissions will prompt the user again, but I don't think the Internet one will show up all of a sudden.

 

Definitely seems worth logging a bug for, either way: DIT

Paul Bernhardt
Application Development Consultant
BlackBerry
@PBernhardt

Did this answer your question? Please accept this post as the solution.
Found a bug? Report it to the Developer Issue Tracker