Generate Computer ID Win/Mac

My Building Creator extension is licensed per machine. Currently I have a method (only on windows) of getting a unique machine ID. There are several problems with my current method.

  1. Uses a separate app (exe) to generate the ID. I’d like to be able to do it in ruby.
  2. Only works on windows. I’d like to be able to use it on mac.
  3. It’s unreliable. Sometimes the ID changes even though it’s being used on the same computer.

Any ideas?

Often this is done by using the computer network interface’s MAC address, which is globally unique. This post on stackexchange appears to show how to fetch the MAC address.

1 Like

We discussed it here …
Getting unique ID of a user's machine

… and here …

On windows, you might just run …

%x[ipconfig /all > somefile.txt]

… and then parse the output for the line with “Physical Address” following after the line which begins “Ethernet adaptor”

Note: I show redirection to file because every few SU versions the execute string (global backquote method,) gets broken by SketchUp’s Ruby Console implementation (on Windows editions at least.)