Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-15404

Remove FilePermission("<<ALL FILES") from tests

    XMLWordPrintable

Details

    • Task
    • Resolution: Won't Do
    • Major
    • None
    • None
    • MP Reactive Messaging
    • None

    Description

      This affects tests in testsuite/integration/microprofile both RSO and RM tests. To fix it we need https://github.com/eclipse/microprofile-reactive-streams-operators/pull/170 merged. 

      I get errors like:

      Caused by: java.security.AccessControlException: WFSM000001: Permission check failed (permission "("java.io.FilePermission" "/Users/kabir/.m2/repository/org/eclipse/microprofile/reactive-streams-operators/microprofile-reactive-streams-operators-core/2.0/microprofile-reactive-streams-operators-core-2.0.jar" "read")" in code source "(vfs:/content/rx-messaging-publisher-signature.war/WEB-INF/classes <no signer certificates>)" of "ModuleClassLoader for Module "deployment.rx-messaging-publisher-signature.war" from Service Module Loader")
      	at org.wildfly.security.manager.WildFlySecurityManager.checkPermission(WildFlySecurityManager.java:309)
      	at org.wildfly.security.manager.WildFlySecurityManager.checkPermission(WildFlySecurityManager.java:201)
      	at java.lang.SecurityManager.checkRead(SecurityManager.java:888)
      	at org.wildfly.security.manager.WildFlySecurityManager.checkRead(WildFlySecurityManager.java:374)
      	at sun.net.www.protocol.jar.JarFileFactory.getCachedJarFile(JarFileFactory.java:206)
      	at sun.net.www.protocol.jar.JarFileFactory.getOrCreate(JarFileFactory.java:103)
      	at sun.net.www.protocol.jar.JarURLConnection.connect(JarURLConnection.java:129)
      	at sun.net.www.protocol.jar.JarURLConnection.getInputStream(JarURLConnection.java:172)
      	at java.net.URL.openStream(URL.java:1092)
      	at java.util.ServiceLoader.parse(ServiceLoader.java:304)
      	at java.util.ServiceLoader.access$200(ServiceLoader.java:185)
      	at java.util.ServiceLoader$LazyIterator.hasNextService(ServiceLoader.java:357)
      	at java.util.ServiceLoader$LazyIterator.access$600(ServiceLoader.java:323)
      	at java.util.ServiceLoader$LazyIterator$1.run(ServiceLoader.java:396)
      	at java.util.ServiceLoader$LazyIterator$1.run(ServiceLoader.java:395)
      	at java.security.AccessController.doPrivileged(Native Method)
      	at java.util.ServiceLoader$LazyIterator.hasNext(ServiceLoader.java:398)
      	at java.util.ServiceLoader$1.hasNext(ServiceLoader.java:474)
      	at org.eclipse.microprofile.reactive.streams.operators.spi.ReactiveStreamsFactoryResolver.loadFromSpi(ReactiveStreamsFactoryResolver.java:83)
      	at org.eclipse.microprofile.reactive.streams.operators.spi.ReactiveStreamsFactoryResolver.instance(ReactiveStreamsFactoryResolver.java:61)
      	at org.eclipse.microprofile.reactive.streams.operators.ReactiveStreams.of(ReactiveStreams.java:86)
      	at org.wildfly.test.integration.microprofile.reactive.messaging.ported.signatures.PublisherSignatureTestCase$BeanProducingAPublisherOfPayload 

      It seems to be something along the lines of the first time this is called, since the tests presently work as a whole but some fail if run individually with -Dsecurity.manager=true. And similarly if I remove the FilePermission from existing tests that have it, they start failing.

      Attachments

        Activity

          People

            kkhan1@redhat.com Kabir Khan
            kkhan1@redhat.com Kabir Khan
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: