I hope this will help someone.
I have been pulling my hair out for two days to find a solution to a number of errors within Application Loader on Mac while trying to publish an application that I had built in Flash Builder 4.6 on windows to the App store. The first error was:
- 'unable to extract archive. please make sure myApp.ipa is a valid zip or ipa archive"
To solve this:
1. Change the extension of the myApp.ipa file to myApp.zip on the windows machine
2. Move the myApp.zip file via thumb drive (not email) to the mac
3. Decompress myApp.zip. You should see the Payload dir.
4. Inside the payload there is a myApp.app file. Compress that file to myApp.zip
5. Upload that new compressed myApp.zip via Application Loader
Solved, new error:
- 'Application failed codesign verification.The signature was invalid, contains disallowed entitlements, or it was not signed with an iPhone Distribution Certificate.'
- 'Unable to extract codesigning entitlements from your application. Please make sure myApp is a valid Mach executable that's properly codesigned.'
The new myApp.zip file is not signed correctly, fail.
Next solution is to sign the payload correctly on the Mac:
1. Take the original myApp.zip file from the thumb drive
2. Decompress myApp.zip. You should see the Payload dir.
3. Sign the myApp.app file inside the Payload dir.
- Open terminal
- codesign -f -s "the name of your distribution cert" myApp.app
4. Compress the Payload dir into Payload.zip
5. Rename the Payload.zip to myApp.ipa
6. Upload that new myApp.ipa via Application Loader
Solved, rejected by app store:
The identifier "myApp" in your code signature for myApp in myApp.app must match its Bundle Identifier "my.app".
Ok, now I'm starting to get cross. After all that the solution to the entire thing was quite simple. 'resources' IS A RESERVED DIRECTORY!!! I included a directory in my src called 'resources' that stored all the graphical assets. Flash builder obviously has a problem with this and corrupts the signing process of the app with no feedback what so ever. I simply renamed the resources dir, published the .ipa from Flash Builder, uploaded via Application Loader, and approved no worries. fml.
I have absolutely no idea how I came across this solution but it worked. So forget everything you have read in this post and simply CHECK YOUR SRC DIRECTORY!.