I've just uploaded an iOS app (written using Xamarin forms 3.1) to the App Store and received an email that stated:
"_Your delivery was successful, but you may wish to correct the following issues in your next delivery
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._"
While it is quite descriptive, explaining what is wrong, why it is wrong and how to fix it, my app doesn't use and of the Location APIs - it doesn't need them at all.
This was only an information message and it did not prevent the app from being uploaded I did receive a similar email after a previous upload which referred to a missing 'NSCalendarsUsageDescription' key and that did fail the process. Once again, my app does not access the users calendar in any way but I had to add the key with some text, I used 'this app does not require this permission!', to get the app uploaded.
I am using a couple of plugins within the app, Xam.Plugin.Media and it's dependancy Plugin.Permissions as well as the AppCenter Analytics and Crashes packages. But I'm only using these to take photos, gather analytics and report crashes - nothing directly to do with the Calendar or Location.
I can easily add the specified keys to the info.plist but I'd like to know what it causing this issue - it didn't happen with a previous Xamarin.Forms application that I uploaded a month or so ago.
Can anyone point me in the direction of some documentation (I've Googled around but not found anything helpful so far) or a tool that I can use to determine the source of these apparently calls to the Calendar and Location APIs.
Hello @DaveCarson, I had the same issue when I submitted my app to iTunes connect, but I noticed this problem is also caused for the description that I gave .
We must be careful when we're filling the app in iTunes connect, you can check your app description and if there are misunderstandings you can change it, also you can quite these issues editing your info.plist and writing the next
<key>NSLocationAlwaysUsageDescription</key <string>Your description</string> <key>NSCalendarsUsageDescription</key> <string> user your calendar.</string>
Answers
I came across this too and saw this post which makes some sense of it.
https://forums.xamarin.com/discussion/113707/this-app-attempts-to-access-privacy-sensitive-data-without-a-usage-description
Looks like I'm not the only one experiencing this issue and it doesn't seem to be related to Xamarin.Forms or the plugins I'm using.
Looking at the Apple Developer System Status page it looks like there were problems with App Store Connect and TestFlight recently but Apple don't seem to think it important to say what the issues were - just that they've been fixed - so I don't know if it was cause of my problems.
I think that the workaround is to just put some bogus text into the info.plist entry and cross my fingers ;-)
Yeah I mean sticking those keys in will get around it. Its just a little annoying I guess.
Hello @DaveCarson, I had the same issue when I submitted my app to iTunes connect, but I noticed this problem is also caused for the description that I gave .
We must be careful when we're filling the app in iTunes connect, you can check your app description and if there are misunderstandings you can change it, also you can quite these issues editing your info.plist and writing the next
I had a space in the "Declaration"
NSCalendarsUsageDescription
Validate there are no spaces.