Improve reCaptcha 2.0 solving automation script (Selenium) Improve reCaptcha 2.0 solving automation script (Selenium) selenium selenium

Improve reCaptcha 2.0 solving automation script (Selenium)


you can't do that, I think the image obstacle is used when too many requests are done from the same IP anyway, so you can't bypass it, what you can do is use proxies


Here is my solution:

# -*- coding: utf-8 -*-from selenium import webdriverfrom selenium.webdriver import ActionChainsfrom selenium.webdriver.common.by import Byfrom selenium.webdriver.support import expected_conditions as ecfrom selenium.webdriver.support.ui import WebDriverWaitdriver = webdriver.Chrome()driver.get(url='https://www.google.com/recaptcha/api2/demo')# find iframecaptcha_iframe = WebDriverWait(driver, 10).until(    ec.presence_of_element_located(        (            By.TAG_NAME, 'iframe'        )    ))ActionChains(driver).move_to_element(captcha_iframe).click().perform()# click im not robotcaptcha_box = WebDriverWait(driver, 10).until(    ec.presence_of_element_located(        (            By.ID, 'g-recaptcha-response'        )    ))driver.execute_script("arguments[0].click()", captcha_box)