Bug 56923 - Symlinks under WEB-INF/lib trigger a NullPointerException in StandardJarScanner
Summary: Symlinks under WEB-INF/lib trigger a NullPointerException in StandardJarScanner
Status: RESOLVED INVALID
Alias: None
Product: Tomcat 8
Classification: Unclassified
Component: Examples (show other bugs)
Version: 8.0.12
Hardware: PC Linux
: P2 normal (vote)
Target Milestone: ----
Assignee: Tomcat Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-07 10:32 UTC by Heinrich Schuchardt
Modified: 2014-09-17 14:15 UTC (History)
1 user (show)



Attachments
catalina.out (8.52 KB, text/plain)
2014-09-07 10:32 UTC, Heinrich Schuchardt
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Heinrich Schuchardt 2014-09-07 10:32:42 UTC
Created attachment 31971 [details]
catalina.out

Starting application examples using the Tompcat web application manager fails with a NullPointerException. Please, find attached catalina.out.

Apache Tomcat/8.0.9 (Debian)
JVM 1.7.0_65-b32 Oracle Corporation
Linux 3.16.0 i386

Debian Bug report #753372
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=753372
Comment 1 Mark Thomas 2014-09-07 18:19:29 UTC
Absent some evidence to the contrary, the assumption is going to be that this is a bug in Debian's packaging since we haven't had any similar reports for the the Tomcat 8.0.9 release.

If you can reproduce this with an Apache Tomcat installed from the ASF distribution then please re-open this and provided the steps necessary to recreate the issue from a clean install.

To avoid reporting known issues that have already been fixed, I recommend testing with the latest 8.0.x release (8.0.12 at the time of writing) rather than 8.0.9.
Comment 2 Emmanuel Bourg 2014-09-17 13:19:52 UTC
It looks like this issue is caused by the symlinks to /usr/share/java/jstl.jar and /usr/share/java/standard.jar installed in the WEB-INF/lib directory of the examples application. Replacing the links with the actual files no longer triggers the error.

This error doesn't appear with the tomcat7-examples package which also uses symlinks (Tomcat 7.0.55).
Comment 3 Mark Thomas 2014-09-17 13:26:57 UTC
Then that is a packaging issue for Debian to solve. A default Tomcat install from the ASF doesn't use symlinks. It looks like the Debian folks have failed to read the migration guide, particularly the section on Web application resources.
Comment 4 Emmanuel Bourg 2014-09-17 14:15:54 UTC
Adding <Resources allowLinking="true"/> to the context solved the issue, thank you for the help Mark.