How does development track you?

2020/04/17 17:11
Reading number 131

preface

When shopping on Taobao, if you search for a certain shoe of a certain brand, it will then push you other shoes of that brand or similar shoes of other brands. You must have received a lot of similar advertisements. So how do advertisers accurately put content you are interested in on your device? There are different apps on the mobile phone. Why didn't the push of Sogou Map APP be sent to Sogou Recording Assistant APP? How can you ensure that it can be accurately pushed to your device without confusion between different APPs?

The clear question is how to track and locate specific devices and APPs? This requires the unique identification of the device and APP to distinguish, and the identification content and effect To sort out~

Common equipment ID identifier

1) IMEI

IMEI (International Mobile Equipment Identity): International mobile device ID code. This method was abandoned after iOS 5. Therefore, mobile phone IMEI cannot be obtained after iOS 5. However, mobile phone IMEI numbers can also be obtained through private APIs. However, if you obtain IMEI numbers through Apple's private APIs, you will be rejected from the Apple Store.

Telecom operators have IMEI and IMSI of users' mobile phones and SIM cards because the communication network protocols are all IMEI and IMSI of users' mobile phones.

Obsolete version: iOS5.0+.

2) MAC address

Mac (Medium/Media Access Control): the physical address of the network device. If IMEI is considered to be the unique identifier of the device, then Mac is the unique identifier of the network interface. As you know after learning computer network, the Mac address is used when physical addressing is based on IP address.

MAC The address is used to distinguish the uniqueness of devices on the network. All devices accessing the network have a MAC address. They must be different and unique. An iPhone may have multiple MAC addresses, including WIFI, SIM, etc., but there is one WIFI on the iTouch and iPad, so just get the MAC address of WIFI, that is, the address of en0. MAC address is like the ID number on our ID card, which is globally unique. Also due to privacy issues, the unique device cannot be identified by the Mac address after iOS 7, because the Mac address obtained after iOS 7 is a fixed value.

Obsolete version: iOS7.0+(of course, App has some special methods, such as actively prompting the user to select the WIFI network to obtain the MAC address).

3) UDID

UDID The full name of is UniqueDevice Identifier. As its name implies, it is the unique identification code of Apple IOS devices. It consists of 40 characters of letters and numbers. It is often used in many applications that need to limit one device to one account.

The UDID of the device can be obtained in iOS5, but it has been completely disabled in iOS7. If the app used before iOS7 runs on iOS7, it will not return the UDID of the device, but will return a string of strings, starting with FFFFFFFF, followed by the hexadecimal value of identifierForVendor.

UDID Other data can be associated to related devices. For example, connecting to the developer account allows the device to install or test applications before publishing; Developers can also get iOS beta for experience. Apple uses UDID to connect to Apple ID. These devices can automatically download and install applications purchased from the App Store, save music purchased from iTunes, and help Apple send push notifications and instant messages. In the early days of iOS applications, UDID was used by third-party application developers and online advertisers to collect user data, which can be used to associate addresses, record application usage habits, and so on, so as to push accurate advertisements.

The developer associates the UDID with the user's real name, password, address, and other data; The network snooper will collect these data from multiple applications, and then get many private data from this person. At the same time, most applications do frequently transmit UDID and private information. In order to avoid class action litigation, Apple finally decided to abolish this practice in iOS 5. Developers were guided to generate a unique identifier, which could only detect applications, and other information was not provided. Now the application's attempt to obtain a UDID has been disabled and is not allowed to go on sale.

Obsolete version: iOS6.

4) UUID

Universally Unique Identifier , universal unique identifier. UUID refers to the number generated on a machine, which changes according to time. A 32-bit hexadecimal sequence, connected by a dash.

At present, the UUID that is most widely used is the globally unique identifier GUID of Microsoft. Its purpose is to make all elements in the distributed system have unique identification information without specifying identification information through the central control terminal.

UUID It is based on a single application on the iOS device. As long as the user has not completely deleted the application, the UUID will remain unchanged when the user uses the application. If the user deletes the application and then reinstalls it, the UUID has changed. After the user deletes the program you developed, it is basically impossible for you to obtain the previous data.

The current solution is to write the UUID into the key string to obtain a user-defined UDID (not native to the system). Even if the user reinstalls the APP, as long as the key string is returned every time, it will remain unchanged.

Applicable to iOS6.0+, such as 26EA83F9-F510-4A08-BA4C-0CD431922D9C.

5) IDFV

Identifier For Vendor (Application development trademark identifier) is used for Vender to identify users. Each device has the same value in the same Vender application. The Vender refers to the application provider, but to be precise, it is matched through the first two parts of the DNS inversion of the BundleID. If they are the same, they are the same Vender.

