开发者

get session by ID

I'm currently working on Authentication and Membership system for my Web Application. It is licensed to number of users, that can be logged on in the same time.

So I come up with concept that I will make ActiveUsers table where I will store information about logged on users with their sessio开发者_C百科ns' IDs.

Before new user can log in, application will check this table and will get all SIDs, then it will check whether particular session exists on server. If not it will delete record in table.

My question is: is there a way to check if session with particular ID exists on server?

Because HttpContext.Current.Session affects only current user.


There's a whole bunch of nifty events in Global.asax that you can probably use for deleting the row. Check out Session_OnEnd() for instance.

http://msdn.microsoft.com/en-us/library/ms178583.aspx

Edit: Just noticed that this really doesn't answer the question...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