Reputation: 41
I'm looking for a way to retrieve the UDID on devices running iOS 6+ (Enterprise deployment only - no app store limitations).
Calling the (now private) method uniqueIdentifier
returns the 'vendorIdentifier' starting with 'FFFFFFF'. Unfortunately thats not what I want.
Any ideas? Is there another private method or something?
Thanks in advance.
Upvotes: 4
Views: 3828
Reputation: 7176
Sorry, but Apple warned it would be deprecated and it has been. I've had the same headache myself.
I can't help you identify the device in the same way Apple do, but you can always generate an unique UUID on app launch and stash that away in KeyChain. It won't be perfect, but it will persist between installations and will be unique to the device. As far as I know, that's the current solution
Upvotes: 0
Reputation: 19239
I recommend you reading this article. To sum up:
uniqueIdentifier
now works like vendorIdentifier
on iOS 7+, so it's no longer usable even for Enterprise AppsvendorIdentifier
hasn't changed, but it's not recommended for Enterprise Apps because it can change when updating the App.advertisingIdentifier
API is the way to go for new Apps. It's the same for all Apps and should not change frequently, but the user can reset it in the settings page.Edit: Website udid.io obtains the real Device UDID instead of the obfuscated one if you need it for anything outside your App. If you need the UDID from within the App, see my answer above.
Upvotes: 2
Reputation: 2078
You can get a Unique UDID via this method using private api. Follow this link Look for the code in accepted answer.
Upvotes: 1