I am trying to upload an app to the app store and I am getting this error on the page that has the certs. As far as I can tell I have changed the field so they have matched,
In Xcode 10, I got it working by moving the entitlements file to correct folder in Project Navigator. I didn't have the entitlements file, but I managed to get one by toggling features on capabilities tab.
I came across this page recently after trying to create a duplicate target - none of the suggestions were working for me. Further investigation, and some amount of hair pulling, eventually led me to scouring through the build settings for my app to try and figure out what was wrong.
It turned out that my project was still pointing to the entitlements file of the ORIGINAL target, rather than having one of its own. To resolve this, I navigated to the original entitlements file in Finder (e.g. ${SRCROOT}/MyProject/Entitlements/TargetName.entitlements), created a copy within the same folder and then renamed it (e.g NewTargetName.entitlements).
Then, I opened my new entitlements file and changed the application-identifier field to match the ending of my new target's bundle identifier (e.g. ABCDEFGH.US.co.fake-company.superduperapp-newtargetname).
Finally, I updated the 'Code Signing Entitlements' field in the build settings to the path of my entitlements file (for me, this was something along the lines of ${SRCROOT}/MyProject/Entitlements/TargetName.entitlements).
I returned to the Signing & Capabilities tab, and lo, the issue was fixed. Hope someone out there finds this useful.
In my case the issue was following: provisioning profile used for build step was created for different app id than provisioning profile used for export step.
So make sure you're using the same provisioning profile for build and export step.
I had this issue with a brand new app, in Xcode 12 beta 3 (app submissions started today).
Xcode had "Automatically manage signing" on. However, the Team ID displayed in the "Signing Certificate" didn't match the Team ID displayed in iTunes Connect website. This was the root cause preventing the app from being uploaded.
How I fixed it:
Rightclick on Finder -> Go to Folder...
~/Library/MobileDevice/Provisioning
For Xcode 11
~/Library/MobileDevice/Provisioning Profiles/
Delete all provisioning profiles, done.
I got this same error and none of the solutions above solved the problem in my case.
What did work for me was to change the "Can be debugged" setting in the "Entitlements.plist" file from "NO" to "YES."