LeoHuang
LeoHuang
  • 发布:2021-11-09 11:27
  • 更新:2023-01-03 11:00
  • 阅读:1444

iOS 离线打包被拒 2.3.1 和 2.5.2

分类:uni-app

我这边有个应用,使用离线打包上架,今天收到反馈 2.3.1 和2.5.2
具体两项

2.3.1 We discovered that your app contains obfuscated code, selector mangling, or features meant to subvert the App Review process by changing this app’s concept after approval to the App Store.

Obfuscated code has been manipulated to be difficult to understand and is typically used to hide features and content while your app is in review
相关混淆代码且可能有违反苹果商店的隐藏功能,并且表示混淆代码变得十分难以理解
我这个工程是直接使用离线SDK里面直接打包的,没有使用任何的混淆工具,所以想询问下,uniapp离线SDK是否有混淆关键词让苹果审核人员难以理解?

2.5.2 This code, combined with a remote resource, can facilitate significant changes to your app’s behavior compared to when it was initially reviewed for the App Store. While you may not be using this functionality currently, it has the potential to load private frameworks, private methods, and enable future feature changes. This includes any code which passes arbitrary parameters to dynamic methods such as dlopen(), dlsym(), respondsToSelector:, performSelector:, method_exchangeImplementations(), and running remote scripts in order to change app behavior and/or call SPI, based on the contents of the downloaded script. Even if the remote resource is not intentionally malicious, it could easily be hijacked via a Man In The Middle (MiTM) attack, which can pose a serious security vulnerability to users of your app.

uniapp里面是否有包含这些高危方法?我这边没有用到地图和支付相关,且没有引入相关的lib,目前使用的第三方库为:
facebook, appsflyer和zalo

目前搜索之后再app-service里面发现了dlopen方法,机审这一步就过不了了,请问是否有什么方案?

所以十分疑惑,uniapp如果默认工程没有问题,不应该出现这样的审核拒绝。

另外,离线打包是否有什么注意事项?比如libliblog是否应该打包进去?

-------------------------------------2021-11-18 号更新-----------------------------------------------------------

这次我们去除了热更新检测之后,提交了一个新包,回复了明确的一点。

Guideline 2.3.1 - Performance

We discovered that your app contains hidden features. Specifically, your app continues to contain signs of Javascript “hot update” downloading support.

明确告诉我们,说我们的应用有支持javascript 热更新的能力,所以拒绝我们。

同时我在https://ask.dcloud.net.cn/question/125714 这个问题中了解到,hotUpdate关键字存在于app-service.js中,导致出现2.5.2,感觉后续这种问题会大面积出现,是否有对应的方法

2021-11-09 11:27 负责人:DCloud_UNI_LXH 分享
已邀请:
DCloud_iOS_XHY

DCloud_iOS_XHY

  1. 是否用到了wgt热更新?如果用到了就去掉在试试;
  2. SDK没有做混淆,dlopen这个是前端js的一个方法名,原生这边是没有用到这些方法的,有很多用户都在使用离线打包,应该是个例;也不排除苹果审核机制更新后导致检索到dlopen关键字然后拒绝审核的;为了避免苹果扫关键字,之后版本会将js框架中的dlopen去掉;
  3. libliblog 发版时不要带,不过这个库也不会影响审核的;

方便的话可以追问一下审核人员具体的方法是哪个,我们看看是否有优化的地方;

  • LeoHuang (作者)

    目前在跟苹果那边交涉,看下那边能否给出更加具体的消息。

    dlopen应该是被扫描到关键字。

    目前有wgt热更新,所以接下来会先去除,SDK也是没有做混淆,也会做混淆,看下审核态度。

    感谢回复,有新的进展会继续回复。


    2021-11-09 18:26

  • LeoHuang (作者)

    这次我们去除了热更新检测之后,提交了一个新包,回复了明确的一点。

    Guideline 2.3.1 - Performance


    We discovered that your app contains hidden features. Specifically, your app continues to contain signs of Javascript “hot update” downloading support.


    明确告诉我们,说我们的应用有支持javascript 热更新的能力,所以拒绝我们。


    2021-11-18 09:40

  • LeoHuang (作者)

    同时我在https://ask.dcloud.net.cn/question/125714 这个问题中了解到,hotUpdate关键字存在于app-service.js中,导致出现2.5.2,感觉后续这种问题会大面积出现,是否有对应的方法


    2021-11-18 09:58

  • DCloud_iOS_XHY

    回复 LeoHuang: 原来如此,我记得当初已经将这个方法重新命名了,可能后来框架升级vuex后又有了,你可以和苹果解释一下 这个方法是 vuex 中的方法,和热更新没有任何关系,顺便给他科普一下 vuex 的作用,应该就可以了


    2021-11-18 16:22

  • LeoHuang (作者)

    回复 DCloud_iOS_XHY: Specifically, your app continues to contain signs of Javascript “hot update” downloading support. It would be appropriate to remove this feature before resubmission. 申诉解释之后返回这个,javascript 拥有热更新下载的迹象,要求我们移除响应的功能再提交审核,哪里可以移除热更新的功能?我想先上架先


    2021-11-23 09:34

  • DCloud_iOS_XHY

    回复 LeoHuang: 修改方式参考下面的回复


    2021-11-23 19:26

  • LeoHuang (作者)

    回复 DCloud_iOS_XHY: 已经上架成功,不过我是手动修改hotupdate的关键词,建议在打包的时候替换


    2021-12-13 10:53

DCloud_UNI_LXH

DCloud_UNI_LXH

修改 HX安装目录\plugins\uniapp-cli\node_modules\vuex\dist\vuex.esm.js 文件。

搜索 hotUpdate 。将

Store.prototype.hotUpdate = function hotUpdate (newOptions)

改为

Store.prototype[[104,111,116,85,112,100,97,116,101].map(item =>String.fromCharCode(item)).join('')] = function (newOptions)

编译后,在打出的资源包根目录的 app-service.js 中搜索 hotUpdate ,看是否还存在

  • LeoHuang (作者)

    已經修改打包上传,看下这次审核结果如何。


    2021-11-23 20:41

  • DCloud_UNI_LXH

    回复 LeoHuang: 如果已经确认了没有 hotUpdate ,应该问题不大


    2021-11-24 11:12

  • LeoHuang (作者)

    回复 DCloud_UNI_LXH: 目前已经上架成功,可以确定的是如果程序包含hotupdate, hot等相关关键词会被2.3.1和2.5.2。不建议你这种改法,可以在打包编译的时候,使用webpack的插件替换这些关键的内容,不过据我现在调查知道,hotUpdate也就这个vuex才有,且如果开发过程没用到可以直接删除。


    2021-12-13 10:52

  • DCloud_iOS_XHY

    回复 LeoHuang: 最新版本框架内部已经处理了这个关键词


    2021-12-16 17:35

西恩十月

西恩十月

哈喽,你的Zalo第三方库怎么引入的?我看插件市场没有zalo的插件

要回复问题请先登录注册