From: kkolinko Date: Mon, 2 Nov 2009 09:03:13 +0000 (+0000) Subject: Make WebappClassLoader to do not swallow AccessControlException X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=97718998aab4b87605695c8213190c757da058fb;p=tomcat7.0 Make WebappClassLoader to do not swallow AccessControlException See https://issues.apache.org/bugzilla/show_bug.cgi?id=48097 git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@831828 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/java/org/apache/catalina/loader/WebappClassLoader.java b/java/org/apache/catalina/loader/WebappClassLoader.java index c87e5edb6..1437397f9 100644 --- a/java/org/apache/catalina/loader/WebappClassLoader.java +++ b/java/org/apache/catalina/loader/WebappClassLoader.java @@ -70,7 +70,7 @@ import org.apache.tomcat.util.IntrospectionUtils; * Specialized web application class loader. *

* This class loader is a full reimplementation of the - * URLClassLoader from the JDK. It is desinged to be fully + * URLClassLoader from the JDK. It is designed to be fully * compatible with a normal URLClassLoader, although its internal * behavior may be completely different. *

@@ -901,6 +901,8 @@ public class WebappClassLoader throw cnfe; } } catch(AccessControlException ace) { + log.warn("WebappClassLoader.findClassInternal(" + name + + ") security exception: " + ace.getMessage(), ace); throw new ClassNotFoundException(name, ace); } catch (RuntimeException e) { if (log.isTraceEnabled()) @@ -911,6 +913,8 @@ public class WebappClassLoader try { clazz = super.findClass(name); } catch(AccessControlException ace) { + log.warn("WebappClassLoader.findClassInternal(" + name + + ") security exception: " + ace.getMessage(), ace); throw new ClassNotFoundException(name, ace); } catch (RuntimeException e) { if (log.isTraceEnabled())