Solved

How to generate CD Keys

Posted on 2010-11-08
7
405 Views
Last Modified: 2012-05-10
Where can I find an algorithm to generate and include CD Keys in my applications?

In C# or C++

CD Keys like Microsoft uses for it's applications (ex. XX35-KJ32-PLKF-K43J)
0
Comment
Question by:evo_x
  • 3
  • 3
7 Comments
 
LVL 16

Expert Comment

by:Stephan
Comment Utility
Take a look at this: http://ellipter.com/

This will give you an insight how you can generate your keys.
0
 
LVL 44

Expert Comment

by:AndyAinscow
Comment Utility
I don't know if there is a 'standard'.  In fact if one thinks about it then a standard way could be abused.

You will need code to create a key AND code to check the key the user enters is valid.

I suggest you need to think about what information you require in the key.  What format the key has.  What sort of extra padding you want in the key to give a constant length.  Possibly one or two chars for a checksum type of validation.  Finally an encryption routine to then hide things.

I've done things like having an expiry date as 5 digits, the 1st in char 4, 2nd in char 11....
0
 
LVL 2

Author Comment

by:evo_x
Comment Utility
I need to include the product id, version number and reseller id
any method would be good as an example.
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 
LVL 2

Author Comment

by:evo_x
Comment Utility
AndyAinscow: That is what I am looking for but that is a commercial library, I want to implement my own instead of paying $250
0
 
LVL 44

Expert Comment

by:AndyAinscow
Comment Utility
OK.
What I did was sit down with a piece of paper and list what I required.  Worked out how many digits I needed, then jumbled the digits around.  A couple of hours and everything was coded.
0
 
LVL 2

Author Comment

by:evo_x
Comment Utility
And what encryption method should I use? which is free of course for commercial use.
0
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 500 total points
Comment Utility
Whatever you wish.

This is one possibility:
http://en.wikipedia.org/wiki/Tiny_Encryption_Algorithm

0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now