Skip to content
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

DRM: Don't work-around firefox issue if the application asked for specific capabilities #1498

Merged
merged 1 commit into from
Aug 13, 2024

Conversation

peaBerberian
Copy link
Collaborator

In #1495, we recently worked around an issue specific to firefox on windows where asking for at least one unsupported video or audio capability resulted (in our opinion, incorrectly) to a navigator.requestMediaKeySystemAccess API call failure.

To work-around this and other similar bugs, we decided to just always perform a second navigator.requestMediaKeySystemAccess call in our logic which doesn't ask for any capability.

However, I just realized that this may break some API usages.

For example let's imagine that an application specifically set an audioCapabilitiesConfig or videoCapabilitiesConfig in a loadVideo call to ask for specific capabilities (either specific codecs, or specific robustnesses like PlayReady SL3000 or Widevine L1).

Here, we would first perform a check with the asked capabilities, yet also a second one without. Meaning that an application could be left with a key system that is not the one it explicitely asked for (e.g. we could be playing with PlayReady SL2000 when the application asked explicitely for PlayReady SL3000).

So the fix here is to disable the "no capabilities" work-around if an application explicitely ask for specific capabilities.

…cific capabilities

In #1495, we recently worked around an issue specific to firefox on
windows where asking for at least one unsupported video or audio
capability resulted (in our opinion, incorrectly) to a
`navigator.requestMediaKeySystemAccess` API call failure.

To work-around this and other similar bugs, we decided to just always
perform a second `navigator.requestMediaKeySystemAccess` call in our
logic which doesn't ask for any capability.

However, I just realized that this may break some API usages.

For example let's imagine that an application specifically set an
`audioCapabilitiesConfig` or `videoCapabilitiesConfig` in a
`loadVideo` call to ask for specific capabilities (either specific
codecs, or specific robustnesses like PlayReady SL3000 or Widevine L1).

Here, we would first perform a check with the asked capabilities, yet
also a second one without. Meaning that an application could be left
with a key system that is not the one it explicitely asked for (e.g.
we could be playing with PlayReady SL2000 when the application asked
explicitely for PlayReady SL3000).

So the fix here is to disable the "no capabilities" work-around if an
application explicitely ask for specific capabilities.
@peaBerberian peaBerberian added this to the 4.2.0 milestone Aug 13, 2024
@peaBerberian peaBerberian added bug This is an RxPlayer issue (unexpected result when comparing to the API) DRM Relative to DRM (EncryptedMediaExtensions) Compatibility Relative to the RxPlayer's compatibility with various devices and environments Priority: 0 (Very high) This issue or PR has a very high priority. Efforts should be concentrated on it first. labels Aug 13, 2024
@peaBerberian peaBerberian merged commit 3f8b756 into dev Aug 13, 2024
10 checks passed
peaBerberian added a commit that referenced this pull request Sep 13, 2024
This is a backport of #1495 and #1498 for the v3
peaBerberian added a commit that referenced this pull request Sep 13, 2024
This is a backport of #1495 and #1498 for the v3
peaBerberian added a commit that referenced this pull request Sep 23, 2024
This is a backport of #1495 and #1498 for the v3
@peaBerberian peaBerberian deleted the fix/firefox-workaround-v2 branch November 9, 2024 21:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This is an RxPlayer issue (unexpected result when comparing to the API) Compatibility Relative to the RxPlayer's compatibility with various devices and environments DRM Relative to DRM (EncryptedMediaExtensions) Priority: 0 (Very high) This issue or PR has a very high priority. Efforts should be concentrated on it first.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant