fix: enhance stealth mode with additional anti-detection measures
Add 7 new init scripts to cover WebGL fingerprinting, missing Chrome APIs, permissions behavior, CDP artifacts, and HeadlessChrome UA string. Enable Chromium's new headless mode (Channel: "chromium") when stealth is active to use the full UI layer that is harder to detect. Closes #58 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -92,6 +92,9 @@ func initBrowser(opt BrowserOptions) (*browserInitResult, error) {
|
||||
if len(launchArgs) > 0 {
|
||||
launchOpts.Args = launchArgs
|
||||
}
|
||||
if stealth && opt.Browser == BrowserChromium && headless {
|
||||
launchOpts.Channel = playwright.String("chromium")
|
||||
}
|
||||
browser, err = bt.Launch(launchOpts)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to launch browser: %w", err)
|
||||
|
||||
Reference in New Issue
Block a user