5

I'm working on an iOS enterprise app that relies on an Configuration Profile being put on the phone. Unfortunately, the user can "cancel" this profile, which really screws with our app.

So I was wondering if a) is it possible to prevent a configuration profile from being deleted OR

b) is there a way to check to see if a configuration profile is installed already (say, at runtime, then we can just install it again if it's not there)?

4

2 回答 2

8
  • 如果您希望配置文件不被用户篡改/禁用,这是可能的!如果您使用Apple Configurator在 Generals 选项卡中构建.mobileconfig文件,请选择securityas never. 请注意:一旦配置文件安装在设备上,除非您恢复设备,否则无法恢复

  • 长话短说,目前还没有记录的方法可以以编程方式调用/安装配置.mobileconfig文件(到目前为止可用的文档)-如果您确实找到了方法,请告诉我

笔记:

.mobileconfig文件只能通过 Safari / Mail 运行。

这个类似的 SO 讨论可能会有所帮助:在 iPhone 上安装配置文件 - 以编程方式

于 2012-10-05T16:02:15.293 回答
1

可以检查是否安装了 .mobileconfig。你需要做的是:

  1. 创建 CA(证书颁发机构)并将其导出为 .cer。
  2. 使用创建的 CA 和导出证书颁发证书以及 .cer。
  3. 使用 Apple Configurator 应用程序在证书区域添加 CA .cer。移动配置文件将具有 CA .cer。
  4. 颁发的证书(在第二步)添加到应用程序包。
  5. 在步骤 2 中使用安全框架评估 ( SecTrustEvaluate ) 颁发的证书。
于 2017-06-19T11:23:29.803 回答