ios Xcode 进程启动失败:安全
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/25824908/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Xcode process launch failed: Security
提问by Tom Spee
I have been developing an app for 1 or 2 weeks now and just yesterday I have updated my iPhone 5S to the iOS 8 GM. Everything worked fine and I could test on my device as well until I deleted the app from my phone and wanted to build again. The following error appeared:
我已经开发了 1 或 2 周的应用程序,就在昨天,我将我的 iPhone 5S 更新到了 iOS 8 GM。一切正常,我也可以在我的设备上进行测试,直到我从手机中删除该应用程序并想重新构建。出现以下错误:
Could not launch "My App"
process launch failed: Security
When I test with the simulator it works fine. Is this because of the iOS 8 GM update and how can I fix this launch problem? I want to be able to test on my iPhone and in the simulator.
当我用模拟器测试时,它工作正常。这是因为 iOS 8 GM 更新,我该如何解决这个启动问题?我希望能够在我的 iPhone 和模拟器中进行测试。
回答by SushiGrass Jacob
If you get this, the app has installed on your device. You have to tap the icon. It will ask you if you reallywant to run it. Say “yes
” and then Build & Run again
.
如果您收到此消息,则该应用程序已安装在您的设备上。您必须点按该图标。它会问你是否真的想运行它。说“ yes
”然后Build & Run again
。
As from iOS 9
, it is required to go to Settings→ General→ Device Management→ Developer App→ Trust`.
作为从iOS 9
,就需要去Settings→交通General→交通Device Management→交通Developer App→交通Trust`。
On someversions of iOS
, you will have to go to Settings→ General→ Profileinstead.
在 的某些版本上iOS
,您必须转至Settings→ General→ Profile。
回答by Tom Spee
Updated answer for Xcode 7: Tapping the app no longer works (as of beta 1 it just displays an "untrusted enterprise developer" message with only a Dismiss button).
Xcode 7 的更新答案:点击应用程序不再有效(从 beta 1 开始,它只显示“不受信任的企业开发人员”消息,只有一个“关闭”按钮)。
To fix, open the Settings app, go to General / Profiles, and you'll see your profile. Mark it trusted and things should start working normally again.
要修复,请打开“设置”应用,转到“常规”/“个人资料”,您将看到自己的个人资料。将其标记为受信任,事情应该会再次开始正常工作。
Updated For iOS 9.2.1 and Xcode 7.2.1:
针对 iOS 9.2.1 和 Xcode 7.2.1 更新:
Goto: Settings > General > Device Management > Select App from Developer Apps > Trust App.
转到:设置 > 常规 > 设备管理 > 从开发者应用程序中选择应用程序 > 信任应用程序。
回答by nickthedude
Hey so the accepted answer works, except if you need to debug the initial launch of the app. However I think that answer is more of a work around, and not an actual solution. From my understanding this message occurs when you have some weirdness in your provisioning profile / cert setup so make extra sure everything is in tip-top shape in that dept. before ramming your head against the wall repeatedly.
嘿,接受的答案有效,除非您需要调试应用程序的初始启动。但是,我认为该答案更像是一种解决方法,而不是实际的解决方案。根据我的理解,当您的配置文件/证书设置有一些奇怪时,会出现此消息,因此请额外确保该部门的所有内容都处于最佳状态。在反复用头撞墙之前。
What worked for me was as follows from the apple docs:
对我有用的是来自苹果文档的以下内容:
Provisioning Profiles Known Issue If you have upgraded to the GM seed from other betas you may see your apps crashing due to provisioning profile issues.
Workaround:
Connect the device via USB to your Mac
Launch Xcode Choose Window ->Devices
Right click on the device in left column, choose "Show Provisioning Profiles"
Click on the provisioning profile in question
Press the "-" button Continue to removing all affected profiles.
Re-install the app
配置文件已知问题 如果您已从其他测试版升级到 GM 种子,您可能会看到您的应用程序因配置文件问题而崩溃。
解决方法:
通过 USB 将设备连接到 Mac
启动 Xcode 选择窗口 -> 设备
右键单击左栏中的设备,选择“显示配置文件”
单击有问题的配置文件
按“-”按钮继续删除所有受影响的配置文件。
重新安装应用
Make sure you right click on the image of the device not the name of the device or you won't see the provisioning profiles option. I restored my new phone from an old backup and there was a lot of cruft hanging around, i also had 2 different dev. certs active (not sure why) but i deleted one, made a new profile got rid of all the profiles on device and it worked.
确保右键单击设备图像而不是设备名称,否则您将看不到配置文件选项。我从旧备份中恢复了我的新手机,周围有很多杂物,我还有 2 个不同的开发人员。证书处于活动状态(不知道为什么),但我删除了一个,创建了一个新的配置文件,删除了设备上的所有配置文件并且它工作正常。
Hope this helps someone else.
希望这对其他人有帮助。
回答by Ben Cochrane
Update for iOS9.2.1 and Xcode 7.2.1
iOS9.2.1 和 Xcode 7.2.1 更新
If you get this error when building to a device in Xcode:
如果在 Xcode 中构建到设备时出现此错误:
On your device, tap the app icon that would have just been added from your attempt at building the app and you should see this:
在您的设备上,点击您尝试构建应用程序时刚刚添加的应用程序图标,您应该会看到:
Next, on your device, go to Settings --> General --> Device Management, and you will see this page:
接下来,在您的设备上,转到设置 --> 常规 --> 设备管理,您将看到以下页面:
Select the profile you are using with Xcode, and you should see this page:
选择您在 Xcode 中使用的配置文件,您应该会看到此页面:
Click Trust "[email protected]" then click Trust on the next popup.
单击信任“[email protected]”,然后在下一个弹出窗口中单击信任。
Go back to Xcode and re-run your project and it should build the app to your device.
返回 Xcode 并重新运行您的项目,它应该将应用程序构建到您的设备上。
回答by pkamb
To get around the process launch failed: Security
issue and immediately launch the app on your device, tap the app icon on your iOS device after running the app via Xcode.
要解决此process launch failed: Security
问题并立即在您的设备上启动应用程序,请在通过 Xcode 运行应用程序后点击 iOS 设备上的应用程序图标。
This will allow you to immediately run the app. It may not actually "fix" the root issue that is causing these permission alerts.
这将允许您立即运行该应用程序。它实际上可能无法“修复”导致这些权限警报的根本问题。
Be sure to tap the app icon while the Xcode alert is still shown. Otherwise the app will not run. I continually forget this vital step and am unable to run the app on my device. Thus I am documenting it here for myself and everyone else :)
确保在 Xcode 警报仍然显示时点击应用程序图标。否则应用程序将无法运行。我不断忘记这一重要步骤,无法在我的设备上运行该应用程序。因此,我在这里为自己和其他人记录它:)
- Run the app via Xcode. You will see the security alert below. Do not press OK.
- 通过 Xcode 运行应用程序。您将在下方看到安全警报。不要按确定。
- On your iOS device, tap the newly installed app icon:
- 在您的 iOS 设备上,点击新安装的应用程序图标:
After tapping the icon, you should now see an alert asking you to "Trust" the Untrusted App Developer. After doing so the app will immediately run, unconnected to the Xcode debugger.
- If you do not see this "Trust" alert, you likely pressed "OK" in Xcode too soon. Do not press "OK" on the Xcode alertuntil aftertrusting the developer.
点击该图标后,您现在应该会看到一条警告,要求您“信任”不受信任的应用程序开发人员。这样做后,应用程序将立即运行,与 Xcode 调试器断开连接。
- 如果您没有看到此“信任”警报,则您可能过早在 Xcode 中按了“确定”。在信任开发人员之前,不要在 Xcode 警报上按“确定”。
- Finally, go back and press "OK" on the Xcode alert. You will have to re-run the app to connect the running app on your iOS device to the Xcode debugger.
- 最后,返回并在 Xcode 警报上按“OK”。您必须重新运行应用程序才能将 iOS 设备上正在运行的应用程序连接到 Xcode 调试器。
回答by kavehmb
SETTINGS -> GENERAL -> Profiles & Device Management choose the developer profile and push Trust.
SETTINGS -> GENERAL -> Profiles & Device Management 选择开发者配置文件并推送信任。
if you do not have Profiles & Device Management menu you have to enroll your device on beta.apple.comand download the profile from Safari.
如果您没有配置文件和设备管理菜单,您必须在beta.apple.com上注册您的设备并从 Safari 下载配置文件。
- install the profile
- Restart your device
- tap on the developer profile and trust.
- 安装配置文件
- 重新启动您的设备
- 点击开发者资料和信任。
You are all set.
你都准备好了。
回答by David Andreoletti
Alternatively if one does not see "Untrust App Developer" dialog:
或者,如果没有看到“不信任应用程序开发人员”对话框:
Go to your iPhone > Settings > General > Profile > "[email protected]" > Trust
转到您的 iPhone > 设置 > 通用 > 个人资料 > “[email protected]” > 信任
回答by Christian
I have the same issue. I click ok in xcode and when launching the app on my iPhone I'm asked if I want to trust this application. Doing it, the app runs and further build-and-run from xcode went without any issue until deleting the app from the iPhone and reinstalling it. Then goto first line ;-)
我有同样的问题。我在 xcode 中单击确定,当我在 iPhone 上启动该应用程序时,系统会询问我是否要信任该应用程序。这样做,应用程序运行并从 xcode 进一步构建和运行没有任何问题,直到从 iPhone 中删除应用程序并重新安装它。然后转到第一行;-)
回答by Plus7
In iOS 9.2 they renamed the 'Profiles' to 'Device Management'
在 iOS 9.2 中,他们将“配置文件”重命名为“设备管理”
This is how you should do it now:
这是你现在应该做的:
- Settings -> General -> Device Management
- Verify the app
- 设置 -> 通用 -> 设备管理
- 验证应用
回答by zizutg
Ok this this seems late and I was testing the app with internet connection off to test my app for some functionality. As I turned off the internet it gave me such error. After I turned on the internet I can install again. I know this is silly but this might be helpful to someone
好的,这似乎很晚了,我正在关闭互联网连接来测试应用程序,以测试我的应用程序的某些功能。当我关闭互联网时,它给了我这样的错误。我打开互联网后,我可以再次安装。我知道这很愚蠢,但这可能对某人有所帮助