I want unique device ID for iPhone that remains unchanged?, I want Unique device ID that cannot be changed if I uninstall application and install again on same device. I am Using swift 2.1.1 and xcode 7.2.1. I have tried this code but both will not work.
//First approach
let device_id = UIDevice.currentDevice().identifierForVendor!.UUIDString
print("unique device id: (device_id)")
//Second approach
let dID = CFUUIDCreate(kCFAllocatorDefault)
let deviceID = CFUUIDCreateString(kCFAllocatorDefault, dID) as NSString
print("unique CFUUID id: (deviceID)")