对于
java Web应用程序,使用JRE 1.6.0_22时出现此错误
java.lang.SecurityException: class “org.apache.log4j.Logger” does not match trust level of other classes in the same package
但是,使用JRE 1.6.0_13时它可以正常工作.
我在谷歌搜索,发现自update 19以来有一个安全增强.
对于这个例外,它说,
The following two SecurityExceptions are thrown after mixed components had previously been detected and a decision was made to allow them to coexist. The exceptions indicate that a component name collision (resource name or class package name) was detected between trusted and untrusted components and the request to load the resource or class was denied.
现在问题是,我怎么能找到哪些类(可能是org.apache.log4j.Logger?)有碰撞以及它们在哪些包中?
我发现在Oracle forums有一个类似的问题
最佳答案 有趣的链接.我还没有遇到问题 – 但可能是你在某个地方和Web应用程序中的JavaEE容器类路径中都有“org.apache …”的jar.
寻找并测试从Web应用程序中删除它