views:

162

answers:

1

In asp.net session length, can it be of a different length depending on the type of user logging in? I want admin users to timeout after 3 hours, but standard users to timeout after 30mins, because staff in the office often have multiple windows open, and requested a longer session length. I'm a little sceptical about lengthening it for the outside world.

+2  A: 

You can set the Session timeout (minutes).

 if (User.IsInRole("Admin"))
      Session.Timeout = 3 * 60;
Dead account