About this question
I have seen them plenty of times, with many different types of software, but the one thing I have always wondered is how software keygens know what key to generate. I know the basic principle of it: the keygen looks somewhere in the software installation files and creates a key that matches some encrypted file which allows the program to work. But I wanted to know how they do that, and how to prevent it. This is really a multiple part question.
How does the key-system work?
How do programmers usually create software that works based on a key. I am an intermediate programmer, but I never learned much of the security/anti-piracy aspect of it. How do they create and/or recognize the keys to allow the software to start working?
Where does it usually look to find this "encrypted file"?
Is it in a physical file on the computer, or an off-site database that it calls? What do the companies do to encrypt that file?
I would emagine that the key must be stored in more than just plaintext, what do they do to keep it encrypted?
What method is the keygen using to create the key?
I have played around a little with some password-cracker software such as "cain & able" and I have noticed, that with some of the password-cracking methods, such as brute-force and dictionary, it gives me ETAs in years, however keygens seem to create keys instantly. Are they using different methods entirely?
What measures can companies take to prevent the use of keygens in pirated software?I am starting to write my own software to be distributed, I was wondering what existing, relatively easy methods can I use to prevent