You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Matthew L Daniel <md...@scdi.com> on 2001/03/22 18:11:09 UTC

[PATCH] Bug # 1002 patch (plus misc)

	All of these patches are against the jakarta-tomcat-4.0-b1.tar.gz
distribution, since it gave me a stable(?) place from which to work.  If I
have commited a faux pas by doing this, just let me know.

	Bug 1002 is in regard to the SecurityException: sealing violation.
	The comments and javadoc explain in detail, but the brief idea is that
there is a HIGH likelyhood that the sealing exception is caused by a user's
WEB-INF entry, thus, to circumvent the SecurityException just catch it and
delegate to the parent classloader (who has a HIGH likelyhood of containing
the real jar, otherwise we wouldn't have gotten the SecurityException).

	This patch also fixes a NullPointerException (I hate those) because
our WebApp (deployed from our filesystem) did not contain a Manifest.  This is
a double patch, since the Extension class did not return empty Lists like the
javadoc said it would, and the StandardClassLoader didn't check for there not
being a Manifest before calling Extension.  I saw that someone else in the
mailing list called this out, but it was still broken in 4.0-b1.

	Also included in this patch (for continutity) is the RequestBase
returning -1 as the server port, which IMHO is extremely bad.  Above and
beyond the moral implications of a port being -1, when used with my Warp
connection it was returning "Location: http://localhost:-1/index.jsp" headers.

	Further included in this patch is a WarpEngine correction with regard
to the HostID not being initialized.  I realize that this is a touch "kludgy",
but that's why it's OpenSource, right? :-)

	In the separate file, I patched the JikesJavaCompiler to work to my
liking.  :-)  Seriously, on the Linux Sun 1.3.0_02 vm (and prior ones), the
java.class.path does not contain rt.jar, which jikes will not work without.  I
saw that someone had already included a workaround for MicrosoftVM, so I just
updated it.

	In the last patch, I found it a thousand times more useful to use the
Ant support for property files rather than trying to monkey with your build.sh
and the 100 environmental variables.  I think including this patch in the
standard distribution is a Good Thing(tm) because if the user wants to use
build.properties, great, and if not Ant will /silently/ ignore the entry.

	I also know how to make a WebApp talk to Inprise Application Server
using only the WebApp (contra starting Catalina using vbj), if anyone is
interested in such a trick.

  I hope these help you as much as they help me.
  -- /v\atthew
-- 
Matthew L Daniel                     Discovery is seeing what everybody 
Internet Developer,                  else has seen, and thinking what 
Still Current Development, Inc.      nobody else has thought.
mdaniel@scdi.com                     -- Albert, Szent-Gyorgi