I have a website that requires NTLM authentication, so I have created a FireFox profile:
FirefoxProfile profile = new FirefoxProfile();
profile.SetPreference("network.http.phishy-userpass-length", 255);
profile.SetPreference("network.automatic-ntlm-auth.trusted-uris", uri.Host);
profile.SetPreference("network.negotiate-auth.delegation-uris", uri.Host);
profile.SetPreference("network.negotiate-auth.trusted-uris", uri.Host);
driver = new FirefoxDriver(profile);
Then I navigate to page with GoToUrl method which goes fine, but when I call Refresh – authentication popup comes up. Googling around I found that it occurs if call “forced refresh”, like “Ctrl + F5” and indeed it does, even when do it manually. So, the question is how to perform a plain refresh and not forced refresh?
Thanks in advance
I don’t have a way to test if this is going to “force” refresh, but you could try refreshing directly in JS. ((JavascriptExecutor)driver).executeScript(“document.location.reload()”);