I am getting the "save password" dialog when creating a ChromeDriver like this:
var options = new ChromeOptions();
options.AddArguments("chrome.switches", "--disable-extensions --disable-extensions-file-access-check --disable-extensions-http-throttling --disable-infobars --enable-automation --start-maximized");
var driver = new ChromeDriver(options);
And navigates to a login form and submit it.
How do I get rid of the popup?
Can a website detect when you are using selenium with chromedriver? Yes. Also, what I haven't experimented with is older selenium and older browser versions - in theory, there could be something implemented/added to selenium at a certain point that Distil Networks bot detector currently relies on.
browser. close() will close only the current chrome window. browser. quit() should close all of the open windows, then exit webdriver.
The answer is No. You have to have the chrome application inside your computer.
ChromeDriver is a separate executable that Selenium WebDriver uses to control Chrome. It is maintained by the Chromium team with help from WebDriver contributors. If you are unfamiliar with Selenium WebDriver, you should check out the Selenium site.
You need to add these preferences:
options.AddUserProfilePreference("credentials_enable_service", false);
options.AddUserProfilePreference("profile.password_manager_enabled", false);
So your final code will look like this:
var options = new ChromeOptions();
options.AddArguments("chrome.switches", "--disable-extensions --disable-extensions-file-access-check --disable-extensions-http-throttling --disable-infobars --enable-automation --start-maximized");
options.AddUserProfilePreference("credentials_enable_service", false);
options.AddUserProfilePreference("profile.password_manager_enabled", false);
var driver = new ChromeDriver(options);
Here is this same solution adapted to Java, as used in my code. Adapting was non-trivial so sharing here in case other Java users read this:
ChromeOptions chOption = new ChromeOptions();
chOption.addArguments("--disable-extensions");
chOption.addArguments("test-type");
Map<String, Object> prefs = new HashMap<String, Object>();
prefs.put("credentials_enable_service", false);
prefs.put("profile.password_manager_enabled", false);
chOption.setExperimentalOption("prefs", prefs);
driver = new ChromeDriver(chOption);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With