How to get a unique Device ID in WinRT (C#)

December 11, 2012

In a project I'm working on I needed to get an ID that uniquely identifies the device that is running the app. WinRT provides an API for HardwareIdentification but you should be aware that the call to GetPackageSpecificToken method will produce different value for each app that calls it.And if you have several applications that needs to interact with a websevice and pass the device id you can't rely on it for identification.Another approach you can use is taking the NetworkAdapterId , which is like using the MAC address (WinRT doesn't give an API to take the MAC itself).Here is a...