Clarification on customizing "drm.initDataTransform"
See original GitHub issueHave you read the FAQ and checked for duplicate open issues? Yes
What version of Shaka Player are you using? 2.5.8
Please ask your question
I recently reported an issue on the Shaka Packager issue tracker regarding an error I get for Fairplay content packaged with Shaka Packager and played with Shaka Player: Shaka Error DRM.INIT_DATA_TRANSFORM_ERROR (RangeError: Malformed FairPlay init data)
.
They brought in @joeyparrish asking if he knew what it might be and he responded with referencing the Tutorial for customizing the init data.
The issue I’m facing is that It’s not clear to me how to go about implementing a custom initDataTransform
. The tutorial show a code sample using a function called getMyContentId
with no further elaboration.
Also, the tutorial states If you don't use the default content ID derivation, you need to specify a custom init data transform:
Which seems to imply that it’s not required.
Any help would be appreciated. Thank you.
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (6 by maintainers)
Top GitHub Comments
Getting a 500 response is different from
DRM.INIT_DATA_TRANSFORM_ERROR
. TheDRM.INIT_DATA_TRANSFORM_ERROR
means the init data transform function threw an exception; a 500 response means the init data transform worked fine but the license server rejected the request.My guess is there are two errors here. First is #2214 where we call the init data transform twice. The first works fine, and the second gives a
DRM.INIT_DATA_TRANSFORM_ERROR
. The other error is the first transform call works but is rejected by the server. What is probably happening is the server doesn’t recognize the data. The data could be invalid from the browser, the server may expect you to wrap/transform the data before sending it, or your content ID may be invalid.If JW Player works out-of-the-box, we may need to look at how they are handling the license to see why we get a 500 from the server.
@TheModMaker Yup that fixed it. TYVM!