I am using keychain in my app and I get this error when run app as AdHoc. It doesn't appear when I run it with debugger (with developer provisioning profile). If app has already been installed on the device and I install it again on top of it from Xcode then I notice that app doesn't have access to keychain. It happens certainly because of those error.
I have spent much time googling that error and some recommends to add entitlements file with keychain-access-group in it. But I could not find any Apple doc or any reasonable explanation what entitlements file needed for.
Can someone help me to solve it?
There is a pretty old post here you need the entitlements to say which Bundle Identifier you App's Bundle seed is under since that is the way KeyChain allows your application to access it by.
Once two Applications have the same Bundle identifier in their bundle seed, they can share KeyChain access..
So if Application A has a Common Bundle Id: com.yourcompany.AAAAAA And application B as a Common Bundle Id com.yourcompany.BBBBBB
And if they both have an entitlements file in their .ipa (plist containing an array keyed "keychain-access-groups" with a string ".com.yourcompany.AAAAA" and .com.yourcompany.BBBBB")
They can share KeyChain access..