0

I have a Widevine DRM based encrypted video. The video is encrypted using bento4 ,

mp4dash --widevine-header provider:widevine_test#content_id:2a --encryption-key 90351951686b5e1ba222439ecec1f12a:0a237b0752cbf1a827e2fecfb87479a2 video-source.mp4 Check this link for more info

Now I am trying to play this video on Android using Exoplayer and I am getting an error

android.media.MediaCodec$CryptoException: Error decrypting data: requested key has not been loaded

Error decrypting data: requested key has not been loaded

I have mpd file on my sdcard .I have tried to the simple mpd file (without encryption), it played successfully but I have tried a lot playing the encrypted video with key but I am unable to play .What is the right way to pass the key ?

Please guide me .Thanks in advance

Community
  • 1
  • 1
Sourabh soni
  • 488
  • 7
  • 11
  • Did you set the widevine proxy correctly? (`https://proxy.uat.widevine.com/proxy?video_id=2a&provider=widevine_test` for example) – aergistal Aug 22 '17 at 07:45
  • yes I added this in media.exolist.json { "name": "Encrypted with key", "uri": "file:///storage/emulated/0/DCIM/61385/61385.mpd", "drm_scheme": "widevine", "drm_license_url": "https://proxy.uat.widevine.com/proxy?provider=widevine_test" } – Sourabh soni Aug 22 '17 at 07:48
  • ok I just added it .and tried again........still same issue android.media.MediaCodec$CryptoException: Error decrypting data: requested key has not been loaded – Sourabh soni Aug 22 '17 at 07:55
  • how to pass the encryption key ? – Sourabh soni Aug 22 '17 at 07:55
  • I tested with `shaka-player` and the `video_id` is not needed. If you have access to an actual web server to host the files you could try to see if it works [here](https://shaka-player-demo.appspot.com). – aergistal Aug 23 '17 at 10:15
  • I tested on shaka player, video is playing – Sourabh soni Aug 23 '17 at 10:22
  • Do you have any idea to play MPEG DASH encrypted video in exoplayer – Sourabh soni Aug 23 '17 at 10:23
  • What happens if you use the hosted manifest in `media.exolist.json` instead of using the sdcard? Try the same options that worked in shaka-player. – aergistal Aug 23 '17 at 10:32
  • If you have any demo example ..please provide me – Sourabh soni Aug 23 '17 at 10:34

0 Answers0