Start by visiting the program portal
and make sure that your developer
certificate is up to date. It expires
every six months and, if you haven't
requested that a new one be issued,
you cannot submit software to App
Store. For most people experiencing
the "pink upload of doom," though,
their certificates are already valid.
What next?
Open your Xcode project and check that
you've set the active SDK to one of
the device choices, like Device - 2.2.
Accidentally leaving the build
settings to Simulator can be a big
reason for the pink rejection. And
that happens more often than many
developers would care to admit.
Next, make sure that you've chosen a
build configuration that uses your
distribution (not your developer)
certificate. Check this by
double-clicking on your target in the
Groups & Files column on the left of
the project window. The Target Info
window will open. Click the Build tab
and review your Code Signing Identity.
It should be iPhone Distribution:
followed by your name or company name.
You may also want to confirm your
application identifier in the
Properties tab. Most likely, you'll
have set the identifier properly when
debugging with your developer
certificate, but it never hurts to
check.
The top-left of your project window
also confirms your settings and
configuration. It should read
something like "Device - 2.2 |
Distribution". This shows you the
active SDK and configuration.
If your settings are correct but you
still aren't getting that upload
finished properly, clean your builds.
Choose Build > Clean (Command-Shift-K)
and click Clean. Alternatively, you
can manually trash the build folder in
your Project from Finder. Once you've
cleaned, build again fresh.
If this does not produce an app that
when zipped properly loads to iTunes
Connect, quit and relaunch Xcode. I'm
not kidding. This one simple trick
solves more signing problems and "pink
rejections of doom" than any other
solution already mentioned.
Best Solution
The code signing step is notoriously fussy and buggy. Make sure you have followed the steps to get the certificate and profile from Apple absolutely exactly. Then check your build settings under 'code signing identity'.
You don't need a device connected though it is handy for checking it all worked. However I have found on occasion I've needed to edit the project file by hand - you shouldn't need to do that, especially with 3.xSDK as it is a bit better at the code signing stuff.
Possible reasons for the error are
1) a mismatch in the name that is in the certificate, vs the name that is set in your project. However 3.0 is supposed to automatically match 'iPhone distribution' and not be so fussy about an exact match.
2) You haven't added the certificate you got from apple to the keychain
3) Your project file has got confused and has wrong profile settings due to a bug in XCode. Shouldn't really happen but I find myself going into the project package contents and editing the project file in textedit sometimes - not for the faint of heart, and you should make a backup if you try this.
4) Make sure the profile you got from apple is installed properly in xcode (look in the organiser window).
5) To check that it works OK it does help to try installing it on a device, though it's not strictly necessary. Using the application uploader rather than the itunesconnect website to upload the distribution file is another good check, it should object if the file is not signed properly. (Though having said that I've had trouble with the app uploader and had to use the website upload sometimes).
The short version is there is a pretty good chance you've done everything right and just hit a bug in xcode. Even when it seems to have worked, it often hasn't. The whole thing is a mess. Just try redoing the steps and changing the code signing identity in xcode. Also clean out any old profiles you're not using, to give xcode less chance of picking the wrong one.