What I am doing is I set both alfresco and share to session time out time 60 minutes in their web.xml file.
My scenario is
- When I want to start a workflow in Start Workflow page, I fill all
necessary data but do not click “Start Workflow” button.- After session time out, I click this “Start Workflow” button.
- At the first time, authentication box opens and request for username
and password.- I filled user name and password of another user.
- It starts a workflow with the authenticated another user.
- Other times for session timeout, it does not request authentication
box, but acts for previously requested authenticated user.
So I think Why does it happen??? Is it because of cookie??
Currently there are four cookies used, namely alfLogin, alfUsername2, JSSESSIONID, _alfTest. Only when user is logged out, alfUsername2 cookie is deleted and others are remained.alfLogin and alfUsername2 cookies’ expire time is 7 days and other cookie are depends on session.
Can alfresco web script still be used after session timeout? If so, how can I avoid this condition?
Although I have to answer my own question, I just want to share my result. I have to trace much. But answer is so simple.
Firstly, it is not because of cookie.
This answer is not only just for clicking “Start Workflow” button but also calling alfresco webscript after session time out in share.
All calling to alfresco webscript is done by
EndPointProxyControllerspecificallyorg.springframework.extensions.webscripts.servlet.mvc.EndPointProxyControllerinspring-webscripts-1.0.0-sources.jar.In
handleRequestInternalmethod if there is no session and basicHttpAuthChallenge is true, basic authentication box is shown as below.We can avoid this condition as
Like