Getting below Sign in error while logging in on environment which is hosted on Azure

0
  I'm experiencing an issue with SAML authentication in Mendix. When trying to validate a response, I get the following error: Error: Could not create a session for the provided user principal. saml20.implementation.SAMLFeedbackException: Could not create a session for the provided user principal at saml20.implementation.ArtifactHandler.handleSAMLResponse(ArtifactHandler.java:215) The full stacktrace is as follows: Unable to validate Response, see SAMLRequest overview for detailed response. Error: Could not create a session for the provided user principal. saml20.implementation.SAMLFeedbackException: Could not create a session for the provided user principal.at saml20.implementation.ArtifactHandler.handleSAMLResponse(ArtifactHandler.java:215)at saml20.implementation.ArtifactHandler.handleRequest(ArtifactHandler.java:48)at saml20.implementation.SAMLRequestHandler.processRequest(SAMLRequestHandler.java:156)at com.mendix.externalinterface.connector.RequestHandler.doProcessRequest(RequestHandler.java:37)at com.mendix.external.connector.MxRuntimeConnector.$anonfun$processRequest$1(MxRuntimeConnector.scala:54)at com.mendix.external.connector.MxRuntimeConnector.$anonfun$processRequest$1$adapted(MxRuntimeConnector.scala:54)at com.mendix.util.classloading.Runner$.withContextClassLoader(Runner.scala:20)at com.mendix.external.connector.MxRuntimeConnector.processRequest(MxRuntimeConnector.scala:54)at com.mendix.basis.impl.MxRuntimeImpl.processRequest(MxRuntimeImpl.scala:233)at com.mendix.m2ee.appcontainer.server.handler.RuntimeServlet.service(RuntimeServlet.scala:40)at javax.servlet.http.HttpServlet.service(HttpServlet.java:590)at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:764)at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1665)at org.eclipse.jetty.websocket.servlet.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:170)at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:202)at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1635)at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:527)at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:221)at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1580)at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:221)at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1384)at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:176)at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:484)at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1553)at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:174)at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1306)at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:129)at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)at org.eclipse.jetty.server.Server.handle(Server.java:563)at org.eclipse.jetty.server.HttpChannel$RequestDispatchable.dispatch(HttpChannel.java:1598)at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:753)at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:501)at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:287)at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:314)at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:100)at org.eclipse.jetty.io.SelectableChannelEndPoint$1.run(SelectableChannelEndPoint.java:53)at org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.runTask(AdaptiveExecutionStrategy.java:421)at org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.consumeTask(AdaptiveExecutionStrategy.java:390)at org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.tryProduce(AdaptiveExecutionStrategy.java:277)at org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.run(AdaptiveExecutionStrategy.java:199)at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:411)at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:969)at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.doRunJob(QueuedThreadPool.java:1194)at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1149)at java.base/java.lang.Thread.run(Unknown Source)Caused by: java.lang.Exception: Single Sign On unable to create new session: Maximum number of sessions exceeded! (You are currently using a trial license)at saml20.implementation.security.SessionManager.createSession(SessionManager.java:299)at saml20.implementation.ArtifactHandler.handleSAMLResponse(ArtifactHandler.java:196)... 44 moreCaused by: com.mendix.basis.util.license.LicenseRuntimeException: Maximum number of sessions exceeded! (You are currently using a trial license)at com.mendix.basis.util.license.LicenseUtil.checkTrialLimitation(LicenseUtil.scala:111)at com.mendix.basis.util.license.LicenseUtil.checkUserLimitations(LicenseUtil.scala:90)at com.mendix.basis.util.license.LicenseUtil.checkUserLimitations(LicenseUtil.scala:215)at com.mendix.basis.util.license.LicenseUtil.checkSession(LicenseUtil.scala:212)at com.mendix.basis.session.SessionManager.createSession(SessionManager.scala:266)at com.mendix.basis.session.SessionManager.$anonfun$initializeSession$3(SessionManager.scala:248)at scala.Option.getOrElse(Option.scala:201)at com.mendix.basis.session.SessionManager.initializeSession(SessionManager.scala:248)at com.mendix.basis.session.SessionManager.initializeSession(SessionManager.scala:226)at com.mendix.basis.component.SessionCore.initializeSession(SessionCore.scala:75)at com.mendix.basis.component.SessionCore.initializeSession$(SessionCore.scala:74)at com.mendix.basis.component.InternalCore.initializeSession(InternalCore.scala:24)at com.mendix.basis.component.InternalCore.initializeSession(InternalCore.scala:24)at com.mendix.core.Core.initializeSession(Core.java:1677)at saml20.implementation.security.SessionManager.createSession(SessionManager.java:236)... 45 more I've checked the Mendix documentation and ensured that my SSL certificates are properly configured. However, I'm still encountering this issue. Can anyone provide guidance on resolving this problem?   Thanks, Darshan
asked
2 answers
0

Some items I'd suggest checking that have caused this error for me in the past:

  1. In the SAML Configuration IdP Attributes tab, ensure the attribute mapped is not duplicated in the "Just in time provisioning" section. Ideally the attribute mapped is the Name attribute.
  2. Validate that the attribute used in #1 is stored lower case, the attribute is treated case sensitive.  If the user already exists but the attribute from #1 is stored with a different case the SAML module will attempt to create a new user object and fail due to uniqueness validation.
  3. If using Mendix 9.24 or older, check the userlib folder for duplicate SAML JAR files, duplicate versions of the same library will cause unusual errors.

Hope this helps!

 

answered
0

The problem was resolved by updating the license key and license ID, which had apparently expired. Once the platform was renewed, the system began working properly.

answered