[kaffe] tomcat3.2.3 doesn't work properly on Kaffe-1.0.6-6

Dalibor Topic robilad at yahoo.com
Thu Jun 13 14:14:04 PDT 2002


--- Dalibor Topic <robilad at yahoo.com> wrote:
> 
> --- Tatsuya Tsurukawa <turukawa at isl.melco.co.jp>
> wrote:
> > I'm now testing Apache SOAP 2.2 and TOMCAT 3.2.3
> on
> > Red Hat Linux 7.2.
> > to make simple Web Services. 
> > 
> > They work well on Sun's JDK1.3.1. Then I tried to
> > use Kaffe-1.0.6-6 as
> > JVM instead of Sun's JDK, and I found it doesn't
> > work. I saw follwing
> > errors.
> 
> I just had a success to get tomcat 3.2.4 running on
> current kaffe from CVS with the attached patches
> from
> Tim Stack.

And I've also tested tomcat 3.3.1 It doesn't run, and
it won't run before we implement jdk 1.2 security
model. That's going to take a while.

The problem is that tomcat 3.3.1 tries to use features
from jdk 1.2 when it finds them. This is what I get:

topic at clerks:~/Projects/Java/Kaffe/projects/jakarta-tomcat-3.3.1>
/usr/local/kaffe/bin/kaffe
-Dtomcat.home=/home/topic/Projects/Java/Kaffe/projects/jakarta-tomcat-3.3.1
 org.apache.tomcat.startup.Main start
Guessed
home=/home/topic/Projects/Java/Kaffe/projects/jakarta-tomcat-3.3.1/lib/common
Exception: java.lang.reflect.InvocationTargetException
java.lang.reflect.InvocationTargetException:
java.lang.Exception: Invalid access control context 
        at
java.lang.Throwable.fillInStackTrace(Throwable.java:native)
        at
java.lang.Throwable.<init>(Throwable.java:38)
        at
java.lang.Exception.<init>(Exception.java:24)
        at
org.apache.tomcat.util.compat.Jdk12Support.doPrivileged(Jdk12Support.java:92)
        at
org.apache.tomcat.startup.EmbededTomcat.execute(EmbededTomcat.java:685)
        at
java.lang.reflect.Method.invoke0(Method.java:native)
        at
java.lang.reflect.Method.invoke(Method.java:256)
        at
org.apache.tomcat.util.IntrospectionUtils.execute(IntrospectionUtils.java:87)
        at
org.apache.tomcat.startup.Main.execute(Main.java:313)
        at
org.apache.tomcat.startup.Main.main(Main.java:140)
Root Exception: java.lang.Exception: Invalid access
control context 
java.lang.Exception: Invalid access control context 
        at
java.lang.Throwable.fillInStackTrace(Throwable.java:native)
        at
java.lang.Throwable.<init>(Throwable.java:38)
        at
java.lang.Exception.<init>(Exception.java:24)
        at
org.apache.tomcat.util.compat.Jdk12Support.doPrivileged(Jdk12Support.java:92)
        at
org.apache.tomcat.startup.EmbededTomcat.execute(EmbededTomcat.java:685)
        at
java.lang.reflect.Method.invoke0(Method.java:native)
        at
java.lang.reflect.Method.invoke(Method.java:256)
        at
org.apache.tomcat.util.IntrospectionUtils.execute(IntrospectionUtils.java:87)
        at
org.apache.tomcat.startup.Main.execute(Main.java:313)
        at
org.apache.tomcat.startup.Main.main(Main.java:140)

i've looked at the source, and the problem is that
doPrivileged gets an AccessControlContext == null. and
I think that one comes from our
java.security.AccessController.getContext(), which
always returns null (like JDK1.1). In JDK 1.2, it is
supposed to return an AccessControlContext which
essentially contains the protection domains of the
classes in the stack snapshot taken by getContext().
Note that we don't support ProtectionDomains properly
yet, neither do we implement
Class.getProtectionDomain, which would be necessary
for this to work. In order to get getProtectionDomain
working we need to provide
java.security.AllPermission, as that's the permission
used for the system core classes. and update the class
loaders accordingly. And so on.

In short: getting Tomcat 3.3.1 to work will require
that we implement more of the JDK 1.2 security
architecture. Tim Stack has been doing a lot of work
on this recently (thanks Tim!), but I'd bet that he
could use a helping hand ...

cheers,

dalibor topic

__________________________________________________
Do You Yahoo!?
Yahoo! - Official partner of 2002 FIFA World Cup
http://fifaworldcup.yahoo.com




More information about the kaffe mailing list