I am trying to uniquely identify the iPhone/iPad mobile devices to save user data.
I found out some, including
[NSString *UUID = [[NSUUID UUID] UUIDString];
[UIDevice currentDevice].identifierForVendor.UUIDString;
or take device token from
- (void)application:(UIApplication *)app didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken
{ ... }
But the problem is that
- UUID changes everytime I close and restart the app (I experienced from debugging)
- identiferForVendor changes every time I delete and reinstall the app (or update the app)
- I used device token to uniquely identify device across version updates, reinstall, but I learnt that it can be changed, and I am experiencing it from my updates and debugging in xCode.
Since app store rejects using uniqueIdentifer, my question here is: Is there any way we can uniquely identify devices across any application updates, deletion, reinstallation?