Re: problem of setting up ssl in tomcat 5.5.9

2006-01-12 Thread Siddhartha Mehta
I am not sure if anyone has replied to you on this..
   
  At least from what I understand, the error below means is that the 
certificate file server.pem is not found as specified in the server.xml 
(configuration file) entry.
   
  You will find the server.xml file in the conf folder (under tomcat installed 
directory) and search for server.pem. Then verify if the path that is specified 
in server.xml to server.pem is valid or not. See if it helps.
   
  Siddhartha

zhou jian [EMAIL PROTECTED] wrote:
  Jan 11, 2006 2:59:44 PM
org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
Jan 11, 2006 2:59:44 PM
org.apache.tomcat.util.net.puretls.PureTLSSocketFactory
init
INFO: Error initializing SocketFactory
java.io.FileNotFoundException: server.pem (No such
file or directory)
at java.io.FileInputStream.open(Native Method)
at
java.io.FileInputStream.(FileInputStream.java:106)
at
java.io.FileInputStream.(FileInputStream.java:66)
at
COM.claymoresystems.ptls.SSLContext.loadEAYKeyFile(SSLContext.java:200)
at
org.apache.tomcat.util.net.puretls.PureTLSSocketFactory.init(PureTLSSocketFactory.java:134)
at
org.apache.tomcat.util.net.puretls.PureTLSSocketFactory.createSocket(PureTLSSocketFactory.java:69)
at
org.apache.tomcat.util.net.PoolTcpEndpoint.initEndpoint(PoolTcpEndpoint.java:292)
at
org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:142)
at
org.apache.catalina.connector.Connector.initialize(Connector.java:928)
at
org.apache.catalina.core.StandardService.initialize(StandardService.java:580)
at
org.apache.catalina.core.StandardServer.initialize(StandardServer.java:764)
at
org.apache.catalina.startup.Catalina.load(Catalina.java:490)
at
org.apache.catalina.startup.Catalina.load(Catalina.java:509)
at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at
java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:243)
at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:408)
Jan 11, 2006 2:59:44 PM
org.apache.coyote.http11.Http11Protocol init
SEVERE: Error initializing endpoint
java.io.IOException: server.pem (No such file or
directory)
at
org.apache.tomcat.util.net.puretls.PureTLSSocketFactory.init(PureTLSSocketFactory.java:149)
at
org.apache.tomcat.util.net.puretls.PureTLSSocketFactory.createSocket(PureTLSSocketFactory.java:69)
at
org.apache.tomcat.util.net.PoolTcpEndpoint.initEndpoint(PoolTcpEndpoint.java:292)
at
org.apache.coyote.http11.Http11Protocol.init(Http11Protocol.java:142)

1,1 Top


--- zhou jian wrote:

 Hello everyone,
 
 I want to configure the SSL in tomcat5 and I
 followed
 the following instructions:

http://tomcat.apache.org/tomcat-5.0-doc/printer/ssl-howto.html
 
 However, after starting the tomcat without any
 problem. 
 
 [EMAIL PROTECTED] bin]$ ps aux | grep java
 globus4 2668 2.2 6.2 296704 64436 pts/1 S 
 17:07 0:11 /opt/jdk1.5.0_04//bin/java

-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager

-Djava.endorsed.dirs=/home/globus4/jakarta-tomcat-5.5.9/common/endorsed
 -classpath

:/home/globus4/jakarta-tomcat-5.5.9/bin/bootstrap.jar:/home/globus4/jakarta-tomca
 globus4 3137 0.0 0.0 3580 636 pts/1 S 
 17:15 0:00 grep java
 
 However, I could access with https://localhost:8443.
 I
 am using jdk1.5.0_04. The only step I skipped is
 JSSE.
 Do you have any ideas?
 
 Thanks,
 --Paul
 
 
 __
 Do You Yahoo!?
 Tired of spam? Yahoo! Mail has the best spam
 protection around 
 http://mail.yahoo.com 
 

-
 To unsubscribe, e-mail:
 [EMAIL PROTECTED]
 For additional commands, e-mail:
 [EMAIL PROTECTED]
 
 


__
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

  



-
Yahoo! Photos – Showcase holiday pictures in hardcover
 Photo Books. You design it and we’ll bind it!

RE: Error loop for R - Tomcat 3.3.1a

2006-01-10 Thread Siddhartha Mehta
Hey Larry,
   
  Finally a refresh click brought a smile on my face :-)
   
  Yeah, it is one of those scenarios where people want backward support as 
against to moving forward.
   
  One thing that I dont understand is that the UIs are working very well. In 
fact I am able to change the password (that is when these exceptions are 
thrown) and is updated as well. Then why this backend exception. Any thoughts 
here?
   
  Also, there is a forward that is called before the include as you pointed 
out. Do you have any ideas on what tweaking I can try?
   
  Thanks again for your reply.
   
  Sid
   
  

Larry Isaacs [EMAIL PROTECTED] wrote:
  Sid,

The code where the exception is occurring is:

private final String getAbsolutePathRelativeToContext(String relativeUrlPath) {
String path = relativeUrlPath;

if (!path.startsWith(/)) {
String uri = (String) 
request.getAttribute(javax.servlet.include.servlet_path);
if (uri == null)
uri = ((HttpServletRequest) request).getServletPath();
401 String baseURI = uri.substring(0, uri.lastIndexOf('/'));
path = baseURI+'/'+path;
}

return path;
}

The code is trying to convert the weblmpagetop.jsp relative
path to a path from the root of the webapp. What Jasper has to
work with to establish where weblmpagetop.jsp is located is
failing the uri.lastIndexOf('/'). This suggests the problem
is related to the forwards that are occurring prior to reaching
the include. Perhaps there is something that needs to start with
a '/' that doesn't.

I can't say that this isn't due to a quirk, bug, or spec ambiguity,
as opposed the webapp doing something wrong with respect to
the Servlet 2.2 spec. It sounds like you are stuck with 3.3.1
as is. Hopefully a reasonable workaround can be found.

Cheers,
Larry


 -Original Message-
 From: Siddhartha Mehta [mailto:[EMAIL PROTECTED] 
 Sent: Tuesday, January 10, 2006 1:50 AM
 To: users@tomcat.apache.org
 Subject: Error loop for R - Tomcat 3.3.1a
 
 I am currently working on a web application that uses 
 Tomcat 4.1.27 and JDK 1.4.2_03.
 
 The same piece of code now needs to be supported on Tomcat 
 3.3.1 and JDK 1.4.2_08. I managed to get the classes, jsps 
 coompile and built by modifying the ant script. In fact even 
 the application runs perfect and the functionalities are 
 working as expected. Although, all is not good as it seems 
 so. In the backend, the tomcat - startup windows isn't quite 
 happy with the changes. I repeatedly get the following error 
 and I can make out very little from it.
 
 I can think of possible cause as this code in my jsp but not 
 really sure:
 
 
 
 
  name=body-title-text
  % name=body-location-text
 
 Exception thrown in tomcat-start up window is below:
 
 2006-01-10 11:48:04 - Ctx(/WebLM) : Exception in R( /WebLM + 
 /weblmlogin.jsp + n
 ull) - javax.servlet.ServletException: String index out of range: -1
 at 
 org.apache.jasper.runtime.PageContextImpl.handlePageException(PageCon
 textImpl.java:460)
 at com.avaya.weblm.weblmlogin._jspService(Unknown Source)
 at 
 org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java)
 at 
 org.apache.tomcat.facade.ServletHandler.doService(ServletHandler.java
 :574)
 at org.apache.tomcat.core.Handler.invoke(Handler.java:322)
 at org.apache.tomcat.core.Handler.service(Handler.java:235)
 at 
 org.apache.tomcat.facade.ServletHandler.service(ServletHandler.java:4
 85)
 at 
 org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispa
 tcherImpl.java:272)
 at 
 org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatc
 herImpl.java:174)
 at 
 com.avaya.weblm.WebLMServlet.forwardToNextPage(Unknown Source)
 at com.avaya.weblm.WebLMClientLogin.doPost(Unknown Source)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java)
 at 
 org.apache.tomcat.facade.ServletHandler.doService(ServletHandler.java
 :574)
 at org.apache.tomcat.core.Handler.invoke(Handler.java:322)
 at org.apache.tomcat.core.Handler.service(Handler.java:235)
 at 
 org.apache.tomcat.facade.ServletHandler.service(ServletHandler.java:4
 85)
 at 
 org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispa
 tcherImpl.java:272)
 at 
 org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatc
 herImpl.java:174)
 at 
 org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.jav
 a:423)
 at com.avaya.weblm.weblmlogin._jspService(Unknown Source)
 at 
 org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java)
 at 
 org.apache.tomcat.facade.ServletHandler.doService(ServletHandler.java
 :574)
 at org.apache.tomcat.core.Handler.invoke(Handler.java:322)
 at org.apache.tomcat.core.Handler.service(Handler.java:235)
 at 
 org.apache.tomcat.facade.ServletHandler.service(ServletHandler.java:4
 85)
 at 
 org.apache.tomcat.facade.RequestDispatcherImpl.doForward

