com.sun.xml.wss.XWSSecurityException

java.lang.ClassCastException: org.apache.xerces.dom.ElementNSImpl incompatible with javax.xml.soap.SOAPElement

Samebug tips0

We couldn't find tips for this exception.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web5

  • Stack trace

    • com.sun.xml.wss.XWSSecurityException: java.lang.ClassCastException: org.apache.xerces.dom.ElementNSImpl incompatible with javax.xml.soap.SOAPElement at com.sun.xml.wss.impl.misc.XWSSProcessor2_0Impl.secureOutboundMessage(XWSSProcessor2_0Impl.java:79) at com.soap.client.SOAPTestClient.createSoapMessage(SOAPTestClient.java:219) at com.soap.client.SOAPTestClient.main(SOAPTestClient.java:84) Caused by: java.lang.ClassCastException: org.apache.xerces.dom.ElementNSImpl incompatible with javax.xml.soap.SOAPElement at com.sun.xml.wss.impl.SecurableSoapMessage.findWsseSecurityHeaderBlock(SecurableSoapMessage.java:183) at com.sun.xml.wss.impl.SecurableSoapMessage.findOrCreateSecurityHeader(SecurableSoapMessage.java:225) at com.sun.xml.wss.impl.filter.TimestampFilter.process(TimestampFilter.java:120) at com.sun.xml.wss.impl.HarnessUtil.processWSSPolicy(HarnessUtil.java:68) at com.sun.xml.wss.impl.HarnessUtil.processDeep(HarnessUtil.java:218) at com.sun.xml.wss.impl.SecurityAnnotator.processMessagePolicy(SecurityAnnotator.java:143) at com.sun.xml.wss.impl.SecurityAnnotator.secureMessage(SecurityAnnotator.java:118) at com.sun.xml.wss.impl.misc.XWSSProcessor2_0Impl.secureOutboundMessage(XWSSProcessor2_0Impl.java:77) ... 2 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    Unknown visitor
    Unknown visitorOnce,