Uploaded image for project: 'Tuscany'
  1. Tuscany
  2. TUSCANY-2653

doPrivileged needed in interface2WSDLGenerator

    XMLWordPrintableJSON

Details

    Description

      The call to WSDLFactory.newInstance in the contructor of org.apache.tuscany.sca.binding.ws.wsdlgen.Interface2WSDLGenerator needs to be called in a doPrivileged block.

      The following exception occurs with java 2 security enabled:
      java.security.AccessControlException: access denied (java.io.FilePermission /test/was7soa/WebSphere/AppServer/java/jre/lib/wsdl.properties read)
      at java.security.AccessControlContext.checkPermission(AccessControlContext.java:323)
      at java.security.AccessController.checkPermission(AccessController.java:546)
      at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
      at com.ibm.ws.security.core.SecurityManager.checkPermission(SecurityManager.java:210)
      at java.lang.SecurityManager.checkRead(SecurityManager.java:871)
      at java.io.FileInputStream.<init>(FileInputStream.java:100)
      at javax.wsdl.factory.WSDLFactory.findFactoryImplName(WSDLFactory.java:262)
      at javax.wsdl.factory.WSDLFactory.newInstance(WSDLFactory.java:60)
      at org.apache.tuscany.sca.binding.ws.wsdlgen.Interface2WSDLGenerator.<init>(Interface2WSDLGenerator.java:127)

      Attachments

        Activity

          People

            simonslaws Simon Laws
            bdaniel Brent Daniel
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: