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

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

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

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


当前回答

net反应堆

更新

Jared指出de4dot声称能够反编译它。

.NET Reactor provides complete protection for your sensitive intellectual property by converting your .NET assemblies into unmanaged processes which cannot be understood as CIL, and which no existing tool can decompile. Hackers have no access to any intelligible form of your source. Powerful and flexible, the .NET Reactor licensing features allow you to enforce your license conditions and protect your revenue stream by using hardware and software locks. The license manager can build trial or permanent licenses, in a matter of seconds. A fully documented software development kit (SDK), complete with examples, allows you to call the licensing system directly from your code, allowing you to create custom extensions to the licensing system.

其他回答

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.

是的。如果代码没有混淆,. net代码非常容易进行逆向工程。

混淆将给试图逆向工程您的软件的人增加一层烦恼。根据你得到的版本不同,你会得到不同程度的保护。

Visual Studio包括Dotfuscator的一个版本。因为它是一个捆绑版本,你肯定不会得到最强烈的混淆。如果您查看它们的特性列表,就会清楚地看到您遗漏了什么(以及应用程序将如何使您的代码更安全)。

还有其他一些免费或开源的。net混淆器(但我不能评论它们的质量或使用的各种方法):

Obfuscar 巴别塔。网上

最后,没有什么是完美的。如果有人真的想看看你的软件是如何工作的,他们会的。

你不能。

您可以采取一些步骤来增加一些难度,但最终本地机器上的任何可执行文件都是可以被破解的。最终,这些代码必须转换为本机机器码,每个可运行的应用程序都很容易受到攻击。

你要做的就是让它变得足够难破解,让它不值得人们去麻烦。

我有一些建议可以帮助你保护你的应用程序:

Obfuscate your code. Dotfuscator has a free edition and comes with Visual Studio. Use public/private key or asymmetric encryption to generate your product licenses. This ensures that only you can generate your license codes. Even if your application is cracked, you can be sure that they won't be releasing a key generator for your application, because it is impossible to reverse the key generating algorithm. Use a third-party packer to pack your .NET executable into an encrypted Win32 wrapper application. Themida is one of the better ones. This stops people from reflecting your application in .NET Reflector and makes it a pain to unpack for reversing. Write your own custom packer. If the third-party packers are too expensive, consider writing your own. Sometimes custom packers can be very effective, because there aren't well published methods on how to unpack them. The tutorial How to write your own packer gives a ton of good information on writing your own Win32 packer.

最终,如果人们想要破解你的应用,他们会的。看看所有的商业软件,它们有大量的资源来保护它们的应用程序,但它们在应用程序发布给公众之前就被破解了。

一个熟练的逆向工程师可以启动IDA-Pro,并像切黄油一样切开您的应用程序,无论您做什么。一个打包的应用程序可以被解包,而混淆只会阻止它变得像在公园里散步一样简单。您使用复杂许可代码所做的所有艰苦工作都可以通过一个单字节补丁来完成。

你只需要接受这样一个事实:人们很有可能会盗版你的软件。有些人无论如何都不会为你的应用程序付费,这些人是你不需要担心的。

然而,有许多企业永远不会冒着诉讼的风险,他们很乐意购买软件许可证,而许多计算机用户要么不想冒险,要么发现它是错误的,要么没有足够的技术知识来盗版。这些是你真正的客户,你应该把精力集中在为他们提供良好的用户体验上,而忽略那些破解你软件的人。

我的应用程序以前被盗版过,我认为这是对我个人的侮辱。我是一个小开发者,全身心地投入到一个应用中,而这些人却有胆量剽窃我的作品?!他们直接从我口袋里拿钱!

我立即添加了一堆严格的DRM代码,并试图破坏任何使用非法或破解副本的人。当然,我应该努力让我的应用程序变得更好,而不是试图阻止不可避免的事情。不仅如此,我还伤害了我真正的客户,因为我设置了这些额外的保护措施。

经过长时间的战斗,我意识到我是在与潮流作斗争,所有这些浪费的时间都是徒劳的。除了最基本的许可函数之外,我取出了所有的phone-home代码,并且再也没有回头。

net反应堆

更新

Jared指出de4dot声称能够反编译它。

.NET Reactor provides complete protection for your sensitive intellectual property by converting your .NET assemblies into unmanaged processes which cannot be understood as CIL, and which no existing tool can decompile. Hackers have no access to any intelligible form of your source. Powerful and flexible, the .NET Reactor licensing features allow you to enforce your license conditions and protect your revenue stream by using hardware and software locks. The license manager can build trial or permanent licenses, in a matter of seconds. A fully documented software development kit (SDK), complete with examples, allows you to call the licensing system directly from your code, allowing you to create custom extensions to the licensing system.

最好的答案是第一个来自小开发人员自己的经验,上面讨论的所有反反转技术对于任何严肃的反向工程师来说都是101个教科书案例。

一些商业DRM解决方案相当不错,但它们总是在数小时(或数天)内使用自定义DRM解决方案破解每一款AAA级游戏。只有一个全新的DRM解决方案的引入——有时——延迟是不可避免的,可能需要几个星期。

充分利用DRM需要花费大量的时间和金钱,而且很容易损害性能、可靠性、兼容性/可移植性和客户关系。要么坚持一些像样的商业DRM,不要试图太聪明,承担你的(更少的)损失,要么完全忘记它……

一个DRM解决方案的例子,它挖了自己的(商业)坟墓:http://en.wikipedia.org/wiki/StarForce