33

Is it possible to create an unsigned iOS app, .ipa file? We have an enterprise customer that requires an unsigned IPA file of our iOS application, which they will then sign with their MAM product.

If it's possible, how can I do this?

Diego Barros
  • 2,071
  • 2
  • 33
  • 45

6 Answers6

49

Once I copy it from a blog. The steps are as follow:

Build unsigned .ipa without Developer Account on Xcode 5

To Disable Code Signing:

1.1 GoTo /Applications then right click Xcode.app and click "Show Package Contents"

1.2 GoTo Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk/ and copy the file SDKSettings.plist to desktop

1.3 Open the file copied SDKSettings.plist. Under "DefaultProperties" ==> "dict" find CODE_SIGNING_REQUIRED and change its value from YES to NO. Save the file

1.4 Copy this modified SDKSettings.plist file back to Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk/ replacing the orginal file [YOU MAY SAVE THE ORIGINAL FILE AS BACKUP] Do the required AUTHENTICATION AS REQUIRED

1.5 Restart Xcode and open your runnable xcode project

1.6 In Project Navigator select your project and open Build Settings section of your porject and Select All sub-heading.

1.7 Under Code Signing find Code Signing Identity and for both Debug and Release modes set Any iOS SDK to Don't Code Sign.

To make an IPA:

2.1 In Xcode, goto Product and click Archive

2.2 7th step will build you project and creat an Archive. After the completion of the process, new window Organize - Archive will be opened. In the list of this window you can see your project. Right click project and click Show in Finder which will reveal *.xcarchive file

2.3 Right click the *.xcarchive file and click Show Package Contents and goto Products => Applications where you will see an app file with the name of your project "projectname".app

2.4 Open iTunes change view to Apps and drag the app file "projectname".app into the iTunes.

2.5 Right Click your app, click Show in Finder. There you will have you .ipa file.

Important Notes :

3.1 In Step 2.1, if the Archive menu is disabled this is most likely because the a simulator option is currently selected as the run target in the Xcode toolbar. Changing this menu either to a connected device, or the generic iOS Device target option should enable the Archive option in Product menu.

3.2 You will also need to install AppSync in your iPhone via Cydia.

Nikolay Fominyh
  • 8,946
  • 8
  • 66
  • 102
Rashad
  • 11,057
  • 4
  • 45
  • 73
  • 2
    Seems like a lot of playing around and messing even with Xcode's internals (Package contents). Seems easier to just get the client to re-sign it with something like https://github.com/maciekish/iReSign or codesign app itself. – Diego Barros Aug 20 '14 at 03:53
  • @dbarros & Drongo - Do any of these methods still work with iOS 9.2 ? – Alex S Feb 28 '16 at 06:36
  • @AlexS Sorry, I've not looked at this in a long time. – Diego Barros Feb 29 '16 at 01:22
  • 1
    @AlexS Yes I have built the ipa with these method on iOS 9.3 – jedi Jul 08 '16 at 11:10
  • 1
    What does "Under ==> find and change its value from YES to NO. Save the file" means What is "==>" ? Which key should we convert to NO – ozanonurtek Sep 18 '16 at 12:45
  • With XCode 8.2, I couldn't able to add .app file to iTunes to create ipa file since it is showing an error "could not be added to your itunes library because it is not a valid app". Can you please give some inputs on this issue? – Srinivas G Dec 15 '16 at 14:21
  • @phantom It is "CODE_SIGNING_REQUIRED" – Srinivas G Dec 15 '16 at 14:23
  • http://initcodes.blogspot.com/2014/01/build-unsigned-ipa-without-developer.html video demonstration: https://www.youtube.com/watch?v=yAT8TcwjoIU – sabbir Jul 17 '17 at 23:49
  • I have followed the same but I am getting build error i.e Project requires development Team. Anyone can help me out on this, I am using Xcode Version 10.2.1 – kalpa Sep 19 '19 at 09:04
  • If anyone really needs the iTunes with the deprecated apps section, you can still get it from Apple: https://support.apple.com/en-us/HT208079 – Funktional Nov 13 '19 at 21:48
  • Thank you! I got my IPA file and installed on my Jailbroken device. – iThanh Dec 04 '20 at 07:42
32

