如何添加软件更新订阅
我们希望为我们的产品添加自动更新或更新通知(C++)。
更新应基于订阅:
- 用户购买订阅期为 1 年的更新,
- 当订阅到期时,不再有可用的更新。
有人可以推荐用于实施此类服务的软件或提供商吗?
我找到了一些自动更新的例子,但它们都是没有时间限制的。
该服务必须基于每个用户进行限制并允许扩展。
We want to add auto-update or update notification to our products (C++).
Update should be subscription-based:
- user buys subscription for 1 year of updates
- when subscription expires, no more updates are available.
Can someone suggest software or provider for implementing such a service?
I found a few examples of auto-update but they all are unlimited in time.
This service must be limited on per-user basis and allow extensions.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
就成分而言,您需要的是:
这 我建议使用可嵌入的 HTTP 客户端定义一个简单的 XML over HTTP 服务,例如(无耻的插件) Arachnida,具有一个简单的 API - 类似于:
如上所示,它们的密钥本身是一个字符串,通过其编码,将包含某种有关其有效性的信息 - 例如某种 CRC了解输入的字符串是否有效。密钥的其余部分(包括其到期日期)可以在服务器端进行管理,尽管到期信息也可以编码在密钥本身中(但这意味着如果用户延长许可证,则需要更改密钥)。
对于服务器端,当出现密钥和更新请求时,服务器将
如果下载失败,可以重新启动或再次请求。如果您想对单个下载收费,则需要客户端确认下载成功 - 或报告失败错误 - 这样您就不会两次计算单个下载。
当然,这一切都不是我的想法——可能有一些细节我没有想到。每种成分都很容易获得。 Arachnida 的开源版本可以在 SourceForge 上获取,如果您需要的话,我有一些代码可以对许可证密钥进行编码(使用它适用于我的另一个产品),但我确信如果您不想使用我的产品,您可以这样写。
您可能需要考虑的一些事情是对您的客户端进行安全身份验证 - 这样他们就不会共享许可证密钥 - 保护您的 HTTP 连接,这样您最终就不会向全世界发布您的更新,等等。无论是服务器还是客户端客户端的实现需要非常复杂,因为大多数构建块已经存在。
HTH
RLC
What you would need, in terms of ingredients, would be:
What I would suggest would be to define a simple XML over HTTP service using an embeddable HTTP client, such as (shameless plug) Arachnida, with a simple API - something like:
They key itself would, as seen above, be a string that, through its encoding, would contain some kind of information as to its validity - e.g. some kind of CRC to know whether the entered string is valid. The rest of the key - including its expiration date - could be managed server-side, although expiration information could also be encoded in the key itself (but that would mean changing the key if the user extends the license).
As for the server-side, when presented with a key and a request for an update, the server would
If a download fails, it can be restarted or asked for again. If you want to charge for individual downloads, you'd need the client to confirm a successful download - or report an error on failure - so you don't count individual downloads twice.
Of course, all this is off the top of my head - there might be some details I haven't thought of here. Each of the ingredients are pretty easy to come by. An open source version of Arachnida is available on SourceForge and I have some code to encode license keys if you need it (used it for another of my products), but I'm sure that you can write that if you don't want to use mine.
A few things you might want to think of are secure authentication of your clients - so they don't share license keys - securing your HTTP connection so you don't end up publishing your updates to the world, etc. Neither the server nor the client need be very complicated to implement, as most of the building blocks already exist.
HTH
rlc