They make a test request from the client and check it’s received on the server end and returns what they expect on the client end at a guess. Basically they try to load an ad and if they don’t see the request on the server, or the client doesn’t get the sort of data it expects, it assumes you’re ad blocking.
The client side code probably expects to see and use the data, although I could be wrong on that. Some ad block do work like that though, I think.I find just deliberately taking a 30 second break to be the easiest ad block, and it’s better for you too.
There are many ways. Something I’ve come up with just now:
Put a few blocks of information encoded in the video of the ad itself. Require that block of information as a key to watch the next video on Youtube. No key, no videos. Extract the key by reading the video data as it plays from the client side. Stream the ad at only half a second at a time, so it’s never fully in the clients buffer.
Theoretically an addon could block the video for 30 seconds and just slow a blank screen, but it’d be impossible to block the ad without interruptions.
Less complicated anti ad block scripts are out there. Simply serving an important piece of Javascript from a host and filename that would normally look like an ad would probably trick the adblocker into blocking it. If that bit of script takes care of making the video play and the default HTML on the page says “no adblock plz” you’re already there.
Detecting adblock isn’t hard, and preventing users with adblock isn’t either. It requires constant attention from Google programmers though, which is quite expensive.
They don’t need to catch all ad block either. They just need to catch enough people enough times that paying for their video services is more comfortable to them than running adblock or accepting ads.
That’s why you’d need to stream the ad one second at a time so you can’t scan the full file. Whether you’re watching an ad or not, you’d be waiting for the ad to finish.
Of course this is a rather naive idea, but it just shows how one might go about accomplishing this. I’m sure Google’s programmers can come up with much better solutions.
How does YouTube know whether I’m blocking or not if it all happens at the client side?
They make a test request from the client and check it’s received on the server end and returns what they expect on the client end at a guess. Basically they try to load an ad and if they don’t see the request on the server, or the client doesn’t get the sort of data it expects, it assumes you’re ad blocking.
What if we allow the request but then just discard the response?
The client side code probably expects to see and use the data, although I could be wrong on that. Some ad block do work like that though, I think.I find just deliberately taking a 30 second break to be the easiest ad block, and it’s better for you too.
The problem for me is when I use youtube videos to fall asleep and adblocks doesn’t work.
youtube-dl is your friend.
I like how we’re going back to straight up pirateing to not get hit by ads.
I mean, if youtube premium were $5/mo I would consider it.
Not even then.
There are many ways. Something I’ve come up with just now:
Put a few blocks of information encoded in the video of the ad itself. Require that block of information as a key to watch the next video on Youtube. No key, no videos. Extract the key by reading the video data as it plays from the client side. Stream the ad at only half a second at a time, so it’s never fully in the clients buffer.
Theoretically an addon could block the video for 30 seconds and just slow a blank screen, but it’d be impossible to block the ad without interruptions.
Less complicated anti ad block scripts are out there. Simply serving an important piece of Javascript from a host and filename that would normally look like an ad would probably trick the adblocker into blocking it. If that bit of script takes care of making the video play and the default HTML on the page says “no adblock plz” you’re already there.
Detecting adblock isn’t hard, and preventing users with adblock isn’t either. It requires constant attention from Google programmers though, which is quite expensive.
They don’t need to catch all ad block either. They just need to catch enough people enough times that paying for their video services is more comfortable to them than running adblock or accepting ads.
Interesting. But it probably only takes less than a few seconds for a program to scan a 30s video file and extract that bit of information.
That’s why you’d need to stream the ad one second at a time so you can’t scan the full file. Whether you’re watching an ad or not, you’d be waiting for the ad to finish.
Of course this is a rather naive idea, but it just shows how one might go about accomplishing this. I’m sure Google’s programmers can come up with much better solutions.