The easiest way is to build on the command line.

    /usr/bin/xcodebuild -scheme MYSCHEME -workspace MYWORKSPACE.xcworkspace   
    -configuration Release clean archive -archivePath "build/APPNAME.xcarchive" 
    CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO
Daniel Broad
  • 2,512
  • 18
  • 14
  • 12
    How can I then create an .ipa from xcarchive? xcodebuild -exportArchive requires exportOptions.plist and signes the app. – Pavel Alexeev Apr 05 '18 at 08:15
  • for Xcode 10.2 I had to use CODE_SIGNING_ALLOWED=NO. – szotp Apr 09 '19 at 06:50
  • 2
    This is a vastly preferable solution to hacking Xcode. – Joshua Sullivan Aug 02 '19 at 21:22
  • 1
    hi @Daniel Broad I hav followed these steps, but I am getting the following error PhaseScriptExecution Bundle\ React\ Native\ code\ and\ images /Users/@@@@/Library/Developer/Xcode/DerivedData/xxxxxx-bosdocbhmrkuljajuzqyqhhwmwdz/Build/Intermediates.noindex/ArchiveIntermediates/xxxxxxx/IntermediateBuildFilesPath/xxxxxx.build/Release-iphoneos/xxxxxx.build/Script-00DD1BFF1BD5951E006B06BC.sh. xxxxxx: is my project name here. I deleted the derived data and tried again but still no luck. Same error I got – kalpa Sep 19 '19 at 07:11
7

yes, this is possible; I do this currently with Xcode 5/iOS 7 SDK.

you must edit the /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS*.*.sdk/SDKSettings.plist file as below.

change this:

<key>CODE_SIGNING_REQUIRED</key>
<string>YES</string>

to this:

<key>CODE_SIGNING_REQUIRED</key>
<string>NO</string>

The directions I have used are taken from this Wiki here which may provide you some additional helpful information.

There may be some additional changes you need to make to the build settings such as Code Signing Identity and Provisioning Profile (probably just set these to none)

Alex S
  • 242
  • 2
  • 17
Brad Allred
  • 7,323
  • 1
  • 30
  • 49
3

These were my steps after iTunes 12.7.0 since they removed the App View menu item.

2.4 - Create a new New Folder called Payload

2.5 - Add the "procjectname".app into the Payload folder

2.6 - Compress the file into a zip folder

2.7 - Rename the file from Payload.zip to "projectname".zip

2.8 - Change from "projectname".zip to "projectname".ipa

-1

Steps to create unsigned IPA (Tested on Xcode 9.4.1)

Step 1: Open finder > Go to Folder.. as below screen

enter image description here

and then copy and paste the below line:

/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS*.*.sdk/SDKSettings.plist

Open iPhoneOS.sdk as showing in below image: enter image description here

Step 2: Copy the SDKSettings plist in another folder because you can't make changes here:

Step 3: Make change in duplicate

set CODE_SIGNING_REQUIRED to NO enter image description here

Step 4: Now replace duplicate Plist with original one (Both name must be same). This will also ask admin permission to change.

Warning: Please make sure you have copied the original plist and save somewhere for future reference.

Step 5: Now set code signing identity to as below image: enter image description here

and now you can create the Archive file enter image description here

**Step 6:**Right click on this test Archive file and show in finder:

Again right click and click on show package contents

then Products>Applications>and copy the .App file

Step 7:

  • Copy the .app file into a new subfolder named Payload (this folder name is case sensitive)
  • press Payload folder and rename it to app_name-version_number.ipa
  • Example- Test-version_1.1.ipa

And finally you have unsigned IPA file :)

Note: After done with your app changes replace the original plist again or set set CODE_SIGNING_REQUIRED to YES

Alok
  • 24,880
  • 6
  • 40
  • 67
-3

To Disable Code Signing:

  • GoTo /Applications then right click Xcode.app and click "Show Package Contents"
  • SDKSettings.plist is located at /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.x.sdk

After modifying SDKSettings.plist file, restart your Xcode.

Note: Keep the backup of “SDKSettings.plist” in a different directory.

After generating unsigned .ipa file, replace SDKSettings.plist file with original SDKSettings.plist file and delete “CODE_SIGNING_ALLOWED” key pair value under User-Defined settings.

(I have also created a YouTube video, providing a walkthrough of the same steps.)

Cody Gray - on strike
  • 239,200
  • 50
  • 490
  • 574