Author: remy.maucherat(a)jboss.com
Date: 2008-04-09 20:39:22 -0400 (Wed, 09 Apr 2008)
New Revision: 582
Modified:
trunk/conf/catalina.policy
trunk/java/org/apache/el/lang/FunctionMapperImpl.java
trunk/java/org/apache/juli/ClassLoaderLogManager.java
trunk/webapps/docs/changelog.xml
Log:
- Port 3 Tomcat patches.
- NPE in function mapper.
- Permission improvements in JULI.
Modified: trunk/conf/catalina.policy
===================================================================
--- trunk/conf/catalina.policy 2008-04-10 00:06:14 UTC (rev 581)
+++ trunk/conf/catalina.policy 2008-04-10 00:39:22 UTC (rev 582)
@@ -49,6 +49,7 @@
grant codeBase "file:${catalina.home}/bin/tomcat-juli.jar" {
permission java.util.PropertyPermission
"java.util.logging.config.class", "read";
permission java.util.PropertyPermission
"java.util.logging.config.file", "read";
+ permission java.io.FilePermission
"${java.home}${file.separator}lib${file.separator}logging.properties",
"read";
permission java.lang.RuntimePermission "shutdownHooks";
permission java.io.FilePermission
"${catalina.base}${file.separator}conf${file.separator}logging.properties",
"read";
permission java.util.PropertyPermission "catalina.base",
"read";
Modified: trunk/java/org/apache/el/lang/FunctionMapperImpl.java
===================================================================
--- trunk/java/org/apache/el/lang/FunctionMapperImpl.java 2008-04-10 00:06:14 UTC (rev
581)
+++ trunk/java/org/apache/el/lang/FunctionMapperImpl.java 2008-04-10 00:39:22 UTC (rev
582)
@@ -120,6 +120,8 @@
public void writeExternal(ObjectOutput out) throws IOException {
out.writeUTF((this.prefix != null) ? this.prefix : "");
out.writeUTF(this.localName);
+ // make sure m isn't null
+ getMethod();
out.writeUTF((this.owner != null) ?
this.owner :
this.m.getDeclaringClass().getName());
Modified: trunk/java/org/apache/juli/ClassLoaderLogManager.java
===================================================================
--- trunk/java/org/apache/juli/ClassLoaderLogManager.java 2008-04-10 00:06:14 UTC (rev
581)
+++ trunk/java/org/apache/juli/ClassLoaderLogManager.java 2008-04-10 00:39:22 UTC (rev
582)
@@ -22,6 +22,7 @@
import java.io.IOException;
import java.io.InputStream;
import java.net.URLClassLoader;
+import java.security.AccessControlException;
import java.security.AccessController;
import java.security.PrivilegedAction;
import java.util.Collections;
@@ -296,9 +297,14 @@
InputStream is = null;
// Special case for URL classloaders which are used in containers:
// only look in the local repositories to avoid redefining loggers 20 times
- if ((classLoader instanceof URLClassLoader)
- && (((URLClassLoader)
classLoader).findResource("logging.properties") != null)) {
- is = classLoader.getResourceAsStream("logging.properties");
+ try {
+ if ((classLoader instanceof URLClassLoader)
+ && (((URLClassLoader)
classLoader).findResource("logging.properties") != null)) {
+ is = classLoader.getResourceAsStream("logging.properties");
+ }
+ } catch (AccessControlException ace) {
+ // No permission to configure logging in context
+ // Ignore and carry on
}
if ((is == null) && (classLoader == ClassLoader.getSystemClassLoader()))
{
String configFileStr =
System.getProperty("java.util.logging.config.file");
Modified: trunk/webapps/docs/changelog.xml
===================================================================
--- trunk/webapps/docs/changelog.xml 2008-04-10 00:06:14 UTC (rev 581)
+++ trunk/webapps/docs/changelog.xml 2008-04-10 00:39:22 UTC (rev 582)
@@ -57,6 +57,10 @@
<bug>44646</bug>: Fix tracking problems in the Comet utility valve
(which provides
notification for certain events such as session expiration and server shutdown).
(markt)
</fix>
+ <fix>
+ Better handling of lack of permission for context specific logging, and add
permission
+ for reading the JDK logging.properties. (markt)
+ </fix>
</changelog>
</subsection>
<subsection name="Coyote">
@@ -103,8 +107,11 @@
<subsection name="Jasper">
<changelog>
<fix>
- Port Tomcat fix for bugzilla 42693. (jfclere).
+ <bug>42693</bug>: Port Tomcat fix for bugzilla 42693. (jfclere).
</fix>
+ <fix>
+ <bug>44428</bug>: NPE in function mapper. (markt)
+ </fix>
</changelog>
</subsection>
</section>
Show replies by date