-
-
Notifications
You must be signed in to change notification settings - Fork 742
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
[Bug] puppeteer-extra-plugin-stealth cannot bypass meet.google.com protection with Chrome 122 #898
Comments
This is a issue I am experiencing. Are there any workarounds? |
I am also very concerned about how this issue is progressing, and I still cannot successfully enter googlemeet. |
I am also facing same issue. Anyone solved it yet ? |
They detect iframe is forged + cds changed. Instead
Use
|
That's great. Thanks for the solution. |
@vladtreny thanks, let me try |
@vladtreny I 've checked what you suggest and it still not work in headless mode |
I have succeeded in using this method. You must have made a mistake. Did you use "page.setUserAgent"? If so, please do not setUserAgent |
@Mrkk1 Oh thanks very much, it work now. You totally saved me :V |
Hahahaha, we are all helping each other |
I have found a workaround in running chrome with |
I have checked again and now i dont use anything else just: const puppeteer = require("puppeteer-extra");
const StealthPlugin = require("puppeteer-extra-plugin-stealth");
puppeteer.use(StealthPlugin()); And run in headless mode, everything working ok. So weird because i remeber trying that before but not work "puppeteer": "^22.1.0", |
That's what I did before. I couldn't get in. I think Google did something yesterday and stopped testing. |
In order to stabilize the operation, I feel that I will no longer change the code, but will always adopt the solution of deleting cds before. |
import puppeteer from "puppeteer-extra"; const prisma = new PrismaClient(); const pp = Stealth(); pp.enabledEvasions.delete('iframe.contentWindow'); puppeteer.use(pp); export const scrapeExtraInfoBySymbol = async () => { try {
} catch (err) { // Utility function to generate a random number between a given range export const startScraping = (time) => { hey can you guys look at the code i have tried everything but still data is not loading on the website am i doing something wrong |
Try to remove argument |
Still not working sometimes it just randomly works like 1 in 10-15 times
|
Remove all args in
|
tried it still not working 🙁 |
Probably your IP is detected or rate limited. |
add this line after the page created
|
Wow ! The only solution that worked, thanks for the help |
So I have just spent the last few days solving my evasion issues. It's been a serious challenge. I have been using the following websites to test what issues are popping up.
After finally, successfully, integrating rebrowser patch to deal with CDP evasion and integrate it with puppeteer-extra and stealth, I finally passed all of the tests. But still, when I attempted to access Google search, I'd immediately get the dreaded recaptcha. The only sign that something was off was that the IP Address field that shows up below the recaptcha had a bunch of jumbled characters appended to it. (IP is changed for privacy of course).
I also got the same sort of thing when I connected to one of our proxies for an office in another city, but seems like the symbols change depending on your IP, but remain consistent to each IP address.
I knew for absolutely sure that it's I have literally no idea how @vladtreny figured this out, but I can confirm without a doubt that the following code solves the issue: import { type Browser, type Page } from "puppeteer";
const puppeteer = require("puppeteer");
const { addExtra } = require("puppeteer-extra");
const puppeteerExtra = addExtra(puppeteer);
const StealthPlugin = require("puppeteer-extra-plugin-stealth");
const stealth = StealthPlugin();
stealth.enabledEvasions.delete('iframe.contentWindow');
stealth.enabledEvasions.delete('media.codecs');
puppeteerExtra.use(stealth); I can also confirm that you must turn off both the Another confirmation (at least for me) is that headless mode is not required for evasion. However I have to admit, I've done a significant amount of customisation to make my browser look legitimate, so there's a chance that this won't apply to everyone by default. I just want to write off other solutions to this problem for now: await page.evaluateOnNewDocument(() => delete Function.prototype.toString)
await page.setBypassCSP(true) // Ensure CSP is bypassed Doesn't seem to work. In fact, bypassing CSP is suspicious, and I've specifically set it to false. Though it might help some people. Somehow I highly doubt that deleting So thank you very much vlad, for the excellent and auspiciously timely solution. Side note: Anyone working on a similar thing should be aware. |
Describe the bug
puppeteer-extra-plugin-stealth
package works onhttps://meet.google.com
website with puppeteer version 22.1.0 (Chrome for testing version 121.0.6167.85). However, when using puppeteer 22.2.0 (Chrome for testing version 122.0.6261.57), the website detects automation tool usage and blocks the access. Looks like either some old tricks stopped working or some new ways of detection were added.Code Snippet
To reproduce the issue, save the following code into
test.js
file and runnode test.js
, while having the following dependencies in package.json:To verify that it works with older versions of Chrome, just replace
puppeteer
version inpackage.json
:Versions
The text was updated successfully, but these errors were encountered: