Wrong code signing identity is chosen (SOLVED)

All of a sudden I have problems when signing apps for iOS - or rather the signing part works in Defold, but when I try to upload it with Application Loader I get

“ERROR ITMS-90179: Invalid code signing. The executable ‘’ must be signed with the certificate that is contained in the provisioning profile”.

I have recreated both my Certificate and the provisioning profile to no avail, but it seems the signing identity chosen by Defold is not the desired one. I only have one in the list, and that is “Developer ID Application”, which is not the same as I would choose in XCode (and it is also not the one corresponding to the cert downloaded from Apple Dev).

This is usually a nightmare to figure out. Some things to look into:

  • Make sure that you have a “iPhone Developer: xyz” or “iPhone Distribution: xyz” certificate in your Keychain and that it has a valid key.
  • Make sure the certificate in your keychain and what you chose in the Bundle->iOS Application->Code Signing Identity matches what you have in the provisioning profile that you select in the Bundle->iOS Application->Provisioning profile dialog (or if you’re bundling via bob.jar).
  • I do have an “iPhone Distribution: xyz” with a valid key - but it doesn’t show up when I bundle in Defold and it says “This certificate has an invalid issuer” when selected in Keychain
  • The provisioning profile should have the “iPhone distribution” cert, but I can’t choose that in Defold and I can’t create a provisioning profile with “Developer ID Application” as far as I know

Ok - I solved it by resigning the application with the correct cert manually so the problem is definitely that I can not choose that cert in Defold

This sounds like something having to do with Apple issuing a new cert, please try this; http://stackoverflow.com/questions/35390072/error-this-certificate-has-an-invalid-issuer-using-apple-push-services

The available values in the “Code Signing Identity” dropdown when you bundle for iOS are taken from the valid certificates in your keychain. If you have a problem with your certificate in your keychain then it won’t show up in Defold.

Yes, I found that thread while searching for the error and installing the new certificate was my first action - but it didn’t help

Johan managed to solve this by deleting the cert from the Keychain and redownloading it from Apple.

1 Like