Implement encryption support for HLS
METHOD=AES-128
In case this could be helpful to others, I wanted to mention that I've ported the support for encrypted streams from the Dailymotion fork of ExoPlayer to the dev-hls branch from Google. The branch is available at https://github.com/perchrh/ExoPlayer/tree/dev-hls-google-crypto-support
This is the encrypted stream I've used for testing: http://playertest.longtailvideo.com/adaptive/oceans_aes/oceans_aes.m3u8
@perchrh Thank you, this was helpful. We'll push our own changes very soon. BTW, In your stream I noticed that only the first chunk (TS file) has PMT in it, and all the other chunks have no PMT after PAT. This seems broken to me. Where did you get it?
@andudo I found the stream in this list of test streams, http://www.jwplayer.com/html5/hls/ I'm not that into the TS format, so I cannot comment on the PMT/PAT. Quicktime plays the video too without any noticeable problems. There are, perhaps, some common encoding mistakes that players tend to work around.
Let me know if you need more encrypted test streams!
Edit: I btw noticed that my normalizeIV() method has a trivial bug, it looks for leading '0x', but it should, according to the spec, also handle '0X' (capital x) in the IV. Fixed in the mentioned branch.