The Apple HTTP Live Streaming (HLS) specification uses AES-128 encryption to provide content protection. The Advanced Encryption Standard (AES) is a specification for the encryption of electronic data established by the U.S. National Institute of Standards and Technology. In case of HLS with AES-128, individual media segments get encrypted with a 16-octet key. Most modern streaming servers have simple configuration options for enabling AES-128 on HLS streams.
Content Protection in THEOplayer
THEOplayer supports decryption and playback of HLS streams with AES-128 content protection out of the box, without extra configuration in the player. In order to play AES-128 content protected streams, the decryption key and an optional initialization vector have to be provided in the manifest. When configured correctly, THEOplayer allows playback of AES-128 content protected streams on all supported devices in real time. It allows for the usage of a single key, or a rotating key.
In order to make sure THEOplayer can decrypt the stream, make sure the following information is correct in the manifest:
- If a decryption key is specified, it is relevant for all following media segments. This allows you to specify a key for each segment or one for the whole manifest
- The decryption key can be hosted externally (by referencing the key URL) or embedded in the manifest file (by key value)
Cross Origin Resource Sharing
Make sure CORS is enabled both on the media segments that have to be downloaded, decrypted and played as well as the decryption key if referenced externally in the manifest file.
THEOplayer playing an AES-128 Content Protected stream.
Video on Demand stream with multiple encryption keys
An example manifest of a 44 second long VOD stream protected with AES-128 content protection - each media segment has its own key.
This feature is supported on all browsers supported by THEOplayer.
Internet Explorer 10+