Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Get Mac Address & Specs
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00652249
Message ID:
00653076
Views:
25
Stanley,
The first thing I would do is convert the MAC address to a numeric and not translate it into an ASCII representation. Simply remove all the colons from the MAC address. You now have a hexadecimal numeric. In your example, 0x00E081107EAF = 964238016175. Us this number for all your calculations.

I question why you are using any information about diskspace in your key generation. Hard drives are not unique in drive size or configuration. Someone merely has to move the network card from one machine to another with the same hard drive configuration and the same key will work. The unique factor is the network card. Why not use it by itself?

If you want something unique about the drives you could get the serial number from the drive. WinAPI#12653 has an example of how to do this. You could run your equation on the MAC address and pre-/append the result to the concatenation of the alphanumeric serial numbers to get your key.

Good luck!

>05/05/2002 8:35 PM
>Hi Larry,
>
>Here is exactly what I am trying to achieve...
>Its a permission scheme that ensures a user cannot run our software on more than 1 machine without having an entirely different key. The only thing that is stored in a table is the key we provide, and all other info is dynamic.
>
>A Machine ID is created by getting the mac address of the ethernet card( "00E081107EAF") plus a "~", plus the total of both the C: and D: drives bytes count(18194253824). The machine ID is not dividable because it consists of alpha-numeric characters. So I convert the Machine ID using the ASC() function on each character and concatenate all the ASC() results together. Example, my mac address is "00E081107EAF" and my disk size in bytes is 18194253824, for which my Machine ID is "00E081107EAF~18194253824", which translates to the above mentioned global variable "4848694856494948556965701264956495752505351565052" At this point, we have an absolute machine ID.
>
>Now because we license the software based on the number of records the system is handling we need to generate a different license key based on the reccno() function. Our units of measurements equals 10,000 records, so what I want to do is divide the converted Machine ID(global variable) by the number of units, which will give me a different key which is based on the size of drive C:, drive D:, the mac address, and the number of units they want to license.
>So, for the customer, they give me the unconverted Machine ID( "00E081107EAF~18194253824") and the qty of units, and I will generate them a key that will not work on any other machine in the world. I then have enough info to authenticate their license. Also, if they change their net card, or the size of their c: drive or d: drives, they will need to re-license. At that point, I can easily see whats changed, and make decisions on what to do.
>
>Currently, I have such a system working by using hardlocks on the parallel ports, and it works flawlessly. The problem is the initial cost, the hassle of sending new ones out and getting the old ones back. By changing it to the way mentioned above, it can all be done by fax or phone and retain the security the hardlocks offer.
>
>Thanks for listening,
>Stanley
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Previous
Reply
Map
View

Click here to load this message in the networking platform