[英]How to skip "[ERROR] Only final fields may have an initial value!" using java obfuscation through Allatori obfuscator?
I am using Allatori obfuscator for java jar file it works well when there is no initialized variable during declaration but if there is only variable which is initialized and not final generates exception:我正在将 Allatori 混淆器用于 java jar 文件,当声明期间没有初始化变量时它运行良好,但如果只有初始化的变量而不是最终的变量会生成异常:
[ERROR] Only final fields may have an initial value!
What should I do to skip this exception because I don't want to uninitialize my variables?我应该怎么做才能跳过这个异常,因为我不想取消初始化我的变量?
Any suggestions please任何建议请
This has reportedly been acknowledged by the Allatori vendor (Smardec Inc) as a bug.据报道,Allatori 供应商(Smardec Inc)承认这是一个错误。 Mahmoud M. Hammad states the following in his PhD thesis Self-Protection of Android Systems from Inter-Component Communication Attacks 2018. Mahmoud M. Hammad 在他的博士论文《自保护 Android 系统免受组件间通信攻击2018》中陈述了以下内容。
"For instance, Allatori raised this exception “com.allatori.IiIIIIiiii: Only final fields may have an initial value!” “例如,Allatori 提出了这个异常“com.allatori.IiIIIIiiii:只有最终字段可能有初始值!” on many apps. We contacted the provider of Allatori about this exception, who informed us that this problem has been reported by other users, but could not be reproduced. Consequently, we helped them reproduce it to improve their product. They reported to us that this exception is mainly caused by the use of dex2jar, although a fix for the exception is still in progress."在很多应用上,我们就这个异常联系了Allatori的供应商,他告诉我们这个问题已经被其他用户报告过,但无法重现。因此,我们帮助他们重现它以改进他们的产品。他们向我们报告说此异常主要是由于使用了 dex2jar 引起的,尽管对该异常的修复仍在进行中。”
I did not see mention of a specific version of Allatori in Hammad's thesis, but there is a good chance that the bug has been fixed in a recent version.我在 Hammad 的论文中没有看到提到 Allatori 的特定版本,但很有可能在最近的版本中修复了该错误。 Check that you are using an up-to-date version of the tool.检查您使用的是该工具的最新版本。 You could also contact the vendor about this 1 .您也可以联系供应商了解此1 。
How to skip the error?如何跳过错误?
I don't think you can.我不认为你可以。
1 ... assuming that you have a legitimate copy. 1 ...假设你有一个合法的副本。 The idea of someone (hypothetically!) using a pirated or unsupported copy of a proprietary obfuscator to protect their own software is delightfully ironic.有人(假设!)使用专有混淆器的盗版或不受支持的副本来保护自己的软件的想法具有讽刺意味。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.