在C ++软件中加入共享软件限制 [英] Incorporating shareware restrictions in C++ software

查看:181
本文介绍了在C ++软件中加入共享软件限制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望在共享软件的基础上实现我的软件,所以用户是
给定最大试用期(比如)30天,试用软件。在购买我打算给用户一个随机生成的密钥,当输入
再次启用软件。

I wish to implement my software on a shareware basis, so that the user is given a maximum trial period of (say) 30 days with which to try out the software. On purchase I intend the user to be given a randomly-generated key, which when entered enables the software again.

我从来没有走这条路线。

I've never been down this route before, so any advice or feedback or pointers to 'standard' ways of how this is done would be much appreciated.

我不希望用户通过更改系统日期作弊,因为任何建议或反馈或指向标准方式的操作如何完成。或任何类似的东西,虽然这可能值得考虑。

I do not anticipate users cheating by changing the system date or anything like that, though this is probably worth considering. Apologies if this topic has appeared before.

推荐答案

关于随机生成的密钥,您将如何验证密钥是合法的或者如果一个密钥是伪造的,如果它实际上是随机的?请查看文章实现部分序列号验证系统,因为它非常好,并且易于以任何语言实现。

With regards to a random-generated key, how will you verify a key is legit or if a key is bogus if it is actually random? Have a look at the article "Implementing a Partial Serial Number Verification System" as it is quite good and is easy to implement in any language.

作为基本的解决方案将是比较你的主要可执行文件创建时间到当前系统时间和行动的差异。这假设您的安装程序将文件创建时间设置为安装时间,而不是保留编译时间! :)

With regards to time trials, as basic solution would be to compare your main executable files creation time to the current system time and act on the difference. This assumes your installer sets the files creation time to the time of install as opposed to preserving the time you compiled it! :)

这篇关于在C ++软件中加入共享软件限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