ASP.NET session id shared amongst browser tabs

前端 未结 6 1023
情深已故
情深已故 2021-01-05 01:42

I\'ve recently been developing a website using asp.net webforms that uses in proc sessions and I noticed that session ids are shared amongst browser tabs. So I was wondering

6条回答
  •  渐次进展
    2021-01-05 02:12

    All tabs in a browser belong to the same instance, so all tabs share cookies and sessions, there isnt much you can do about it. If you want to implement this badly the only solution that comes to mind is carrying a unique session id with each URL. Based on that unique id you can link a specific user. You will need customize the session logic and would have to make sure all links in your website carry this unique id. It could be done with alot of effort but the real question is , is it worth doing?

提交回复
热议问题