61

I need to know what methods people are using to distribute (internally) demo of iPad application wirelessly without having to manage UDID?

I do not need a solution like testflight or betabuilder, all these requires me to manage UDID in the apple provisioning profile portal.

I am asking this question because I am seeing another studio doing a much smarter way right now and I wish to know how they did it - With a link they gave to us, we can install their demo application from a simple HTML over the air, and a provisioning profile magically appears in my iPad. All this happened without me telling them the UDID of my iPad, and therefore definitely without them to recompile the project.

How did they do it?

Bill the Lizard
  • 398,270
  • 210
  • 566
  • 880
mkto
  • 4,584
  • 5
  • 41
  • 65

7 Answers7

77

I've been distributing my apps wirelessly for several months now with no problems. Granted, I am distributing under the Enterprise license, which costs $299 a year and is intended for internal business use. This may work with a normal developer license, but you'd have to do some testing to make sure. I imagine the process is the same if it does work. I'm using XCode 4, so this may be slightly different if you're using a different version. Basically, you have to add an Entitlements.plist file to your resources:

New->File->Code Signing->Entitlements

and before you distribute, you have to change:

"Can be debugged" to NO

Make sure your project is set up with the correct Code signing profiles. Now go to:

Product->archive

then with your newly built entry, click on: Share

Select "iOS App Store Package (.ipa)"

and choose the proper distribution profile you want to use. Click next, then choose a location to save the .ipa file to. Before you click Save, you need to check

Save for Enterprise Distribution

The .ipa file needs to be saved on an FTP Server, or at least that's how I got it to work. For the "Application URL" field, use the path to the .ipa file you are going to save, for example,

ftp://ftp.company.com/Installers/myApp.ipa

