Requirement: no apple developer account.
I don't care about iOS devices. Only a unique id of a Mac (iMac, Mac mini and Macbook) is needed.
I have used this approach but it does't work any more on some latest Mac:
ioreg -rd1 -c IOPlatformExpertDevice | awk '/IOPlatformUUID/ { split($0, line, "\""); printf("%s\n", line[4]); }'
Why I think it doesn't work?
I have got some feedbacks from my clients that this approach get some random number. And I have checked the IDs my server received: Yes, they are random numbers (maybe it is regenerated after the Mac restarts).
So my question is:
How to get an unique id of a Mac now in 2018? Approaches that doesn't demand writting Objective-C or C++ code are preferred.
I'm trying to get the ID in C#: Mono, Unity3D or Xamarin.