fysh711426 / UndetectedChromeDriver

GNU General Public License v3.0
166 stars 60 forks source link

Update UndetectedChromeDriver.cs debug port fixed #63

Closed JuliusCesar23 closed 10 months ago

JuliusCesar23 commented 10 months ago

To use a custom port with the Create() Constructor the debug port and the chromdriver port has to be the same, with this change if there is a pre set port the port listener and the chromedriver port would be the same and the can connect

fysh711426 commented 10 months ago

This port is used by service.

var service = ChromeDriverService.CreateDefaultService(
    Path.GetDirectoryName(driverExecutablePath),
    Path.GetFileName(driverExecutablePath));
if (port != 0)
    service.Port = port;
JuliusCesar23 commented 10 months ago

it is but it need to listen on that port also, try to set a port in the Constructor to see if it sets the port and opens the browser now

JuliusCesar23 commented 10 months ago

tested on chrome 115 using this chromedriver https://github.com/AntidetectBrowser/ChromeDriverBypassCloudflareForWindow

JuliusCesar23 commented 10 months ago

this change is wrong, sorry for inconveniences