iOS 应用程序“无法验证应用程序”仅在一台设备上
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/28231338/
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
iOS app 'The application could not be verified' only on one device
提问by Sunil
I have two iphone devices( 4s and 5 ) connected to my computer and i am trying to install an application in both the devices. It installs pretty well in iphone 5 but it gives an error 'The application could not be verified
.' when attempted to install in the iphone 4s device.
我有两个 iphone 设备(4s 和 5)连接到我的电脑,我正在尝试在这两个设备中安装一个应用程序。它在 iphone 5 中安装得很好,但它给出了一个错误“ The application could not be verified
.” 尝试在 iphone 4s 设备中安装时。
The UDIDs of both the devices have been added in the provisioning profile generated for the application.
两个设备的 UDID 都已添加到为应用程序生成的配置文件中。
Also, to add a note, I have just updated my iphone version to 8.1.3 in my 4s device. I am not sure though if the error has anything to do with it.
另外,要添加一个注释,我刚刚在我的 4s 设备中将我的 iphone 版本更新为 8.1.3。我不确定该错误是否与此有关。
Any help on this would be much appreciated. I have been stuck on this for some time now.
对此的任何帮助将不胜感激。我已经坚持了一段时间了。
EDIT:
编辑:
I just connected this to another iPhone device and the issue seems to be there again. Basically this means that the app, for some reason, installs only in the phone which I have been using for some time now and not in any other phone. Once again, I am pretty sure that the provisioning profile contains the UDIDs of all these 3 devices.
我刚刚将它连接到另一台 iPhone 设备,问题似乎又出现了。基本上,这意味着由于某种原因,该应用程序仅安装在我已经使用了一段时间的手机中,而不会安装在任何其他手机中。再一次,我非常确定配置文件包含所有这 3 台设备的 UDID。
回答by hotpaw2
I had something similar happen to me just recently. I updated my iPhone to 8.1.3, and started getting the 'application could not be verified' error message from Xcode on an app that installed just fine on the same iOS device from the same Mac just a few days ago.
我最近也发生了类似的事情。几天前,我将 iPhone 更新到 8.1.3,并开始从 Xcode 收到“无法验证应用程序”错误消息,该应用程序在同一台 Mac 的同一台 iOS 设备上安装得很好。
I deleted the app from the device, restarted Xcode, and the app subsequently installed on the device just fine without any error message. Not sure if deleting the app was the fix, or the problem was due to "the phase of the moon".
我从设备上删除了该应用程序,重新启动了 Xcode,随后该应用程序安装在设备上就好了,没有任何错误消息。不确定删除应用程序是否是修复,或者问题是由于“月相”。
回答by Nitin Gohel
As I notice The application could not be verified.raise up because in your device there is already an app installed with the same bundle identifier.
正如我所注意到的,无法验证该应用程序。因为在您的设备中已经安装了一个具有相同捆绑标识符的应用程序。
I got this issue because in my device there is my app that download from App store. and i test its update Version from Xcode. And i used same identifier that is live app and my development testing app. So i just remove app-store Live app from my device and this error going to be fix.
我遇到这个问题是因为在我的设备中有我从 App Store 下载的应用程序。我从 Xcode 测试它的更新版本。我使用了相同的标识符,即实时应用程序和我的开发测试应用程序。所以我只是从我的设备中删除了 app-store Live 应用程序,这个错误将得到修复。
回答by Jorge Balleza
just delete the app and try again, it happens to me when i try to launch over a device that has the same app but generated by an ipa file.
只需删除该应用程序并重试,当我尝试通过具有相同应用程序但由 ipa 文件生成的设备启动时,它发生在我身上。
回答by Mark McCorkle
You probably used the "Fix Issue" option in Xcode when plugging in a new device. Old question but I believe this is the actual answer to WHYthis is happening. When you install an app on a device it is signed with a specific development provisioning profile. If, for instance, you plug in another device that is not registered on your developer account Xcode will ask you to "fix the issue". When you press that the device is added and another provisioning profile is created/modified. If you try to overwrite an existing app you'll receive that error. Deleting the app and reinstalling it works since the profile has been altered. I find this often happens when a Team is set and a member plugs in a new device then Xcode "Fixes" the problem.
插入新设备时,您可能在 Xcode 中使用了“修复问题”选项。老问题,但我相信这是为什么会发生这种情况的实际答案。当您在设备上安装应用程序时,它会使用特定的开发配置文件进行签名。例如,如果您插入另一台未在您的开发者帐户上注册的设备,Xcode 会要求您“修复问题”。当您按下添加设备并创建/修改另一个配置文件时。如果您尝试覆盖现有应用程序,您将收到该错误。删除应用程序并重新安装它可以工作,因为配置文件已被更改。我发现当设置团队并且成员插入新设备然后 Xcode“修复”问题时,经常会发生这种情况。
回答by Morieris
Might have figured it out... Deleting the app from the device worked for me, as others mentioned before (thanks!).
可能已经想通了......正如其他人之前提到的那样,从设备中删除应用程序对我有用(谢谢!)。
I think the reason is that the app on the device was actually signed with a separate provisioning profile, specifically a distribution profile in my case.
我认为原因是设备上的应用程序实际上是使用单独的配置文件签名的,特别是在我的情况下是分发配置文件。
回答by plivesey
To others not using RubyMotion and don't think that deleting the app is acceptable (as in, you want to do upgrade testing). Check out the bottom of these docs from Apple:
对于其他不使用 RubyMotion 并且认为删除应用程序是不可接受的(例如,您想要进行升级测试)。查看 Apple 提供的这些文档的底部:
https://developer.apple.com/library/ios/technotes/tn2319/_index.html
https://developer.apple.com/library/ios/technotes/tn2319/_index.html
It looks like they changed something in 8.1.3 to check for this new rule.
看起来他们在 8.1.3 中改变了一些东西来检查这个新规则。
The Fix
修复
"[Add] the installed application's application-identifier value, as logged in the second parentheses, to the previous-application-identifiers entitlement's array value for the app being installed (by resigning it or re-building it) and requesting new special provisioning profiles as shown below."
“[添加] 已安装的应用程序的应用程序标识符值,如第二个括号中所记录的,到正在安装的应用程序的先前应用程序标识符权利的数组值(通过重新签名或重新构建它)并请求新的特殊配置文件如下所示。”
<key>previous-application-identifiers</key>
<array>
<string>{Your Old App ID Prefix}.YourApp.Bundle.ID</string>
</array>
EDIT:
编辑:
In order to do this, you need special provisioning profiles. You can request these from Apple: "To enable signing with the previous-application-identifiers entitlement new special provisioning profiles are required that can be obtained by going to the Contact US page and requesting them." (from the docs linked above).
为此,您需要特殊的配置文件。您可以从 Apple 请求这些:“要使用以前的应用程序标识符权利进行签名,需要新的特殊配置文件,可以通过转到联系我们页面并请求它们来获得。” (来自上面链接的文档)。
回答by Natasha
I faced this issue a lot. I am not sure if this is the issue, but I think, when xCode saw that there is an app with the same bundle identifier as of the app, I am trying to install, it didn't allow me. So, I had to delete the older one and attempted to install and it worked. However sometimes for testing purpose, I needed multiple version of the same app and in that case, I would change the bundle identifier and try to install. It only works if, I am using an wildcard provisioning profile.
我经常遇到这个问题。我不确定这是否是问题所在,但我认为,当 xCode 看到有一个应用程序与该应用程序具有相同的捆绑标识符时,我正在尝试安装,但它不允许我安装。所以,我不得不删除旧的并尝试安装并且它起作用了。但是有时出于测试目的,我需要同一个应用程序的多个版本,在这种情况下,我会更改包标识符并尝试安装。它仅适用于我使用通配符配置文件的情况。
回答by Krishnaprasad Jagadish
Had the same issue on my iPad running 8.1.3 Deleting the app and installing again fixed the issue. I use two different provisioning profiles on two different machines and that could have caused this issue.
在运行 8.1.3 的 iPad 上遇到同样的问题删除应用程序并再次安装修复了该问题。我在两台不同的机器上使用了两个不同的配置文件,这可能导致了这个问题。
回答by Lukasz
Working & tested solution, which does not require to delete application:
工作和测试的解决方案,不需要删除应用程序:
It looks like AppStore Distribution Provisioning Profileor just iOS Distribution certificate have special permissions and "Could not be verified..."problem does not apply to them. They will always override previous certificate.
看起来AppStore 分发配置文件或只是 iOS 分发证书具有特殊权限,并且“无法验证...”问题不适用于它们。它们将始终覆盖以前的证书。
In other words: AppStore release will install successfully, even if already installed (testing, adhoc or enterprise) app has been signed by the certificate from different team.
换句话说:即使已经安装(测试、临时或企业)的应用程序已经由不同团队的证书签名,AppStore 版本也会成功安装。
If you are lucky and have previously uploaded app to the AppStore account owned by the same team as in certificate you have a problem with - then things are very simple: just download & install app from AppStore.
如果您很幸运并且之前已将应用程序上传到与证书相同的团队拥有的 AppStore 帐户,那么您遇到问题 - 那么事情非常简单:只需从 AppStore 下载并安装应用程序。
When it installs - app certificate will be the same as the one you want to test with and problem goes away.
安装时 - 应用程序证书将与您要测试的证书相同,问题就会消失。
If your app is not on the AppStore yet - iTunesConnect beta comes to the rescue:
如果您的应用程序尚未在 AppStore 上架 - iTunesConnect 测试版来拯救您:
Disclaimer: I did not tested this but since cert an prev are the same as AppStore release, I bet it works:
免责声明:我没有对此进行测试,但由于 cert an prev 与 AppStore 版本相同,我敢打赌它有效:
- Archive your app with AppStore provisioning profile (iOS Distribution cert) and upload to iTunesConnect (to the account owned by the same developer team as included in the provisioning profile not you want to run).
- Invite person with the device you want to run on (yourself?) to beta test.
- Download & install the app from iTunes connect beta.
- Now you are able to install your testing version.
- 使用 AppStore 配置文件(iOS 分发证书)存档您的应用程序并上传到 iTunesConnect(上传到您不想运行的配置文件中包含的同一开发人员团队拥有的帐户)。
- 邀请拥有您想要运行的设备的人(您自己?)进行 Beta 测试。
- 从 iTunes Connect Beta 下载并安装该应用程序。
- 现在您可以安装您的测试版本。
回答by Aks
The application could not be verified" , in your device there could be already an app installed with the same bundle identifier.
无法验证应用程序”,您的设备中可能已经安装了具有相同捆绑标识符的应用程序。
So Simple solution Just delete the App & try again.. ....
如此简单的解决方案只需删除应用程序并重试......