-
Notifications
You must be signed in to change notification settings - Fork 6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to play ClearKey encrypted DASH #3201
Comments
If you're encrypting with Widevine you must have a license server of some kind. That error indicates the license response did not include the keys required for decryption. |
Thank you for the response . Currently I am using license url https://proxy.uat.widevine.com/proxy?provider=widevine_test . |
I don't think that's how Widevine works. The server is responsible for issuing a license that contains the necessary keys for decryption. If you're using someone else's license server and the response contains different keys than you've encrypted your content with, that's not going to work. |
ok ..I have gone through the demo app of exoplayer .It has a Widevine secure example. But there is no example which uses MPEG DASH encryption key...can you suggest how I can pass MPEG-DASH encryption key to the player. |
The demo app plays Widevine content that was encrypted using the same keys that the Widevine test server provides. If you want to protect content with Widevine then I'm pretty sure you have to have a proper license server. I'm not sure what "pass MPEG-DASH encryption key to the player" means, or what encryption scheme you're referring to when you say this (are you sure it's Widevine)? |
yes it is Widevine DRM. |
What does "MPEG-DASH encrypted(No Widevine)" mean, exactly? You need to be more precise about the encryption scheme for us to help. Thanks! |
I have MPEG-DASH encrypted video .Video have a encryption key . |
As above, "MPEG-DASH encrypted video" is not precise enough. There are multiple schemes that you can use to encrypt DASH content. Are you able to play this content successfully in any other player, in particular any web player? We're just not able to help without precise information, sorry. |
Its a .MPD file having encryption key .It is working in shaka player implemented in our desktop app.
|
Got it. This is ClearKey encrypted content (not Widevine encrypted). You need to initialize the |
Thank you ..I just tried the link you provided .Now the screen is black ...no audio or video is displayed but the video time is visible. It shows a message```
|
the custom |
you can see this log for more detail
|
Are you sure that you're initializing the |
Yes, This is how I created
And this MyDrmCallback class
Player shows an error
in logcat it shows message like
|
I think you're probably quite close to having it working, but the logging you're seeing indicates that the player thinks the content is encrypted with a different DRM scheme than the one for which you've initialized the DrmSessionManager. If the DrmSessionManager is being initialized correctly (as appears to be the case), then that would indicate that the player doesn't think the content is ClearKey encrypted. This may be a shortcoming that will be addressed as part of #3138, but to diagnose (and also help work out how you'd be able to get this content playing) I think we'd need access to the content itself. |
I have mpd file (inside zip) on dropbox .Please download it from here https://www.dropbox.com/s/y20s6a2mm4rfu45/Constitution.zip?dl=0 KID : 91341951696b5e1ba232439ecec1f12a Exoplayer java file is here : Actually I download the zip file on android sdcard .Than extract the zip which contains mpd file.Than I am passing the uri of .mpd file(present on sd card) to Exoplayer .you can check the content |
This will be duplicated to #3138 after a few changes have been submitted. |
Good news: I was able to get the sample content working. You need to use the very latest
Note that The only remaining work to get ClearKey content working in all cases is to work around a platform issue where it uses base64 rather than base64url encoding for the key request/response. We're tracking this in #3138. For most cases the two encodings will be identical (as is true for the test content in this thread). |
Closing, since this is now working in the |
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 .It always display above error in logcat
What is the right way to pass the key ?
The text was updated successfully, but these errors were encountered: