iOS应用收到“设备身份验证错误”消息扫描Chromecast设备时 [英] iOS app getting a "device authentication error" when scanning for Chromecast devices

查看:100
本文介绍了iOS应用收到“设备身份验证错误”消息扫描Chromecast设备时的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在为Chromecast开发iOS发送器应用程序。我已经设置了两个Chromecast设备,并且能够检测并连接到这两个设备,直到切换到另一台测试iPhone为止。现在,当我尝试扫描Chromecast设备时,从不发送deviceDidComeOnline消息。

I'm working on an iOS sender app for Chromecast. I have two Chromecast devices set up and was able to detect and connect to both of them until I switched to a different test iPhone, and now when I try to scan for Chromecast devices, the deviceDidComeOnline message is never sent.

我能够使用示例应用程序此处,以及GoogleCast框架的2.5.1版。以下是示例应用无法检测到Chromecast时的控制台输出:

I am able to reproduce the problem with the sample app here, with version 2.5.1 of the GoogleCast framework. The following is console output from the sample app when it fails to detect a Chromecast:

2015-01-17 07:52:37.314 CastVideos[411:33216] Start Scan
2015-01-17 07:52:37.315 CastVideos[411:33216] -[GCKDeviceScanner startNetServiceScan]  startNetServiceScan
2015-01-17 07:52:37.341 CastVideos[411:33216] -[GCKNetworkReachability updateStatus]  updateStatus
2015-01-17 07:52:37.345 CastVideos[411:33216] -[GCKDeviceScanner networkReachabilityStatusDidChange:]  networkReachabilityStatusDidChange:1
2015-01-17 07:52:37.345 CastVideos[411:33216] -[GCKDeviceScanner purgeAllOnlineDevices]  purgeAllOnlineDevices
2015-01-17 07:52:37.489 CastVideos[411:33216] -[GCKDeviceScanner startFilteringDevice:]  starting filter for device: <0x1780b0b60:GCKDevice> ChromecastDev2 (be1be9dcbaa4cb82678b977203c3ef91)
2015-01-17 07:52:37.494 CastVideos[411:33216] -[GCKDeviceScanner startFilteringDevice:]  starting filter for device: <0x1700a38a0:GCKDevice> ChromecastDev (3df5a88f22a974661a8a3556acafdd2f)
2015-01-17 07:52:37.629 CastVideos[411:33216] -[GCKCastSecureSocket continueHandshake]  Peer trust certificate invalid; disconnecting
2015-01-17 07:52:37.630 CastVideos[411:33216] -[GCKCastSecureSocket doTeardownWithErrorCode:]  doTeardownWithErrorCode:3
2015-01-17 07:52:37.630 CastVideos[411:33216] __42-[GCKCastSecureSocket initWithBufferSize:]_block_invoke18  Error reading from SSL buffer to stream buffer, status: -50
2015-01-17 07:52:37.630 CastVideos[411:33216] -[GCKCastSecureSocket doTeardownWithErrorCode:]  doTeardownWithErrorCode:1
2015-01-17 07:52:37.631 CastVideos[411:33216] -[GCKDeviceManager castSocket:didDisconnectWithError:]  castSocket:didDisconnectWithError:Error Domain=com.google.GCKError Code=3 "Device authentication failure" UserInfo=0x170272180 {NSLocalizedDescription=Device authentication failure}
2015-01-17 07:52:37.631 CastVideos[411:33216] -[GCKDeviceManager handleConnectionError:]  handleConnectionError error=Error Domain=com.google.GCKError Code=3 "Device authentication failure" UserInfo=0x170272180 {NSLocalizedDescription=Device authentication failure}, _appConnectionState=0
2015-01-17 07:52:37.631 CastVideos[411:33216] -[GCKDeviceManager handleConnectionError:]  giving up on reconnect; _pausedAppID=(null), _wasConnected=0
2015-01-17 07:52:37.632 CastVideos[411:33216] -[GCKDeviceManager unregisterForAppStateNotifications]  unregisterForAppStateNotifications
2015-01-17 07:52:37.634 CastVideos[411:33216] -[GCKDeviceManager disconnectWithError:isExplicit:]  disconnectWithError:(null)
2015-01-17 07:52:37.634 CastVideos[411:33216] -[GCKDeviceScanner filteringFailedForDevice:withError:]  Filter failed for device <0x1700a38a0:GCKDevice> ChromecastDev (3df5a88f22a974661a8a3556acafdd2f) with error Error Domain=com.google.GCKError Code=3 "Device authentication failure" UserInfo=0x170272180 {NSLocalizedDescription=Device authentication failure}
2015-01-17 07:52:37.634 CastVideos[411:33216] -[GCKDeviceScanner filteringFailedForDevice:withError:]  Marking device <0x1700a38a0:GCKDevice> ChromecastDev (3df5a88f22a974661a8a3556acafdd2f) invalid
2015-01-17 07:52:37.635 CastVideos[411:33216] -[GCKDeviceManager unregisterForAppStateNotifications]  unregisterForAppStateNotifications
2015-01-17 07:52:37.635 CastVideos[411:33216] -[GCKDeviceManager disconnectWithError:isExplicit:]  disconnectWithError:(null)
2015-01-17 07:52:37.635 CastVideos[411:33216] -[GCKCastSecureSocket disconnectWithError:]  disconnect

这是在运行iOS 8.0的iPhone 6+上发生的。当我在此手机上打开其他兼容Chromecast的应用程序(Chromecast,YouTube)时,两个Chromecast设备均被成功检测到。仅仅是我从Xcode运行的应用程序,并且只是在这台特定的测试电话上,似乎都出现了这个问题。

This is happening on an iPhone 6+ running iOS 8.0. When I open other Chromecast compatible apps (Chromecast, YouTube) on this phone, both Chromecast devices are detected successfully. It's just the apps I run from Xcode, and just on this particular test phone, that seem to have this problem.

我已经在其他几个应用程序上尝试过相同的示例应用程序测试设备,看它是否与设备/操作系统有关。在以下iPhone / iPad上都检测到两个Chromecast设备没有问题:

I've tried the same sample app on several other test devices to see if it had anything to do with the device / OS. Both Chromecast devices are detected without issue on the following iPhones/iPads:


  • iOS 8.1.2上的iPhone 6

  • iOS 8.1.2上的iPhone 5

  • iOS 8.0.2上的iPhone 6 +

  • iOS 8.0上的iPhone 5

  • iOS 8.0上的iPad Air

  • iPhone 6 on iOS 8.1.2
  • iPhone 5 on iOS 8.1.2
  • iPhone 6+ on iOS 8.0.2
  • iPhone 5 on iOS 8.0
  • iPad Air on iOS 8.0

任何人知道这是什么原因吗?
提前谢谢。

Any idea what would cause this? Thanks in advance.

推荐答案

证书问题可能是由于手机上的日期无效引起的。检查日期时间是否正确,因为这可能会导致证书问题,然后导致Chromecast问题

It is Possible that the certificate problem was caused by an invalid date on the phone. Check the date time is correct because this could cause the certificate issue and then the Chromecast Issue

这篇关于iOS应用收到“设备身份验证错误”消息扫描Chromecast设备时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