Skip to content

tvos: Add platform DRM key system registration - #12482

Open
abhijeetk wants to merge 1 commit into
youtube:mainfrom
abhijeetk:drm-key-registration
Open

tvos: Add platform DRM key system registration#12482
abhijeetk wants to merge 1 commit into
youtube:mainfrom
abhijeetk:drm-key-registration

Conversation

@abhijeetk

@abhijeetk abhijeetk commented Sep 6, 2026

Copy link
Copy Markdown
Collaborator

Register the platform DRM key system in the Cobalt content renderer
client for internal tvOS builds.

This registration is required to prevent NotSupportedError when
the YouTube application calls requestMediaKeySystemAccess. By
providing the platform-specific KeySystemInfo, the renderer can
successfully advertise supported initialization data types and
encryption schemes, enabling the creation of MediaKeys for the
platform DRM.

Supported by internal build only.

Bug: 501343649
Bug: 498421484

@github-actions

github-actions Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor
Context State Description
CI / android ✅ PASS Passed
CI / aosp ✅ PASS Passed
CI / evergreen ✅ PASS Passed
CI / linux ✅ PASS Passed
CI / tvos ✅ PASS Passed
import/copybara ✅ PASS Change imported to Gerrit
kokoro ✅ PASS Kokoro build finished

@github-actions

github-actions Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

🤖 Gemini Suggested Commit Message


tvos: Add platform DRM key system registration

Register the platform DRM key system in the Cobalt content renderer
client for internal tvOS builds.

This registration is required to prevent NotSupportedError when
the YouTube application calls requestMediaKeySystemAccess. By
providing the platform-specific KeySystemInfo, the renderer can
successfully advertise supported initialization data types and
encryption schemes, enabling the creation of MediaKeys for the
platform DRM.

Bug: 501343649
Bug: 498421484

💡 Pro Tips for a Better Commit Message:

  1. Influence the Result: Want to change the output? You can write custom prompts or instructions directly in the Pull Request description. The model uses that text to generate the message.
  2. Re-run the Generator: Post a comment with: /generate-commit-message

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds support for platform DRM key system info on iOS internal builds by updating the BUILD.gn dependencies and registering the key system in cobalt_content_renderer_client.cc. The review feedback suggests nesting the new dependency check inside the existing use_starboard_media block in BUILD.gn to avoid duplication and improve maintainability.

Comment thread cobalt/renderer/BUILD.gn
Register the platform DRM key system (com.youtube.<platform-drm>) in
the Cobalt content renderer client with encryption scheme support.

Without this registration, YouTube JS's call to
navigator.requestMediaKeySystemAccess("com.youtube.<platform-drm>", config)
fails with NotSupportedError because no KeySystemInfo exists for this
key system. Blink's KeySystemConfigSelector checks each requested
initDataType against the registered
KeySystemInfo::IsSupportedInitDataType(). The PlatformDrmKeySystemInfo
advertises W3C EME init data types (cenc, webm) that match what YouTube
negotiates, allowing the capability check to pass and enabling MediaKeys
creation for Platform DRM.

Supported by internal build only.

Bug: 501343649
Bug: 498421484
@abhijeetk

Copy link
Copy Markdown
Collaborator Author

@abhijeetk

abhijeetk commented Sep 7, 2026

Copy link
Copy Markdown
Collaborator Author

These changes initially was part of existing PR : #11141, now its rebased. We can land it separatelly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants