[Flutter/Fairplay][DRM] Bitmovin Player + Axinom License Server

Hello folks,

Is there a way to get Bitmovin working with Axinom for Flutter/Fairplay?

Keep getting:

[BMP] [Player] [Error] Event: SourceError, Data: {"code":2301,"data":{"message":"The operation couldn’t be completed. (BitmovinPlayerCore.FairplayResponse.Failure error 1.)","code":400},"timestamp":1746296769.142633,"message":"The operation couldn’t be completed. (BitmovinPlayerCore.FairplayResponse.Failure error 1.)","type":"onSourceError"} code: 2301 [Data code: 400, message: The operation couldn’t be completed. (BitmovinPlayerCore.FairplayResponse.Failure error 1.), underlying error: BitmovinPlayerCore.FairplayResponse.Failure(error: Error Domain=com.bitmovin.source.error Code=2306 "Network Error: 'Response Validation Failed. Status Code: 400'" UserInfo={NSLocalizedDescription=Network Error: 'Response Validation Failed. Status Code: 400'}, metadata: Optional(<_BMPRequestMetadata: 0x119161aa0>))]

for

FairplayConfig(
                licenseUrl:
                    'https://drm-fairplay-licensing.axprod.net/AcquireLicense',
                licenseRequestHeaders: {
                  'X-AxDrm-Message': token,
                  'Content-type': 'application/octet-stream',
                },
                certificateUrl: cert,
                certificateRequestHeaders: {
                  'Content-type': 'application/octet-stream'
                },
                prepareContentId: (contentId) {
                  print("=> ContentId: $contentId " + (contentId.split('/').lastOrNull ?? contentId));

                  final index = contentId.indexOf("skd");
                  return index != -1 ? contentId.substring(index) : contentId;
                },
                prepareMessage: (spcData, _) {
                  print("=> spcData: $spcData");

                  return spcData;
                },
                prepareSyncMessage: (spcsData, _) {
                  print("=> spcsData: $spcsData");

                  return spcsData;
                },
                prepareLicense: (ckc) {
                  print("=> ckc: $ckc");

                  return ckc;
                },
                prepareLicenseServerUrl: (url) {
                  print("=> url: $url");

                  return url;
                },
                prepareCertificate: (cert) {
                  print("=> cert: $cert");

                  return cert;
                },

Hello All,

To make the DRM-enabled playout and casting work, we needed to update Bitmovin Flutter plugin.

So far we’re using our own copy, but also submitted the PRs:

Hope they can be integrated in the upcoming official release.

1 Like

Hi @lukasz.bajorski,

Thanks a lot for your contributions and for taking the time to submit those PRs!
These changes have now been merged and are included in version 0.21.0 of the Player Flutter SDK.

We really appreciate your help in improving the SDK!

Best regards,
Michele