4

I'm working on some apps for distribution through the Enterprise program onto company iPads (so I / the company has complete control over them). What is the "correct", if there is one, way to identify the device that the apps are running on, in the context of corporate owned devices?

CFUUIDCreate as recommended here UIDevice uniqueIdentifier Deprecated - What To Do Now? won't work, as the id has to be the same across several apps.

Right now How can I programmatically get the MAC address of an iphone looks like the best way, but I'm very new to Apple stuff and would like to know if there is a better way.

The iPads are for warehouse use, and id'ing the device is to id which warehouse that iPad is assigned to.

Community
  • 1
  • 1
Turch
  • 1,546
  • 2
  • 15
  • 31

3 Answers3

1

I run an enterprise program as well and you're right, the new UUID pieces Apple provides aren't useful. Not only are they not the same across apps but they aren't the same if the user deletes and redownloads your enterprise app.

Since you're not distributing through the App Store, you won't get shut down for using the [UIDevice uniqueIdentifier] and it still does work in iOS today. I personally send that and the MAC address and cross my fingers that this will continue to work in future releases. It's possible that Apple starts returning @"" or some other null string for the UUID in the future so be prepared.

pho0
  • 1,751
  • 16
  • 24
  • Good to know that [UIDevice uniqueIdentifier] still works if you don't need to submit to the app store. I'll try OpenUDID as suggested in the other answer with this as a backup :) – Turch Mar 19 '13 at 14:39
  • the vendor id will be the same across apps, but not devices. – Nick Turner Apr 30 '13 at 15:30
  • In the latest **iOS7** SDK, the mac address will not work. They will return the same address `(02:00:00:00:00:00)` on all devices when you call system. – user2361406 Jun 18 '13 at 02:37
1

We are using OpenUDID in our projects for persistent cross-app identifier as a drop-in replacement for deprecated UDID.

Usage:

#include "OpenUDID.h"
NSString* openUDID = [OpenUDID value];
redent84
  • 18,901
  • 4
  • 62
  • 85
0

With iOS7 (beta) UIDevice uniqueIdentifier now behaves like identifierForVendor. i.e. The ID will differ for each app and also will be reset when the app is reinstalled.

Jay
  • 1,022
  • 10
  • 10