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

在子域下设置父域cookie失败 #31

Open
hi-liuyj opened this issue Jul 27, 2020 · 0 comments
Open

在子域下设置父域cookie失败 #31

hi-liuyj opened this issue Jul 27, 2020 · 0 comments

Comments

@hi-liuyj
Copy link

步骤:

  1. 跳转到login页面
driver.url("https://login.test.com")
  1. set cookie
// 失败
driver.cookie("ticket", "something", {
  domain: 'test.com'
}) 
// 成功
driver.cookie("ticket", "something", {
  domain: 'login.test.com'
}) 
  1. 尝试直接通过document.cookie设置,可以成功

问题

  1. 是否支持子域设置父域cookie,该怎么做?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant