The short answer is when you get this error message, there is no valid development provisioning profile in the built application.
That alone won't solve your problem! There are a number of common causes of this:
- You've moved to a new machine and haven't installed the provisioning profile in Xcode. Also see below
- You've moved to a new machine and it's not in developer mode OR not added to the provisioning profile
For both of these, let Xcode regenerate it, or do it yourself in the Member centre... You can validate the causes is something to do with your provisioning profile by running Console and filtering on taskgated where you can see which provisioning profile it is trying to use (it will pull the one embedded in the application first, then try to pull from any installed on the Mac).
Make sure you check in your build settings that the right one is being used for Debug builds. Simple steps that normally resolve (XCode 5)
- Go to member centre and create a new development profile
- Select the app and certificate
- Validate that the machine you are using is in the list of machines to be included in the profile, tick the box
- Generate the certificate
- Download it, and drag it over the Xcode icon in the doc
Go to the Build Settings tab in your target and set the provisioning profile to the one you've just downloaded
- You haven't configured your iCloud/APN/GameCenter entitlements correctly.