Use hashing to generate an unlock key. The idea is to collect some data that is captured on the target machine, but also unique. Examples are the machine name, network card ID, ... Create a hash from these values and let the user send this data to you. Created a new hash from this value and a secret key (only known by you) and sent it to the user. Now the user must enter this key to unlock your software.
Achim source share