"No identity found" error when codesigning app

I keep getting this error despite having installed new certificates. I have 3rd Party Mac Developer Application, AddTrust External CA Root, Apple Application Inegration Certification Authority, Developer ID Application, Apple Worldwide Developer Relations Certification Authority, Developer ID Application, Developer ID Certification Authority, Developer ID Installer and some others. Why does it give me this error?

Replies

Are you getting this error from Xcode? Or are you signing from the command line?

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"

I am signing from the command line.

If you run:

$ security find-identity

does the identity show up in the resulting list? If so, in which section?

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"

there are 4 identities in both Matching and Valid sections.


1 is "com.apple.idms.appleid.prd....."

2 are for iPhone (Dist and Developer)

1 is for "3rd Party Mac Developer Application"


I guess it can't find the others even though they're listed in Keychain Access?

I have my app on my Desktop, did "cd Desktop" then ran

codesign -f -s "3rd Party Mac Developer Application: MyName (MyNumber)" "MyApp.app"

but it says "No such file or directory". I ran ls and it listed my app on the desktop where i had navigated to in Terminal too. Don't understand. No typos either. Is that script wrong? Yes, i did replace my MyName, MyNumber and MyApp with the appropriate ones.

In Keychain Access, I selected my Developer ID certificates and then had Keychain Access evaluate them. The Developer Application certificate is good for codesigning. The Developer Installer certificate, though, is listed as Invalid Extended Key Usage. The 3rd Party Mac Developer Application certificate is listed as Success and Good. I believe this certificate is for another app specifically, though, one i'd tried to get into the App Store before, but it was turned down because it used QuickTime, a "legacy app." Tried creating a "wild card" certificate, but it won't let me install it. It says "Only Development Provisioning Profiles can be installed in System Preferences. Production Provisioning Profiles are imported within Xcode." No idea what that means. Wish i could just hire someone to do this for me. It's ridiculous.

The problem for me was that I didn't have the private key in my keychain for the certificate. If the private key is imported, you will see a disclosure triangel next to the certificate in KeyChain and when you expand it you will see the private key. I had generated the CSR on another machine. I imported the certificate into that machine's KeyChain, then exported it as a .p12 file with a password and imported into the machine where I was getting this error. It then worked.

codesign -f -s "3rd Party Mac Developer Application: MyName (MyNumber)" "MyApp.app"

Here you just have to provide MyNumber to -s arg.
Here is how it gets done:
codesign -f -s "MyNumber" "MyApp.app"

Happy Code Signing!

I figured this out for my account after a bit of trial and error. I had typed...

"Developer ID Application : Chilton Webb"

... and after running security find-identity in the terminal, I copy and pasted what I found:

"Developer ID Application: Chilton Webb"

Note the lack of a space ^^^^ after Application, before the colon.

That was it.

Good hunting, -Chilton

  • CHILTON my guy, you are a lifesaver. This fixed it for me! THANK YOU!

Add a Comment