I developed an application in C# and now I'm on the licensing process. What should I do with the license key after I register my app with it online with on my servers? Where should I keep it? Should I validate the application at every startup?
A:
You basically have three options:
- Store the license keys in a database, provide a webservice and have the application authenticate against it on every startup (downside is, you need to maintain the authentication servers and provide very good uptime or you'll have disgruntled customers)
- Create license keys that are made up out of unique data of a client's computer. For example you can generate a license key out of the NIC hardware MAC address, harddrive serial number, etc. In this scenario the client application would send you all the data on initial startup. Your servers can then calculate a corresponding key and send it back to the client (e.g. via email). This way the client application would only have to be authenticated one time. The downside is, if the client changes some hardware that you use to calculate your key, the client would have to request a new key.
- The simplest and most unsecure way would be to create some algorithm that creates a key. The client application would decode that key and would determine if it's valid. Very easy to implement but nothing prohibits users to share the keys with each other
Tom Frey
2009-09-30 06:01:57