33

I get this build error when I build my iPhone project to run on my device:

 **Code Sign error: The identity 'iPhone Developer: x Xxxxx' doesn't match any identity in any profile**

My development code signing certificate expired so I got a new one. On my first attempt I created a new CSR and got the message above. The second time I reused my original CSR and got the same result. Another strange thing is the new certificate has an extra string with brackets after my name in the "common name" when I look at it using Keychain Access like this:

iPhone Developer: x Xxxxx **(3BDUAJYC9Q)**

`My original certificate didn't have that.

I have Xcode Version 3.1.3
Component versions
Xcode IDE: 1191.0
Xcode Core: 1192.0
ToolSupport: 1186.0

Does anyone know how to solve this?

Nag
  • 1,438
  • 1
  • 11
  • 39
Cal
  • 1,625
  • 4
  • 20
  • 30

6 Answers6

44
  1. Right Click the Project (eg. x.xcodeproject) and select Show Package Content
  2. Open project.pbxproj with TextEdit
  3. Search for all "CODE_SIGN_IDENTITY[sdk=iphoneos*]" and set it to "CODE_SIGN_IDENTITY[sdk=iphonesos*]" = "iPhone Developer";
  4. Search for "PROVISIONING_PROFILE[sdk=iphoneos*]" and set it to "PROVISIONING_PROFILE[sdk=iphoneos*]" = "";
  5. Save the file
  6. Reopen the Xcode project or select "Read from Disk" resulting from Xcode the prompt.
  7. This Worked for me. I hope it works for you too.
rahil627
  • 92
  • 2
  • 8
kw4m3n4
  • 441
  • 1
  • 4
  • 2
  • 1
    Great, that led me to the solution of my problem, see here: http://stackoverflow.com/questions/1072311/code-sign-error-the-identity-iphone-developer-x-xxxxx-doesnt-match-any-ident/6376483#6376483. Thanks! – Tim Büthe Jun 16 '11 at 18:05
  • Argh. Mine need those modifications, but TextEdit won't let me save them. File is not locked and I have read/write on it, however it's saying I don't have permission. What's the magic trick to get it to let me save? – Brian Knoblauch Sep 17 '12 at 17:01
  • PROVISIONING_PROFILE does not exist in project.pbxproj in my version of Xcode. Using Xcode 4.6.3 (4H1503). – Nick Bolton Jul 02 '13 at 11:27
19

I think you need to create new provisioning profiles based on your new certificate.

Log on to developer.apple.com and go to the iOS Provisioning Portal -> Provisioning -> Development. Most likely, the profile you once created has expired, so just renew and redownload it.

Trott
  • 66,479
  • 23
  • 173
  • 212
David Maymudes
  • 5,664
  • 31
  • 34
3

Following kw4m3n4's answer, I found the special characters (umlaute) in my name where messed up in the file. I fixed it like this:

  1. right click the .xproject file (e.g. yourproject.xproject) and select Show Package Content
  2. open project.pbxproj with textEdit
  3. search and replace the messed up name / umlauts (e.g. "Tim B√ºthe" -> "Tim Büthe")
Community
  • 1
  • 1
Tim Büthe
  • 62,884
  • 17
  • 92
  • 129
1

For me the problem was that I did choose debug on device by accident, as I inteded to switch to iPhone simulator. To debug on an emulator it worked as before by selecting simulator in the menu.

user507410
  • 512
  • 4
  • 12
1

If you have multiple developer accounts, then make sure you're signed into the right one in xCode- that was the problem when I had this error.

Brad
  • 705
  • 7
  • 21
0

Silly me... The problem was I still needed to create a new "Provisioning Profile" which uses the new certificate in the iPhone program portal and load it into Xcode. I didn't need to add the extra string after my name in the code signing section for debug.

Cal
  • 1,625
  • 4
  • 20
  • 30