question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Automatically fallback to Widevine L3 in case there is a DRM error

See original GitHub issue

[REQUIRED] Use case description

Recently some devices had their Widevine L1 license revoked (see #7986, #8075). This causes the affected devices to be unable to play DRM content by default, because ExoPlayer will attempt to use L1 (since the device claims to support it), which will fail (since the device had its license revoked).

Proposed solution

ExoPlayer should have an option to automatically retry playback with L3 (if the DRM license allows it) instead of throwing a DRM-related exception. Only if playback was also unsuccessful with L3 should an error be thrown.

Alternatives considered

  • Implement this fallback mechanism directly in the app. It would be nice though if ExoPlayer offered this out of the box.
  • Include the affected devices in needsForceWidevineL3Workaround(). However, this list would have to be manually kept up to date, and it would not cover devices with similar issues that have yet to be discovered.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:7
  • Comments:14 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
icbakercommented, Jan 26, 2021

Is it possible to manually override the Widevine security level based on device model?

You can force the device to use L3 by setting the “securityLevel” property to “L3” on the underlying MediaDrm object (like this).

You can achieve this from ExoPlayer by writing a custom ExoMediaDrm.Provider (you can probably delegate to FrameworkMediaDrm.DEFAULT_PROVIDER) that mutates the ExoMediaDrm object inside Provider#acquireExoMediaDrm() by calling the ExoMediaDrm#setPropertyString() method. You probably only want to do this if uuid is C.WIDEVINE_UUID.

You can wire up this custom provider by passing it to DefaultDrmSessionManager.Builder#setUuidAndExoMediaDrmProvider.

If you always set this property then (obviously?) L1 content won’t play correctly.

1reaction
icbakercommented, Jan 15, 2021

I’m tracking the work to allow specifying a custom MediaSourceDrmHelper in #8466.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Facing DRM error on older Android devices like Pixel C ...
Issue. One of the possible reasons for this behaviour could be L1 Widevine device certificate revocation by Google/Widevine for such devices.
Read more >
Widevine L1 to L3 Fallback Broken with OxygenOS 9.0.0 and ...
(My bootloader is still unlocked.) On Pie however, this fallback seems not to work any more automatically, hence breaking the whole "DRM request"...
Read more >
Question - Widevine L1 drop to L3 | XDA Forums
It's a truly random problem. Sometimes it happens constantly every few minutes and other times it happens every few days. The most logical ......
Read more >
Fallback HDCP - Brightcove APIs
Hardware Security ; FairPlay · Type 0 required, HDCP type 0 content streams is enforced. · Type 1 required (Highest) ; Widevine ·...
Read more >
Cross origin Widevine broken in Android with Chrome 91
It fails with the error: "DOMException: Unsupported keySystem or ... Android Firefox with Widevine DRM, IOS Safari with Fairplay DRM Safari ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found