Is there is a alternative for UDID. My app will not be going to App Store as i'm using enterprise distribution. So is there any replacement. I tied advertising identifier, open udid, UIID and secure UDID. But if the phone is reset then i will get a new UDID. Any help would be appreciated.
Apple Will No Longer Approve Apps Using Unique Device Identifier (UDID) Beginning May 1, Must Also Support iPhone 5 and Retina Display - MacRumors.
Disability Certificate Issuing Authorities (CMO Office/Medical Authority) will use this application to record the details of Persons with Disabilities (PwDs) and issue Disability Certificate/UDID Card electronically. Application from the PwD will be received by the CMO Office/Medical Authority.
If you trust the developer, sure. The UDID is just a unique identifier for your physical iPhone, and the developer needs to register it with Apple so that they can build the app for you.
For above 6.0 iOS you can use identifierForVendor
Or CFUUIDRef
.
-(NSString*)uniqID
{
NSString* uniqueIdentifier = nil;
if( [UIDevice instancesRespondToSelector:@selector(identifierForVendor)] ) {
// iOS 6+
uniqueIdentifier = [[[UIDevice currentDevice] identifierForVendor] UUIDString];
} else {
// before iOS 6, so just generate an identifier and store it
uniqueIdentifier = [[NSUserDefaults standardUserDefaults] objectForKey:@"identifierForVendor"];
if( !uniqueIdentifier ) {
CFUUIDRef uuid = CFUUIDCreate(NULL);
uniqueIdentifier = ( NSString*)CFUUIDCreateString(NULL, uuid);
CFRelease(uuid);
[[NSUserDefaults standardUserDefaults] setObject:uniqueIdentifier forKey:@"identifierForVendor"];
}
}
return uniqueIdentifier;
}//
UPDATE
As Leon Lucardie
comment he is right
identifierForVendor will change after app uninstall/reinstall. See here The value in this property remains the same while the app (or another app from the same vendor) is installed on the iOS device. The value changes when the user deletes all of that vendor’s apps from the device and subsequently reinstalls one or more of them.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With