Reputation: 7750
I have to identify workstation by unique identifier that must be stable. I decided to use MAC address but what shall I do if there are several ethernet adapters (some of them may belong to VMWare installed)? Wich one shall I choose?
I use GetAdaptersInfo function and deal with IP_ADAPTER_INFO structures.
May be you shall choose another approach to unique (and stable) workstation ids than using MAC addresses?
It's a pitty - workstation for me is "read-only". I can't automatically generate some unique identifier to create, store and reuse on workstation.
Upvotes: 1
Views: 477
Reputation: 25690
If you're bent on MAC addresses, how about either select just the first MAC address in the list, or XOR them together?
However, I'm sure Windows has some GUID for the computer itself somewhere, which might be more along the way Microsoft intended things to work?
Upvotes: 1