11

I'm having problems submitting my iphone application. I saw some similar questions, but I didn't find an answer.

When I archive the project and click validate, I get the error message "Application failed codesign verification. The signature was invalid, or it was not signed with an Apple submission certificate."

I'm assuming I did something wrong in the codesigning section. I followed a youtube tutorial that had me download all the certificates and set up the codesigning section, but I don't think I set up the codesign section correctly.

enter image description here

enter image description here

Additionally, when I build for iOS I get this. In all the tutorials I've seen, no one actually has "" written out, so it's possible that this is related to the problem.

enter image description here

I am not getting Ear Training (name of my app) as an option under the menu of distribution. I downloaded all the distribution certificates, so I can't figure out what I'm doing wrong. I also tried making my own certificate, as instructed by this tutorial, but the certificate does not appear under the code signing options. Any help would be appreciated, Thanks

this is what I have in keychain access. The certificate with the x is the one I tried creating in the tutorial. Is it possible that I need to import them to xcode? I tried dragging and dropping into the project as well as the organizer, but to no avail.

enter image description here

Mahir
  • 1,684
  • 5
  • 31
  • 59

11 Answers11

20

Your Build settings appears to have a DEVELOPER certificate for the RELEASE version.

In order, to validate and submit a binary you've to configure the release version to use a DISTRIBUTION certificate.

Create and download a Distribution certificate and import it (drag and drop to Xcode).

Configure the build/release for using the distribution certificate. If you don't see the new distribution certificate as an option for your build, check the AppleID used both for generate the certificate and for your Build settings. They must be the same, otherwise Xcode can't sign your app correctly.

This will solve your problem.

valvoline
  • 7,737
  • 3
  • 47
  • 52
  • It doesn't let me drag and drop the certificate from keychain access – Mahir Jan 19 '12 at 07:50
  • 1
    the certificate on your keychain access does not have anything to do with the provisioning profile. I suggest you to read in deep the Apple Developer Documentation. Sounds like you are missing some foundamentals. – valvoline Jan 19 '12 at 10:27
  • This fixed a warning for me - even though I was using a distribution profile for my custom ad hoc scheme – gheese Mar 07 '13 at 18:17
4

To solve this type of problems, Go through following steps:

  1. Download required provisioning profiles(debug,ad_hoc,app_store)
  2. Go to target (click on application name --> target)
  3. click on info tab (next to summary )
  4. change the Bundle identifier as you given in provisioning profile
  5. click on build settings
  6. go to code signing section
  7. now select correct provisioning profile in each row(code signing identity,debug,... etc.)(for app-store must select app_store provisioning profile )
  8. set "yes to distribution" in "build options" section
  9. click on project name under "project section "
  10. repeat step 6,7 and 8
  11. go to "edit scheme" (click on project name next to stop button --> edit scheme)
  12. change build configuration to distribution(only for app_store and ad_hoc profiles)
  13. make a build for ios device and then validate or distribute
user unknown
  • 35,537
  • 11
  • 75
  • 121
3

I had same problem while I send my binary to itunes connect.

I found the solution by renaming "resources" folder with some different name.

Make sure you have not created or used folder in your application with name "Resources". This may conflict while submitting app to itunes connect.

dandan78
  • 13,328
  • 13
  • 64
  • 78
0

The error went away for me when I compressed the .app.dSYM file together with my .app file before uploading it to iTunes with the application loader.

kaore
  • 1,288
  • 9
  • 14
0

I spent 9 hours solving this problem... turned out that Xcode also gives the "Application failed codesign verification" error if your project is located on another server.

Skod_alf
  • 1
  • 1
0

Check that the TARGET (and not only the Project) is setup with the correct Code Signing Identity for Release

Lucas
  • 6,675
  • 3
  • 25
  • 43
0

This is generally very helpful with figuring out CodeSign problems. A very detailed troubleshooting guide.

https://developer.apple.com/legacy/library/technotes/tn2250/_index.html#//apple_ref/doc/uid/DTS40009933-CH1-TNTAG31

Cœur
  • 37,241
  • 25
  • 195
  • 267
DenNukem
  • 8,014
  • 3
  • 40
  • 45
0

In spite of what you say, there does not appear to be an appropriate distribution certificate downloaded. In the Provisioning portal click on the "Distribution" tab and find your certificate. Click the download button on the right next to the appropriate certificate.

ChrisPadgham
  • 860
  • 5
  • 4
  • I took a screenshot of what I already have in keychain and added it to the question. Let me know if I still need to download it again – Mahir Jan 17 '12 at 02:42
0

Try to close your app first then open it again... if it still can't see your distribution

try to see if there are possible options in the (Don't Code Sign) rows

if still no options you can repeat the tutorial that you followed

try to see the info.plist if your bundle id is correct. com.(company name).(appname)

if you get

Code sign errors

you can view this Link and this Link

Community
  • 1
  • 1
NoobMe
  • 544
  • 2
  • 6
  • 26
  • @MahirE try also to clean and build . – NoobMe Jan 17 '12 at 02:59
  • also see this link http://www.smartapps.co/2011/02/tutorial-code-signing-in-xcode-4/ it is for xcode 4 and i assume that you are using xcode 4 – NoobMe Jan 17 '12 at 03:04
  • I forgot to mention, when I try building with iOS device, it says "Xcode would like to use key " Everywhere I've seen, xCode actually displays a key, but for mine, it just says "" Could that be a problem? – Mahir Jan 17 '12 at 03:17
  • I tried creating my own certificate as the tutorial instructed, but it won't show up under the code signing menu in my app – Mahir Jan 18 '12 at 02:48
0

You need not only a valid Distribution certificate, but a distribution provision file that matches that certificate and is appropriate for your app's Bundle ID.

hotpaw2
  • 70,107
  • 14
  • 90
  • 153
0

First of all you have to create a new App ID in in the iOS Provisioning Portal. To create your App ID be sure to use the same Bundle Identifier that you are using in your project.

Second you have to create a Distribution Provisioning Profile in the "Provisioning" section and "Distribution" tab. This profile will link your App ID with your Distribution Certificate. Be sure to select "App Store" Distribution Method, and the App ID reciently created. Download the Distribution Profile and double-click to install (you can also add it manually with the Organizer in the "Devices" tab).

Now you are able to setup the codesign section in your project. Select the profile you have just created for release and distribution methods, archive and then validate.

For further information you can read the How to's in the iOS Provisioning Portal

Esepakuto
  • 1,332
  • 9
  • 12