Enhanced Clear Key Content Protection with on-the-fly encryption #150
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.
This PR implements support for encrypting streams on the fly using either "cbcs" or "cenc" scheme and fetching the keys over HTTP towards the server. The keys and key IDs are generated from the asset name and related to each other which allows for easy lookup and generation.
Both normal and low-latency streaming should be supported. The video and audio segments are encrypted in an extra process round. The init segments also need to be prepared. That is done when ingesting the content. At the same time, it is checked whether the segments are already encrypted, in which case the extra encryption information is not stored.
Pre-encrypted content should also work. Has been tested with an HbbTV asset provided in #122 (after changing the spelling of Laurl and the namespace).
The URL generator has been updated with the new option for eccp.
This solves #122.