5
votes

I am new in iPhone Distribution . I created Apple ID U765UXW88D.com.edwincs.*. and provisioning profile name is MobileHealthGuide. I made these in Distribution tab.

My xcode version is 3.2.4 While uploading application with application loader , I got this error

Application failed codesign verification. The signature was invalid, or it was not signed with an Apple submission certificate.

My project name is MobileHealthGuide too. I have tried revoking the certificate and provisioning profile, but the error persists.

How can I solve this problem?

7
did any of the below solutions worked for you ?Ajay Sharma
No. I can't solve the problem still now.thinzar
then try with removing all certificates & key from Keychain & start with fresh certificates using this link : mobiforge.com/developing/story/…. Anyhow it will solve your problem.Ajay Sharma

7 Answers

1
votes

I've encountered the same problem too. It showed that I had a duplicate certificate registration in my keychains. Removing one of them (I removed the one from my system keychain) fixed the problem.

Steps that helped me to resolve my problem:

  1. Open KeyChain Access application
  2. Select the 'login' keychain, and select in the bottom pane 'Certificates'
  3. Switch to the 'system' keychain and see if there are certificates registered in both chains.
  4. Remove one of them
  5. Rebuild the application
  6. You probably need to check what code signing profile is selected in your distribution build properties.

Alright, then make sure to clean the build & delete the Build folder from the app. If this doesn't work for you, there is one more alternative :

Verify below steps to create distribution certificate and perform that if you miss anyone.

  1. Generate a certificate signing request in keychain.
  2. Using that create or revoke a DISTRIBUTION certificate in the portal. after that download and install it and verify key under the name.
  3. Register the device in the provisioning portal.
  4. Then create or modify a DISTRIBUTION profile in the portal. after that download and install it and verify it appears to be valid in Organiser as there are no warnings.
  5. Make sure to select proper build setting in xcode.

Now this will definitely, solve your problem.

1
votes

Make sure you added right code sign in project target.enter image description here

1
votes

Ok so here are detailed steps on how to distribute:

You want to request a development and distribution certificate in Keychain Access and upload it to developer.apple.com (you are part of the developer member program right?)

Create an app ID (in provisioning profiles)

Create a distribution certificate - make sure this and step 2 follow your bundle ID

Download the profile and drag to Xcode

Go to your Xcode project, in the target or project build settings set your code signing option to the Distribution certificate (which must match your Bundle ID and of course your distribution and development certificate) - there might be a recommended or automatic profile, just choose the one that matches your identity and app provisioning profile and Bundle ID

Now go to edit scheme -> then change from debug to release

Then go to project than target than build settings and type in 'Code Signing', change the options to your distribution profile

Set to build for an iOS device (or none at all)

Go to product -> Build For -> Build For Archive

Scroll down on the side (your classes tab etc.) to the product which should be named (AppName.app) and show it in finder.

Create an application on iTunes Connect

Compress the .app and load it to Application Loader

Send it off!

Tips:

  1. Make sure you are using the correct Bundle ID
  2. Try cleaning
  3. Make sure you're certificate is not expired

Here is an expanded list of reasons why this may occur:

0
votes

Upgrade your xCode! you are using a really old one.

Probably you tried it but go to https://developer.apple.com/ then iOS provisional portal there are lots of tools can help you.

If you are not using inApp purchase, push notification, iCloud etc. you can skip the App ID and just set a general certificate one that would be like U765UXW88D.* so that you don't need to do this process every time for new apps.

Make sure you created distribution certificate and sign with that on xCode for release/distribution.

On xCode itself make sure you defined the bundle ID same as on iTunes connect.

Good luck.

0
votes

I've got a similar problem as well. In one project, using my dist profile, it works perfectly and I can build to a device.

In another project, when using the same dist profile, the app launches, loads the splash screen, processes the first page and then exits without throwing an error in Xcode or in its own log.

When I change the code signing to a generic dev profile, the app launches without a problem on the desired device.

I've redownloaded the certs, the dist profiles, deleted the old ones.

How is this even remotely possible? And how can this be fixed?

0
votes

Failed signature verification can happen for many different reasons. See Apple's list of common causes in TN2250.

0
votes

The most common reason for failing distribution signature validation is because the app was signed with a developer profile instead of a distribution profile, or the app was built with the wrong build configuration. To consider this potential cause check your settings against the recommendations that follow:

The Release build configuration must be assigned to your Archive task. To ensure this, select the "Scheme" pop-up menu in the upper-left corner of the Xcode Toolbar, and choose "Edit Scheme". Select the "Archive" task and make sure the Build Configuration is "Release".

To check that your app is signed with the correct distribution profile, use the steps in section How do I check which certificate was used to sign my app? and ensure the Authority is "iPhone Distribution". If it is not, continue to next bulleted items to correct the responsible configuration.

Ensure that the appropriate distribution provisioning profile that you created for this application on the iOS Portal site is assigned to the Release build configuration. To ensure that use the steps in section Assigning Provisioning Profiles to Build Configurations.

Next, ensure that you are choosing the correct distribution provisioning profile when distributing your app on the Xcode Organizer > Archives tab. To do that, use the sections linked below depending on your distribution method and take special note you're selecting the correct profile on the "Identity" field (Xcode 4-4.2) or "Code Signing Identity" field (Xcode 4.3+) after clicking Submit/Share/Validate or Distribute on the Xcode Organizer > Archives tab.

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