10-23-2012 10:57 AM
I've been getting complains from customers that they can't install our app from App World, they're getting "Error starting AppNameHere: Module 'AppNameHere-1' attempts to access a secure API."
The app is signed correctly and runs on OS 6+ devices (tested on Bold 9780 and Torch 9800) but gives this error on OS 5 devices (tested on Bold 9000). I've tried installing from App World, Web .jad install, and using development tools and it always gives me this error no matter how I sign it. The app USED to work on OS 5 but then I started using net.rim.json.org packages which aren't available on OS 5. I fixed that by following this: http://stackoverflow.com/questions/10010484/net-ri
Any idea why this would be happening?
Solved! Go to Solution.
10-23-2012 11:11 AM
10-23-2012 11:37 AM
10-23-2012 11:49 AM
I've had this problem before where this error would occur on all devices and resigning fixed the problem. But in this case it only seems to be OS 5 so I don't see how it could be the wrong cod or something if OS 6 devices installed fine from the same source (tested using web distribution on our site).
I was thinking about your last reply when you said "clean the OS 5 project...". Is there some setting in the app descriptor or something that I could have accidentally made this a non OS 5 project? I'm using Blackberry JRE 7.0 in the build path, would that have anything to do with it?
10-23-2012 12:15 PM
10-23-2012 12:18 PM
10-24-2012 04:22 AM
Actually, you did sign the app on OS6. So do one thing. sign your code with OS5. Then you will not find any issue.
if you sign the app on os6, then some this issue come.
this is not correct, you can use whatever version of the signing tool you want, what matters is that the code is compiled on JRE 5 if it is to be used on OS 5.
10-26-2012 10:45 AM
I have finally fixed this thanks to Simon
The problem was I was using Blackberry JRE 7.0.0 to compile and I believe this *was* working until I tried to use 'net.rim.device.api.util.ByteArrayUtilities' which doesn't appear to be included in OS5. (This is just my assumption as to why it mysteriously stopped working)
Steps to solve:
I had to write my own 'ByteArrayUtilities.byteArrayToHex()' (Stolen from Here) after using JDE 5.0
I don't believe you can use org.json.me in OS5. Looks like it was only introduced in OS6. See the OS5 docs http://www.blackberry.com/developers/docs/5.0.0api
That's where I was getting my original error in OS5, so I've included this https://github.com/upictec/org.json.me in my project and included it as a custom package so it doesn't interfere in OS6+.
10-26-2012 11:35 AM