Give it a Title, then in "Large Image URL" and "Small Image URL" give it a path to your large (512x512) and small (72x72) icon files, (I'm developing for iPad, so iPhone may be different). For example,

ftp://ftp.company.com/Installers/small.png

Save the .ipa file. Now you need to place your .mobileprovision file on the ftp server. Anyone that wants to run the app needs the file installed or they won't be able to run it. Now, I'm not sure if you will need a .mobileprovision file that has all of the device ID's built into it if you're not part of the enterprise program, but you can try and see. Once your files are all on the ftp server, you'll need to create an email that has links to the two files, but the link for the .ipa file has to be in a special format. For the provisioning file:

ftp://ftp.company.com/Installers/profile.mobileprovision

and for the .ipa file:

itms-services:///?action=download-manifest&url=ftp%3A%2F%2Fftp.company.com%2FInstallers%2FmyApp.plist

Now when you send this email to someone, they just need to first download and install the .mobileprovision file, then the .ipa file. Voila, they are running your program. Let me know if this works without the enterprise subscription. I imagine it would as long as the .mobileprovision file contained the device ID's.

Edit:

I've found a much better way of distributing apps, but it requires you to have a PHP server. What you do is create a PHP file that generates the plist file on the fly and returns that. In the links for large image, small image and ipa file you pass in links to other PHP files that return those things for your specific program. When you want to install an app from a link, you just pass in the url like this:

itms-services:///?action=download-manifest&url=http://mycompany.com/php/installApp.php?app=myappname

In your PHP functions you would just insert myappname into the other PHP calls, which would pull the proper files from your server. Using this method, you don't need to store plist files for any of your apps as they are generated, which makes updating your apps easier since you don't need to retype the information every time, don't even check the checkbox for enterprise distribution, just save the ipa file over the old one and you're good to go. Also, it is easy to implement security and login features with this method. Also, you don't need to specifically install the mobile provision file, as it installs itself when you install the app. It is stored in the ipa file.

Edit:

Just to clarify the PHP method, you create a php file that creates plist files. Copy a standard plist file created from an enterprise distribution build, then in your php file, set the headers like this:

$pathToAddFi = "installers/".$_GET['app'].".plist"; //points to the php server file location of your .ipa files. when you call this php script, you pass in the name of the ipa file you want to install. Note: this location doesn't actually contain any plist files!
$root = "http://yourserver.com/php/root/"; //path to this PHP file's directory

header('content-type: application/xml');
header('Content-Disposition: attachment; filename='.basename($pathToAddFi));
header('Content-Transfer-Encoding: binary');

Then you build a string replacing the urls for your items like this:

<string>".$root."ipa_serve.php?app=". $_GET['app']."</string>

and end it with one last header before you echo the xml string:

header('Content-Length: ' . strlen($myXml));

Lastly, you create a php file to serve your ipa file, one to serve your large image, and one to serve your small image. Should be fairly straight forward unless you aren't very familiar with PHP.

Cœur
  • 37,241
  • 25
  • 195
  • 267
Davido
  • 2,913
  • 24
  • 38
  • 1
    hi Davido, thanks for coming here to reply me, when u said u have the "enterprise license" at $100 a year? Are you referring to this Enterprise license at USD299 per year? There are 3 licenses, personal (99), corporate (99) and enterprise (299). – mkto Apr 06 '11 at 01:36
  • 1
    Good catch. I thought it was $99, but then again it was the company's money, not mine, so I had less reason to be worried about the exact amount at the time. – Davido Apr 06 '11 at 16:28
  • Hi Davido, I am surprise that you have to manage UDIDs for enterprise license. I thought USD299 Enterprise license is designed for internal distributions in large enterprise and therefore UDID management in the portal is no longer needed. As i said I see some people manage to distribute apps wirelessly without caring whats the UDID of the tester/customer. I tot that's an enterprise feature. I have submitted a technical support request to apple just to ask this question, if i got any reply i will update u too. thanks! – mkto Apr 07 '11 at 02:37
  • 4
    I guess my post wasn't quite clear enough. I DO NOT have to manage UDID's for my apps. I was only saying that you could try the same method out on a normal account and see if it works or not. On an enterprise account, UDID's are completely unnecessary. – Davido Apr 07 '11 at 20:42
  • Hi Davido! Cool!! you are the first one to answer my question! So with the 299 license, no more asking UDIDs from customers! But can i check with you, will we meet any legal issues to share apps with potential customers instead of internal employees? And do you have a limit on the devices that you can deploy? – mkto Apr 08 '11 at 08:10
  • i have marked your response as answer anyway, really thanks :D – mkto Apr 08 '11 at 08:16
  • Hi Davido, sorry one more question, as a company, can i say that if you want to put apps on Appstore using company's name + distribute enterprise apps you need the corporate license (99) + enterprise license (299) at the same time? – mkto Apr 08 '11 at 08:21
  • Yes, you need two completely separate accounts, one for selling apps and one for internal use. There is no limit to how many apps you can distribute via enterprise, at least not that I know of. Legally you're not allowed to distribute enterprise apps to anyone outside of the company that holds the enterprise license, but I don't think they have any way of monitoring that. For example, if I forwarded the email that has my links to someone in china, they could install my app just fine and I don't think apple would ever know. I'm not saying that's what you should do, just that it's possible. – Davido Apr 08 '11 at 14:37
  • 3
    For the record, you don't need to separately download the provisioning profile. The profile will be embedded in your application with the name 'embedded.mobileprovision' and will be automatically installed by the OS when the application is installed. This has been available since iOS 3 or so. – Mike Weller Dec 15 '11 at 12:08
  • 2
    Here's a link to the Enterprise Developer Program documentation for wireless distribution: http://help.apple.com/iosdeployment-apps/#app43ad871e – Joony Feb 16 '12 at 11:51
  • Mike, thanks for the tip, didn't realize that. Joony, apple must have posted that page fairly recently, it wasn't there when I had to figure this stuff out. Thanks for the link. – Davido Feb 16 '12 at 18:51
  • My company is doing this for their apps and my phone is the ONLY one that it dosn't work on. The app downloads, makes progress, and then right at the end: "Unable To Download Application [appname] could not be downloaded at this time [done] [retry]" Maybe because I have a personal developer account bound to the appleId of this device? – gerbz Mar 08 '12 at 18:41
  • @ggwarpig - I think the issue may have something to do with existing provisioning profiles on the device. Try deleting your provisioning profiles then try again. Let me know if that works. – Davido Apr 05 '12 at 17:37
  • @Davido that worked! my other profiles seemed totally unrelated. thanks so much! – gerbz Apr 20 '12 at 17:09
  • Please explain your link to download the `.ipa` file. You mention putting the `.mobileprovision` and the `.ipa` file on the FTP, but your like then refers to 'ftp://ftp.company.com/Installers/myApp.plist'. When/how did that plist file get there? According to the answer, only the `.ipa` is on the FTP server, so why does the URL refer to a `.plist` file? – aroth Oct 04 '12 at 00:31
  • I updated my answer above if it helps you. When you create a enterprise distribution for an app, you typically create an ipa file, which is your program and contains the mobileprovision file. You also create a plist file, which is what you call from your device to install the app. The plist tells the device where to find the installer file and where to find the placeholder image to display for the icon while the app installs. – Davido Oct 04 '12 at 16:19
  • Thanks a lot for the answer @Davido. I feel like I'm almost there. I don't fully understand how you did it with the PHP file though? What exactly is it you are doing with it? Can you share some code or maybe even a tutorial? Thanks again. – Holger Sindbaek Feb 12 '13 at 07:40
  • I clarified a bit more above, should get you going. Once you get it setup, things run very smoothly. – Davido Feb 15 '13 at 15:28
  • @Davido How long will the software work for on the device? Is it indefinitely? – Recycled Steel Jan 09 '14 at 13:56
  • It will work until the certificate it was created with expires. – Davido Jan 14 '14 at 16:41
  • When I understand http://help.apple.com/iosdeployment-apps/mac/1.1/?lang=en-us#app43ad756d correctly you still have to collect the UDIDs even with the enterprise program. – powtac Jan 30 '14 at 10:04
  • Regardless of what their website says or what they say does or doesn't work, this is the method we have been using for the last three years with no problems. Unless apple changes how things work in the future, this method does work and works well. Not really that hard to test out the method either. The software works for the full 12 months that the certificate you signed it with is valid. – Davido Jan 30 '14 at 19:25
  • Apple has released official documentation on this process in Appendix C of their [iOS Deployment Technical Reference](https://www.apple.com/iphone/business/docs/iOS_Deployment_Technical_Reference_EN_May14.pdf). Everything above is accurate, but this document may be helpful. – bloudermilk Jul 15 '14 at 23:50
  • Does installing .mobileprovision file approach is worked with iOS 8 based devices? – Amit Bobade Oct 21 '14 at 15:17
  • The .mobileprovision file is included automatically when you publish following these instructions, at least with the enterprise account, not sure about a normal account. – Davido Oct 22 '14 at 17:29
  • How current is this? I would love to jump on a call with you @Davido? – Pavan Dec 27 '16 at 16:25
  • It's still current. I still use this method to distribute apps. No .mobileprovision file step is required. Archive and sign with enterprise account, then when the user downloads the app, they just have to go into settings and accept the enterprise profile. – Davido Dec 27 '16 at 19:38
  • Mentioned your answer [here](https://apple.stackexchange.com/a/322941/279727) on Ask Different. – Nimesh Neema Apr 18 '18 at 18:14
8

I've just been through the same thing. I think the big different is the Enterprise Distribution Profile ($299 per year) - if you have one of these, you don't need to have Device UDIDs in the list. If you have a normal $99 per year deal, you have to. Simple as that.

Good news is that Apple have recently dropped the "500 employee" restriction so any company can get one of these: http://blog.apperian.com/2010/10/apple-opens-ios-developer-enterprise.html

You just have to get a free DUNS Number from Dun and Bradstreet, which take 30 days. We've applied for ours and will see how it all pans out.

Jon Marks
  • 81
  • 1
7

You do need a provisioning profile, but it's embedded in the .ipa file, it doesn't need installing via iTunes as a separate installable.

You should check out TestFlight, a web app for managing OTA Ad Hoc build distributions; it's fantastic. It does all kinds of clever stuff, including gathering the UDIDs of your user's devices for you. (You, the developer, still need to input these into the iPhone Dev Center's provisioning portal, but the user can remain blissfully unaware that UDIDs even exist, never mind that they have to send it to you. Maybe this is what your boss used previously.)

Simon Whitaker
  • 20,506
  • 4
  • 62
  • 79
  • Testflightapp makes this entire process blindingly simple. It even has an upload API, allowing you to fully automate distribution of your app. – kubi Apr 05 '11 at 21:06
  • 2
    Hi guys thanks, but what i want to know is how people manage to deploy wirelessly without managing UDID.Is that a feature in the USD299 enterprise license.. – mkto Apr 06 '11 at 01:42
  • @simon whitaker Do we need to recompile our app for .ipa or do we only need to add UDID in developer portal certificate? – Baby Groot Aug 30 '13 at 07:20
2

I don't know of a way to accomplish this without the UDID of the user. My guess is that the developer already had your boss' UDID from before and created/bundled a new provisioning profile, or your boss was testing a mobile web app.

You can do ad-hoc distributions a little more easily now with Wireless App Distribution.

iOS 4: wireless app distribution for in-house applications

Community
  • 1
  • 1
jmans
  • 5,648
  • 4
  • 27
  • 32
2

The application you're referring to is called Beta Builder. My boss used it for the first time today and it worked great. Definitely worth $2.

FreeAsInBeer
  • 12,937
  • 5
  • 50
  • 82
  • The application still needs to be signed using a provisioning profile that contains the UUID for any devices that are going to download and install the application. – FreeAsInBeer Apr 05 '11 at 02:49
  • yeah i also have the same conclusion after reading all the comments in that Beta Builder link. so i think my boss is drunk. he must have given out his UDID before? – mkto Apr 05 '11 at 02:59
  • What about enterprise license? Since it is to support many employees, is it possible that the app has to be bundled with all their UDIDs before hand? – mkto Apr 05 '11 at 03:11
  • hi guys, i have tested the "boss's link" myself, and have confirmed that there's a way to make it work without giving out UDID. Once i clicked the link on a html page, i can download the app and a distribution profile magically appears in my ipad. I suspect maybe enterprise license can do this... i m now back to the original point. still need help~~~ – mkto Apr 05 '11 at 03:44
0

The accepted answer is pretty old, and I found a lot of confusing resources for distributing Enterprise apps, so I thought I'd respond with a better solution.

HockeyApp is free and allows you to upload your Enterprise (and Ad-Hoc) builds and serve as a public download page. Note that this will only work without registering users and provisioning their device's UDIDs if you have an Apple Enterprise account as others here have mentioned, but it is by far the simplest, quickest workflow for distributing apps to clients quickly without the overhead of device provisioning.

fisch2
  • 2,574
  • 2
  • 26
  • 29
0

All this happened without me telling them the UDID of my ipad, and therefore definitely without them to recompile the project.

Little known fact: You don't need to recompile the app. You don't even need to resign the app. All that matters is there's an installed provisioning profile that's "similar enough" to the embedded.mobileprovision inside the app (profile name? bundle ID? bundle seed? Who knows).

Alternatively, they could be doing automated builds. Maybe. Maybe not.

What might be happening:

  1. The server sends you a "configuration profile" (see SCEP/enterprise whatever). Apparently this can be used to get your device's UDID. TestFlight does this.
  2. The server automatically does a few things (either by screen scraping, or through some Enterprise API if there is one):
    1. Add the device UDID to Apple's list of devices.
    2. Tell apple to generate the provisioning profile.
    3. Download the provisioning profile.
tc.
  • 33,468
  • 5
  • 78
  • 96