FairPlay 逻辑有任何变化吗?我的应用程序具有受 FairPlay 保护的视频和音频,它们在 iOS 15.7 之前完美运行,但在 iOS 16 中
makeStreamingContentKeyRequestData is throwing me following error :
Error Domain=CoreMediaErrorDomain Code=-19152 "(null)"
Error Domain=AVFoundationErrorDomain Code=-11800 "The operation could not be completed"
UserInfo={NSLocalizedFailureReason=An unknown error occurred (-19156), NSLocalizedDescription=The operation could not be completed,
NSUnderlyingError=0x280deac10 {Error Domain=NSOSStatusErrorDomain Code=-19156 "(null)"}}
造成这种情况的可能原因和解决方案是什么?
提前致谢
我们正在使用AVContentKeySession
下载时遇到同样的错误,已修复。对于我们的案例,问题如下。
观察到的问题:
- 在iOS16.0.3上,下载过程中应用程序首次触发“许可证请求”12秒后,AVFoundation框架将再次触发“许可证请求”
(
"contentKeySession(_ session: AVContentKeySession, didProvide keyRequest: AVContentKeyRequest)"
又被叫了),然后报错“-19152“
wad通过框架快速报告。
错误日志:
contentKeySession(_:contentKeyRequest:didFailWithError:),行:XXX,
消息:XXX,网址:XXX,错误为 Domain=CoreMediaErrorDomain
代码=-19152“(空)”
- 在iOS15.6.1上,触发“许可证请求”后
通过应用程序在下载过程中,框架不会再次触发任何“许可证请求”。
根本原因:iOS 框架 API(AVContentKeySession 和 AVPersistableContentKeyRequest)行为在 iOS16 上发生了变化。
解决方案:
Add “keyRequest.processContentKeyResponse(keyResponse)”
在 iOS16+ 上下载 CKC 后。
- 在iOS11 - iOS15上,我们下载后并没有调用它,而是只在本地保存perpetualKeyData,并在播放时调用processContentKeyResponse。这在这些 iOS 版本上一直运行良好。
- 但在iOS16及以上版本(目前为止iOS16.1 Beta4),旧流程会触发框架错误。所以我们添加了这个修复。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)