程序的许可和自动删除

发布于 2024-07-08 00:48:36 字数 541 浏览 8 评论 0原文

我有一个在客户端计算机上复制并运行的应用程序。 该程序采用 Adob​​e Projector 文件的形式。 我想编写一个过程来检查程序何时开始运行许可证是否仍然有效,如果不是,则删除整个程序。

程序本身知道其安装的真实日期,并且由于我们自己为客户安装程序,因此我们可以确保在安装时与客户计算机上的日期匹配。 每次启动程序时,它都会将当前日期与上次运行程序的日期进行比较。 如果今天的日期晚于该日期,则会从剩余天数中减去已过的日期数。 如果该日期早于上次运行的日期,则会对客户端进行固定天数的处罚(这是为了阻止客户端尝试重置计算机上的日期并使其许可证永不过期)。

如果他们要将整个目录复制到新计算机,则程序内的安装日期将与目录中任何文件的创建日期不匹配,并且会将这种情况视为过期许可证。

我的问题是:是否有一种简单的方法可以编写脚本以在每次启动应用程序时运行? 我们当前创建了一个可以指向批处理作业的快捷方式,但是您在批处理作业中放置了什么? 或者这种许可方法是完全错误的吗? 购买该程序的人只会购买有时间限制的许可证,并且该程序是通过将目录复制并粘贴到目标计算机上来运行的。

I have an application which get copied and run on client machines. The program is in the form of an Adobe Projector file. I want to write a process that checks when the program starts running whether or not the license is still active, and if not, delete the entire program.

The program itself knows the real date that it was installed, and since we install the program ourselves for the clients, we can ensure that at install time the date on the client's computer matches. Every time they start up the program, it compares the current date with the date they last ran the program. If today's date is after that date, it subtracts the number of elapsed dates from the number of days remaining. If the date is before the date it was last run, it penalizes the client by a constant number of days (this is to discourage the client from trying to reset the date on the computer and have their license never expire).

If they were to copy the entire directory over to a new machine, the installation date inside the program would not match the created date on any of the files in the directory, and it would treat this case like an expired license.

My question is this: is there a simple way to script this to run every time they start the application? We currently create a shortcut which could be pointed to a batch job, but what do you put in the batch job? Or is this approach for licensing completely wrong? People who buy this program will only buy time-limited licenses, and the program is run by copying and pasting a directory onto the target machine.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

兮颜 2024-07-15 00:48:36

我相信你想得太复杂了。 为什么不将其设置为试用版,在安装、首次使用或任何您希望的方式后 n 天到期。

关于删除exe的方法:小心,这可能是对别人计算机的非法干预。

I believe you are thinking too complicated. Why not make it like a trial version that expires n days after installation, first use, or whatever you wish.

About the deleting the exe approach: Be careful, this could be an illegal intervention in somebody elses computer.

z祗昰~ 2024-07-15 00:48:36

今天,我们接受试用期结束后不在系统上运行软件的行为。 我认为实际上删除该程序不会。 我知道我永远不会再使用这样的应用程序。

Not running software on a system when the trial period has expired is accepted today. I don't think actually deleting the program would be. I know I would never use such an application again.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文