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

Add an option to customize cookie settings after log in. #74

Closed
pongstr opened this issue Jul 21, 2015 · 1 comment
Closed

Add an option to customize cookie settings after log in. #74

pongstr opened this issue Jul 21, 2015 · 1 comment

Comments

@pongstr
Copy link
Contributor

pongstr commented Jul 21, 2015

Hello there, I was wondering if there's any way to customize the Cookie Settings after log in? I tried to customize this via app.session so I can use these cookies to sub domain (e.g., *.mydomain.com), but after login the access_token and userId cookies is set to mydomain.com.

res.cookie('access_token', info.accessToken.id,
  {
    signed: req.signedCookies ? true : false,
    maxAge: 1000 * info.accessToken.ttl,

    // Domain Option Here
    domain: '.mydomain.com'
  });
res.cookie('userId', user.id.toString(), {
  signed: req.signedCookies ? true : false,
  maxAge: 1000 * info.accessToken.ttl,

  // And maybe another one here?
  domain: '.mydomain.com'
});
@pongstr
Copy link
Contributor Author

pongstr commented Aug 6, 2015

Resolved with f577431 #75

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