GNOME Bugzilla – Bug 728497
Add Adobe HDS streaming support
Last modified: 2018-11-03 13:22:40 UTC
Similar to Microsoft's MSS and Apple's HLS, Adobe Flash now uses HDS (HTTP Dynamic Streaming). After downloading a manifest file, such as this one [1], we get something like [2]. This file can then be processed by a script like this one: https://github.com/K-S-V/Scripts/blob/master/AdobeHDS.php I could not find much more information about the protocol though. [1]: http://us-cplus-aka.canal-plus.com/z/1404/ZAPPING_EMISSION_140417_AUTO_24118_169_video_,MOB,L,H,HD,.mp4.csmil/manifest.f4m?hdcore=2.11.3&g=TFLGDRZDWEQU [2]: <?xml version="1.0" encoding="UTF-8"?> <manifest xmlns="http://ns.adobe.com/f4m/1.0" xmlns:akamai="uri:akamai.com/f4m/1.0"> <akamai:version>2.0</akamai:version> <akamai:bw>5000</akamai:bw> <id>/1404/ZAPPING_EMISSION_140417_AUTO_24118_169_video_,MOB,L,H,HD,.mp4.csmil_0</id> <streamType>recorded</streamType> <akamai:streamType>vod</akamai:streamType> <duration>350.435</duration> <streamBaseTime>0.000</streamBaseTime> <bootstrapInfo profile="named" id="bootstrap_0">AAAAi2Fic3QAAAAAAAAAAQAAAAPoAAAAAAAFWOMAAAAAAAAAAAAAAAAAAQAAABlhc3J0AAAAAAAAAAABAAAAAQAAADoBAAAARmFmcnQAAAAAAAAD6AAAAAADAAAAAQAAAAAAAAAAAAAXcAAAADoAAAAAAAU38AAAIPMAAAAAAAAAAAAAAAAAAAAAAA==</bootstrapInfo> <bootstrapInfo profile="named" id="bootstrap_1">AAAAi2Fic3QAAAAAAAAAAQAAAAPoAAAAAAAFWOMAAAAAAAAAAAAAAAAAAQAAABlhc3J0AAAAAAAAAAABAAAAAQAAADoBAAAARmFmcnQAAAAAAAAD6AAAAAADAAAAAQAAAAAAAAAAAAAXcAAAADoAAAAAAAU38AAAIPMAAAAAAAAAAAAAAAAAAAAAAA==</bootstrapInfo> <bootstrapInfo profile="named" id="bootstrap_2">AAAAi2Fic3QAAAAAAAAAAQAAAAPoAAAAAAAFWOMAAAAAAAAAAAAAAAAAAQAAABlhc3J0AAAAAAAAAAABAAAAAQAAADoBAAAARmFmcnQAAAAAAAAD6AAAAAADAAAAAQAAAAAAAAAAAAAXcAAAADoAAAAAAAU38AAAIPMAAAAAAAAAAAAAAAAAAAAAAA==</bootstrapInfo> <bootstrapInfo profile="named" id="bootstrap_3">AAAAi2Fic3QAAAAAAAAAAQAAAAPoAAAAAAAFWOMAAAAAAAAAAAAAAAAAAQAAABlhc3J0AAAAAAAAAAABAAAAAQAAADoBAAAARmFmcnQAAAAAAAAD6AAAAAADAAAAAQAAAAAAAAAAAAAXcAAAADoAAAAAAAU38AAAIPMAAAAAAAAAAAAAAAAAAAAAAA==</bootstrapInfo> <media bitrate="323" url="0_2dbc92db08d2df60_" bootstrapInfoId="bootstrap_0"> <metadata>AgAKb25NZXRhRGF0YQgAAAAMAAhkdXJhdGlvbgBAdeb1wo9cKQAFd2lkdGgAQIQAAAAAAAAABmhlaWdodABAdoAAAAAAAAANdmlkZW9kYXRhcmF0ZQBAaN2SEF73ugAJZnJhbWVyYXRlAEA4/1xdBkWCAAx2aWRlb2NvZGVjaWQAQBwAAAAAAAAADWF1ZGlvZGF0YXJhdGUAQF9p1G1n234AD2F1ZGlvc2FtcGxlcmF0ZQBA5YiAAAAAAAAPYXVkaW9zYW1wbGVzaXplAEAwAAAAAAAAAAZzdGVyZW8BAQAMYXVkaW9jb2RlY2lkAEAkAAAAAAAAAAhmaWxlc2l6ZQBBax5YQAAAAAAACQ==</metadata> </media> <media bitrate="477" url="1_2dbc92db08d2df60_" bootstrapInfoId="bootstrap_1"> <metadata>AgAKb25NZXRhRGF0YQgAAAAMAAhkdXJhdGlvbgBAdeb1wo9cKQAFd2lkdGgAQIQAAAAAAAAABmhlaWdodABAdoAAAAAAAAANdmlkZW9kYXRhcmF0ZQBAdg6cRALvywAJZnJhbWVyYXRlAEA4/1xdBkWCAAx2aWRlb2NvZGVjaWQAQBwAAAAAAAAADWF1ZGlvZGF0YXJhdGUAQF9p1G1n234AD2F1ZGlvc2FtcGxlcmF0ZQBA5YiAAAAAAAAPYXVkaW9zYW1wbGVzaXplAEAwAAAAAAAAAAZzdGVyZW8BAQAMYXVkaW9jb2RlY2lkAEAkAAAAAAAAAAhmaWxlc2l6ZQBBc/3/UAAAAAAACQ==</metadata> </media> <media bitrate="877" url="2_2dbc92db08d2df60_" bootstrapInfoId="bootstrap_2"> <metadata>AgAKb25NZXRhRGF0YQgAAAAMAAhkdXJhdGlvbgBAdeb1wo9cKQAFd2lkdGgAQIQAAAAAAAAABmhlaWdodABAdoAAAAAAAAANdmlkZW9kYXRhcmF0ZQBAh4Khh0FSigAJZnJhbWVyYXRlAEA4/1xdBkWCAAx2aWRlb2NvZGVjaWQAQBwAAAAAAAAADWF1ZGlvZGF0YXJhdGUAQF9p1G1n234AD2F1ZGlvc2FtcGxlcmF0ZQBA5YiAAAAAAAAPYXVkaW9zYW1wbGVzaXplAEAwAAAAAAAAAAZzdGVyZW8BAQAMYXVkaW9jb2RlY2lkAEAkAAAAAAAAAAhmaWxlc2l6ZQBBglbCiAAAAAAACQ==</metadata> </media> <media bitrate="1472" url="3_2dbc92db08d2df60_" bootstrapInfoId="bootstrap_3"> <metadata>AgAKb25NZXRhRGF0YQgAAAAMAAhkdXJhdGlvbgBAdeb1wo9cKQAFd2lkdGgAQIQAAAAAAAAABmhlaWdodABAdoAAAAAAAAANdmlkZW9kYXRhcmF0ZQBAlQ/tW2vHAQAJZnJhbWVyYXRlAEA4/1xdBkWCAAx2aWRlb2NvZGVjaWQAQBwAAAAAAAAADWF1ZGlvZGF0YXJhdGUAQF9p1G1n234AD2F1ZGlvc2FtcGxlcmF0ZQBA5YiAAAAAAAAPYXVkaW9zYW1wbGVzaXplAEAwAAAAAAAAAAZzdGVyZW8BAQAMYXVkaW9jb2RlY2lkAEAkAAAAAAAAAAhmaWxlc2l6ZQBBjsfX6AAAAAAACQ==</metadata> </media> </manifest>
The manifest has a mime-type of video/f4m. The description of the manifest format and the streaming protocol are available at: http://www.adobe.com/devnet/hds.edu.html
SVT Play seems to use HDS nowadays (was RTMP previously). There is a python program to download videos from this (and some other streaming sites): https://github.com/spaam/svtplay-dl If you run it with -v it will show the URLs of the framgements getting fetched. I think this might be useful to get some hints.
Looks like there are some simpler f4m files available, such as: http://config.playwire.com/videos/v2/3029440/manifest.f4m which contains: <?xml version="1.0" encoding="UTF-8"?> <manifest xmlns="http://ns.adobe.com/f4m/1.0"> <id>3029440</id> <duration>118</duration> <baseURL>http://cdn.phoenix.intergi.com/19850/videos/3029440</baseURL> <media url="video-sd.mp4?hosting_id=19850" bitrate="1200" height="360" width="640"/> </manifest> Would be a good first step to support.
This should hopefully be quite simple with Thiago's adaptive streaming demuxer base class soon.
I have started looking into this, will report when I get something working.
Got to a deadend as there seem to be no mention of where to obtain codec_data for the streams. Playing the same stream with the javascript implementation works. Tried contacting Adobe for further technical information without success. This extra reading of javascript code wasn't in my initial plan and I don't have time at the moment to finish this.
My ongoing work can be found at http://cgit.freedesktop.org/~thiagoss/gst-plugins-bad/log/?h=hds if anyone wants to take from there.
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/141.