0

In Selenium Chromedriver added proxy, fake user agent, disabled Webrtc by extension, spoofed Webgl with selenium-stealth, spoofed time zone and language as follows:

driver.execute_cdp_cmd('Emulation.setTimezoneOverride', tz_params)
options.add_experimental_option('prefs', {'intl.accept_languages': language})

so that on https://pixelscan.net/ my browser is not detected as a bot. But it works only on one(first) tab opened. On the website I work with the authorization window pops up, which does not save all the settings that are necessary for the browser to remain undetectable (of the above remains only the proxy and useragent) How to make these parameters work on pop-up windows opened by a website? I would also be glad if there are any alternative libraries that can help me achieve the desired result

I found a way out - an extension that changes my location and language depending on what country my ip address is. Unfortunately, such an extension for WebGL I have not found, only those that change drivers WebGL to random values (I need the values specified by me)

undetected Selenium
  • 183,867
  • 41
  • 278
  • 352
Eugene
  • 43
  • 5

1 Answers1

0

selenium-stealth settings is effective only on the first tab and the settings doesn't propogates to the subsequent tabs or window handles is a known issue for quite some time now.

This issue is being actively tracked through the discussion Settings doesn't apply on all tabs (but only on the first one)

undetected Selenium
  • 183,867
  • 41
  • 278
  • 352
  • The settings work if I separately call tab: `driver.execute_script(f'window.open("https://www.google.com/")')`. But how do I call the randomly generated popup window? – Eugene Feb 08 '23 at 11:57
  • In my [tag:windows-10] setup even with `execute_script()` the settings won't propogate. – undetected Selenium Feb 08 '23 at 12:13
  • It works for me, I'm using Mac OS now. Well, I'll try replacing it with undetectable_chromedriver – Eugene Feb 08 '23 at 12:28