如何限制我的窗口C#只能在一台PC上工作? [英] How I can limit my windows form C# to work on only one PC?

查看:63
本文介绍了如何限制我的窗口C#只能在一台PC上工作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何让我的项目在一台PC上工作,如果有人试图在其他PC上打开它只是关闭PC我想要代码的帮助,我搜索了很多关于这个,但我找不到任何关于这个,所以我需要帮助码?以及我如何使用独特的PC ID工作?





我尝试过的:



i可以获得

处理器ID

HDD序列号

MAC地址

how i can make my project work on one PC and if anyone try to open it in other PC just close PC i want help with code please i searching a lot about this but i couldnt found anything about this so i need help with code? and how i can make it work with unique PC ID?


What I have tried:

i can get
Processor Id
HDD Serial No
MAC Address

推荐答案

您需要对Windows安装程序for .NET进行一些基础研究。首先在StackOverFlow上研究这些线程:[ ^ ],[ ^ ]。



在另一台没有许可的PC上启动你的应用程序的想法会关闭那台PC是非常糟糕的想法:你的应用应该只是关闭,也许会显示一个消息框,用礼貌的语言解释为什么它会关闭。



有各种各样的方案使用软件和/或硬件(加密狗)将应用程序绑定到特定PC。从长远来看,没有任何许可方案可以被黑客攻击。



商业安装程序软件,如InstallShield,InstallAware,提供高级安装安全性,足以阻止随便的黑客很贵......虽然您可以使用像Wix或Inno Setup这样的开源安装程序,但是修改它们的源代码以实现某种形式的硬件检测和安全设施,imho,需要非常高级的编程技能。



请在此处查看一些Windows更为人熟知的安装程序包:[ ^ ]。
You need to do some basic research on Windows Installers for .NET. Start by studying these threads on StackOverFlow: [^], [^].

The idea that starting your app on another PC, where it is not licensed, would then "close down" that PC is a very bad idea: your app should simply shut-down, perhaps displaying a message box that explains, in polite language, why it is shutting down.

There are a variety of schemes for "binding" an app to a specific PC, using software and/or hardware (dongles). In the long run no licensing scheme is invulnerable to being hacked.

Commercial installer software, like InstallShield, InstallAware, that provide advanced installation security which is robust enough to discourage "casual hackers" are ... expensive. While you might be able to use an open-source installer like Wix or Inno Setup, modifying their source code to implement some form of hardware detection and security facility would, imho, require very advanced programming skills.

Do check-out some of the Windows more well known installer packages here: [^].


这篇关于如何限制我的窗口C#只能在一台PC上工作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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