For example, the two BundleIDs com.somecompany.appone and com.somecompany.apptwo belong to the same Vendor and share the same idfv value.

Different from idfa, the value of idfv can be obtained, so it is very suitable to be used as the primary ID for internal user behavior analysis to identify users and replace OpenUDID.

If the user uninstalls all the apps belonging to this vendor, the value of idfv will be reset, that is, reinstall the vendor's app. The value of idfv is different from that before.

Applicable: iOS6.0+.

6) IDFA

Identifier For Advertising (Advertising identifier), all apps on the same device will get the same value, which is set by Apple for each advertising provider to track users. Advertisement identifiers are stored by the system.

Advertisement identifiers are stored by the system. However, even though this is stored by the system, there are several cases where the advertisement identifier will be regenerated. If the user completely resets the system ((Setup ->General ->Restore ->Restore Location and Privacy), this ad identifier will be regenerated. In addition, if the user explicitly restores the advertisement (Setup ->General ->About the local ->Advertisement ->Restore the advertisement identifier), the advertisement identifier will also be regenerated.

It is suitable for external applications, such as advertising promotion, volume exchange and other cross application user tracking.

7) Device ID

Device Id It is the unique identifier of the device in the push system. It is a combination of 32-bit numbers and lowercase letters. When pushing on the console or through OpenAPI, you can specify terminal push, that is, push through the deviceId of the specified terminal.

8) Bundle ID

Bundle ID (Bundle identifier), also called App ID or App ID, is the unique identifier of every iOS application, just like a person's ID card number iOS The App ID is used for certificates, packaging ipas, and creating apps in itunesconnect. The entire app listing process is linked by this App ID.

Every time you develop a new application, you need to first create a Bundle ID.

B u ndle  ID There are two types: Explicit App ID (explicit APP ID). The general format is com. domainname. appname. This ID can only be used on one app. Create one for each new application; Wildcard App ID (wildcard APP ID). The general format is com. domainname. *. This ID can be used in multiple applications. Although it is convenient, the application using this ID cannot use the notification function, so it is not commonly used.

In the Android system, it is judged that the unique ID of an app is Package name, which is the same as that of iOS Bundle ID is right Should be.

Bundle ID Format: Due to Apple and Google, the Android packageName and iOS Bundle ID of the same application are different. For example, WeChat: iOS Bundle ID is com.tencent.xin; Android packageName is com.tencent.mm;

9) Device token

Device token APNs (Apple Push Notification Service) is an identifier used to distinguish and identify each iOS device and different apps on the device. After a long connection is established between the device and the APNs server, it is encrypted and fed back to the app after being generated by APNs by registering the push service. It can also be used by APNs to route push messages to specified devices. That is to say, in terms of the amount of information: device token=device id+bundle id.

summary

The above lists the identifiers of various common marking devices or users, which are briefly summarized as follows:

one )IMEI: international mobile device ID code, obsolete version: iOS5.0+;

two )MAC address: the physical address of the network device. It is used to distinguish the uniqueness of the device on the network. Obsolete version: iOS7.0+;

three )UDID Unique identification code of Apple IOS device, obsolete version: iOS6.0+;

four )UUID Universal unique identifier, which can be UUID Write it into the key string to obtain a user-defined UDID (not native to the system). Even if the user reinstalls the APP, as long as the key string is returned every time, it will remain unchanged.

five )IDFV Application development trademark identifier. Each device has the same value in the same Vender application, which is applicable to iOS6.0+;

six )IDFA: Advertising identifier, which is stored by the system and is set by Apple specifically for advertising providers to track users, may change, such as system reset and restoring advertising identifier in settings. Users can turn on "Restrict ad tracking" in settings, which is applicable to iOS 6.0+;

seven )Device ID: the unique identifier of the device in the push system;

eight )Bundle ID: the unique ID of each iOS application;

nine )Device token: an identifier used to distinguish and identify each iOS device and different apps on the device;

The above various device ID identifiers are common in the current mobile application development process, and the interpretation and implementation of the same ID may be slightly different in different companies and different developers. For the sake of protecting user privacy, Apple has clear restrictions on the positioning of various devices and apps. Once the restrictions are exceeded, the app will be rejected during Apple's review.


This is the first time to record so much. See you next time.

I hope you can gain something, make progress together and learn from each other!

Sogou test WeChat signal: Qa_xiaoming

Sogou test QQ fan group: 459645679


This article is shared from the WeChat official account Sogou QA.
In case of infringement, please contact support@oschina.cn Delete.
Participation in this article“ OSC Source Innovation Plan ”, welcome you to join us and share with us.

Expand to read the full text
Loading
Click to lead the topic 📣 Post and join the discussion 🔥
Reward
zero comment
zero Collection
zero fabulous
 Back to top
Top