tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 59226] StandardJarScanner ignores jars in manifest Class-path header
Date Thu, 28 Apr 2016 10:28:11 GMT
https://bz.apache.org/bugzilla/show_bug.cgi?id=59226

--- Comment #3 from Ignacio del Valle Alles <idelvall@brutusin.org> ---
Hi Mark, this  problem comes for system (application) class loader, that is
responsible of handling class-path entries, not returning manifest jar urls
when executed as java -jar.

If there is a portable way of knowing the executable jar at runtime, the
solution would be trivial: just parse its manifest class path entries. But
there is not (AFAIK)

The suggested change does not get jar entries from the class-path header of the
manifest, instead it infers jar entries from the enumeration of manifest that
it sees (and its parent don't)

It is true that it requires jars referenced in the manifest of the executable
jar to have a manifest in order to be scanned, but this improves the current
behavior of not scanning them at all

For code simplicity I added the same processing for every class loader in
Tomcat, but it is true, that I adds a little overhead, so I have just created a
new pull request that applies the hack only to the system class loader.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message