Question
VMIA
AU
Last activity: 16 Oct 2018 12:03 EDT
Logoff on requestor timeout not working correctly
Hi All,
I have a requirement where I need to log off the user from the application after a given amount of inactive time. The environment is configured to run via SAML SSO.
We shouldn't be reauthenticating the SSO session again after timeout but rather redirecting the user to the logoff screen after timeout.
If I am correct in my assumption there should ideally be 2 ways to do this.
1) Change the values in the pxSessionTimer html fragment and embed it in a section in the portal. We dont want to go with this approach as this behaviour should be controlled via the kingd of access the user has to the system
2) Define an authentication timeout time in the access group. The SAML authentication rule is then configured to run the logoff activity on authentication timeout which it gets from the access group of the user.
While trying to use the 2nd approach, While Requestor is getting ended the logoff screen doesn't seem to show, we are getting log errors, which I have attached.
ERROR MESSAGES
Hi All,
I have a requirement where I need to log off the user from the application after a given amount of inactive time. The environment is configured to run via SAML SSO.
We shouldn't be reauthenticating the SSO session again after timeout but rather redirecting the user to the logoff screen after timeout.
If I am correct in my assumption there should ideally be 2 ways to do this.
1) Change the values in the pxSessionTimer html fragment and embed it in a section in the portal. We dont want to go with this approach as this behaviour should be controlled via the kingd of access the user has to the system
2) Define an authentication timeout time in the access group. The SAML authentication rule is then configured to run the logoff activity on authentication timeout which it gets from the access group of the user.
While trying to use the 2nd approach, While Requestor is getting ended the logoff screen doesn't seem to show, we are getting log errors, which I have attached.
ERROR MESSAGES
2017-06-08 18:14:29,957 [jsse-nio-8443-exec-7] [ STANDARD] [ ] [ UATDefects:01.01.01] (ngineinterface.service.HttpAPI) ERROR dev3.spps-ptv.net| : com.pega.pegarules.pub.PRRuntimeException
com.pega.pegarules.pub.PRRuntimeException: No failure response set by custom authentication activity
at com.pega.pegarules.session.internal.mgmt.authentication.SchemePRCustom.onAuthenticationFailure(SchemePRCustom.java:972)
at com.pega.pegarules.session.internal.mgmt.authentication.Authentication.doAuthentication(Authentication.java:664)
at com.pega.pegarules.session.internal.engineinterface.service.HTTPAuthenticationHandler.performAuthentication(HTTPAuthenticationHandler.java:247)
at com.pega.pegarules.session.internal.engineinterface.service.HTTPAuthenticationHandler.doHttpReqAuthentication(HTTPAuthenticationHandler.java:136)
at com.pega.pegarules.session.internal.engineinterface.service.HttpAPI.handleAuthentication(HttpAPI.java:2120)
at com.pega.pegarules.session.external.engineinterface.service.EngineAPI.activityExecutionProlog(EngineAPI.java:549)
at com.pega.pegarules.session.external.engineinterface.service.EngineAPI.processRequestInner(EngineAPI.java:388)
at sun.reflect.GeneratedMethodAccessor72.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.pega.pegarules.session.internal.PRSessionProviderImpl.performTargetActionWithLock(PRSessionProviderImpl.java:1301)
at com.pega.pegarules.session.internal.PRSessionProviderImpl.doWithRequestorLocked(PRSessionProviderImpl.java:1038)
at com.pega.pegarules.session.internal.PRSessionProviderImpl.doWithRequestorLocked(PRSessionProviderImpl.java:893)
at com.pega.pegarules.session.external.engineinterface.service.EngineAPI.processRequest(EngineAPI.java:331)
at com.pega.pegarules.session.internal.engineinterface.service.HttpAPI.invoke(HttpAPI.java:825)
at com.pega.pegarules.session.internal.engineinterface.etier.impl.EngineImpl._invokeEngine_privact(EngineImpl.java:327)
at com.pega.pegarules.session.internal.engineinterface.etier.impl.EngineImpl.invokeEngine(EngineImpl.java:270)
at com.pega.pegarules.session.internal.engineinterface.etier.impl.EngineImpl.invokeEngine(EngineImpl.java:247)
at com.pega.pegarules.priv.context.JNDIEnvironment.invokeEngineInner(JNDIEnvironment.java:278)
at com.pega.pegarules.priv.context.JNDIEnvironment.invokeEngine(JNDIEnvironment.java:223)
at com.pega.pegarules.web.impl.WebStandardImpl.makeEtierRequest(WebStandardImpl.java:594)
at com.pega.pegarules.web.impl.WebStandardImpl.doPost(WebStandardImpl.java:390)
at sun.reflect.GeneratedMethodAccessor71.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.pega.pegarules.internal.bootstrap.PRBootstrap.invokeMethod(PRBootstrap.java:370)
at com.pega.pegarules.internal.bootstrap.PRBootstrap.invokeMethodPropagatingThrowable(PRBootstrap.java:411)
at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethodPropagatingThrowable(AppServerBridgeToPega.java:224)
at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethod(AppServerBridgeToPega.java:273)
at com.pega.pegarules.internal.web.servlet.WebStandardBoot.doPost(WebStandardBoot.java:121)
at com.pega.pegarules.internal.web.servlet.WebStandardBoot.doGet(WebStandardBoot.java:92)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:635)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:742)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:192)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:165)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:478)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:80)
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:624)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:341)
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:799)
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:861)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1455)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:745)
STEPS TO REPRODUCE
1) Save Code-Security.LogOff in same class with application ruleset. Name could remain same or different name can also be used.
2) In the Saved as version of default pega "LogOff" activity, remove 1st step that checks for SSO Login.
3) Create "LogOffSSOWrapper" activity which calls earlier created copy of "LogOff" without 1st step. Give the step page as "pyDisplayHarness". In pages and classes declare "pyDisplayHarness"of class "Data-Portal"
4) Create test access group with access to said application and define Authentication Timeout in advanced tab as "30" (i.e. 30 Seconds). Keep portal as "Developer".
5) Configure SSO user's default access group as above created.
6) Login with SSO Url.
7) After logging into developer portal, do not do anything. Minimize window if required. Wait for 30 seconds (or whatever time out value is defined in access group).
8) After 30 seconds, go into open developer portal. The portal will still show pega developer portal Home.
9) Click on any link in the portal. Link will not work. No new rule can be opened nothing can be done. [which means requestor session is over]
***Updated by moderator: Lochan to remove IP address***
**Moderation Team has archived post**
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.