gpt4 book ai didi

java - 如果用户登录并关闭窗口并使用不同的帐户 ID 登录,则两个用户的 session 相同

转载 作者:行者123 更新时间:2023-12-01 13:11:25 25 4
gpt4 key购买 nike

让我们考虑一个用户登录站点并关闭窗口的场景。现在,他使用不同的用户 ID 登录该网站。第二个用户的 session ID 和第一个用户的 ID 相同吗?

最佳答案

A session ID is a unique number that a Web site's server assigns a specific user for the duration of that user's visit (session). The session ID can be stored as a cookie, form field, or URL (Uniform Resource Locator). Some Web servers generate session IDs by simply incrementing static numbers. However, most servers use algorithms that involve more complex methods, such as factoring in the date and time of the visit along with other variables defined by the server administrator.

Every time an Internet user visits a specific Web site, a new session ID is assigned. Closing a browser and then reopening and visiting the site again generates a new session ID. However, the same session ID is sometimes maintained as long as the browser is open, even if the user leaves the site in question and returns. In some cases, Web servers terminate a session and assign a new session ID after a few minutes of inactivity.

来自HERE

关于java - 如果用户登录并关闭窗口并使用不同的帐户 ID 登录,则两个用户的 session 相同,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22834156/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com