media: Playback of the Widevine-DASH video (on-the-fly) fails with the error: android.media.MediaCodec$CryptoException - Error decrypting data: insufficient output protection.
Version
Media3 1.2.1
More version details
No response
Devices that reproduce the issue
Smausng Galaxy Tab A8 Android 13 Smausng Galaxy Note9 Android 9 Smausng Galaxy Tab A7 Lite Android 13
Devices that do not reproduce the issue
Analyzing the Firebase data, it seems that other brands of Android devices should not encounter this issue.
Reproducible in the demo app?
Not tested
Reproduction steps
The issue regarding “MediaCodec.native_queueSecureInputBuffer” in Firebase Crashlytics is observed predominantly on Samsung devices (Android OS 9~14) when playing Widevine-DASH (on-the-fly) videos using media3 (1.2.1). Is this a hardware issue with Samsung devices, an issue with ExoPlayer handling MediaCodec, or a problem with the video itself? PS: My media player app uses the media3 (1.2.1) player
Expected result
The video playback is successful.
Actual result
It appears that playback fails on these devices.
Non-fatal Exception: androidx.media3.exoplayer.ExoPlaybackException: Unexpected runtime error at androidx.media3.exoplayer.ExoPlayerImplInternal.handleMessage(ExoPlayerImplInternal.java:685) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loopOnce(Looper.java:226) at android.os.Looper.loop(Looper.java:313) at android.os.HandlerThread.run(HandlerThread.java:67)
Caused by android.media.MediaCodec$CryptoException: Operation not supported in this configuration: ERROR_DRM_CANNOT_HANDLE ============================== Beginning of DRM Plugin Log ============================== 03-19 07:20:47.640 I found instance=clearkey version=android.hardware.drm@1.3::IDrmFactory 03-19 07:20:47.640 I found instance=widevine version=android.hardware.drm@1.3::IDrmFactory 03-19 07:20:47.644 E uuid=[edef8ba979d64ace a3c827dcd51d21ed] No supported hal instance found 03-19 07:20:48.379 W Cannot cast android.hardware.drm@1.0::IDrmPlugin obj to android.hardware.drm@1.4::IDrmPlugin plugin 03-19 10:04:46.348 E uuid=[edef8ba979d64ace a3c827dcd51d21ed] No supported hal instance found 03-19 10:04:47.464 W Cannot cast android.hardware.drm@1.0::IDrmPlugin obj to android.hardware.drm@1.4::IDrmPlugin plugin 03-19 10:41:34.809 W Cannot cast android.hardware.drm@1.0::ICryptoPlugin obj to android.hardware.drm@1.4::ICryptoPlugin plugin ============================== End of DRM Plugin Log ============================== at android.media.MediaCodec.native_queueSecureInputBuffer(MediaCodec.java) at android.media.MediaCodec.queueSecureInputBuffer(MediaCodec.java:2942) at androidx.media3.exoplayer.mediacodec.AsynchronousMediaCodecBufferEnqueuer.doQueueSecureInputBuffer(AsynchronousMediaCodecBufferEnqueuer.java:240) at androidx.media3.exoplayer.mediacodec.AsynchronousMediaCodecBufferEnqueuer.doHandleMessage(AsynchronousMediaCodecBufferEnqueuer.java:205) at androidx.media3.exoplayer.mediacodec.AsynchronousMediaCodecBufferEnqueuer.access$000(AsynchronousMediaCodecBufferEnqueuer.java)
log_Galaxy_Tab_A7_Lite.txt
log_Galaxy_Note9.txt
log_Galaxy_Tab_A8.txt
Media
I can provide relevant Widevine Dash video information, but the video URL and Widevine token cannot be disclosed on the GitHub platform. If you need detailed information about the video, please let me(my e-mail: myvideotom@gmail.com or tomchlin@taiwanmobile.com) know, and I will email it to you.
The information about the video played on the Galaxy Tab A8: videoUrl:https://dache.myvideo.net.tw/Media/20210712/Smooth/EME0100000033… widevineLicenseUrl:https://widevine-… widevineToken:CIvx2lPc5hG/Js7AyTLOARf5EHRRtZAaFG5tyMTWw656y+gTIqJjczGaVXolnKIxrX+sb7evNL6ixzTWBFBV4E6HbAfzScqawdravCbav8AWkfy5gEtOsBsTzyl+lQH8G2V6CPIiyh6…
The information about the video played on the Galaxy Note9: videoUrl:https://dache.myvideo.net.tw/Media/20210708/Smooth/LON01000… widevineLicenseUrl:https://widevine… widevineToken:CIvx2lPc5hG/Js7AyTLOAV1AWgEdPpwPsHKf2C7VttbFwD0KqJs5Mfi3DQU7DpDxeRh5G1YUD7dWI69Md1Oj7cGg65rJIOJRqaTisAJ+UE/6NL0Ielppxx0UNKOrm4dwUOlJTq67…
The information about the video played on the Galaxy Tab A7 Lite: videoUrl:https://dache.myvideo.net.tw/Media/20200703/Smooth/ALL0300… widevineLicenseUrl:https://widevin…</widevineLicenseUrl> widevineToken:CIvx2lPc5hG/Js7AyTLOAUf4X2gE80f7dGX7fKCUQoShBA/aO+Pw1wWBJR+hxSkknFKA4NbQsUWiRnoBF3r16lYoZ2n56Q12RpkAQ8YONDaLlRIaq53J1J7RC+…
Bug Report
- You will email the zip file produced by
adb bugreportto android-media-github@google.com after filing this issue.
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 20
Thanks for providing tokens to retest this.
FYI, only one out of three “ALL03000007745H” attains a license.
The other two fail with
requested key has not been loaded: ERROR_DRM_NO_LICENSEWe will continue testing with ALL03000007745H. Could you confirm the info for the two mentioned?
@icbaker @rrfrias The complete information(videoDetalInfo_0402.txt) of the video (videoUrl, widevineLicenseUrl, and widevineToken [long-lasting token, valid until 5/2]) has been emailed to android-media-github@google.com.