tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Oxley <d...@staffplanner.co.uk>
Subject RE: [4.1.9] Fix for major bugs
Date Wed, 21 Aug 2002 10:53:13 GMT
Remy,

The stack trace was caused because TC4 was installed in a path with spaces.
After that I tried in a path without spaces and it still didn't work.

I think there's two bugs here. One is the URL's should be encoded, but two,
I should never have come across the first bug because the classes are being
searched for in the wrong location.

The actual issue is that with RMI, the classloader is not using the
java.rmi.server.codebase parameter to search for the class. The class is
available for download in \Tomcat\webapps\app\com\..\...\???.class, but it
is being looked for in \Tomcat\webapps\app\WEB-INF\classes and
\Tomcat\webapps\app\WEB-INF\lib\*.jar.

The client should be looking at http://server/app/com/../.../???.class and
shouldn't get this exception:
Caused by: java.security.AccessControlException: access denied
(java.io.FilePermission C:\Tomcat\webapps\spweb\WEB-INF\- read)

Try the test case that is attached to the bug. It shows this bug.

I don't mind this being fixed after the first stable 4.1.x release, but I am
unable to put any version of TC4 into production at the moment because of
this.

Hope this explains my problem a bit better.
Cheers.
Dave.


Here's the stack trace (The bottom bit is the important bit).
21 Aug 2002 11:27:03,014 FATAL    CriticalException - RMI failed:
java.rmi.ServerException: RemoteException occurred in server thread; nested
exception is:
        java.rmi.UnmarshalException: error unmarshalling arguments; nested
exception is:
        java.lang.ClassNotFoundException: access to class loader denied
        at
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:292)
        at sun.rmi.transport.Transport$1.run(Transport.java:148)
        at java.security.AccessController.doPrivileged(Native Method)
        at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
        at
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
        at
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:7
01)
        at java.lang.Thread.run(Thread.java:536)
        at
sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteC
all.java:247)
        at
sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)
        at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:133)
        at
com.staffplanner.utils.rmi.StaffplannerRemoteImpl_Stub.executeTask(Unknown
Source)
        at
com.staffplanner.utils.rmi.RemoteController.execute(RemoteController.java:77
)
        at
com.staffplanner.utils.rmi.RemoteServer.callRemote(RemoteServer.java:56)
        at
com.staffplanner.utils.rmi.RemoteServer.callRemote(RemoteServer.java:38)
        at
com.staffplanner.utils.rmi.XNServer.getNextFosKey(XNServer.java:21)
        at
com.staffplanner.kernel.employees.Employee.getDefaultEposKeyNumber(Employee.
java:1348)
        at
com.staffplanner.pages.employees.EmployeeMaintenancePage$EmployeeMaintenance
Data.<init>(EmployeeMaintenancePage.java:326)
        at
com.staffplanner.pages.employees.EmployeeMaintenancePage.getScreenData(Emplo
yeeMaintenancePage.java:513)
        at
com.staffplanner.pages.base.MaintenancePage.processPageLoad(MaintenancePage.
java:479)
        at
com.staffplanner.pages.base.MaintenancePage.processPost(MaintenancePage.java
:140)
        at
com.staffplanner.pages.base.StaffPlannerPage.doPost(StaffPlannerPage.java:45
3)
        at
com.staffplanner.servlets.StaffPlannerServlet.processRequest(StaffPlannerSer
vlet.java:233)
        at com.staffplanner.base.ServletBase.doPost(ServletBase.java:71)
        at com.staffplanner.base.ServletBase.doGet(ServletBase.java:98)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:247)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:193)
        at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:260)
        at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
        at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
        at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
        at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:191)
        at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
        at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
        at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
        at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2350)
        at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180
)
        at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
        at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.
java:170)
        at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:641)
        at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:171
)
        at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:641)
        at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:469)
        at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:641)
        at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
        at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
        at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:174)
        at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invok
eNext(StandardPipeline.java:643)
        at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
        at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
        at
org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
        at
org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:256)
        at
org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:355)
        at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:563)
        at
org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:535)
        at
org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:638)
        at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:533)
        at java.lang.Thread.run(Thread.java:536)
Caused by: java.rmi.UnmarshalException: error unmarshalling arguments;
nested exception is:
        java.lang.ClassNotFoundException: access to class loader denied
        at
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:252)
        at sun.rmi.transport.Transport$1.run(Transport.java:148)
        at java.security.AccessController.doPrivileged(Native Method)
        at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
        at
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
        at
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:7
01)
        ... 1 more
Caused by: java.lang.ClassNotFoundException: access to class loader denied
        at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:421)
        at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:159)
        at
java.rmi.server.RMIClassLoader$2.loadClass(RMIClassLoader.java:631)
        at java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:257)
        at
sun.rmi.server.MarshalInputStream.resolveClass(MarshalInputStream.java:200)
        at
java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1513)
        at
java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1435)
        at
java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1626)
        at
java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
        at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324)
        at sun.rmi.server.UnicastRef.unmarshalValue(UnicastRef.java:297)
        at
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:246)
        ... 6 more
Caused by: java.security.AccessControlException: access denied
(java.io.FilePermission C:\Tomcat\webapps\spweb\WEB-INF\- read)
        at
java.security.AccessControlContext.checkPermission(AccessControlContext.java
:270)
        at
java.security.AccessController.checkPermission(AccessController.java:401)
        at
java.lang.SecurityManager.checkPermission(SecurityManager.java:542)
        at
sun.rmi.server.LoaderHandler$Loader.checkPermissions(LoaderHandler.java:1128
)
        at
sun.rmi.server.LoaderHandler$Loader.access$000(LoaderHandler.java:1082)
        at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:385)
        ... 17 more

> -----Original Message-----
> From: Remy Maucherat [mailto:remm@apache.org]
> Sent: 20 August 2002 16:59
> To: Tomcat Developers List
> Subject: Re: [4.1.9] Fix for major bugs
> 
> David Oxley wrote:
> > Hi Remy,
> >
> > I've just attached some comments to the bug log
> > (http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7082) that were
> posted to
> > the user list a week or so ago. They seem to explain exactly why this is
> > happening. Have a read through and see what you think.
> 
> I think the root cause of the problem is just that the URLs should be
> encoded. As I said, this will be fixed after the first stable 4.1.x
> release to avoid the possibility of introducing new bugs.
> 
> In more complex scenarios, I suppose other problems can happen, but the
> stack trace which was attached seemed to hint at a simple issue.
> 
> Remy
> 
> 
> --
> To unsubscribe, e-mail:   <mailto:tomcat-dev-
> unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:tomcat-dev-
> help@jakarta.apache.org>

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


Mime
View raw message