44

I'm trying to debug my app on Xcode and I'm having the following error:

The identity used to sign the executable is no longer valid.

Please verify that your device’s clock is properly set, and that your signing certificate is not expired.

(0xE8008018).

enter image description here

Now I know there are many questions regarding this issue, and I have tried every possible way to solve it, what I have tried so far (didn't work):

  • Some suggested to restart Xcode.
  • Refreshing the account.
  • Deleting all the certificates from the keychain.
  • Revoking all the certificates from the member center.
  • Installing the certificates manually.
  • Checked my Devices clocks (obviously)
  • Removed Xcode (disparately) and re-installed it.
  • Checking my project Build config, and made sure that the developer account is selected.
  • Checked my account expiration date (it's renewed 5 days ago)
  • Checked if I have to accept some Conditions and Terms (none)
  • Disabled the devices I have in the Member profile
  • Tested on multiple iPhones (same result)
  • Checked out a git tag/branch which is stable (I thought the project might be corrupted also disparately)

My concern is that it might be a temporary issue from apple, or a bug in Xcode, although it was working hours ago on my iMac, when I switched to the MacBook Pro I had this issue (and I always do this with no problems at all).

Running:

  • OSX Yosemite 10.10.4 (14E46)
  • Xcode 6.4
Hatem Alimam
  • 9,968
  • 4
  • 44
  • 56

11 Answers11

68

Trying to remove and re-add your apple id, it works for me.

  1. xcode: Preferences...
  2. Accounts
  3. Select your apple account
  4. Remove that (-)
  5. Add again your apple account (+)
  6. Run yor app!
Sebastián Lara
  • 5,355
  • 2
  • 28
  • 21
29

After hours of investigating, the shell script for signing the project was failing at some point, without reporting back to Xcode.

I noticed that in the DerivedData folder (found in /Users/yourUsername/Library/Developer/Xcode/DerivedData/) of Xcode there were two folders with the same name of my project ending with a different hash, for example:

ProjectName--dcakkvkdhqvxstehdiuzwbpsmdal
ProjectName--kurbctkdhqvxuytrwnczwbpsmdal

I closed Xcode, and made sure to delete both folders, somehow Xcode generated two different folders for the project at some point, restarting Xcode after the deletion of the folders fixed this.

Hatem Alimam
  • 9,968
  • 4
  • 44
  • 56
  • This worked for me as well. My derived data folder was in a different location though (http://stackoverflow.com/questions/24039932/how-to-delete-derived-data-in-xcode6) is how I found mine. I couldn't delete the folder through Xcode though, so I copy and pasted the path that xcode told me and then deleted it command line as described above. (facepalm) I want this hour of my life back. – gregkerzhner Nov 13 '15 at 10:46
  • Nothing worked for me but this solution. I went totally crazy generating again certs and profiles.. I had 3 folders with the same name of my project. Deleted them and.. magic! Thanks! – mursang Nov 18 '15 at 12:29
25

I have experienced the same situation.

But it was cleared by deleting and downloading again the provisioning profiles on my mac.

The location of the provisioning profiles is:

/Users/yourUsername/Library/MobileDevice/Provisioning Profiles/

Oliver W.
  • 13,169
  • 3
  • 37
  • 50
Yeong Hoon Cha
  • 251
  • 3
  • 2
4

I had the same issue. What helped me:

  1. Set Profile to a wrong one (other project)
  2. Run project and received the popup with information that provision profile is wrong and proposal to Fix the issue
  3. Press Fix the issue
EugeneD
  • 41
  • 3
1

Just login to your developer account and create new developer certificate or revoke older one an create new. It will resolve the issue.

1

A Solution that might help some People

  1. Go to developer.apple.com
  2. go to the identities/certificates page
  3. then click on Provisioning Profiles If you found few invalid
  4. profiles just edit them
  5. Make sure you check your main profile.
  6. Click generate and close.
  7. Now in XCode, remove your profile Add it again.
  8. You're good to go

This will happen if you changed your Primary Email

Shehabic
  • 6,787
  • 9
  • 52
  • 93
0

Delete files and folders from:

  • ~/Library/MobileDevice/Provisioning Profiles/
  • ~/Library/Developer/Xcode/DerivedData/
Misa Lazovic
  • 2,805
  • 10
  • 32
  • 38
0

The only solution for this problem is to delete the folder from

~/Library/Developer/Xcode/DerivedData/YourAppName- 

This way everything will get back to normal !

Cheers !

jogo
  • 12,469
  • 11
  • 37
  • 42
danger2k7
  • 1
  • 2
0

All of the answers helped a lot but in my case developer certificate got expired that's i was getting this error while building the app.

Keychain -> Login -> My Certificates

So just removed the certificate and created new one worked fine for me.

Buntylm
  • 7,345
  • 1
  • 31
  • 51
0

NONE of this worked for me

vomako 's answer at The identity used to sign the executable is no longer valid DID work -

i.e. "Solution within Xcode:

In Xcode, go to Preferences --> Accounts --> View Details

Press the refresh button in the lower left corner (called Download all in Xcode 7)"

end of his post

It's a little refresh symbol now (circling arrow) Then click on the Request button

Hope this saves somebody some time

Community
  • 1
  • 1
DontKnow
  • 399
  • 4
  • 14
0

I have solved the same problem. Just from "https://developer.apple.com/account/ios/profile/production/create" re-created the new Provisioning Profiles. Then download and install the new Provisioning Profiles of (Development and Distribution). enter image description here

ylgwhyh
  • 1,588
  • 18
  • 21