Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [glassfish-dev] missing security provider classes with GF 6.1

Hi,

That's correct. The "com.sun.enterprise.security.provider.PolicyWrapper" contained large parts of code copied from the JDK. Unfortunately, it didn't copy everything but left a lot of references in to sun.* code. In this way it could not possibly work with JDK 11. GlassFish however always had the com.sun.enterprise.security.jacc.provider.SimplePolicyProvider available as well, which didn't had this issue.

I'll do a PR to explicitly reference this policy provider instead. Alternatively we can create a dummy class in GlassFish to reference com.sun.enterprise.security.jacc.provider.SimplePolicyProvider using the old name, but I think using the new default directly is more straightforward.

Kind regards,
Arjan Tijms





On Sun, Mar 7, 2021 at 2:26 PM Gurunandan Rao <gurunandan.rao@xxxxxxxxxx> wrote:
Hi,
"com/sun/enterprise/security/provider/PolicyWrapper" is missing from <glassfish-home>/glassfish/modules/security-ee.jar

Detailed exception stack trace is as below:

--------------------------------------------------------------------------------------------------------

[2021-03-06T18:33:09.991+0000] [glassfish 6.1] [SEVERE] [] [jacc] [tid: _ThreadID=54 _ThreadName=AutoDeployer] [timeMillis: 1615055589991] [levelValue: 1000] [[
  vendor's Policy instantiation error
java.lang.ClassNotFoundException: com.sun.enterprise.security.provider.PolicyWrapper
at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:471)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:588)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
at com.sun.ts.tests.jacc.provider.TSPolicy.loadPolicy(TSPolicy.java:224)
at com.sun.ts.tests.jacc.provider.TSPolicy.<init>(TSPolicy.java:81)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
at com.sun.enterprise.security.PolicyLoader.loadPolicy(PolicyLoader.java:113)
at com.sun.enterprise.security.SecurityLifecycle.onInitialization(SecurityLifecycle.java:139)
at com.sun.enterprise.security.SecurityLifecycle.postConstruct(SecurityLifecycle.java:184)
at org.jvnet.hk2.internal.ClazzCreator.postConstructMe(ClazzCreator.java:303)
at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:351)
at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:466)
at org.jvnet.hk2.internal.SingletonContext$1.compute(SingletonContext.java:59)
at org.jvnet.hk2.internal.SingletonContext$1.compute(SingletonContext.java:47)
at org.glassfish.hk2.utilities.cache.Cache$OriginThreadAwareFuture$1.call(Cache.java:74)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at org.glassfish.hk2.utilities.cache.Cache$OriginThreadAwareFuture.run(Cache.java:131)
at org.glassfish.hk2.utilities.cache.Cache.compute(Cache.java:176)
at org.jvnet.hk2.internal.SingletonContext.findOrCreate(SingletonContext.java:98)
at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2103)
at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:93)
at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:67)
at com.sun.enterprise.security.ee.SecuritySniffer.setup(SecuritySniffer.java:106)
at com.sun.enterprise.v3.server.ContainerStarter.startContainer(ContainerStarter.java:73)
at com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainer(ApplicationLifecycle.java:973)
at com.sun.enterprise.v3.server.ApplicationLifecycle.setupContainerInfos(ApplicationLifecycle.java:678)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:354)
at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:195)
at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:467)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:516)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:512)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/javax.security.auth.Subject.doAs(Subject.java:361)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$2.execute(CommandRunnerImpl.java:511)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$3.run(CommandRunnerImpl.java:542)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$3.run(CommandRunnerImpl.java:534)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/javax.security.auth.Subject.doAs(Subject.java:361)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:533)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1441)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1823)
at org.glassfish.deployment.autodeploy.AutoOperation.run(AutoOperation.java:140)
at org.glassfish.deployment.autodeploy.AutoDeployer.deploy(AutoDeployer.java:573)
at org.glassfish.deployment.autodeploy.AutoDeployer.deployAll(AutoDeployer.java:460)
at org.glassfish.deployment.autodeploy.AutoDeployer.run(AutoDeployer.java:388)
at org.glassfish.deployment.autodeploy.AutoDeployer.run(AutoDeployer.java:379)
at org.glassfish.deployment.autodeploy.AutoDeployService$1.run(AutoDeployService.java:209)
at java.base/java.util.TimerThread.mainLoop(Timer.java:556)
at java.base/java.util.TimerThread.run(Timer.java:506)
]]
-------------------------------------------------------------------------------------------------------------------


regards,
Guru
_______________________________________________
glassfish-dev mailing list
glassfish-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/glassfish-dev

Back to the top