Product
Player
Question
Hello, Bitmovin Flutter team.
We want to play DRM Contents on Flutter project.
While playing DRM videos on iOS I am facing this error. The video is encoded via Pallycon. It works perfectly fine on Android.
But we can’t play DRM contents on iOS.
I developed drm configuration on flutter. (Please see below code)
And I gave you detail error message
[BMP] [Source] [Error] Content key request failed with error: The operation couldn’t be completed. (OSStatus error -42681.) [Data code: -42681, message: The operation couldn’t be completed. (OSStatus error -42681.), underlying error: Error Domain=NSOSStatusErrorDomain Code=-42681 “(null)”]
I don’t know why “Source Error. This content is not authorized.” error.
Please check our problem.
Map<String, String> _fairPlayHeaders(String pallyconToken) {
return { 'pallycon-customdata-v2': pallyconToken,
'Content-Type': 'application/octet-stream' };
}
fairplay: FairplayConfig(
licenseUrl: 'https://license.pallycon.com/ri/licenseManager.do',
certificateUrl:
'https://license-global.pallycon.com/ri/fpsKeyManager.do?siteId="AAAA', // (`AAAA` is example)
licenseRequestHeaders: _fairPlayHeaders(token),
certificateRequestHeaders: _fairPlayHeaders(token),
prepareContentId: (contentId) {
return contentId.substring(cId.indexOf('skd://') + 6);
},
prepareCertificate: (certificiate) {
print("=> Certificate $certificiate");
List<int> decode = base64.decode(certificiate);
Uint8List bytes = Uint8List.fromList(decode);
String result = String.fromCharCodes(bytes);
return result;
},
prepareLicense: (license) {
print("=> License $license");
return license;
},
prepareMessage: (spcData, _) {
// spcData, assetId
print("=> Message $spcData");
return spcData;
},
),