Live data from Hacker News

YouTube video has its own URL in it

youtube.com

21–30 of 160 posts

Re: YouTube video has its own URL in it

#22

Earlier quoted context omitted.

Start uploading a video, pause the upload, you could already get the ID of the vid, render rest of the video and then continue the upload that now contains the ID of the video :D

How to pause? and re upload pending part with new video?

I'm not sure you could do this in the website itself but this would be trivial using the YouTube APIs.

Re: YouTube video has its own URL in it

#23
Definitely not the same technique, but at one point I watched a Mario Maker puzzle level someone had uploaded that used part of its own level code as a clue. The trick was that only two characters of the level code were used, which is hexadecimal, so there are 256 combinations of those two characters, allowing the level creator to brute force re-uploading the level until getting the desired combination.

Re: YouTube video has its own URL in it

#25
post #3

This looks really interesting. Has YouTube ever published their URL generation technique? Any one has a guess how this was done? If they use a one way hash over metadata and content if video does this not mean that someone has figured out their secret key.

I'm wondering how this could actually be exploited. Is there any value in knowing your URL ahead of time besides impressing the HN crowd?

Re: YouTube video has its own URL in it

#26
I think it's most likely done with the API. From what I remember from looking at it a while ago you can create the entry before, then it'll give you the right endpoint where you post your actual file to later on in the process. You just have to do that quickly enough so the endpoint doesn't expire.

Re: YouTube video has its own URL in it

#28
my guess is the url is a hash of the video upload time, username , video length (is deterministic) so he uploaded 100 (or 1000) and kept the one that worked

tip: if you see something magic it's usually just dilligence in disguise. (like the Prestige)

Re: YouTube video has its own URL in it

#29
post #9
post #6

Earlier quoted context omitted.

Just a guess but I assume this was done by starting an upload with the API which gave the guy the ID but then not streaming the actual video file until it was recorded. Looking at an example of the API in use ( https://developers.google.com/youtube/v3/docs/videos/insert#... ) that certainly seems plausible although I would imagine that there would be a timeout making it difficult. edit: after looking at the other guy…

The ID returns once your upload is completed. Edit: I don't know the answer but I assume from all the APIs I worked with in the past, but if you get the URL before the upload is completed then yeah it's pretty easy to "fake".

Not for me. When I'm uploading a video even when it's at 0% I see "The URL of your uploaded video will be: blah"

So it seems you can get the URL immediately... maybe then stop the upload mess with the video and then resume the upload... but I assume the resume feature takes a hash or something to make sure it's the same file..

Post reply on HN