Click here to Skip to main content
15,899,126 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
See more:
hi all,

In my windows application, i need to store the product key for my setup. I need your suggestions to store my Product key safely and Securely.

My considerations are...
If i store my Product Key inside setup, then user can use the same product Key for different setup installation.
So, i have an idea to store my Product Key in Database after some Encryption process. I will set a flag after using the particular Product Key. So, i can validate whether the particular Key is valid or not.

Is this correct process?? or i need to improve some ??
waiting for your replies...


Regards
Karthick
Posted

Encryption may help, but probably won't - bear in mind that in order to use or check your product key you have to decrypt it - which needs the encryption key.
Anyone who is smart enough to find the key, is smart enough to find the decryption key by examining your code!

Since the user will have entered the product key at some point, doesn't he already have it? So what is the point of hiding it now?

Why not use the Windows method: Product key + hardware information -> Microsoft who returns an validation code which is only effective for that particular Product key + hardware information combination? No encryption needed!

Since the Product key is validated against specific hardware information at your end, you just record the hardware against which the product key was used, and don't let it be re-used unless it was uninstalled first.
 
Share this answer
 
I agree with OriginalGriff, earlier Microsoft was not provide such Hardware information but I used to get LAN Card Number which is unique for every LAN Card.

People were selling dongle also which is unique and need to attached in LPT (Printer Port), but not it is no longer in use.

You can either get LAN Card Info with your ProductKey or can get Hardware Information to generate a Unique Key.

Regards
Rushi
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900