Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please offer a solution for basic authentication #6644

Closed
AndreasKarz opened this issue Nov 12, 2018 · 9 comments
Closed

Please offer a solution for basic authentication #6644

AndreasKarz opened this issue Nov 12, 2018 · 9 comments

Comments

@AndreasKarz
Copy link

AndreasKarz commented Nov 12, 2018

Meta -

OS:

Selenium Version:

Browser:

Browser Version:

Expected Behavior -

Please finally make it possible that it is possible to send a header with the method GoToUrl(). This is the only really working possibility for Basic Authentication. Because tools like AutoIt don't work on BrowserStack etc.

Actual Behavior -

There is no way to send a header. And the complete problem is open since 2016!!!
SeleniumHQ/selenium-google-code-issue-archive#34
We are thinking about to change to Ranorex -- with this issues we can't work professional.

Steps to reproduce -

@jimevans
Copy link
Member

You mean using something like a solution using a proxy? You haven’t said, but guessing that you’re using C#, there are example repositories that demonstrate using a proxy to accomplish lots of tasks that may nor be possible with Selenium.

@AndreasKarz
Copy link
Author

AndreasKarz commented Nov 12, 2018

Jim, sorry -- I have not read all the content of you solution, sorry.
I think, this is it, what I looking for. I will test tomorrow and then I give you a feedback.

LG

Andreas

@shs96c
Copy link
Member

shs96c commented Nov 12, 2018

To do this in a cross-browser way that provides a pleasant user API is distinctly non-trivial, but we're working on it, as w3c/webdriver#385 shows.

It turns out that not every browser has a mechanism for simply "implementing a header function so that the tool can be used professionally". Personally, I'm tempted to blame those amateurs who've poured years of effort into the blasted things.

More seriously, @AndreasKarz, we know this is something that people really want, and it's something that we really want too. If you'd like to help us push it over the line, contributing to the W3C webdriver spec would be an excellent first step: it's on GitHub and run in the open specifically to enable this kind of collaboration.

@unverified-contact
Copy link

Are there any hacks or workarounds to be able to do this kind of thing in the meanwhile? Maybe there's a (semi) neat way to achieve this effect with a plugin or something similar?

@walter-hernandez
Copy link

@shs96c @AndreasKarz in the w3c/webdriver#385, in the last comment, they are welcoming the writing of the prose and merged of the change. @AndreasKarz it would be a great contribution to a highly demanded spec in the W3C webdriver and hence, selenium

@ghost
Copy link

ghost commented May 30, 2020

Following

@ArmandoAssuncao
Copy link

ArmandoAssuncao commented Jun 27, 2021

While is not is done, i created this code that work:

https://gist.github.com/ArmandoAssuncao/51edbbdc8dc2e8e6ac8c16c2847ed960

@diemol
Copy link
Member

diemol commented Nov 2, 2021

While not a cross browser solution yet, as we are still heading in that direction with WebDriver BiDi, for now this can be done on Chromium based browsers, see the example at https://www.selenium.dev/documentation/webdriver/bidi_apis/#register-basic-auth

@diemol diemol closed this as completed Nov 2, 2021
@github-actions
Copy link

github-actions bot commented Dec 3, 2021

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked and limited conversation to collaborators Dec 3, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

8 participants