0

We have an internal web application that I am trying to automate using Selenium and BrowserStack, in C#.

I have managed to use BrowserStack's 'local' functionality to get at the application but I'm now hitting a basic authentication popup (see below for a similar example):

authentication popup

I don't encounter this when running it locally (as it'll just pick up my own credentials).

I've done some scouting around on here and elsewhere and seen this sort of question asked many times. However, many answers are old and revolve around the "http://user:password@[address]" approach which is now deprecated in Chrome 59+ (I'm using 80). I also plan on executing tests in MS Edge.

Any ideas on a more modern solution? I've seen custom Chrome extensions mentioned. Is this the only viable solution for this scenario? Is there an equivalent for MS Edge?

  • you could use chrome profile, also could you please explain what kind of pop up you are getting – PDHide Feb 18 at 16:57
  • Sorry, forgot to add that. Have amended question. – Moorpheus Feb 18 at 17:00
  • Does Approach 3 here help at all? softwaretestingmaterial.com/handle-authentication-popup-window – Kate Paulk Feb 18 at 18:42
  • I have tried switching to the alert, and also active element, but neither approach seems to have an impact on sending keys through to the popup unfortunately :( – Moorpheus Feb 19 at 13:27
2

This is normally done by injecting authorization headers into the outgoing packets. However BrowserStack seems not having this feature in their nearest roadmap.

enter image description here

| improve this answer | |
0

Basic auth works with Chrome 80, 79, 78.., 75

I verified this till Chrome v75, on BrowserStack also this works like charm

Please check if there is any special character in the basic auth credentials

| improve this answer | |
0

Basic Auth via url was deprecated and even removed in some version of chome. But then they revert this functionality back and now you can use it.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.