?
Solved

SharePoint Session Timeout

Posted on 2004-08-23
1
Medium Priority
?
1,778 Views
Last Modified: 2008-01-09
I am aware that by default, sharepoint will timeout a web part.
However, you are able to just refresh the page and provide the information again.
I would like to have the session timeout, force the user to login again.
I have read on some other threads that I should modify the web.config file to do this.

If someone could confirm this and give me a little direction on how to edit this file correctly... it would be greatly appreciated.

Thanks!
0
Comment
Question by:mmcleod1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 10

Accepted Solution

by:
avidya earned 200 total points
ID: 11875428
Hi,

Just add this in your global.asax.
'Uses the OnAcquireRequestState event so you have session vars accesible
Sub Application_OnAcquireRequestState(sender as Object, Details as EventArgs)
If Session("MyVariable") = "" Then
'Signout
FormsAuthentication.SignOut()
' Tries to Reload the page and then redirects to the Login page
Server.Transfer(Request.Url.AbsolutePath.ToString, True)
End If
End Sub


This one explains a lot about web.config:
http://authors.aspalliance.com/das/web.config.aspx#10
http://www.csharpfriends.com/Articles/getArticle.aspx?articleID=307

This one about security
http://www.15seconds.com/issue/040511.htm



if(Session["memberID"] == null)
{
Response.Redirect("redirectpage.aspx");
}
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Because your company can’t afford for you to make SEO mistakes, you’ll want to ensure you’re taking the right steps each and every time you post a new piece of content. This list of optimization do’s and don’ts can help you become an SEO wizard.
There’s a good reason for why it’s called a homepage – it closely resembles that of a physical house and the only real difference is that it’s online. Your website’s homepage is where people come to visit you. It’s the family room of your website wh…
This video teaches users how to migrate an existing Wordpress website to a new domain.
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.
Suggested Courses
Course of the Month8 days, 3 hours left to enroll

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question