We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this questionNo offence intended, but let's not discuss that licensing schemes can be cracked (I know that) and that recourse to the law is usually a better deterrent (maybe in your country, but no in all).
Not my choice - I have been told to implement licensing, just good enough to keep casual hackers away.
However, it is also acceptable to use an existing system, whether FOSS or purchased, so long as it doesn't cost mo开发者_如何学运维re than a few hundred bucks. After all, licensing is a tricky beast it would cost more than a few $100 of my time to design code & test something.
Please see related question - which asked how to implement it; bow I am thinking of using someone else's.
Quoted form original question:
What might make this slightly different is that the PCS which will run the software won't always have internet access privileges.
When someone buys the product, I can build licensing info into it & deliver an install CD.
But, what happens if they want to buy more licenses? I don't want to have to go on site to update the licensing data, but they may not be able to access my server, nor I theirs.
I was thinking of having licenses in external (encrypted) files, each containing a number of licenses and an expiration date. If the user buys more licenses, then I can email out an addition file & their security cleared IT guys can burn it to CD or USB stick and then copy it to the applications data directory.
Public/private key encryption of a license file that can be read at launch, decrypted and interrogated.
You could use a serialized representation of your license object which could be deserialized at runtime. In this object you can store any value you want, such as the expiry date, number of licensed users etc.
Since its encrypted they can't tamper with it, if they do then it won't decrypt. Since its using public/private keys, they can't generate their own and encrypt it to fool the app into thinking its legit.
Obviously its crackable, but for casual and honest users, it will probably suffice.
精彩评论