Giter Site home page Giter Site logo

Comments (5)

elithrar avatar elithrar commented on June 16, 2024

from sessions.

xeoncross avatar xeoncross commented on June 16, 2024

Yes, I outlined that approach as a possible reason, I'm just not sure why that would be used as it seems like bad practice to change session's duration individually (along with not bothering to store these unique durations). That would lead to a testing nightmare and the purpose of logging accounts in/out is better served without setting lifespans unique to each session cookie.

I assume the original author had a specific use-case in mind, but perhaps it was just convenience for setting the cookie options.

from sessions.

elithrar avatar elithrar commented on June 16, 2024

from sessions.

xeoncross avatar xeoncross commented on June 16, 2024

I do think it’s a legitimate use-case to expire sessions; or set a session
cookie that only lives for that browser session based on user input
(“remember me”).

I agree they are legitimate needs, but those are usually handled in a different way than setting different session cookie timestamps for each user. Expiring session cookies can be done universally with a single Max-Age set to 0 (or negative) and doesn't need to be tracked in all fifty thousand user sessions instances. Likewise, "remember me" functionality is generally handled by a separate cookie, not a parameter stored in the users current session. In fact, sessions are usually stored server side and culled after X time periods regardless of what the client cookie says.

from sessions.

stale avatar stale commented on June 16, 2024

This issue has been automatically marked as stale because it hasn't seen a recent update. It'll be automatically closed in a few days.

from sessions.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.