-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Add Apple FairPlay Streaming (FPS) DRM support #4941
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
Draft
tobbee
wants to merge
21
commits into
development
Choose a base branch
from
features/fairplay
base: development
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
+1,311
−45
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
… Moreover, added CertUrlUtils for normalizing and deduping cert urls.
# Conflicts: # src/streaming/protection/controllers/ProtectionController.js
…dash.js into feature/certurl
… ContentProtection for consistency
… for each DRM-type. Widevine certificate download method requests an EME-Challenge from ProtectionModel in order to download a widevine server certificate.
…al payload and only using GET requests to download widevine server certificates.
Enable encrypted DASH playback on Safari (macOS/iOS) via the FairPlay key system (com.apple.fps). FairPlay uses sinf init data instead of PSSH/cenc, requires a server certificate before generateRequest(), and works with cbcs encryption only. Tested successfully with Safari on macOS against the livesim2 EZDRM test stream: https://livesim2.dashif.org/livesim2/drm_EZDRM-1-key-pr-cbcs/testpic_2s/Manifest.mpd New files: - KeySystemFairPlay.js: key system implementation (sinf, binary SPC) - servers/FairPlay.js: license server handler with multi-format CKC response decoding (raw binary, base64, XML, JSON) - Unit tests for both Modified files: - ProtectionConstants.js: FairPlay UUID, key system string, sinf constant - ProtectionKeyController.js: register FairPlay key system and server - DefaultProtectionModel.js: sinf dataType for generateRequest(), priority - MediaCapability.js: optional encryptionScheme parameter (cbcs) - ProtectionController.js: accept sinf initData in _onNeedKey, extract key ID from tenc for session deduplication, sinf initDataTypes and cbcs encryptionScheme in capabilities, certificate-before-session flow
c34a287 to
4cb882e
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
com.apple.fps) to dash.js, enabling encrypted DASH playback on Safari (macOS/iOS)sinfinit data (not PSSH/cenc), requires a server certificate beforegenerateRequest(), and works withcbcsencryption onlytencfor session deduplication, and multi-format CKC license response decodinghttps://livesim2.dashif.org/livesim2/drm_EZDRM-1-key-pr-cbcs/testpic_2s/Manifest.mpdBuilt on top of the certurl draft PR #4876. Addresses feature request #4844 by making use of certurl (#4803).
New files
src/streaming/protection/drm/KeySystemFairPlay.js— key system implementationsrc/streaming/protection/servers/FairPlay.js— license server handler with multi-format CKC decodingModified files
ProtectionConstants.js— FairPlay UUID, key system string, sinf constantProtectionKeyController.js— register FairPlay key system and serverDefaultProtectionModel.js— sinf dataType forgenerateRequest(), priorityMediaCapability.js— optionalencryptionSchemeparameter (cbcs)ProtectionController.js— accept sinf initData, extract key ID from tenc for session dedup, sinf initDataTypes and cbcs encryptionScheme in capabilities, certificate-before-session flow