For a future project, I need to find out how the encoding process for Apple iOS IPA files (iPhone / iPad) works. The goal of my project will be to create (in Delphi) a Windows tool for encoding a single IPA file (previously compiled using "Do not Code Sign" via Xcode).
One certainty is that it is only possible to encode an IPA file on Windows; as Adobe does with AIR / Flash CS5. In addition, Epic Games, Inc. built UDK (Unreal Development Kit) with a third-party tool for encoding IPA files.
This last one was encoded in C # /. NET, so I tried to study the source code to find out how the coding process works, but wow, the code is quite developed and even if between C # / there is a significant similarity between .NET and Delphi, I quickly blur ...
The UDK iPhonePackager is really close to what I want to do (with less features).
From my research: certificates and keys can be "generated" through OpenSSL on the command line; Apple uses X509 certificates for encoding binary code (?); a component such as the Bouncy Castle Crypto API can be used to manage certificates.
An interesting article about the process of creating codes from Apple: http://developer.apple.com/library/mac/#technotes/tn2206/_index.html
I will also have to generate "CodeResources"; "embedded.mobileprovision" from the Mobile Provisioning file; and "CodeSignature / CodeResources" with a hierarchy of all files, such as:
<key>MainWindow.nib</key> <data>GTBfZPINlJlD7HXjMRAKgfAztXU=</data>
If you are still reading, you should definitely have a headache :)
So, below are a few questions to start ...
Is it possible to re-sign a binary file already compiled and signed with "Do not Code Sign"?
Do you think my project is really hard work?
Do you think I would be better off hiring a developer? I may have a budget for this project, but ideally I would like to do it myself, of course ...: D
Thanks a lot in advance for your tips and / or suggestions.
Beny