在BillingService模块中,需要修改哪些内容来提高安全性?
类 BillingService 的注释建议:
在使用此代码之前,您应该对其进行修改和混淆。
好的,但是什么必须修改?
班级名称?用于记录的TAG?方法名称和数据成员?逻辑和程序流程本身?其他?
换句话说,我可以理解混淆的必要性,但是我如何才能在不从头开始重写所有内容的情况下实现建议(可能会出现比不修改任何内容更糟糕的错误)?
The comment for the class BillingService recommends that:
You should modify and obfuscate this code before using it.
OK, but what must be modified?
The class name? The TAG used for logging? Method names and data members? The logic and program flow itself? Other?
In other words, I can understand the need for obfuscation, but how can I get away with implementing the recommendation without rewriting everything from scratch (potentially with bugs that are worse than not modifying anything)?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我目前正在研究这个问题,到目前为止,我的方法如下:
希望这有帮助。
I'm working on this at this moment and my approach, so far, is as follows:
Hope this helps.
这里没有好消息:除了使用 Proguard 之外,您还需要进行任何可以更改的操作。这包括合并类、拆分类、将某些方法从一个模块移动到另一个模块,特别是对存储到数据库中的购买信息进行加密,如
PurchaseDatabase
类的描述所示:原因是,使用 AntiLVL 这样的工具,可以很容易地将反编译(混淆!)的代码与原始示例进行比较,并从中推断出破坏它所需的任何内容。完全防止开裂是不可能的,但应该尽量让它变得困难。
No good news here: You need to change anything you can, in addition to using Proguard. This includes merging classes, splitting them, moving certain methods from one module to another, and especially encrypting the purchase information stored into the database, as the description for the
PurchaseDatabase
class suggests:The reason is that with tools like AntiLVL it is very easy to compare your decompiled (obfuscated!) code to the original sample and deduct from it whatever needed to compromise it. It is impossible to completely prevent cracking, but you should try to make it as difficult as possible.
他们解释如下:
这意味着不要使用所提供的代码,而是更改其中的某些部分,以便黑客无法知道您使用的代码。
基本上,我认为它们不是指 billingService 本身,而是指您在应用程序中使用它的方式。
They explain it as follows:
It means don't use the code as provided, change some part of it so that hackers won't be able to know what code you use.
Basically, I don't think they meant the billingService itself, but the way you use it in your application.