How to get a unique device identifier for IOS

0

In development for Android you can set whether a smartphone is unique through your IMEI or MAC , and may not be the best way to only identify a mobile device, but it works very well.

On the other hand, Apple no longer allows developers to get either MAC or IMEI from mobile devices.

>

I'm aware that you can use CFUUIDCreate to get a unique identifier, but that identifier will only be available until the user uninstalls the application, and if you re-install the identifier will be another one.

How to get a unique ID for an IOS device, regardless of whether the user uninstalled the application?

    
asked by anonymous 19.01.2018 / 15:11

1 answer

2

One possible solution is to save the handle on the Keychain. That way you can retrieve it if the user deletes the app and installs again. There are some libraries that implement this functionality, such as FCUUID .

In iOS 11 Apple introduced the DeviceCheck framework, which allows you to save two bits that are persisted even if the app is reinstalled or the user transfers data from one device to another. This video of WWDC explains with it works, from the 24th minute.

    
20.01.2018 / 02:15