iOS submission - Missing Purpose String in Info.plist

Hello. I just submitted an iOS app to the App Store for review, and I received an email with the following message. Is this a known issue with Xojo that will be fixed in a future release? Or could this have anything to do with any random declares in the code? The app is quite general and does not directly need to access anything from the user’s sensitive data. Don’t even use the sharing panel if that has to do with this message.

[quote]Dear Developer,

We identified one or more issues with a recent delivery for your app, “RD Practice Exam To Go”. Your delivery was successful, but you may wish to correct the following issues in your next delivery:

Missing Purpose String in Info.plist - Your app’s code references one or more APIs that access sensitive user data. The app’s Info.plist file should contain a NSLocationAlwaysUsageDescription key with a user-facing purpose string explaining clearly and completely why your app needs the data. Starting Spring 2019, all apps submitted to the App Store that access user data are required to include a purpose string. If you’re using external libraries or SDKs, they may reference APIs that require a purpose string. While your app might not use these APIs, a purpose string is still required. You can contact the developer of the library or SDK and request they release a version of their code that doesn’t contain the APIs. Learn more (https://developer.apple.com/documentation/uikit/core_app/protecting_the_user_s_privacy).[/quote]

Using Xojo 2019 r1 on Mac Mojave

There is something new about iOS with release 2019r1.1:
http://documentation.xojo.com/resources/release_notes/2019r1.1.html

I hope that help you (no experience with iOS)

Ah. Didn’t know there was a minor update. Thanks Alberto!

Continuing the conversation. I am trying to deploy a new iOS app to the App Store and received a similar message from Apple:

I now have Xojo 2019 r1.1, but this message is a tad difference. It references NSMicrophoneUsageDescription. I do have iOSLib in this project, but I don’t utilize the microphone or any other user data details. The message says I need to update the info.plist to contain the NSMicrophoneUsageDescription key, but I’m not sure where to begin with this. Any help would be appreciated!

Create a plist with that key and drop it in your project navigator. Be sure to add all those keys they are just informational and required even if you don’t use the apis at all.

Thank you Derk. I am not familiar with plists. I entered the following into TextEdit on Mac, converted it to a .txt file, saved it to the desktop, changed the .txt to .plist, dragged it to the left side project navigator, built the app, and it’s still coming back as invalid. Were these the correct steps? And what does the plist have to look like?

[code]<?xml version="1.0" encoding="UTF-8"?>

NSMicrophoneUsageDescription [/code]

[quote=440517:@Ryan Hartz]Thank you Derk. I am not familiar with plists. I entered the following into TextEdit on Mac, converted it to a .txt file, saved it to the desktop, changed the .txt to .plist, dragged it to the left side project navigator, built the app, and it’s still coming back as invalid. Were these the correct steps? And what does the plist have to look like?

[code]<?xml version="1.0" encoding="UTF-8"?>

NSMicrophoneUsageDescription [/code][/quote]

Something like this:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
   <key>NSPhotoLibraryAddUsageDescription</key>
   <string>This app requires read and write permission from the user.</string>
   <key>NSMicrophoneUsageDescription</key>
   <string>This app doesn't use your Microphone.</string>
</dict>
</plist>


<key>NSPhotoLibraryAddUsageDescription</key>
<string>This app requires read and write permission from the user.</string>

Add all the string keys for access rights. keys following: NS*****Description

They are described here:
https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/iPhoneOSKeys.html#//apple_ref/doc/uid/TP40009252-SW10

more info about plist:
https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Introduction/Introduction.html

Here are the descriptions:
https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CocoaKeys.html

More plist information (updated with Derk’s links):
https://documentation.xojo.com/topics/application_structure/mobile/using_a_plist.html

Perfect! Thank you Derk! And thank you Paul for creating a docs page. The app passed submission and now I know a bit more about plists