[Camera Plugin] Missing Info.plist key on iOS app submission

[Camera Plugin] Missing Info.plist key on iOS app submission

  
Forge Component
(11)
Published on 26 Sep by OutSystems R&D
11 votes
Published on 26 Sep by OutSystems R&D

Hi,

We are currently submitted app to the App Store, but there is an issue with the data usage protection:

"Missing Info.plist key - This app attempts to access privacy-sensitive data without a usage description. The app's Info.plist must contain an NSPhotoLibraryUsageDescription key with a string value explaining to the user how the app uses this data.

Once these issues have been corrected, you can then redeliver the corrected binary."

How can I fix it?

On github description it is mentioned that I have to pass some values when generating the app.


Since iOS 10 it's mandatory to add a NSCameraUsageDescription and NSPhotoLibraryUsageDescription in the info.plist.

  • NSCameraUsageDescription describes the reason that the app accesses the user’s camera.
  • NSPhotoLibraryUsageDescription describes the reason the app accesses the user's photo library.

When the system prompts the user to allow access, this string is displayed as part of the dialog box.

To add this entry you can pass the following variables on plugin install.

  • CAMERA_USAGE_DESCRIPTION for NSCameraUsageDescription
  • PHOTOLIBRARY_USAGE_DESCRIPTION for NSPhotoLibraryUsageDescription

Example:

cordova plugin add cordova-plugin-camera --variable CAMERA_USAGE_DESCRIPTION="your usage message" --variable PHOTOLIBRARY_USAGE_DESCRIPTION="your usage message"

If you don't pass the variable, the plugin will add an empty string as value.


How can I pass this variables or override default empty string to use in ServiceStudio app generator?

Thank you.


Solution

Hi Mykola,

We already did that fix in the latest version of the plugin.You shouldn't have that problem anymore. Can you please check if you're using the latest version and try again?

Let me know how it went please.

Best regards,

Ricardo Alves

Solution

Hi Ricardo,

Thanks for your reply - it worked perfectly!


Thanks, this worked for me as well! :)

Hi Ricardo,

Our app is in dutch and also want extra information about privacy for the permissions.

Currently the texts are:
"We access your camera to take pictures."
"We access your photo library to load or save pictures."

How is it possible to adjust the current texts?

Kind regards

Hello, Bram,

If you're only looking a Dutch localization of the message (and can forego English), you can open the Camera Plugin and edit it's extensibility configurations. It should then look something like this:

You will lose the ability to upgrade the plugin directly from the Forge and will have to publish newer versions manually (and re-add the Dutch descriptions).

Another, similar option would be to actually "clone" the plugin module and do your edits there. Then, you would keep the Forge upgrade capabilities and would just have to merge them to your clone.

Would this do?

Best regards,

Carlos Simões

Thanks for the quick reply. And for the good suggestions.

The second option (cloning) seems workable, so we are going to implement that.

We avoid the first option, since we might use this plugin in multiple applications (with different contexts) in the future.

Kind regards,
Bram van Mensvoort

Good point, Bram. Bigger factories will find the first option as unmanageable.

Thanks for sharing!

Carlos Simões

Carlos Simões wrote:

Good point, Bram. Bigger factories will find the first option as unmanageable.

Thanks for sharing!

Carlos Simões

Both your solutions are unmanageable in a factory... Outsystems default values for CAMERA_USAGE_DESCRIPTION and PHOTOLIBRARY_USAGE_DESCRIPTION were just refused by Apple, so we need to change the Camera plugin so that those values will work for all apps in the factory using the plugin.



João Almeida wrote:

Carlos Simões wrote:

Good point, Bram. Bigger factories will find the first option as unmanageable.

Thanks for sharing!

Carlos Simões

Both your solutions are unmanageable in a factory... Outsystems default values for CAMERA_USAGE_DESCRIPTION and PHOTOLIBRARY_USAGE_DESCRIPTION were just refused by Apple, so we need to change the Camera plugin so that those values will work for all apps in the factory using the plugin.



Hello, João,

Sorry to hear that... :\ Unfortunately, Apple's review process can occasionally be a bit more rigorous and these messages may miss the mark. In that sense, we could have a better message, but always keeping in mind it needs to be applicable to all apps using the plugin.

Still, in scenarios where multiple apps use the same plugin, the only current solution is to, effectively, create a new plugin based off of the original one from the Forge, by cloning it. This has the obvious drawback that we would need to merge updates from the original plugins to the clones.

Can you please share this via the Ideas section? This is a great way to have this feedback reach the teams and get their attention. Another request, also related with extensibility configurations, was recently put on the radar of the team.

Best regards,

Carlos Simões

That Idea's focus is slightly different, but would definitely work for me.Thanks!

João Almeida wrote:

That Idea's focus is slightly different, but would definitely work for me.Thanks!

Yes, not at all the same thing (although still related with tweaking Extensibility Configurations), but definitely a most valid one! I will be on the lookout to vote myself!

Thanks and best regards,

Carlos Simões


Hi Carlos Simões


We  are also using the camera plugin , and by default there are configurations present like this in extensibility schema : 



But we are not able to see this usage description on real devices, instead we are seeing default usage description by the iOS system.

Apart from this i need to know If this configurations are present then does it guarantee that apple will not reject the app submission ? 

Regards,

Akshay Tank.

Hi,

When I call TakePicture action of the plugin I am seeing the alert as shown in the screenshot.


I want to show the custom message that I have configured in the extensiblity configuration.