混淆是一种方法,但它不能防止破坏应用程序的盗版保护安全性。如何确保应用程序不被篡改,如何确保注册机制不会被逆向工程?

此外,还可以将c#应用程序转换为本机代码,而Xenocode的成本太高。

c#提供了很多特性,是编写代码的理想语言,所以用c++重新编写整个代码库是不可能的。

安全证书可以很容易地从. net中的签名程序集中删除。


当前回答

Here's one idea: you could have a server hosted by your company that all instances of your software need to connect to. Simply having them connect and verify a registration key is not sufficient -- they'll just remove the check. In addition to the key check, you need to also have the server perform some vital task that the client can't perform itself, so it's impossible to remove. This of course would probably mean a lot of heavy processing on the part of your server, but it would make your software difficult to steal, and assuming you have a good key scheme (check ownership, etc), the keys will also be difficult to steal. This is probably more invasive than you want, since it will require your users to be connected to the internet to use your software.

其他回答

你无法阻止别人破解你的软件。

However, you can make them create cracks that will hurt your sales less. Keygenerators that can issue a valid registration code for your software are much worse than simple patches that remove registration incentives from your software. That's because a crack will work for one software version only, and will cease to work with the next software update you release. The keygenerator will continue to work until you change your registration key algorithm and that's something you don't want to do often because it will put off your honest clients.

因此,如果您正在寻找一种方法来对抗非法的密钥生成器,并且您不想使用不对称加密,因为这会生成很长的注册码,您可以看看部分密钥验证。

Partial Key Verification makes sure that each illegal keygenerator works only for one particular release of your software. Basically what you do is to make sure that each release of your software only links with the code for checking SOME digits of the registration code. Which digits exactly is random, so crackers would have to reverse engineer many different versions of your software and combine all this into one keygenerator in order to release a keygenerator that works for all versions of your software.

如果你定期发布新的软件版本,这将导致大量的密钥生成器散布在各种软件盗版档案中,这些文件不再工作。潜在的软件盗版者通常会寻找最新版本的破解或关键元素,所以他们可能会尝试其中的一些,并最终放弃。

我在我的(c++)新共享游戏中使用了部分密钥验证,它非常有效。之前我们遇到了很多无法对抗的关键生成器问题。后来出现了许多漏洞,一些按键生成器只适用于特定版本的游戏,但没有一个按键生成器适用于所有版本。我们定期发布游戏的小更新,让之前存在的所有漏洞都变得无用。

似乎有一个用于部分密钥验证的开源。net框架,尽管我还没有尝试过。

Use online update to block those unlicensed copies. Verify serial number from different modules of your application and do not use a single function call to do the verification (so that crackers cannot bypass the verification easily). Not only check serial number at startup, do the verification while saving data, do it every Friday evening, do it when user is idle ... Verify application file check sum, store your security check sum in different places. Don't go too far on these kind of tricks, make sure your application never crash/get into malfunction while verifying registration code. Build a useful app for users is much more important than make a unbreakable binary for crackers.

如何确保应用程序不被篡改,以及如何确保注册机制不会被逆向工程。

两者都有一个非常简单的答案:不要把目标代码交给不可信的一方,比如(显然)你的客户。在您的机器上托管应用程序是否可行只取决于它的功能。

如果它不是一个web应用程序,也许你可以允许SSH登录,X转发到应用服务器(或者远程桌面连接,我猜,对于Windows)。

如果你把目标代码交给书呆子,而他们认为破解你的程序可能很有趣,那么它就会被破解。没有办法。

如果你不相信我,那就指出一个没有被破解和盗版的引人注目的应用程序。

如果你使用硬件键,它会使生产成本更高,你的用户会因此讨厌你。在地板上爬来爬去,插拔你27个不同的USB设备,这真是个婊子,因为软件制造商不信任你(我想)。

有一些包可以加密你的EXE,并在允许用户使用它时解密它

当然,绕过它的方法是破解“我能使用它吗”测试,以便它总是返回true。

一个令人讨厌的技巧可能是以一种肮脏的方式在程序的其他地方使用执行测试的操作码的字节值,这将使程序很可能崩溃,除非值刚刚好。它让你链接到一个特定的架构,尽管:-(

根据我的经验,让你的应用程序或库更难破解会伤害你诚实的客户,而只会稍微延迟那些不诚实的客户。专注于制作一款优秀的,低摩擦的产品,而不是花费大量精力去推迟不可避免的事情。

抱歉,完全保护应用程序是不可能的。