Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/selenium/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
服务器上的bot检测绕过selenium_Selenium_Selenium Webdriver_Selenium Chromedriver_Botdetect - Fatal编程技术网

服务器上的bot检测绕过selenium

服务器上的bot检测绕过selenium,selenium,selenium-webdriver,selenium-chromedriver,botdetect,Selenium,Selenium Webdriver,Selenium Chromedriver,Botdetect,大家好我有问题 我想在服务器上使用selenium。因此,我成功地使用Dockerfile在linux环境中安装了chrome驱动程序,并使用下面的关键字执行它 RUN apt-get -y install google-chrome-stable RUN wget https://chromedriver.storage.googleapis.com/89.0.4389.23/chromedriver_linux64.zip RUN unzip chromedriver_linux64.zi

大家好我有问题

我想在服务器上使用selenium。因此,我成功地使用Dockerfile在linux环境中安装了chrome驱动程序,并使用下面的关键字执行它

RUN apt-get -y install google-chrome-stable

RUN wget https://chromedriver.storage.googleapis.com/89.0.4389.23/chromedriver_linux64.zip
RUN unzip chromedriver_linux64.zip
RUN mv chromedriver chromedriver_linux64
但是,当在服务器上发出请求时,会出现一个页面,要求解析服务以发送电子邮件并进行身份验证。它似乎已被检测为机器人,我想知道如何绕过它

绕过bot的选项如下所示,但无效。请求帮助

            options.addArguments("--no-sandbox")
            options.addArguments("--single-process")
            options.addArguments("--headless")
            options.addArguments("--disable-dev-shm-usage")

            options.setExperimentalOption("debuggerAddress", "127.0.0.1:9222")

            options.addArguments("--remote-debugging-port=9222")

如果在无头和无头之间进行检测,请尝试添加用户代理、窗口大小和禁用某些选项。