1

recently I got into iOS development and I got a task of examining the application which is already in App Store . But I found something unusual ... Two different users when loging through two different devices through my application which is downloaded from App Store returns same vendor ID ...... is this the expected one ? Because according to the APPLE DOCUMENTS VENDOR ID MUST BE DIFFERENT FOR DIFFERENT DEVICE REGARDLESS OF VENDOR if the app is downloaded from App Store . Please clarify here .

The code which I am using is :

NSString *UString = [[[UIDevice currentDevice] identifierForVendor] UUIDString];
NSLog(@"Vendor ID %@", UString);
user16780334
  • 422
  • 5
  • 20
  • What is the bundle id of your app? And which versions of iOS do you support and where (which versions) do you get trouble? According to docs, that could be the issue. – skaak Dec 18 '20 at 10:08
  • The issue came for iOS 13 and iOS 12.4 ... we both downloaded app from AppStore and logged in using different user in different device with different OS as mentioned above .. the bundle id is : com.toi.toinews.ios ... but does bundle Id matters if the app is downloaded from AppStore ? We are supporting from iOS 7 onwards – user16780334 Dec 18 '20 at 10:12
  • Seems unusual. Docs seem to suggest on old iOS you'd run into trouble as ```com.toi.toinews``` *only* will be used, but yes, that is if you install yourself, not via appstore. Are these apps related e.g. targets in the same project? – skaak Dec 18 '20 at 10:17
  • It’s the same app and a single target though .... are we able to test it in Dev cert ? as according to the docs it will return same vendor id for different device as it is calculated using bundle id if we install using xcode on different devices – user16780334 Dec 18 '20 at 10:56

1 Answers1

0

After several research and practical results I found several characteristic of VendorID:

  1. VENDOR ID will be unique for every device I.e if a same app is downloaded on two devices from App Store , it will surely return different VENDOR ID. VENDOR ID is calculated based on AppStore data in this case

  2. VENDOR ID will be same for every app on a single device which is from same vendor . That is if I have 5 apps from a VENDOR named A in my device .. ALL THESE 5 APPS WILL HAVE SAME VENDOR ID. If we uninstall one app and reinstall again the VENDOR ID will not change . For VENDOR ID to change we must uninstall all 5 apps .

  3. VENDOR ID in newer iOS will also change if we are installing the build using XCODE or development certificate on different device I.e every device will have a different VENDOR ID for same app . In this case vendor ID is calculated based on BUNDLE ID . For older iOS similar BUNDLE ID for 2 apps may produce identical VENDOR ID .

  4. VENDOR ID is always a 32 bit string

  5. VENDOR ID is not a device identifier instead it’s a UUID through this we can’t identify the details about the device

UPDATION CASE

It is not supposed to change when updating the app from app store as is described in the documentation.

If you are updating an itunes-installed app, then updating it using Xcode or an ipa based on ad hoc provisioning or any provisioning, you will get a different value. You need to make it consistent, Adhoc to adhoc, dev to dev, app store to app store.

Installing and Reinstalling app when the vendor has only single app

Unless the user has another app from the same vendor installed, this id will change after deleting and reinstalling. In your case, where there is no other app by the same vendor, this means that the ID will change,

user16780334
  • 422
  • 5
  • 20