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

Does not work Stealth Plugin #58

Open
KebabGGbab opened this issue Oct 15, 2023 · 0 comments
Open

Does not work Stealth Plugin #58

KebabGGbab opened this issue Oct 15, 2023 · 0 comments

Comments

@KebabGGbab
Copy link

KebabGGbab commented Oct 15, 2023

Hello, I connect everything according to the example, including the Stealth Plugin. To try, I log in to https://google.com, but something goes wrong and the site won’t let me through. I’m writing because I don’t understand what the problem could be, I tried it in JavaScript and it worked.
Code:

            using BrowserFetcher browserFetcher = new BrowserFetcher();
            await browserFetcher.DownloadAsync();
            PuppeteerExtra extra = new PuppeteerExtra().Use(new StealthPlugin()).Use(new AnonymizeUaPlugin());
            using var browser = await extra.LaunchAsync(new LaunchOptions()
            {
                Headless = false,
                ExecutablePath = "C:\\Program Files\\Google\\Chrome\\Application\\chrome.exe",
                UserDataDir = $"D:\\program\\ProjectsVS\\DiscordBot\\Cookie\\{numberAcc}",
                DefaultViewport = null,
                Args = new[] {
                    "--disable-extensions-except=D:\\program\\ProjectsVS\\DiscordBot\\Extensions\\2captcha-solver-main",
                    "--load-extension=D:\\program\\ProjectsVS\\DiscordBot\\Extensions\\2captcha-solver-main",
                    "--no-sandbox",
                    "--disable-GPU",
                    $"--proxy-server={addressProxy}:{portProxy}"
                }
            });

            using var page = await browser.NewPageAsync();

            await page.SetUserAgentAsync(userAgent);
            await page.AuthenticateAsync(new Credentials(){
                Username = loginProxy,
                Password = passwordProxy
            });

            await page.GoToAsync(InviteLink, waitUntil: WaitUntilNavigation.DOMContentLoaded);

Response from the site: "This browser or app may not be secure. Learn more
Try using a different browser. If you're already using a supported browser, you can try again to sign in."

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

No branches or pull requests

1 participant