session-timeout

ASP.NET: How to Detect Authentication Timeout

浪子不回头ぞ 提交于 2019-12-04 03:34:11
I've seen multiple articles like this one that explain how to detect that a user's session has timed out. And for clarity's sake, these articles are referring to the timeout value defined by this web.config line: <sessionState mode="InProc" cookieless="UseDeviceProfile" timeout="120" /> Not to get into that method too much, but this involves checking that Session.IsNewSession is true and that a session cookie already exists. But I haven't seen any articles on how to detect authentication timeout -- the one defined by this web.config line: <authentication mode="Forms"> <forms loginUrl="~/Home

How to delete/unset a cookie on php?

旧城冷巷雨未停 提交于 2019-12-04 02:55:49
问题 I want to unset/delete my existing cookie with this: setcookie ("user", "", time()-1); unset($user); But cookies can not be deleted or unset. So what is problem? 回答1: you can unset cookies this way only may -1 not work try this setcookie ("user", "", time() - 3600); 回答2: When deleting a cookie you should assure that the expiration date is in the past. Delete example: // set the expiration date to one hour ago setcookie("user", "", time()-3600); 回答3: Nothing - that code looks fine to me.

What is the different between Session Timeout and Idle Timeout in IIS?

天大地大妈咪最大 提交于 2019-12-04 01:13:24
In IIS, Select Default Web Site > Properties > Home Directory > Application Settings > Configuration > Options, the default Session timeout is 20 minutes. Also, Select Application Pools > DefaultAppPool > Properties, in the Performance tab, there is Idle timeout which is default to 20 minutes too. What is the different between those two timeouts? Jay The idle timeout determines if, and if so after how many minutes of idle time an AppPool is recycled. Recycling the AppPool frees resources but also means that all cached data (compiled version of ASP.NET applications etc.) of sites that run under

How can you display a session timeout warning that is smart enough to handle multiple open browsers or tabs

强颜欢笑 提交于 2019-12-03 23:01:37
I have implemented a session timeout warning using javascript that simply asks the user if they want to extend their session or logout. The problem is that this is for an intranet portal where power users will often have several browser windows or tabs open at the same time to the application. Currently, they will be prompted that they are about to be logged out from every browser window. How can I make the code smarter to detect that they are actively using another browser session? You'd have to check the session state on the server using Ajax and keep track of all the open sessions/windows

php session destroyed in android application

喜你入骨 提交于 2019-12-03 20:41:54
I am building a login application in android in which i am hitting a url(with username and password) upto that part it works fine but after that whenever I am hitting a url(once the user is authenticated) , it return nothing(i.e. a error message like please login first). However it works fine in very similar iphone app and on browser. I could not understand that what is the actual problem. Is there any problem on server side(i.e. in php coding ) or there is something wrong with android app. We cant actually blame the server side coding because it works fine for same iphone app and on browser.

How to handle expired session using Spring Security and jQuery?

梦想的初衷 提交于 2019-12-03 18:29:55
问题 I'm using Spring Security and jQuery in my application. Main page uses loading content dynamically into tabs via AJAX. And all is OK, however sometimes I've got the login page inside my tab and if I type credentials I will be redirected to the content page without tabs. So I'd like to handle this situation. I know some of the people use AJAX authentication, but I'm not sure it's suitable for me because it looks quite complicated for me and my application doesn't allow any access without log

Strange Timeout in Sitecore 7

北战南征 提交于 2019-12-03 15:04:17
I've been using Sitecore version 7.1 for a few months now and have noticed that the Sitecore client logs me out after being idle for around 20 mins. Also other users have reported these issues whilst content editing. I'm using Windows 7, IIS 7, .NET framework 4.5. I've checked the error log for anything and can see no obvious errors and the keepalive service is running - I get this information in the logs: ManagedPoolThread #14 12:47:24 INFO Scheduling.UrlAgent started. Url:http://testsite/sitecore/service/keepalive.aspx I get some of these in the log, but could this be related? WARN Memory

how to redirect to new page after jquery ajax call in MVC if session timeout?

旧巷老猫 提交于 2019-12-03 13:15:30
问题 1- I have an Ajax link that call an action and that action returns a view , that view open in a specific Div (consider it as a menu that update the div with the corresponding view) 2- if session timeout the returned my logon view so if i click on the link and session is timeout , the log on view open in the div not in the whole page what i should do so if the session timeout it return logon view in new page in on my div? 回答1: An efficient way to handle a session expiry is to create a custom

View /page.jsf could not be restored [duplicate]

℡╲_俬逩灬. 提交于 2019-12-03 08:15:23
This question already has answers here : javax.faces.application.ViewExpiredException: View could not be restored (10 answers) I have problem which I cannot solve. When I refresh opened JSF page after the page is idle for example 10 minutes I get this error message: serverError: class javax.faces.application.ViewExpiredException viewId:/page.jsf - View /page.jsf could not be restored. How I can increase the JSF View time? You can set your session timeout parameter to 45 minute in web.xml like this <session-config> <session-timeout>45</session-timeout> </session-config> also you can easily

Rest call on expired session: HTTP 401 response causes browser to display login window

人盡茶涼 提交于 2019-12-03 06:54:02
I have written a HTML 5 application that uses AngularJS and interfaces with a Java REST backend running on Tomcat. I use Spring Security to handle login and security. When the user enters the website he is forwarded to a login page which creates a session and redirects to the index page. The REST calls that loads further data from the server then uses that session to authenticate. If there is no session in place, I fallback to basic authentication over HTTP, such that it is possible to invoke the REST endpoints separately from the web application. The problem I have now is when the session