Brings back the unique identifier support under iOS 5, it uses the device's mac address in combination with the bundle identifier to generate a new hashed unique identifier.
Objective-C
1,228
19 commits
updated Jul 18, 2013
** NOTE: this is not going to work under iOS 7 **
Apple stopped supporting a unique identifier for iOS. This source code solves the problem. It generates a unique identifier based on the mac address of the device in combination with the bundle identifier.
What you need to do:
copy NSString+MD5Addition and UIDevice+IdentifierAddition to your project.
if your are using ARC in your project, you have to add the -fno-objc-arc flag to both files. Apple ARC Guidelines
use [[UIDevice currentDevice] uniqueDeviceIdentifier] to retrieve the unique identifier (it's a hash of your Bundle ID + MAC address)
use [[UIDevice currentDevice] uniqueGlobalDeviceIdentifier] to retrieve a global unique identifier (it's a hash of the MAC address, used for tracking between different apps).
have fun and follow gekitz ;)
//Thanks to Erica Sadun for her UIDevice+Hardware Addition (used for the mac address retrieval).
see license file.
1,665 followers · starred Aug 2011
837 followers · starred Aug 2011
265 followers · starred Aug 2011
74 followers · starred Aug 2011
Brings back the unique identifier support under iOS 5, it uses the device's mac address in combination with the bundle identifier to generate a new hashed unique identifier.
Objective-C
1,228
19 commits
updated Jul 18, 2013
** NOTE: this is not going to work under iOS 7 **
Apple stopped supporting a unique identifier for iOS. This source code solves the problem. It generates a unique identifier based on the mac address of the device in combination with the bundle identifier.
What you need to do:
copy NSString+MD5Addition and UIDevice+IdentifierAddition to your project.
if your are using ARC in your project, you have to add the -fno-objc-arc flag to both files. Apple ARC Guidelines
use [[UIDevice currentDevice] uniqueDeviceIdentifier] to retrieve the unique identifier (it's a hash of your Bundle ID + MAC address)
use [[UIDevice currentDevice] uniqueGlobalDeviceIdentifier] to retrieve a global unique identifier (it's a hash of the MAC address, used for tracking between different apps).
have fun and follow gekitz ;)
//Thanks to Erica Sadun for her UIDevice+Hardware Addition (used for the mac address retrieval).
see license file.
1,665 followers · starred Aug 2011
837 followers · starred Aug 2011
265 followers · starred Aug 2011
74 followers · starred Aug 2011