To uniquely identify an App in iOS 6 and above you use this code:
UIDevice.currentDevice().identifierForVendor
Is there an equivalent for Mac OSX?
The MAC doesn't have anything equivalent to iOS's identifierForVendor or advertising Id alas.