简体   繁体   中英

WSO2 Identity Server 5.10.0 with Samples 4.2.0 keep on having java.lang.ClassCastException: class org.opensaml.saml1.core.impl.ActionBuilder

When I try Quick Start Guide of WSO2 Identity Server.

Scenario 1 - Configuring Single-Sign-On with SAML2

generate http://localhost.com:8080/saml2-web-app-pickup-dispatch.com/ . When I click the link app server crash with following messages:

HTTP ERROR 500
Problem accessing /saml2-web-app-pickup-dispatch.com/samlsso. Reason:

    Server Error
Caused by:
java.lang.ClassCastException: class org.opensaml.saml1.core.impl.ActionBuilder cannot be cast to class org.opensaml.core.xml.XMLObjectBuilder (org.opensaml.saml1.core.impl.ActionBuilder and org.opensaml.core.xml.XMLObjectBuilder are in unnamed module of loader org.eclipse.jetty.webapp.WebAppClassLoader @4e517165)
    at org.opensaml.core.xml.config.XMLConfigurator.initializeObjectProviders(XMLConfigurator.java:238)
    at org.opensaml.core.xml.config.XMLConfigurator.load(XMLConfigurator.java:203)
    at org.opensaml.core.xml.config.XMLConfigurator.load(XMLConfigurator.java:188)
    at org.opensaml.core.xml.config.XMLConfigurator.load(XMLConfigurator.java:162)
    at org.opensaml.core.xml.config.AbstractXMLObjectProviderInitializer.init(AbstractXMLObjectProviderInitializer.java:52)
    at org.wso2.carbon.identity.saml.common.util.SAMLInitializer.doBootstrap(SAMLInitializer.java:55)
    at org.wso2.carbon.identity.sso.agent.util.SSOAgentUtils.doBootstrap(SSOAgentUtils.java:123)
    at org.wso2.carbon.identity.sso.agent.saml.SAML2SSOManager.<init>(SAML2SSOManager.java:163)
    at org.wso2.carbon.identity.sso.agent.SAML2SSOAgentFilter.doFilter(SAML2SSOAgentFilter.java:143)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1602)
    at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:540)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:146)
    at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:548)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)
    at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:257)
    at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1700)
    at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:255)
    at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1345)
    at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:203)
    at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:480)
    at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1667)
    at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:201)
    at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1247)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:144)
    at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:220)
    at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:152)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132)
    at org.eclipse.jetty.server.Server.handle(Server.java:505)
    at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:370)
    at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:267)
    at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:305)
    at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)
    at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117)
    at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333)
    at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310)
    at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168)
    at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.produce(EatWhatYouKill.java:132)
    at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:698)
    at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:804)
    at java.base/java.lang.Thread.run(Thread.java:834)

I tried on Mac and Linux platform but same result. Is there any env or config issue to make it work?

This is a known issue[1] and is fixed in the samples released with samples-is v4.3.0 release[2]. You should be able to download the new saml2-web-app-pickup-dispatch.com sample from [2].

[1] - https://github.com/wso2/product-is/issues/7891
[2] - https://github.com/wso2/samples-is/releases/tag/v4.3.0

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM