73

The executable was signed with invalid entitlements.

The entitlements specified in your application’s Code Signing Entitlements file do not match those specified in your provisioning profile.(0xE8008016).

I am getting this error. please help me.

I have create the provisioning profile and change the bundle id. I have enable the keychain sharing from Target->Capabilities and generate the new .entitlement file. and i have also change the bundle id in that.

enter image description here

Community
  • 1
  • 1
Hitendra
  • 1,610
  • 1
  • 15
  • 22
  • 1
    Possible duplicate of: http://stackoverflow.com/questions/5240801/the-entitlements-specified-profile-0xe8008016-error-ios-4-2 – Dave Wood Mar 25 '14 at 05:08
  • 2
    Your provisioning might not contain the device id on which you are running your application – Inder Kumar Rathore Mar 25 '14 at 05:54
  • 3
    @InderKumarRathore hi i have set the device in profile. But i know when the issue is comming but could not resolve it. I want to create group folder that can access other apps. so in proget->Target->Capabilites i add keychaingroup. And it create new file called .entitlement file. when i run in device it works at that time. but when i add in "com.apple.security.application-groups" property in .entitlement file it gives me the above screen shot error. – Hitendra Mar 25 '14 at 06:41
  • I have posted a question on Apple Forum, since so far I cannot get rid of it with iCloud KeyValueStore settings: https://forums.developer.apple.com/thread/22867 – loretoparisi Oct 19 '15 at 10:09
  • Possible duplicate of [The entitlements specified...profile. (0xE8008016). Error iOS 4.2](https://stackoverflow.com/questions/5240801/the-entitlements-specified-profile-0xe8008016-error-ios-4-2) – Adela Toderici May 09 '18 at 17:59

22 Answers22

49

In my case (using XCode 10.0) nothing worked but this:

File > Project Settings... > Shared Project Settings: > Build System --> Selected "Legacy Build System" instead of the default "New Build System (Default)".

luis.ap.uyen
  • 1,314
  • 1
  • 11
  • 29
  • I am not able to find build System or shared project setting in my XCode could you please guide us on this? – CodeChanger Apr 10 '19 at 12:24
  • I had switched to legacy build system a few months ago when I first experienced this. It started happening again, and the only thing that solved it was switching back to "New Build System (Default)". – Levi Murray Jul 23 '19 at 21:41
48

For me in Xcode 5.1, I was getting The entitlements specified in your application’s Code Signing Entitlements file do not match those specified in your provisioning profile. when trying to test the app on my device. Device Development Certificate has to expire Feb 2015.

Issue was resolved:

Selected Target->Capabilities, under GameCenter, here I was getting error on GameCenter entitlement as it was not added to project, although first version of application was released via same XCode 5.1 but there were no errors like this before.

Below, a button was given with title Fix Issue. When clicked it added the GameCenter entitlement and issue was resolved.

After wards the screen looks like:

enter image description here

For me, there was nothing to do with certificate or bundle identifier. App now runs successfully on the device.

KlimczakM
  • 12,576
  • 11
  • 64
  • 83
MTahir
  • 1,173
  • 1
  • 13
  • 25
36

In XCode 7.3 I encountered the same question, I 've made the mistake because: Name in (info.plist -->Bundle identifier) is not the same as (target-->build settings -->packaging-->Product bundle identifier). Just make the same, that solved the problem.

KernelPanic
  • 2,328
  • 7
  • 47
  • 90
megar
  • 361
  • 3
  • 2
  • This was also my issue. I was in the middle of switching names with a hybrid mobile app (using Ionic 2) and I forgot to change the build bundle identifier to the new name. One quick change and BOOM. Works like a charm. – TheBrockEllis Jul 21 '16 at 17:36
  • Perfect! This was the issue, but strangely enough though info.plist bundle identifier referred to the bundle id as {PRODUCT_BUNDLE_IDENTIFIER} which is essentially the same as `target-->build settings -->packaging-->Product bundle identifier` the installation was never getting completed for me! – Raj Pawan Gumdal Sep 08 '16 at 13:32
  • This answer helped direct me to the solution in addition to the comment by dzensik. My "Bundle identifier" was some weird value. I replaced it with $(PRODUCT_BUNDLE_IDENTIFIER) and that resolved my issue – Cookster Oct 24 '16 at 21:37
  • 1
    Yeeeees! This helped me with a signing problem I've been having for hours. My problem was that `CFBundleIdentifier` was set to `$(BUNDLE_ID)` instead of `$(PRODUCT_BUNDLE_IDENTIFIER)` in the `Info.plist` of an app extension it gave me the very cryptic error "Profile doesn't match the entitlements file's value for the application-identifier entitlement." when trying to upload to Apple. Hope this helps someone! – Linus Unnebäck May 16 '19 at 09:17
  • I had an extension target (NotificationService) and I had to go to that `Build Settings -> Product Bundle Identifier` in that target and change the value to the correct one. After a day of googling and trying, this issue finally got solved. Thanks! – Rickard Elimää Sep 19 '19 at 07:51
24

First of all, you should check bundle id, provision profile and certificate with private key (.p12).

If it doesn't help. Be sure that the Code Signing Entitlements has correct value or remove it at all.

enter image description here

Dharman
  • 30,962
  • 25
  • 85
  • 135
Maksim Usenko
  • 311
  • 3
  • 5
  • Would it be fine if I completely remove those Code Signing Entitlements? Would it make any problem with AppStore submission or anywhere else on the Earth!!? – Hemang Dec 31 '15 at 11:26
  • Thanks alot after spending 2 days on it,and after tried many solution finally this solution helped me :) – Gauri Bhosle Jul 20 '17 at 11:34
24

As others have pointed out, if you get this error, you need to check that the Bundle ID value in both your .plist file and also here:

Xcode project Build Settings tab with Product Bundle Identifier focused

jscs
  • 63,694
  • 13
  • 151
  • 195
Mike Gledhill
  • 27,846
  • 7
  • 149
  • 159
  • 6
    There is no need to write down manually the Bundle identifier string into the info.plist into the key "Bundle identifier". You can just use the var $(PRODUCT_BUNDLE_IDENTIFIER) – dzensik Sep 19 '16 at 14:22
17

File > Workspace Settings > Build System > Legacy Build System

This worked for me. Xcode 10.0

Raul Borda
  • 181
  • 1
  • 4
  • Worked for me in xcode 10.2.1, changed default value to Legacy Build System – atul May 24 '19 at 11:18
  • I kept getting "Unable to install" errors when trying to install via Xcode for my Ionic app "Failure Reason: The entitlements specified in your application’s Code Signing Entitlements file are invalid, not permitted, or do not match those specified in your provisioning profile." this fixed it – JoshStrange Jan 02 '20 at 18:22
4

enter image description here

Reassign the value of Automatically manage signing, this works for me

Naresh
  • 16,698
  • 6
  • 112
  • 113
Shruti Thombre
  • 989
  • 4
  • 11
  • 27
4

In my case, the app main Target's Team was different from Tests' Target Team. Changing the Tests' Team to the same Team as main Target's solves the issue.

fajar
  • 91
  • 1
  • 2
4

None of the previous answers either applied or worked for me. In my case, updating the settings of the test project, as follows, fixed it:

enter image description here

Ash
  • 2,021
  • 2
  • 26
  • 59
2

One possible reason for this error is: your annual subscription has been renewed. Once the subscription is renewed, all devices related to the active provision profiles will be detached.

  1. The admin must reactivate the list of devices for the new subscribed year.
  2. The admin must delete last year provision profiles. (all are useless).
  3. The admin must regenerate new provision profiles for the new year with the list of devices of his choice.

After this, rebuild project with Xcode and the error will disappear.

Dharman
  • 30,962
  • 25
  • 85
  • 135
Satinos
  • 179
  • 1
  • 7
1

Had this issue. My main app and extension belonged to the same app group id correctly, but there was also one more app ID not in my project that shared said app group id. I had to remove this last app ID's association with the app group.

Royce C
  • 69
  • 1
  • 2
1

I was having same issue on Xcode 7.3 with iPad Air 2 with iOS 9.3.4! Then I tried many options.

Finally I deleted profile from device, changed bundle identifier in project settings, and whola! It worked for me.

P.S. I was using free provision profile using free Apple ID.

D4ttatraya
  • 3,344
  • 1
  • 28
  • 50
1

for me, just press cmd+, then go to account ,chose your developer account refresh(XCODE6) OR download all (XCODE7) will fix.

crystalztl
  • 21
  • 4
1

This happened to me when I was trying to build an App-store ipa exported file on my device, I had to export ad-hoc instead.

Mahgolsadat Fathi
  • 3,107
  • 4
  • 16
  • 34
  • Hi. Could you please explain a little further. I'm getting this error when building an app store ipa. Does this mean I cannot test this on my device ? – T M Aug 11 '19 at 19:35
  • @ThembelaniM you can, but you have to sign your application with ad hoc profile to run it on the device for test. – atereshkov Feb 05 '20 at 08:42
1

You should check provision profile is Product or Develop, if your project use multi configuration You should check configuration which called by schema, because it must make sure, your configuration was set provision Develop

0

Check your bundle identifier and your profiles. If you have a profile for a specific bundle identifier and no team ones and your bundle identifier does not match it will give you that error.

Bundle identifier is in General section of your project properties and the profiles you can check in build settings.

adrian.coroian
  • 582
  • 4
  • 13
0

In my case, I had a duplicate Provisioning Profile with the same name. This was accidentally created when I added an share extension to my project, stash all of those changes with git, and created a new share extension with the same name (com.companyname.project.share-extension-name). Deleting the Provisioning Profile in the developer member center (developer.apple.com) fixed this for me.

timgcarlson
  • 3,017
  • 25
  • 52
0

Had this issue with a cordova / ionic3 app, was caused by forking a main app and not selected again the legacy system in project settings. I selected legacy and the entitlements bs went away.

dgbt
  • 251
  • 1
  • 6
0

Had the same problem, nothing was helping, but I looked in Info.plist and found out that bundle ID was changed to other name (I don't know how it happened), so when I changed it to correct one everything was fine again.

Andronicus
  • 25,419
  • 17
  • 47
  • 88
0

I have also this problem when I do with XCode project what is exported from cordova framework. Resolution : You have to create Apple-ID and Provisioining-profile by yourself. Because Xcode seems to be unable to create it for you.

alphaplus
  • 344
  • 1
  • 3
  • 9
0

For me, it was an inconsistency between Debug profile (it was automatic) and Release profile (it was manual). Setting them both automatic/manual resolved the issue.

jstorm31
  • 111
  • 2
  • 3
0

I had to delete all the provisioning profiles by following this article.

Bugs
  • 4,491
  • 9
  • 32
  • 41
Todd
  • 1,770
  • 1
  • 17
  • 42