Solved

SharePoint Session Timeout

Posted on 2004-08-23
1
1,771 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 50 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

Forrester Webinar: xMatters Delivers 261% ROI

Guest speaker Dean Davison, Forrester Principal Consultant, explains how a Fortune 500 communication company using xMatters found these results: Achieved a 261% ROI, Experienced $753,280 in net present value benefits over 3 years and Reduced MTTR by 91% for tier 1 incidents.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Obsolete font tag need to convert to CSS 3 54
Record locking on classic ASP 3 64
ReadyAPI 1.9.0 2 42
website linking 3 22
Get to know the ins and outs of building a web-based ERP system for your enterprise. Development timeline, technology, and costs outlined.
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

737 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