您是否混淆了商业Java代码? [英] Do you obfuscate your commercial Java code?

查看:131
本文介绍了您是否混淆了商业Java代码?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道是否有人在他自己的商业产品上使用商业/免费java混淆器。我只知道一个项目实际上在发布的ant构建步骤中有一个混淆步骤。



你混淆了吗?如果是这样,为什么要混淆?



它真的是一种保护代码的方式,还是对开发人员/经理来说更好的感觉?



编辑好的,我确切地说明了我的观点:你是否进行了混淆以保护你的IP(你的算法,你投入产品的工作) )?出于安全考虑,我不会混淆,这感觉不对。所以我只是谈论保护你的应用程序代码免受竞争对手的攻击。<​​/ p>

@ staffan 有一个好点:


远离链接代码流的原因是其中一些变化使得无法实现使JVM有效地优化代码。实际上它实际上会降低应用程序的性能。



解决方案

如果你做混淆,远离通过改变代码流和/或添加异常块等修改代码的混淆器,以使其难以反汇编。为了使代码不可读,通常只需更改方法,字段和类的所有名称。



远离更改代码流的原因是其中一些更改使JVM无法有效地优化代码。实际上,它实际上会降低应用程序的性能。


I wonder if anyone uses commercial/free java obfuscators on his own commercial product. I know only about one project that actually had an obfuscating step in the ant build step for releases.

Do you obfuscate? And if so, why do you obfuscate?

Is it really a way to protect the code or is it just a better feeling for the developers/managers?

edit: Ok, I to be exact about my point: Do you obfuscate to protect your IP (your algorithms, the work you've put into your product)? I won't obfuscate for security reasons, that doesn't feel right. So I'm only talking about protecting your applications code against competitors.

@staffan has a good point:

The reason to stay away from chaining code flow is that some of those changes makes it impossible for the JVM to efficiently optimize the code. In effect it will actually degrade the performance of your application.

解决方案

If you do obfuscate, stay away from obfuscators that modify the code by changing code flow and/or adding exception blocks and such to make it hard to disassemble it. To make the code unreadable it is usually enough to just change all names of methods, fields and classes.

The reason to stay away from changing code flow is that some of those changes makes it impossible for the JVM to efficiently optimize the code. In effect it will actually degrade the performance of your application.

这篇关于您是否混淆了商业Java代码?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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