Skip to content
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

CloudFlare update? #532

Closed
ElijahDD opened this issue Jul 25, 2021 · 9 comments
Closed

CloudFlare update? #532

ElijahDD opened this issue Jul 25, 2021 · 9 comments

Comments

@ElijahDD
Copy link

Hi. CloudFlare update their JS Challenge? Stealth plugin can't bypass it now.

@prescience-data
Copy link
Collaborator

image

@taewookim
Copy link

Related

@maxwrlr
Copy link

maxwrlr commented Aug 27, 2021

I had the same issue, so I created the puppeteer browser extension. Might not work for every use case though.

@taewookim
Copy link

@maxwrlr Interesting. Never thought of using browser extension. Can you explain what the extesnsion is trying to do? and in what cases would it not work?

@maxwrlr
Copy link

maxwrlr commented Aug 27, 2021

The extension is used to execute the puppeteer API functions via the browser extension interface.
As stated in the repository, a real headless mode is not possible. Most other limitations result from functionality that is not implemented (yet).

Furthermore, the current design doesn't allow concurrent execution. For example:

const p1 = await browser.newPage();
const p2 = await browser.newPage();

and

const [p1, p2] = await Promise.all([
  browser.newPage(),
  browser.newPage()
])

are scheduling-wise equal, because the secondnewPage will always be executed after the first call to newPage resolved.

@regseb
Copy link
Contributor

regseb commented Aug 31, 2021

Cloudflare doesn't work, it redirects in loop on the page:

Checking your browser before accessing XXX.
This process is automatic. Your browser will redirect to your requested content shortly.

Please allow up to 5 seconds…

DDoS protection by Cloudflare

The following error is displayed in the console.

[[[ERROR]]]: Message: Uncaught TypeError: Converting circular structure to JSON
    --> starting at object with constructor 'Window'
    --- property 'window' closes the circle - URL:  - Line: 5 - Column: 14655 - Error object: {}
{i: "F0qg3w2C0uk=", h: "6e72b2ba904e2ec", tH: "", t: -1630431698613}h: "6e72b2ba904e2ec"i: "F0qg3w2C0uk="t: -1630431698613tH: ""[[Prototype]]: Objectconstructor: ƒ Object()hasOwnProperty: ƒ hasOwnProperty()isPrototypeOf: ƒ isPrototypeOf()propertyIsEnumerable: ƒ propertyIsEnumerable()toLocaleString: ƒ toLocaleString()toString: ƒ toString()valueOf: ƒ valueOf()__defineGetter__: ƒ __defineGetter__()__defineSetter__: ƒ __defineSetter__()__lookupGetter__: ƒ __lookupGetter__()__lookupSetter__: ƒ __lookupSetter__()get __proto__: ƒ __proto__()set __proto__: ƒ __proto__()

Uncaught TypeError: Converting circular structure to JSON
    --> starting at object with constructor 'Window'
    --- property 'window' closes the circle
    at JSON.stringify (<anonymous>)
    at eval (eval at C.<computed> (v1?ray=68780cf65e342209:formatted:2161), <anonymous>:5:14655)
    at nziUGuKFi (eval at C.<computed> (v1?ray=68780cf65e342209:formatted:2161), <anonymous>:5:14749)
    at eval (eval at C.<computed> (v1?ray=68780cf65e342209:formatted:2161), <anonymous>:5:12376)
    at fcfs (eval at C.<computed> (v1?ray=68780cf65e342209:formatted:2161), <anonymous>:5:11181)
    at Worker.w.onmessage (eval at C.<computed> (v1?ray=68780cf65e342209:formatted:2161), <anonymous>:5:11502)

The line in error refers to this code:

(function(done) {
    var _0xf = document.createElement(_[10]);
    _0xf.style.height = _[0x10];
    _0xf.style.height = _[0x10];
    _0xf.srcdoc = _[17];
    document.body.appendChild(_0xf);
    ;wgsMkt[wgsMkt[0]] *= (+(1 === 1)) * (+(+((!+[] + (!![]) + /* ... */ !![]) + (-~~~[]))));
    wgsMkt[wgsMkt[0]] = (+wgsMkt[wgsMkt[0]]).toFixed(10);

    wgsMkt[wgsMkt[0]] += _[17] + (_[17] + JSON.stringify(_0xf.contentWindow[0])).charCodeAt(0);

    document.body.removeChild(_0xf);
    wgsMkt[0]++;
}
)(function() {
    pXYDXxjWw = _[0x8];
    nziUGuKFi();
});

@berstend
Copy link
Owner

berstend commented Sep 17, 2021

@regseb's iframe.contentWindow evasion fix (#545) has landed in puppeteer-extra-plugin-stealth@2.7.10 and might help in this regard

@taewookim
Copy link

@berstend You know what'd be helpful? if you explain the process (what to look for, and how to remedy) in general terms, i think people like myself and others could help improve..

currently, not exactly certain how the anti-puppeteer counter measures are being developed.

i know this is a tall order but if u want, u can explain over zoom and i can record .. and have community of contributors ask questions... then put it up on this repo ... this way we have an idea of what to look for and what you're thinking

@berstend
Copy link
Owner

You know what'd be helpful? if you explain the process (what to look for, and how to remedy) in general terms, i think people like myself and others could help improve..

I'm not against doing that, but unfortunately there's only so many hours in the day :) Overall the material contributions to stealth development from other individuals have been extremely limited since the project's inception, so for now I'll be focussing on the more pressing issues (like landing #454).

For anyone interested in learning more about stealth development and contributing to the open-source project I recommend hanging out in our community discord, there's lots of high quality discussions around JS/CDP based browser hacking.

Closing this issue for now (the issue tracker is more meant for technical discussions rather than a help desk for stealth issues, consider using our discord server for that)

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

No branches or pull requests

6 participants