[java-identity-provider COMMIT] /trunk/idp-cas-impl/src/main/java/net/shibboleth/idp/cas/flow/impl/UpdateIdPSessionWi...

noreply at shibboleth.net noreply at shibboleth.net
Tue Sep 20 11:03:28 EDT 2016


Author: serac
Date: Tue Sep 20 11:03:27 2016
New Revision: 8407

URL: http://svn.shibboleth.net/view/java-identity-provider?rev=8407&view=rev
Log:
IDP-996 Trap runtime exceptions due to misconfig.

https://issues.shibboleth.net/jira/browse/IDP-996
A ConstraintViolationException can arise in the case where a client-oriented
StorageService is configured for session storage, yet the CAS service has the
singleLogoutParticipant flag set. This is a symptom misconfiguration, but should
not cause ticket validation to fail. Log a warning in this case.

Modified:
    trunk/idp-cas-impl/src/main/java/net/shibboleth/idp/cas/flow/impl/UpdateIdPSessionWithSPSessionAction.java

Modified: trunk/idp-cas-impl/src/main/java/net/shibboleth/idp/cas/flow/impl/UpdateIdPSessionWithSPSessionAction.java
URL: http://svn.shibboleth.net/view/java-identity-provider/trunk/idp-cas-impl/src/main/java/net/shibboleth/idp/cas/flow/impl/UpdateIdPSessionWithSPSessionAction.java?rev=8407&r1=8406&r2=8407&view=diff
==============================================================================
--- trunk/idp-cas-impl/src/main/java/net/shibboleth/idp/cas/flow/impl/UpdateIdPSessionWithSPSessionAction.java	(original)
+++ trunk/idp-cas-impl/src/main/java/net/shibboleth/idp/cas/flow/impl/UpdateIdPSessionWithSPSessionAction.java	Tue Sep 20 11:03:27 2016
@@ -93,8 +93,8 @@
         try {
             log.debug("Attempting to retrieve session {}", ticket.getSessionId());
             session = sessionResolver.resolveSingle(new CriteriaSet(new SessionIdCriterion(ticket.getSessionId())));
-        } catch (ResolverException e) {
-            log.warn("Cannot store CASSPSession due to IdPSession resolution error: {}", e);
+        } catch (Exception e) {
+            log.warn("IdPSession resolution error: {}. Possible sign of misconfiguration.", e.getMessage());
         }
         if (session != null) {
             final long now = System.currentTimeMillis();
@@ -110,7 +110,7 @@
                 log.warn("Failed updating IdPSession with CASSPSession", e);
             }
         } else {
-            log.warn("Cannot store CASSPSession since IdPSession not found");
+            log.info("Cannot store CASSPSession since IdPSession not found");
         }
         return null;
     }



More information about the commits mailing list