New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hulu.com, viz.com #398

Closed
jspenguin2017 opened this Issue Jul 15, 2017 · 50 comments

Comments

4 participants
@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

hulu.com requires Flash too!

@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

That should kill the warning and the player hiding setTimeout calls

viz.com##script:inject(setTimeout-defuser.js, Please disable the ad blocker and try reloading this page)
viz.com##script:inject(setTimeout-defuser.js, Please try disabling ad blockers and reloading this page)
@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

I'm not sure if viz.com also requires Flash, need some feedback!

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

Are you sure that works? They have a wrapper that hides the function.

jspenguin2017 added a commit that referenced this issue Jul 15, 2017

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

Anyway, I fixed the message in another way, but video still doesn't play, even if I enable Flash.

@ghajini

This comment has been minimized.

ghajini commented Jul 15, 2017

i see no video panel....only blank space

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

Yea, I am aware of that.

@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

Works as in those adblocking messages no longer appear as the detection is killed with the call, the video not playing is another issue.

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

It's not really another issue as it plays with uBO off.

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

Actually not quite, since I'm Geo Locked.

@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

another issue meaning not related to anti adblock, something else needs to be patched too or is blocked which means it's broken.

@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

Not playing the video even after disabling all my extensions and uBO.

@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

Found this in the console - A Parser-blocking, cross site (i.e. different eTLD+1) script, https://player.hulu.com/js/hulu_global_html5.js?guid=0B1CEA04-DCCB-40cf-AD0E-5222EF66D519&partner=VizAnime&wmode=opaque&width=100%25&height=100%25, is invoked via document.write. The network request for this script MAY be blocked by the browser in this or a future page load due to poor network connectivity. If blocked in this page load, it will be confirmed in a subsequent console message.See https://www.chromestatus.com/feature/5718547946799104 for more details.

That is probably breaking the Hulu embedded player.

@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

It appears the browser itself is blocking the player. Anyone have any other browser should try loading the URL there.

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

Synchronous cross origin request are not blocked unless you are on 2G network.

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

image

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

image

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

Synchronous XHR is actually never blocked on Wi-Fi, when I was testing Violentproxy, there was a misconfiguration that is causing POST requests to be dropped, and some webpages just lock up.

@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

I'm not on a 2G network obviously and it still happening on my end. I don't see that notice either.

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

That notice will always show, but...

