Re:YouTube-dl has received a DMCA takedown from RIAA
by ewanm89 on Saturday October 24, 2020 @11:22AM
(#24879722)
Let me be clear, basically the "rolling cipher" is DASH/HLS streaming for automatic quality changing. This has been an argument RIAA has been making since 2016, but outside of the judgement in Germany (which is wrong). All they have had on it are default judgements where no-one has even tried to counter it in court.
The only _concrete_ circumvention they level at youtube-dl is that it "circumvents YouTube’s rolling cipher". I looked into this more, and before I go into how totally bulshit it is that they've apparently conned judges into believing this, you should read their full accusation (or just read the full DMCA letter from the RIAA):
So that's what the RIAA is saying that youtube-dl is doing. However, they're referencing a document that I _presume_ was attached to their original email, the document from the Hamburg Regional Court, but we don't have that email, as Github didn't publish that document for us to see.So I went looking, and it turns out that the RIAA has used this exact same excuse to go after some other people, their documents are available, and we can see more of what they wrote. I'm referencing this[1] document which I found through this[0] blog post about a 2016 case where the RIAA went after an online service called TYMP3. Here are the links, and here's what the RIAA said:
[0] - https://www.techdirt.com/articles/20160927/17062135646/can-s...
[1] - https://assets.documentcloud.org/documents/3114545/YTMP3-Com...
So, let's go see what the Youtube-dl source code actually is doing. The tl;dr version is that youtube does some slight rearranging of the characters in the URL of the remote resource, but they also supply you with the JS code to un-arrange that code into the actual working "signature" which you can use to request the video from youtube. So youtube-dl downloads the rearranged URL, and the JS that youtube provides, and uses a Python implementation of the JS interpreter to run YOUTUBE'S OWN JS THAT YOUTUBE SENT US IN CLEARTEXT TO FIGURE OUT HOW TO DOWNLOAD THE VIDEO. See the source code (hosted on gitlab for now, hopefully that stays up):https://gitlab.com/HacktorIT/youtube-dl/-/blob/master/youtub...
So to summarize, youtube creates two URLs: one that's a public video URL, and one that's the URL to the actual video content. The URL to the video content changes on a rolling basis, and is slightly rearranged. All that's true. However, what the RIAA is avoiding saying, and which completely changes the context of this discussion is:
YOUTUBE SENDS YOU BOTH URLS IN CLEARTEXT, AND INCLUDES THE CODE FOR HOW TO DOWNLOAD THE VIDEO, SO YOU AND YOUR WEB BROWSER CAN DOWNLOAD THE VIDEOS WITHOUT USING ANY ENCRYPTION/DECODING.
So when a judge asks "how is it that you're getting around this 'rolling cipher' to access the video?" all you have to say is "Youtube told me where to download the video, so I followed Youtube's instructions and downloaded it from the URL that Youtube gave me."
Frankly, I'm amazed that any judge, or any lawyer, would ever lay out or believe such bare faced lies as is being spouted by the RIAA in this document.
FUCK THE RIAA