-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
After upgrade to Firefox 56, addCookie function domain will change to current browser url #1025
Comments
@charlesh21 can you please test with a recent Firefox 57 beta, or even 58 nightly build, if the problem still persists for you? |
Hi @whimboo, geckodriver 0.19.0 + firefox 57.0b13
|
I think the webdriver spec is not specific enough about domain representations. RFC6265 states:
I think the problem in your case is that the cookie domain has a leading dot character which is rejected by marionette as an invalid domain. This is probably because there are no tests currently for domain values with preceding dot characters. The webdriver spec doesn't spell out whether the leading dot in the cookie domain is an accepted representation of a cookie domain, but I feel that the expectation should be that both works and as long as a domain value is provided to add cookie command it is treated as a cookie domain (and the preceding dot is normalized by the browser). This feels like a bug that should be addressed in marionette. |
@aldaris Do you mind filing an issue on w3c/webdriver? |
@andreastt I have filed a bug for Marionette: https://bugzilla.mozilla.org/show_bug.cgi?id=1415828 |
@aldaris Thank you very much. If we can support cookie domain with leading dot, that's really helpful. |
System
Testcase
After upgrade to Firefox 56, our automation testing can't add cookie correctly into Firefox.
I found the suspicious part in cookie domain, the add cookie log seems work as expected.
But after add cookie, I try to print all cookie with getCookies method. The domain changed to the browser current url.
AddCookie
"domain":".yahoo.com"
getCookies
"domain":"tw-b2.beta.mall.yahoo.com"
addCookie
getCookies
The text was updated successfully, but these errors were encountered: