Skip to main content
2 of 3
Updated answer
undetected Selenium
  • 194.5k
  • 44
  • 304
  • 387

In case the Selenium driven ChromeDriver initiated Browsing Context is getting redirected to the page...

Attention Required! | Cloudflare...

... this implies that a Cloudflare program is blocking your program from accessing the AUT (Application under Test).


Analysis

There can be several reasons behind Cloudflare blocking the access as follows:

The access can be denied due to the following factors:

  • Cloudflare is trying to counter a possible Dictionary attack.
  • Your system IP is black listed by Cloudflare for mining Bit coins or Monero coins using your system.

In these cases eventually you are redirected to a captcha page.


Solution

In these cases the a pottential solution would be to use the undetected-chromedriver to initialize the Chrome Browsing Context.

undetected-chromedriver is an optimized Selenium Chromedriver patch which does not trigger anti-bot services like Distill Network / Imperva / DataDome / Botprotect.io. It automatically downloads the driver binary and patches it.

  • Code Block:

    import undetected_chromedriver as uc from selenium import webdriver options = webdriver.ChromeOptions() options.add_argument("start-maximized") driver = uc.Chrome(options=options) driver.get('https://bet365.com') 

Alternative Solution

In these cases the solution is to whitelist your IP address through the Project Honey Pot website and you can find the end-to-end process detailed out in the video tittled Attention Required one more step captcha CloudFlare Error.

undetected Selenium
  • 194.5k
  • 44
  • 304
  • 387