ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I see a lot of applications that download videos from YouTube in a lot of formats. I don't want you to write a YouTube downloader for me but I would like to know where YouTube stores its videos. Is there any address like youtube.com/videos/lpn1dnDO5Os.mp4 (this is an example)??
Thanks for answers.
I see a lot of applications that download videos from YouTube in a lot of formats. I don't want you to write a YouTube downloader for me but I would like to know where YouTube stores its videos. Is there any address like youtube.com/videos/lpn1dnDO5Os.mp4 (this is an example)??
Thanks for answers.
And, please, answer
Hi...
Unless it's your own videos (that you made,) I wouldn't recommend this. A lot of content on Youtube was uploaded illegally, without permission from the author or copyright holder.
@altermetax: if you understand a little about how servers work, you will find that it is very basic stuff to redirect URLs internally, without the visitor ever seeing the underlying file system structure.
but it doesn't matter; there's plenty of youtube downloaders availbale, and if you really want to get into it, you download the source code of one and start digging htrough it. but even then you won't find out anything about google's server's directory tree.
(now i have to duck & run because jesus police is coming after me)
As ondoho says, the effect of the internal redirection, aka streaming, is to hide the bits from the user between the network device and the viewing device.
It is also easy to capture the bit patterns to a normal file, but unless you just want to do that as an exercise it is easiest to just use one of the many tools available for the purpose.
And I wouldn't burden myself with copy guilt... they are posted for the puprose of visitors being able to view them, right? To do so you must download the bit pattern, buffer it on your system and write it to a display device, right? If you use a file as a buffer instead of or in addition to system RAM, you have absolutely NOT harmed the author or any self-appointed "rights holder" (aka, money chanagers).
Those who would lay guilt on you and spin such innocent actions into a brazen crime are at best, misguided.
As for the "Jesus police", as I recall Jesus bypassed the legal tribute collectors and made them come to Him, and He overturned their tables - and their system. I cannot imagine Him vigilantly directing all the poor to dutifully line up at their tables again! Just my personal opinion.
Enjoy the music and the videos at your own convenience, guilt free - and feel free to dance if the mood strikes you!
Last edited by astrogeek; 11-08-2015 at 02:15 PM.
Reason: tpos, typs, typos
You can locate the URLs for the MP4 files by using the browser's developer tools to analyze the page's DOM (Document Object Model). Once you find out where in the DOM it is, you can use Javascript to manipulate the page to insert a download link for it. If I were writing a Youtube video downloader from scratch, it would be a script for Greasemonkey or Tampermonkey.
Those who would lay guilt on you and spin such innocent actions into a brazen crime are at best, misguided.
Someone who uploads content that was not theirs and did not obtain permission to do so is not committing an "innocent" action. It is wrong. I know because the Lord has had to correct me more than once about watching stuff that was illegally uploaded. Now I try to very diligent about the source of the content before I watch it.
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680
Rep:
Surely anything that Google own or have negotiated rights to distribute anything that is available on YouTube, or they wouldn't show it?
The DMCA, amongst other things, would mean that should Google be hosting illegal content, or even if there were a suggestion that they were, on YouTube the site would be shut down pending legal action. That's what US law says, Google is a US company, so anything on Google must be legal to watch or it wouldn't be there.
so anything on Google must be legal to watch or it wouldn't be there.
Hi...
Unfortunately, no, that's not the case. There is quite a bit of stuff on Youtube that was uploaded illegally. At one point, MondoMedia and Youtube put out this funny cartoon I think to make people aware of the problem and the potential penalties. There also wouldn't be the need for takedown forms such as this one.
As far as downloading videos goes, please see this page.
Regards...
Last edited by ardvark71; 11-08-2015 at 04:46 PM.
Reason: Changed wording/Correction.
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680
Rep:
Quote:
Originally Posted by ardvark71
Hi...
Unfortunately, no, that's not the case. There is quite a bit of stuff on Youtube that was uploaded illegally. At one point, MondoMedia and Youtube put out this funny cartoon I think to make people aware of the problem and the potential penalties. There also wouldn't be the need for takedown forms such as this one.
As far as downloading videos goes, please see this page.
Regards...
That simply can't be the case. The DMCA has ended copyright infringement and all those who practice it have been jailed. If I were to host illegal content then my hosting provider would suspend my account until I could prove I wasn't breaking the law. Since YouTube is still up and running all its content must be legal.
The US courts can't have it both ways, I'm afraid.
You can locate the URLs for the MP4 files by using the browser's developer tools to analyze the page's DOM (Document Object Model).
thanks for this.
i keep forgetting how powerful these developer tools are, at least on firefox/iceweasel.
op, on the page in question press "F12" and see mysteries unravel!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.