Error loop for R - Tomcat 3.3.1a

2006-01-09 Thread Siddhartha Mehta
  I am currently working on a web application that uses Tomcat 4.1.27 and JDK 
1.4.2_03.

The same piece of code now needs to be supported on Tomcat 3.3.1 and JDK 
1.4.2_08. I managed to get the classes, jsps coompile and built by modifying 
the ant script. In fact even the application runs perfect and the 
functionalities are working as expected. Although, all is not good as it seems 
so. In the backend, the tomcat - startup windows isn't quite happy with the 
changes. I repeatedly get the following error and I can make out very little 
from it.

I can think of possible cause as this code in my jsp but not really sure:


jsp:include page=weblmpagetop.jsp flush=true
 jsp:param name=disable-session-validation value=true /
 jsp:param name=body-title-text value=%= title % /
 jsp:param name=body-location-text value=%= location % /
/jsp:include


Exception thrown in tomcat-start up window is below:

2006-01-10 11:48:04 - Ctx(/WebLM) : Exception in R( /WebLM + /weblmlogin.jsp + n
ull) - javax.servlet.ServletException: String index out of range: -1
at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageCon
textImpl.java:460)
at com.avaya.weblm.weblmlogin._jspService(Unknown Source)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java)
at org.apache.tomcat.facade.ServletHandler.doService(ServletHandler.java
:574)
at org.apache.tomcat.core.Handler.invoke(Handler.java:322)
at org.apache.tomcat.core.Handler.service(Handler.java:235)
at org.apache.tomcat.facade.ServletHandler.service(ServletHandler.java:4
85)
at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispa
tcherImpl.java:272)
at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatc
herImpl.java:174)
at com.avaya.weblm.WebLMServlet.forwardToNextPage(Unknown Source)
at com.avaya.weblm.WebLMClientLogin.doPost(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java)
at javax.servlet.http.HttpServlet.service(HttpServlet.java)
at org.apache.tomcat.facade.ServletHandler.doService(ServletHandler.java
:574)
at org.apache.tomcat.core.Handler.invoke(Handler.java:322)
at org.apache.tomcat.core.Handler.service(Handler.java:235)
at org.apache.tomcat.facade.ServletHandler.service(ServletHandler.java:4
85)
at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispa
tcherImpl.java:272)
at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatc
herImpl.java:174)
at org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.jav
a:423)
at com.avaya.weblm.weblmlogin._jspService(Unknown Source)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java)
at org.apache.tomcat.facade.ServletHandler.doService(ServletHandler.java
:574)
at org.apache.tomcat.core.Handler.invoke(Handler.java:322)
at org.apache.tomcat.core.Handler.service(Handler.java:235)
at org.apache.tomcat.facade.ServletHandler.service(ServletHandler.java:4
85)
at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispa
tcherImpl.java:272)
at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatc
herImpl.java:174)
at org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.jav
a:423)
at com.avaya.weblm.index._jspService(Unknown Source)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java)
at org.apache.tomcat.facade.ServletHandler.doService(ServletHandler.java
:574)
at org.apache.tomcat.core.Handler.invoke(Handler.java:322)
at org.apache.tomcat.core.Handler.service(Handler.java:235)
at org.apache.tomcat.facade.ServletHandler.service(ServletHandler.java:4
85)
at org.apache.tomcat.core.ContextManager.internalService(ContextManager.
java:917)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:833
)
at org.apache.tomcat.modules.server.Http10Interceptor.processConnection(
Http10Interceptor.java:176)
at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java
:494)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadP
ool.java:516)
at java.lang.Thread.run(Thread.java:534)
Root cause:
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
at java.lang.String.substring(String.java:1444)
at org.apache.jasper.runtime.PageContextImpl.getAbsolutePathRelativeToCo
ntext(PageContextImpl.java:401)
at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.jav
a:411)
at