If blocked in this page load, it will be confirmed in a subsequent console message.`

Do you see the subsequent message? If not, then it's not blocked.

@uBlock-user

This comment has been minimized.

uBlock-user commented Jul 15, 2017

By notice I meant the Geo-Lock notice and I don't see any subsequent messages related to that.

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Jul 15, 2017

Ah, I read it wrong... I think it only show when you have Flash...

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Sep 10, 2017

The requested file is a Flash object, I can't loopback that, I don't have a way to get a working payload.
If there is a XML specific to ads then I might be able to do something.

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Sep 10, 2017

Anyway, if someone want to tinker around, here is a Node script that might be useful:

//Temporary DNS redirector
"use strict";

/**
 * Custom DNS servers.
 * @const {Array.<DNSServer>}
 */
const DNS_SERVERS = ["185.37.37.37", "185.37.39.39"]; //https://unlocator.com/

/**
 * Load modules.
 * @const {Module}
 */
const http = require("http");
const https = require("https");
const url = require("url");
const dns = require("dns");
const net = require("net");

/**
 * Regular expression to test if a string is filled with digits.
 * @const {RegExp}
 */
const reIsAllDigits = /^\d+$/;

//Set DNS server
dns.setServers(DNS_SERVERS);

//Start server
http.createServer().listen(12345).on("request", (req, res) => {
    //HTTP requests do not go though custom DNS for now, and insecure WebSocket does not work
    console.log("REQUEST", req.url);

    let option;
    try {
        option = url.parse(req.url);
    } catch (err) {
        res.writeHead(400, "Bad Request");
        res.end();
        return;
    }

    if (option.protocol !== "http:" && option.protocol !== "https:") {
        res.writeHead(400, "Bad Request");
        res.end();
        return;
    }

    delete req.headers["proxy-authorization"];
    if (req.headers["proxy-connection"]) {
        req.headers["connection"] = req.headers["proxy-connection"];
        delete req.headers["proxy-connection"];
    }

    option.method = req.method;
    option.headers = req.headers;

    const remote = (option.protocol === "http:" ? http : https).request(option, (rres) => {
        res.writeHead(rres.statusCode, rres.statusMessage, rres.headers);
        rres.pipe(res);
    });
    req.pipe(remote);

    remote.on("error", () => {
        res.destroy();
    });
    req.on("error", () => {
        remote.destroy();
    });
}).on("connect", (req, socket, head) => {
    //Everything works as expected in HTTPS mode
    console.log("CONNECT", req.url);

    let port = 443;
    let domain = "";
    {
        let parts = req.url.split(':');
        if (reIsAllDigits.test(parts[parts.length - 1])) {
            port = parseInt(parts.pop());
            if (port < 0 || port > 65535) {
                port = 443;
            }
        }
        domain = parts.join(':');
    }

    dns.resolve(domain, (err, address) => {
        let ip;
        if (err) {
            ip = domain;
        } else {
            ip = address[0];
            console.log(`\t${domain} -> ${ip}`);
        }

        const remote = net.connect({
            host: ip,
            port: port,
            servername: domain,
        }, () => {
            socket.write("HTTP/" + req.httpVersion + " 200 Connection Established\r\n");
            if (req.headers["proxy-connection"] === "keep-alive") {
                socket.write("Connection: keep-alive\r\n");
            }
            socket.write("\r\n");

            remote.write(head);

            socket.pipe(remote);
            remote.pipe(socket);
        });

        remote.on("error", () => {
            socket.destroy();
        });
        socket.on("error", () => {
            remote.destroy();
        });
    });
});

//Start up log
console.log("Server started on http://localhost:12345/");

Start it and use http://localhost:12345/ as proxy.

@ghajini

This comment has been minimized.

ghajini commented Sep 11, 2017

How to use this? Any manual pls?

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Sep 11, 2017

It's for developers.
As I said, start the script in Node and configure your proxy to use http://localhost port 12345. If you are still confused then you should ask Google.

@ghajini

This comment has been minimized.

ghajini commented Oct 12, 2017

Does v12 accomplishments help here? Like replace or mp4 modifier rule or anything?

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Oct 12, 2017

From my previous testing, it seems that viz.com is no longer embedding hulu.com, so the issue is gone by itself. I don't have a way to test hulu.com itself, but I have a way to simulate $mp4 modifier (it's added to v12 core).

jspenguin2017 added a commit that referenced this issue Oct 12, 2017

@ghajini

This comment has been minimized.

ghajini commented Oct 12, 2017

You require hulu account(check if any cookie there on jaguartrials.net) or anything else(VPN,try vyprvpn with sanfrancisco server,chameleon technology)...

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Oct 12, 2017

Geo Lock is not a problem. I just need a test account.

@ghajini

This comment has been minimized.

ghajini commented Oct 12, 2017

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Oct 12, 2017

Not sure, I might try it later.

jspenguin2017 added a commit that referenced this issue Nov 22, 2017

jspenguin2017 added a commit that referenced this issue Nov 22, 2017

Revert "#398"
This reverts commit 4f22153.

jspenguin2017 added a commit that referenced this issue Nov 22, 2017

@jspenguin2017 jspenguin2017 reopened this Nov 24, 2017

jspenguin2017 added a commit that referenced this issue Nov 24, 2017

jspenguin2017 added a commit that referenced this issue Nov 24, 2017

jspenguin2017 added a commit that referenced this issue Nov 24, 2017

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Nov 24, 2017

Alright, replaced all the ads with a 1 second blank video. That filter from Adguard was right, my debug fix was also right, I just wasn't able to verify that it is right until now. Also had to white list an ads loader, but meh, good enough, no real ads gets through.
Big thanks to @lain566 for the help.

Also, Object.defineProperty(window,'show_dfp_preroll',{value:false}); doesn't do anything on viz.com.

@uBlock-user

This comment has been minimized.

uBlock-user commented Nov 24, 2017

Did they do it again ?

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Nov 24, 2017

Do what?

jspenguin2017 added a commit that referenced this issue Nov 24, 2017

jspenguin2017 added a commit that referenced this issue Nov 24, 2017

@rogersachan

This comment has been minimized.

rogersachan commented Sep 9, 2018

@jspenguin2017 Appears that this is broken as of 9/9

@jspenguin2017

This comment has been minimized.

Owner

jspenguin2017 commented Sep 9, 2018

RIP... It's horrifyingly hard to test this issue. I'll see when I can find time to have another look at it.
Also: NanoAdblocker/NanoFilters#97

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment