5 Replies Latest reply on Sep 1, 2009 6:35 PM by rk_jboss

    Getting NotImplementedException for NodeImpl.getTextContent

      Hi,
      I'm getting org.jboss.util.NotImplementedException, when SAML api internally calls
      org.jboss.ws.core.soap.NodeImpl.getTextContent() method. I'm using jboss-5.0.0.GA
      with jbossws-native-3.1.2.GA.


      Looks like jbossws implementation does not support some of the DOM API's.
      Just I'm wondering, is there any alternative ways to make it work. Pls can you update me
      if jboss has any tentative plans to implement those methods.Its a show stopper for me.

      I really appreciate your response.

      I'm copying the exception stacktrace.

      org.jboss.util.NotImplementedException: getTextContent
      at org.jboss.ws.core.soap.NodeImpl.getTextContent(NodeImpl.java:618)
      at org.opensaml.xml.util.XMLHelper.getXSIType(XMLHelper.java:111)
      at org.opensaml.xml.io.UnmarshallerFactory.getUnmarshaller(UnmarshallerFactory.java:77)
      at org.opensaml.xml.io.AbstractXMLObjectUnmarshaller.unmarshallChildElement(AbstractXMLObjectUnmarsh
      aller.java:300)
      at org.opensaml.xml.io.AbstractXMLObjectUnmarshaller.unmarshall(AbstractXMLObjectUnmarshaller.java:1
      20)
      at org.opensaml.xml.io.AbstractXMLObjectUnmarshaller.unmarshallChildElement(AbstractXMLObjectUnmarsh
      aller.java:317)
      at org.opensaml.xml.io.AbstractXMLObjectUnmarshaller.unmarshall(AbstractXMLObjectUnmarshaller.java:1
      20)
      at org.opensaml.xml.io.AbstractXMLObjectUnmarshaller.unmarshallChildElement(AbstractXMLObjectUnmarsh
      aller.java:317)
      at org.opensaml.xml.io.AbstractXMLObjectUnmarshaller.unmarshall(AbstractXMLObjectUnmarshaller.java:1
      20)
      at com.mycompany.xxx.AssertionValidatorHandler.handleMessage(AssertionValidatorHandler.java:111)
      at com.mycompany.xxx.AssertionValidatorHandler.handleMessage(AssertionValidatorHandler.java:1)
      at org.jboss.ws.core.jaxws.handler.HandlerChainExecutor.handleMessage(HandlerChainExecutor.java:293)
      
      at org.jboss.ws.core.jaxws.handler.HandlerChainExecutor.handleMessage(HandlerChainExecutor.java:138)
      
      at org.jboss.ws.core.jaxws.handler.HandlerDelegateJAXWS.callRequestHandlerChain(HandlerDelegateJAXWS
      .java:97)
      at org.jboss.ws.core.server.ServiceEndpointInvoker.callRequestHandlerChain(ServiceEndpointInvoker.ja
      va:125)
      at org.jboss.ws.core.server.ServiceEndpointInvoker.invoke(ServiceEndpointInvoker.java:197)
      at org.jboss.wsf.stack.jbws.RequestHandlerImpl.processRequest(RequestHandlerImpl.java:498)
      at org.jboss.wsf.stack.jbws.RequestHandlerImpl.handleRequest(RequestHandlerImpl.java:295)
      at org.jboss.wsf.stack.jbws.RequestHandlerImpl.doPost(RequestHandlerImpl.java:205)
      at org.jboss.wsf.stack.jbws.RequestHandlerImpl.handleHttpRequest(RequestHandlerImpl.java:131)
      at org.jboss.wsf.common.servlet.AbstractEndpointServlet.service(AbstractEndpointServlet.java:109)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
      
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
      
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
      at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
      at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
      at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishm
      entValve.java:126)
      at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishme
      ntValve.java:70)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
      at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:828)
      at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:601)
      at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
      at java.lang.Thread.run(Thread.java:595)
      
      


      Thanks,
      Ram

        • 1. Re: Getting NotImplementedException for NodeImpl.getTextCont
          anil.saldhana

          You should open a jira issue here https://jira.jboss.org/jira/browse/JBWS

          There is a SAML2 api in JBoss Identity. Look at the developer guide.

          JBoss Identity has an Open Source SAML2 implementation.

          • 2. Re: Getting NotImplementedException for NodeImpl.getTextCont

            Thanks Anil for quick response.

            I looked into jboss identity api but did not find the suitable classes to generate saml 2.0 assertions.I can understand from jboss api
            that it covers federated identities and web SSO.
            My requirement is that,once the web service is authenticated I have to generate the saml request assertion (which includes AuthzDecisionStatement,
            AuthorizationDecisionStatement and AttributeStatement) and will be forwared to another web service which will validate the saml assertion
            and then send the response.

            My saml request looks like

            
             <env:Header>
             <wsse:Security xmlns:wsse='http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd'>
             <saml:Assertion ID='123' IssueInstant='2009-08-20T00:54:04.859Z' Version='2.0' xmlns:saml='urn:oasis:names:tc:SAML:2.0:assertion'>
             <saml:Issuer>http://uhs.adaranet.com</saml:Issuer>
             <saml:Subject>
             <saml:NameID Format='urn:oasis:names:tc:SAML:1.1:nameid-format:x509SubjectName' xmlns:saml='urn:oasis:names:tc:SAML:2.0:assertion'>
             jduke
             </saml:NameID>
             </saml:Subject>
             <saml:AuthnStatement AuthnInstant='2009-08-20T00:54:04.937Z'>
             <saml:AuthnContext xmlns:saml='urn:oasis:names:tc:SAML:2.0:assertion'>
             <saml:AuthnContextClassRef xmlns:saml='urn:oasis:names:tc:SAML:2.0:assertion'>
             urn:oasis:names:tc:SAML:2.0:ac:classes:X509
             </saml:AuthnContextClassRef>
             </saml:AuthnContext>
             </saml:AuthnStatement>
             <saml:AuthzDecisionStatement Decision='Permit' Resource='getMentalNotes'>
             <saml:Action Namespace='urn:patientInformation:getMentalNotes' xmlns:saml='urn:oasis:names:tc:SAML:2.0:assertion'>
             getMentalNotes
             </saml:Action>
             </saml:AuthzDecisionStatement>
             <saml:AttributeStatement>
             <saml:Attribute Name='PhysicianType' NameFormat='http://www.adaranet.com/esb/security' xmlns:saml='urn:oasis:names:tc:SAML:2.0:assertion'>
             <saml:AttributeValue xmlns:saml='urn:oasis:names:tc:SAML:2.0:assertion' xmlns:xs='http://www.w3.org/2001/XMLSchema' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:type='xs:string'>
             Primary
             </saml:AttributeValue>
             </saml:Attribute>
             </saml:AttributeStatement>
             </saml:Assertion>
             </wsse:Security>
             </env:Header>
            
            
            


            Is it possible to genrate the similar kind of saml assertion using jboss api?

            Thanks in advance.


            thanks,
            Ram

            • 3. Re: Getting NotImplementedException for NodeImpl.getTextCont
              anil.saldhana

              It is possible to generate the assertions, statements etc with our API. But I realized that we need to make it simpler with one stop solution.

              I added a feature request to be part of Beta2 which will be released within 7 days. I just need to document it clearly and fix the javadocs link on the project page.
              https://jira.jboss.org/jira/browse/JBID-177

              • 4. Re: Getting NotImplementedException for NodeImpl.getTextCont

                Oh its good that you are coming up with saml 2.0 support.
                In my requirement, I have to move the authorization statements to XACML ploicies,
                and I read that jboss has support for XACML so I'm inclined towards jboss implementations.I wanted to use
                jboss as a suite for web services authentication( using jaas),saml assertion and xacml policies.

                I can wait untill you release the service pack but it would be great if you can share the required jars so that
                I can have a glimpse at the documentation.
                Meanwhile,I'll explore apache rampart/other solutions.

                Thanks in advance.


                thanks,
                Ram

                • 5. Re: Getting NotImplementedException for NodeImpl.getTextCont

                  Hi Anil,
                  Any tentative plan for new release?

                  -thanks,
                  Ram