MatthewKing / DeviceId

A simple library providing functionality to generate a 'device ID' that can be used to uniquely identify a computer.
MIT License
729 stars 118 forks source link

Use MMI instead of System.Management for dotnet core #25

Closed shshzi closed 3 years ago

shshzi commented 3 years ago

This is to fix a problem where using a self-contained dotnet core application that uses System.Management requires specific dotnet framework to be installed on the machine (see here). Instead, we use MMI which is the recommended way. This still fails on some machine, such as Windows 7 SP1 without WMF3.0 installed so changes were made to fail silently and only use obtainable information when creating DeviceId.

MatthewKing commented 3 years ago

Hi. Thanks for this PR - it looks very useful. Are you able to rebase it on the top of the current branch so it's a bit easier to review and merge please? Thanks in advance.