axiomatic-systems / Bento4

Full-featured MP4 format, MPEG DASH, HLS, CMAF SDK and tools
http://www.bento4.com
1.98k stars 481 forks source link

Unable to play cbcs encrypted cmaf content in shaka player/bitmovin player/videojs custom player #682

Open ashiskumarsahu opened 2 years ago

ashiskumarsahu commented 2 years ago

@barbibulle This is bit serious. I have packaged the content with mp4dash with --hls key with cbcs encryption mode. Dash is playing fine but ubable to play hls content. I have tried with shaka player/bitmovin player/videojs custom player in mac safari but no luck.

I used the below command to package

bento4/bin/mp4dash --encryption-cenc-scheme=cbcs --encryption-key=xxxx:xxxx:xxxx --use-segment-template-number-padding --widevine --widevine-header=xxxx --playready --playready-version=4.3 --playready-header=xxx --hls --fairplay-key-uri=skd://xxxx_token Cinderella.mf4

Could you please respond to this in priority? Are we missing anything in command during packaging? It would be great if you can share a sample setup with any standard player like shaka/theo/bitmovin etc.

We are getting following error on videojs player: The media playback was aborted due to a corruption problem or because the media used features your browser did not support.

Bitmovin error screenshot Screenshot from 2022-03-15 12-01-28

Thank You

barbibulle commented 2 years ago

Hi. Can you share a bit more of your context, so that we can help you troubleshoot? Based on the command-line here, it seems that you are enabling multiple DRMs. Do you have compatible DRM servers ready to respond to requests from the DRM client? Can you check on the player which of the DRMs ends up being used? Have you tried with one DRM at a time, to see if some DRMs work and not others? (based on the screenshot here, it seems that the player has selected to use FairPlay. if that's the case, can you check what appears in your logs that may show any communication with your FairPlay server?)

ashiskumarsahu commented 2 years ago

Hi @barbibulle, Thanks for your reply. Actually i want to use multi drm all 3 widevine/playready/fairplay. I am using pallycon multidrm for decryption. I tried to debug this and resolved some from player end. Now only the playready is not working.

Here are the errors returning from various devices:

  1. Video js player on Edge latest : "The Media playback was aborted due to a corruption problem or because the media used features your browser did not support."
  2. Theo player on samsung tv : DRM: unable to create session! --Error generating key request -- InvalidAccessError
  3. Video JS based player on samsung tv : VIDEOJS: ERROR: (CODE:3 MEDIA_ERR_DECODE) The media playback was aborted due to a corruption problem or because the media used features your browser did not support.
  4. Theo player on LG tv : MEDIA_ERR_DECODE error
  5. Video JS based player on LG tv : VIDEOJS: ERROR: (CODE:3 MEDIA_ERR_DECODE) The media playback was aborted due to a corruption problem or because the media used features your browser did not support.
  6. Native player on Fire tv : Not playing in lower version devices.

Note that: For the same version of video js, its playing fine in ubuntu chrome/firefox etc.

As per my analysis, I think the problem is playready 4.3 which is not supported in old devices. Is it possible to support lower version of playready with cbcs encryption?

I want to use cmaf with cbcs encryption by enabling multiple DRMs but not all devices are able to play them.

Note: Adding to this, I can play now, on all apple devices.

Thank You