Comparison of unique identifier of IOS devices

Source: Internet
Author: User

Comparison of the unique identifier of an existing IOS device


UDID

[[UIDevice currentDevice] uniqueIdentfier]

According to a formula, the device serial number, network interface address, and other information are calculated as parameters. After iOS6, the formula is changed.

The results returned by this method are the same in all applications, and the unique identifier of the device is the most accurate.

After iOS5, this method is marked as obsolete! In the end, after January 1, May 1, 2013, AppStore prohibited any applications using this method from being shelved.

This method has been removed from Apis made public in iOS7!

NIC address

Obtain the IP address of the Wi-Fi network card through the Unix API.

This method is the most accurate method in the UDID solution, because the NIC address does not change because of flash and device restoration. Therefore, vendors pursuing uniqueness choose this solution!

After iOS7, the application can no longer obtain the NIC address, so this solution has been deprecated in iOS7.

OpenUDID

An open-source UDID alternative solution is to share a UUID among multiple applications by using the clipboard sharing between applications and some necessary local cache information.

OpenUDID has been widely used since the official disposal of UDID interfaces! It can be said that it is the UDID replacement method for most applications.

OpenUDID will generate a new UDID after it is flushed and restored. In fact, due to the special nature of the clipboard, if all applications that use OpenUDID are uninstalled, the OpenUDID obtained by the re-installation application will be a brand new value!

In iOS7, applications of different groups (that is, applications of different vendors) no longer share data between clipboard!

The same group (that is, the same vendor) application is defined as: the first two Identifiers (such as com. mycompany) in the CFBundleIdentifier field of the software unique identifier in Info. plist are the same.

In iOS7, OpenUDID gradually loses its meaning.

UUID saved in NSUserDefault

After iOS5 marks the UDID as obsolete, it provides an official alternative. CFUUIDCreate is used to generate a UUID, save it in NSUserDefault, and use it as the device identifier. After iOS6, Apple released NSUUID to replace CFUUIDCreate, but the essence is the same.

UUID generates a new string each time. That is to say, after the application is uninstalled, it is considered as a new device, and you do not need to fl or restore the device.

Therefore, no UUID solution is used.

Unique Identifier of the vendor identifierForVender

[[UIDevice currentDevice] identifierForVender]

This method returns the same value for applications of the same vendor, and the values obtained by different vendors are different.

After the device is restored and flushed, the value is changed. Note that if all applications installed by the same manufacturer are uninstalled, the newly installed applications of the same manufacturer will also get a new value instead of the original value!

This solution is not accepted by developers because it cannot be installed across vendors and the software may be changed after being uninstalled.

AdvertisingIdentifier

[[ASIdentifierManager sharedManager] advertisingIdentifier];

Another UDID alternative solution launched in iOS6, which returns the same value to applications of all vendors. The advertisingTrackingEnabled API also provides the advertisingTrackingEnabled parameter, which indicates whether the user wants the ad tracking to be limited. However, this parameter is only a Boolean value used to indicate the user's wishes and does not affect advertisingIdentifier reading.

This method is provided officially and has the same value as the applications of all vendors. Therefore, it is more acceptable, but it is only applicable to iOS6, so more people chose the OpenUDID solution.

After the device is restored and flushed, the obtained value changes. In addition, you can generate a new value by setting-> about local-> advertisement-> restoring ad identifiers.

This method is the most acceptable solution officially supported on iOS7.

IMEI

The official iOS API cannot obtain the IMEI, or the IMEI cannot be obtained. Therefore, few people read IMEI on iOS. However, IMEI, as the unique identifier of a device, is one of the most accurate methods! It will not change with the flash brush or device restoration!

Apps reading IMEI will be rejected by the AppStore!

Similar solutions include the Bluetooth address, iOS device serial number (SerialNumbedr), and so on.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.