Issue with Data Protection on Capabilities tab - ios

I have enabled Data Protection for my iOS application and set Protected Until First User Authentication mode. Here is screenshot from my App ID:
I also set this in my entitlements file:
<?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>com.apple.developer.default-data-protection</key>
<string>NSFileProtectionCompleteUntilFirstUserAuthentication</string>
</dict>
</plist>
However, xcode constantly shows issue on Capabilities tab:
When I click Fix Issue it modifies my entitlements file and sets: NSFileProtectionComplete which is different than App ID setting, so then I get errors on General tab under each provisioning profile (I have disabled Automatically manage signing).
I can't get rid off this issue. However everything seems to work, I can build it without any issues. Any ideas how to fix it?
Bundle identifier is correct and provisioning profiles are set properly. I'm using Xcode 10.2.

Related

Adding Associated Domains Entitlement For a Flutter App

I need to add Associated Domains Entitlement to my Flutter app, so I can implement App Links.
I use the uni_links plugin which works well for Android. I've added a ios/Runner/Runner.entitlements file as described, but it doesn't work. Apple official docs imply that I need to add something to the app via xcode. Problem is, I don't use xcode, rather Android Studio. I believe I need to manually add an entry to info.plist or project.pbxproj which is what I believe xcode does, however I am not sure what.
Open the Runner.entitlements file from this path :
ios/Runner/Runner.entitlements
And add the applink you want
<?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>
<!-- ... other keys -->
<key>com.apple.developer.associated-domains</key>
<array>
<string>applinks:[YOUR_HOST]</string>
</array>
<!-- ... other keys -->
</dict>
</plist>
For more information, read Apple's guide for Universal Links.
Log in to Apple Developer Account.
Check your bundle Id. Edit your App ID. Add Associated Domain Entitlement from there. Update Provisioning profile and Use it in your Flutter project.

how can i resolve keychain access group issue without removing entitlements.plist file?

Here is the screenshot of the error
I have enabled keychain access group in capabilities and its added in Entitlements.plist
<?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>keychain-access-groups</key>
<array>
<string>L23874DF.com.your.appid</string>
</array>
</dict>
</plist>
I signed the archive with development provisioning profile and certificate and given it to the team that pushes it for appstore.
But I got the above error and I don't understand it has right appid prefix and bundle identifier and member center has no options to enable Keychain access group then in my eyes there should not be a problem.
the appstore certificate that they're using is from same appstore account so there shouldn't be a problem with app id.
App id is same for whole account irrespective of whether its development build or adhoc build or release build or appstore build
P.S
I had to remove my entitlements.plist and resign the app with same dev cert and provision to make archive and send to them and it got published to appstore without any problem
somebody explain me whats wrong with this behaviour ? I am still confused

aps-environment is always development

I have created the app id with APNS enabled and I configured both development and production certificate
Now when I create entitlements it is always displaying development even If I change the Provisioning profile to iTunes deployment also the entitlements is displayed as development
<?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>aps-environment</key>
<string>development</string>
</dict>
</plist>
You can't use a production certificate in debug/development. Even if you do it, then, when you 'Archive', Xcode will automatically set it to production (Apple reference). You can see this when you try to submit your app to iTunes connect for TestFlight/Review or for Adhoc deployment.
Xcode 8:
Xcode 9:
XCode 10.2:
If you change your target to "Generic iOS Device" before Archive it will set the aps-environment variable to production. If you archive with the target set to your device it will archive with the aps-environment variable set to development.
There is a known bug in Xcode whereby manually setting this to 'production' causes Xcode to display an error next to your entitlements config with a 'Fix Issue' button. Clicking this sets it back to 'development' This is not intended functionality. As I said it is a known issue and I believe I filed a radar when I first discovered it.
It has been fixed in Xcode 8.3 beta 2. In the meantime, manually set it to 'production' and then ignore the error Xcode gives you, your project will work just fine.

ERROR ITMS-9000 iTunes Connect

I am trying to upload a phonegap build iOS app to the app store and I keep getting this error
ERROR-ITMS-9000:: "Missing Code Signing Entitlements. No entitlements found in the bundle 'com.fitness.challenges' for executable 'Payload/30DayFitness.app/30DayFitness'." at SoftwareAssets/SoftwareAsset (MZItmspSoftwareAssetPackage)
I have set up my development and distribution provisioning profiles and certificates, and uploaded the cerificate.12 and provision profile to build.phonegap.com
any help be great thanks!
i fixed this by adding -538h to the iphone5 splash screen png file name!
so it was - splash-iphone5-538h.png
that was all that was breaking the upload!
According to this topic on phonegap build support forum there's an error in documentation.
In config.xml as id you should put just your app name and not the reverse style domain id as used in provisioning profile.
EDIT: (16.10.2013, 17:33)
I just discovered that it is rather temporary workaround because to upload APK in play store you'd still need the reverse style domain id.
check your Bundle Identifier.
The bundle id supposed to same with App ID.
I had the same problem and fixed it by making sure all the required icons where there.
I had the same problem in a RE-SIGNED APP, using iResign as the re-signing tool.
Here's an example of an Entitlements.plist file that helped me get my build through to Apple.
<?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>application-identifier</key>
<string>B123RP1C12.com.startup.killerapp</string>
<key>keychain-access-groups</key>
<array>
<string>B123RP1C12.com.startup.killerapp </string>
</array>
<key>get-task-allow</key>
<true/>
</dict>
</plist>

has no valid com.apple.developer.ubiquity-kvstore-identifier entitlement AD HOC iCloud

I'm having trouble with iCloud key value store.
I currently have a core data synced by iCloud working, but I cannot get K-V Store to work
I'm getting:
com.domain.appname has no valid com.apple.developer.ubiquity-kvstore-identifier entitlement
com.domain.appname is the format of my appid, masked for privacy.
This has been around for a while, and I've seen people having this issue and when reinstalling the app the issue is gone, but that won't apply to me. Don't know why.
My entitlements:
<?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>com.apple.developer.ubiquity-container-identifiers</key>
<array>
<string>$(TeamIdentifierPrefix)com.domain.appname</string>
</array>
<key>com.apple.developer.ubiquity-kvstore-identifier</key>
<string>$(TeamIdentifierPrefix)com.domain.appname</string>
<key>keychain-access-groups</key>
<array>
<string>$(TeamIdentifierPrefix)com.domain.appname</string>
</array>
</dict>
</plist>
If you need anything else just ask, Thank you!
this link worked for me. Try this.
Reinstall the app as well as quit the xcode and restart the device.
It will work fine.
Simply, the error is saying that the com.apple.developer.ubiquity-kvstore-identifier "Key" is missing from the entitlement file which had generated when you enabled iCloud in capabilities. Follow the steps in the screenshot I attached:
or 1. just go to the entitlement file and right click on any row and choose Show Raw Keys/Values
When you hover over Entitlement File row (at the top), a plus button will appear.
Click it and drop down list will appear, choose com.apple.developer.ubiquity-kvstore-identifier and for the value just copy and paste this $(AppIdentifierPrefix)YOUR_BUNDLE_ID
Clean. Build. And Enjoy.

Resources