I just finished my program, now I want to build a setup with Inno-setup that gets the hardware id and and stores it into a file in the CD so that the program can be installed in only one computer with only one license. Unfortunately i am not good at all at Inno-setup scripting language. Anything you guys can do to help me will do, anything, even small hints, Please help i am out of options right now.
-
What's the hardware-id? – Martin Prikryl Oct 08 '15 at 12:02
1 Answers
I want to build a setup with Innosetup that gets the hardware id and and stores it into a file in the CD so that the program can be installed in only one computer with only one license.
You want to create a unique Installer and CD for every client? Wow, that's a lot of work. It only makes sense for a really small business.
Anyway, in regard to getting a
hardware-id
:There is no function in InnoSetup to get a "hardware id".
You probably mean some kind of identifier, like a hard-disk or motherboard serial number, right? You could decide to fetch some serial numbers or identifiers by querying the
WMI
.
But wait? You compile Innosetup on the developer machine, right? The only hardware-ids you could possibly get at that time are IDs from your own developer machine. How do you get the hardware-id of your client, which is later trying to install your software from CD?
The whole approach doesn't make much sense and is flawed.
In general, doing this kind of protection in the installer is kind of useless.
Please handle your protection in the application, not in the setup.
You might use one of the following approaches: "API-Key" or "license-code" or "license file" or "hardware-dongle".
In other words: its always the same installer on multiple CDs, but the additional separate license code makes the difference - not during, but after the installation. The user simply enters the key or loads the license-file into the application and gets "Application registered to XY".

- 39,862
- 13
- 113
- 141
-
First of all all of this things that are written here i have thought months ahead so you guys haven't said anything new. Anyway i managed to solve the problem using batch files and the `getmac` command. The logic behind is very simple and very far from not working. – Edi Oct 13 '15 at 06:01