RE: xml parsing error in tomcat3.3.a/jdk1.1.8

2002-01-22 Thread Larry Isaacs

The stack trace and log would be helpful.  I would need
to address this issue in Tomcat 3.3.1 before it releases.

Cheers,
Larry

> -Original Message-
> From: Jaishankar Jayaram [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 3:22 PM
> To: Tomcat Users List
> Subject: xml parsing error in tomcat3.3.a/jdk1.1.8
> 
> 
>I searched the archives, but couldn't determine if this is 
> a known issue.
> When starting tomcat, I kept getting an error saying there 
> was an error
> parsing the server.xml. I am using the default files, as 
> downloaded, and
> have not added any web apps either. Finally, I tried starting with the
> estart switch, and tomcat did start, but it threw an XML 
> parsing error for
> all the web apps' web.xml files (even the built in examples 
> and admin ones).
> However the example servlets all worked properly.
> 
>I can post the log error message w/ the stack trace if 
> need be, but first
> wanted to check if this is a known issue.
> 
>I am using the jdk1.1.8 compatible mrj2.2.5 and mrjsdk 2.2 
> on mac os 9.1
> and have been successfully running tomcat 3.2.x (1 through 4).
> 
> Jai
> 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




xml parsing error in tomcat3.3.a/jdk1.1.8

2002-01-22 Thread Jaishankar Jayaram

   I searched the archives, but couldn't determine if this is a known issue.
When starting tomcat, I kept getting an error saying there was an error
parsing the server.xml. I am using the default files, as downloaded, and
have not added any web apps either. Finally, I tried starting with the
estart switch, and tomcat did start, but it threw an XML parsing error for
all the web apps' web.xml files (even the built in examples and admin ones).
However the example servlets all worked properly.

   I can post the log error message w/ the stack trace if need be, but first
wanted to check if this is a known issue.

   I am using the jdk1.1.8 compatible mrj2.2.5 and mrjsdk 2.2 on mac os 9.1
and have been successfully running tomcat 3.2.x (1 through 4).

Jai


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: startup and core dump

2002-01-22 Thread David Smith

Sure -- I just upgraded my desktop system to Mandrake 8.1 and am sorting 
things out.  I'll try to send it a little later this aftenoon.

--David

On Monday 21 January 2002 03:21 pm, you wrote:
> Thanks, David,
>
> Could I ask you to send me the script you use in startup.sh?  That would be
> super.  I am quite adept at Java and C++ but have limited scripting
> abilities.
>
> -- micael
>
> At 01:40 PM 1/21/02 -0500, you wrote:
> >JDK 1.4?  I haven't worked with that yet since last I checked it was still
> > a beta release.   As far as the ulimit... line goes, I was being literal
> > (except for the quote marks :-).  At least that's the command for the
> > bash shell to limit stack space for executed commands.  It may be
> > different depending on the shell you use and I thought the seg fault
> > problem was fixed in 1.4.  Maybe not??  Hopefully someone more familiar
> > with the Bug Parade on JDK 1.4 can offer some insight.
> >
> >Anyway, if you use it, just make sure it's before the java command
> > that actually starts Tomcat itself.  I put it in the startup.sh script
> > before the call to catalina.sh since that's how I start Tomcat on the dev
> > machine.  It's in the script for starting tomcat from /etc/init.d as well
> > on my production server (Mandrake 8).
> >
> >--David
> >
> >On Monday 21 January 2002 12:40 pm, you wrote:
> > > At 10:27 AM 1/21/02 -0500, you wrote:
> > > >I believe this one is well documented, but there is an issue with JDK
> > > > 1.3.x and Linux where a stack set to unlimited will cause a seg
> > > > fault. To fix, use 'ulimit -s 2048' in either startup.sh or
> > > > catalina.sh.
> > > >
> > > >If this doesn't fix it, please post more info (OS dist, JDK version,
> > > > exact error text, etc...)
> > > >
> > > >--David
> > >
> > > I am using JDK1.4.  Would you expand on what "use 'unlimit -s 2048' in
> > > either startup.sh or catalina.sh" means in practice?  Where do I put
> > > that in startup.sh, if you are being literal?  Or, if you are not being
> > > literal, do I just put it in the command line?
> > >
> > > Should I go back to JDK1.3.1?  I really like the new stuff in JDK1.4
> > > and would like to use that if there is a possibility.
> > >
> > > Thanks for your help.
> > >
> > > - Micael
> > >
> > >
> > >
> > > --
> > > To unsubscribe:   
> > > For additional commands: 
> > > Troubles with the list: 
> >
> >--
> >To unsubscribe:   
> >For additional commands: 
> >Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Tomcat 4.0, + apache 1.3.22 + web_mod configuration

2002-01-22 Thread Tamim, Samir

must be in webapps, which is a built-in in tomcat

-Original Message-
From: Ashish kulkarni [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 14:33
To: [EMAIL PROTECTED]
Subject: Tomcat 4.0, + apache 1.3.22 + web_mod configuration


Hi,

If i have to configure tomcat4.0 with apache1.3.22
using web_mod 
1 . I have to add these lines in httpd.conf of apache
WebAppConnection conn  warp  pfizer-maps:8018
WebAppDeploy examples conn  /examples

does examples have to be in webapps directory of
apache tomcat4.0, or can be anywhere else in the the
directory structure of my win2000 server
2. which is better to use for production mod_jk or
web_mod???

Thanx for help
Ashish


__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 



web_mod is stable????

2002-01-22 Thread Ashish kulkarni

Hi,
I have configured tomcat4.0 with apache 1.3.22 using
web_mod,
it works fine but some times i get 5oo internal server
error while serving jsp. but when i refresh the page
it works again
so i want to know is this configuration stable on
win2000 andd winnt server
or should i go back to using mod_jk???
I get this error log
[org.apache.catalina.connector.warp.WarpConnection]
Exception on socket
java.net.SocketException: Connection reset by peer:
JVM_recv in socket input stream read
at java.net.SocketInputStream.socketRead(Native
Method)
at java.net.SocketInputStream.read(Unknown Source)
at java.net.SocketInputStream.read(Unknown Source)
at
org.apache.catalina.connector.warp.WarpConnection.recv(WarpConnection.java:233)
at
org.apache.catalina.connector.warp.WarpRequestHandler.handle(WarpRequestHandler.java:112)
at
org.apache.catalina.connector.warp.WarpConnection.run(WarpConnection.java:194)
at java.lang.Thread.run(Unknown Source)

Ashish

__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: multiple instance of tomcat4.0

2002-01-22 Thread Bo Xu

- Original Message - 
From: "Ashish kulkarni" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, January 22, 2002 2:37 PM
Subject: multiple instance of tomcat4.0


> Hi,
> 
> I want to create multiple instance of tomcat, so how
> can i do it???
> i have read the RUNNING.txt in the tomcat-docs
> directory, but is not very clear, 
> can anyone explain in detail about it.???
> 
> Ashish
>[...]


from:
http://jakarta.apache.org/site/mail2.html
go to:
http://www.mail-archive.com/tomcat-user@jakarta.apache.org/

then search: Configuring Multiple Tomcat JVMs with Apache - Load Balancing

you can find emails :-)

Bo
Jan222002



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




multiple instance of tomcat4.0

2002-01-22 Thread Ashish kulkarni

Hi,

I want to create multiple instance of tomcat, so how
can i do it???
i have read the RUNNING.txt in the tomcat-docs
directory, but is not very clear, 
can anyone explain in detail about it.???

Ashish

__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Tomcat 4.0, + apache 1.3.22 + web_mod configuration

2002-01-22 Thread Ashish kulkarni

Hi,

If i have to configure tomcat4.0 with apache1.3.22
using web_mod 
1 . I have to add these lines in httpd.conf of apache
WebAppConnection conn  warp  pfizer-maps:8018
WebAppDeploy examples conn  /examples

does examples have to be in webapps directory of
apache tomcat4.0, or can be anywhere else in the the
directory structure of my win2000 server
2. which is better to use for production mod_jk or
web_mod???

Thanx for help
Ashish


__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Interceptor in Tomcat 4.0 ???

2002-01-22 Thread Craig R. McClanahan



On Tue, 22 Jan 2002, Renato wrote:

> Date: Tue Jan 22 16:57:45 2002
> From: Renato <[EMAIL PROTECTED]>
> Reply-To: Tomcat Developers List <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED], [EMAIL PROTECTED]
> Subject: Interceptor in Tomcat 4.0 ???
>
> Hi all,
>
> I have an Interceptor I wrote for Tomcat 3.3 and I want to migrate to
> Catalina. I think the concept know is a Valve, right ?

That's probably the right concept to look at, depending on what you are
using your interceptor for.  You can see lots of examples of Valve
implementations in the org.apache.catalina.authenticator and
org.apache.catalina.valves packages in the Tomcat 4 source tree.

> Is there a guideline
> how to migrate an interceptor ?
>

Because the processing models are very different (interceptors call your
module lots of times for different events, while a valve is called once
and you pass the request on or not as appropriate), there is not going to
be much in the way of useful porting advice -- depending on what your
interceptor is doing, it will be anywhere from trivially easy to something
that requires multiple valves to accomplish the same functionality.
Without details, it's not possible to be more specific.

> Thanks
> Renato - Brazil.
>

Craig


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Please help! Unit test fails for Tomcat

2002-01-22 Thread kynn



   Date: Tue, 22 Jan 2002 09:52:46 -0800 (PST)
   From: Bruce Perryman <[EMAIL PROTECTED]>
   Content-Type: text/plain; charset=us-ascii

   Hi,

   We must verify that the correct versions of all the
   libs and their locations are correct.

   Are you using ant1.4?

Yes.

   Did you copy the
   ant1.4-optional.jar to the correct location?

Yes.  I copied it to ${ant.home}/lib.

   Did you
   copy xalan.jar to ${ant.home}/lib?

Yes.

   Did you follow each
   step in building.txt?

As closely as possible.  The only things I did differently are:

1. I could find only JAXP/1.2, not JAXP/1.1

2. I found it necessary to copy jaxp.jar to ${ant.home}/lib,
   otherwise 'ant -projecthelp' failed.

3. I downloaded xerces-1.4.4, instead of 1.4.3

4. The instructions do not say what to do with the
   jdbc2_0-stdext.jar.  I put it under ${base.path}/jdbc2_0-stdext.

5. The instructions say little about the meaning of the various
   variables in build.properties.  I made my best guesses at various
   points.  I include my build.properties file below.



   What jdk are you using?

1.3.1.

Thanks!

KJ

P.S.  This is my build.properties file.  For the listing here, I
indented every line by two spaces, and marked with a '*' the four
lines that differ from their corresponding lines in
build.properties.sample.


  # - Compile Control Flags -
  compile.debug=on
  compile.deprecation=off
  compile.optimize=on
  
  
  # - Build Control Flags
* full.dist=on
  #build.sysclasspath=ignore
  #flags.hide=on
  
  
  # - Default Base Path for Dependent Packages -
* base.path=/usr/local/build/tomcat
  
  
  # - Jakarta Tomcat Connectors path -
  jakarta-tomcat-connector.home=../../jakarta-tomcat-connectors
  
  
  # - Tomcat utils -
  tomcat-util.jar=../lib/tomcat-util.jar
  
  
  # - JK 1.3 connector for Tomcat 4.0 -
  tomcat-ajp.jar=../lib/tomcat-ajp.jar
  
  
  # - Jakarta Regular Expressions Library, version 1.2 -
  regexp.jar=../lib/jakarta-regexp-1.2.jar
  
  
  # - Jakarta Servlet API Classes (Servlet 2.3 / JSP 1.2) -
  servlet.home=${base.path}/jakarta-servletapi-4
  servlet.lib=${servlet.home}/lib
  servlet.jar=${servlet.lib}/servlet.jar
  
  
  # - Java Activation Framework (JAF), version 1.0.1 or later -
  activation.home=${base.path}/jaf-1.0.1
  activation.lib=${activation.home}
  activation.jar=${activation.lib}/activation.jar
  
  
  # - Java API for XML Processing (JAXP), version 1.1 or later -
* jaxp.home=${base.path}/jaxp-1.2
  jaxp.lib=${jaxp.home}
  crimson.jar=${jaxp.lib}/crimson.jar
  jaxp.jar=${jaxp.lib}/jaxp.jar
  xalan.jar=${jaxp.lib}/xalan.jar
  
  
  # - Java Database Connectivity (JDBC) Optional Package, version 2.0 -
  jdbc20ext.home=${base.path}/jdbc2_0-stdext
  jdbc20ext.lib=${jdbc20ext.home}
  jdbc20ext.jar=${jdbc20ext.lib}/jdbc2_0-stdext.jar
  
  
  # - Java Mail, version 1.2 or later -
  mail.home=${base.path}/javamail-1.2
  mail.lib=${mail.home}
  mail.jar=${mail.lib}/mail.jar
  
  
  # - Java Management Extensions (JMX) RI, version 1.0.1 or later -
  jmx.home=${base.path}/jmx-ri_1.0.1/jmx
  jmx.lib=${jmx.home}/lib
  jmxri.jar=${jmx.lib}/jmxri.jar
  
  
  # - Java Naming and Directory Interface (JNDI), version 1.2 or later -
  jndi.home=${base.path}/jndi-1.2.1
  jndi.lib=${jndi.home}/lib
  jndi.jar=${jndi.lib}/jndi.jar
  ldap.jar=${jndi.lib}/ldap.jar
  
  
  # - Java Secure Sockets Extension (JSSE), version 1.0.2 or later -
  jsse.home=${base.path}/jsse-1.0.2
  jsse.lib=${jsse.home}/lib
  jcert.jar=${jsse.lib}/jcert.jar
  jnet.jar=${jsse.lib}/jnet.jar
  jsse.jar=${jsse.lib}/jsse.jar
  
  
  # - Java Transaction API (JTA), version 1.0.1 or later -
  jta.home=${base.path}/jta-spec1_0_1
  jta.lib=${jta.home}
  jta.jar=${jta.lib}/jta-spec1_0_1.jar
  
  
  # - JUnit Unit Test Suite, version 3.7 or later -
  junit.home=${base.path}/junit3.7
  junit.lib=${junit.home}
  junit.jar=${junit.lib}/junit.jar
  
  
  # - Tyrex Data Source, version 0.9.7 -
  tyrex.home=${base.path}/tyrex-0.9.7.0
  tyrex.lib=${tyrex.home}
  tyrex.jar=${tyrex.lib}/tyrex-0.9.7.0.jar
  
  
  # - Xerces XML Parser, version 1.4.3 or later -
* xerces.home=${base.path}/xerces-1_4_4
  xerces.lib=${xerces.home}
  xerces.jar=${xerces.lib}/xerces.jar
  

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Asynchronous messages from servlets

2002-01-22 Thread Craig R. McClanahan



On Tue, 22 Jan 2002, Bo Xu wrote:

> Date: Tue, 22 Jan 2002 13:41:10 -0500
> From: Bo Xu <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: Re: Asynchronous messages from servlets
>
> - Original Message -
> From: "Craig R. McClanahan" <[EMAIL PROTECTED]>
> To: "Tomcat Users List" <[EMAIL PROTECTED]>
> Sent: Tuesday, January 22, 2002 1:04 PM
> Subject: Re: Asynchronous messages from servlets
>
>
> > On Tue, 22 Jan 2002, Ronald Wildenberg wrote:
> >
> > > Date: Tue, 22 Jan 2002 09:50:14 +0100
> > > From: Ronald Wildenberg <[EMAIL PROTECTED]>
> > > Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> > > To: [EMAIL PROTECTED]
> > > Subject: Asynchronous messages from servlets
> > >
> > > Hi,
> > >
> > > I have the following problem. A simple form submits data
> > > to a servlet. The servlet sends a message via JMS to
> > > another application (in another JVM). Once the message
> > > has been sent, the 'service' method of the servlet ends.
> > > After a while, say five seconds, the other application would
> > > like to send back a response. How do I show this response
> > > to the user?
> > >
> > > Since the 'service' method has finished after sending the
> > > message, I have lost control over the output from the other
> > > application.
> > >
> > > What I need is a way to push the response to the browser. I
> > > would like the server to take the initiative in updating the browser
> > > window, not the user. Is this possible in any way?
> > >
> > > Thanks in advance,
> > > Ronald Wildenberg
> > >
> >
> > There are two pieces to the answer for this kind of thing -- getting the
> > data back from the other JVM (I assume you are using asynchronous JMS
> > calls, right?), and displaying the data back to the user.
> >
> > For the first step, doing an asynchronous JMS call in the other direction
> > (to a JMS receiver in the same JVM as Tomcat) could then receive the
> > results, and make them available as a servlet context or session
> > attribute.
> >
> > For the second, I've seen people set up a page that uses the meta-refresh
> > capability in HTML to automatically keep sending a request every XX
> > seconds.  The servlet that receives this request will check to see if the
> > results are back yet - if they are, they are displayed, if they are not it
> > shows a "Request in Progress ... please wait" page with the meta refresh
> > tag.
> >
> > The key thing is that you won't be able to respond on the original HTTP
> > request, since that has already been sent and your service() method has
> > returned.
> >
> > Craig
> >[...]
>
>
> Thanks for your info!  if the processing of "asynchronous JMS calls" will be
> responsed  in short time by JMS-Thread, is the following(half-synchronous
> way) also possible?
> - use javax.servlet.ServletResponse.flushBuffer() to show a
>   info("please wait...") to client
> - make a asynchronous JMS calls
> - block this Servlet-Thread, wait for a "event" sent by JMS
> - when the "event" comes, the blocking ends, then the results
>   are responsed  to client, and the Servlet-Thread ends.
>
> I am not sure about:
> - can javax.servlet.ServletResponse.flushBuffer() always response
>   info to client before the Servlet-Thread ends(so the client can get
> "please wait...
>   " info)?  in my testing, it works, but some emails say that sometimes it
> can not
>   work.
> - is this half-synchronous way a good Servlet-DesignPattern if I can be sure
>   that the blocking will  not need a long-time? or it is not good?
>
> Thanks in advance!
>
> Bo
> Jan222002
>

Whether the "please wait" message will be visible or not is client
dependent.  I would still model this kind of thing as a separate request
with the meta refresh, as I outlined above (you'll need to do the JMS
query in a separate thread for this to work).

Craig


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Custom Authentication

2002-01-22 Thread Craig R. McClanahan



On Sat, 22 Jan 2000, Sergei Batiuk wrote:

> Date: Sat, 22 Jan 2000 16:04:25 +0200
> From: Sergei Batiuk <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: RE: Custom Authentication
>
> Hello,
>
> 
> If you mean a 'Login API', it doesn't exist in Tomcat You need to use
> form-based login instead.

Or write your own custom Realm implementation, using Tomcat's internal
APIs.  You'll need to download the Tomcat sources and look at the
org.apache.catalina.Realm interface (plus the existing implementations in
the org.apache.catalina.realm package).

>
> 
> There is "InitialContext" in Tomcat. This is how I used it to set up
> DataSource ( Tomcat 4.1.0) :

The general docs for this are at:

  http://jakarta.apache.org/tomcat/tomcat-4.0-doc/jndi-resources-howto.html

Craig


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Interceptor in Tomcat 4.0 ???

2002-01-22 Thread Renato

Hi all,

I have an Interceptor I wrote for Tomcat 3.3 and I want to migrate to 
Catalina. I think the concept know is a Valve, right ? Is there a guideline 
how to migrate an interceptor ?

Thanks
Renato - Brazil.

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Asynchronous messages from servlets

2002-01-22 Thread Bo Xu

- Original Message -
From: "Craig R. McClanahan" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Tuesday, January 22, 2002 1:04 PM
Subject: Re: Asynchronous messages from servlets


> On Tue, 22 Jan 2002, Ronald Wildenberg wrote:
>
> > Date: Tue, 22 Jan 2002 09:50:14 +0100
> > From: Ronald Wildenberg <[EMAIL PROTECTED]>
> > Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> > To: [EMAIL PROTECTED]
> > Subject: Asynchronous messages from servlets
> >
> > Hi,
> >
> > I have the following problem. A simple form submits data
> > to a servlet. The servlet sends a message via JMS to
> > another application (in another JVM). Once the message
> > has been sent, the 'service' method of the servlet ends.
> > After a while, say five seconds, the other application would
> > like to send back a response. How do I show this response
> > to the user?
> >
> > Since the 'service' method has finished after sending the
> > message, I have lost control over the output from the other
> > application.
> >
> > What I need is a way to push the response to the browser. I
> > would like the server to take the initiative in updating the browser
> > window, not the user. Is this possible in any way?
> >
> > Thanks in advance,
> > Ronald Wildenberg
> >
>
> There are two pieces to the answer for this kind of thing -- getting the
> data back from the other JVM (I assume you are using asynchronous JMS
> calls, right?), and displaying the data back to the user.
>
> For the first step, doing an asynchronous JMS call in the other direction
> (to a JMS receiver in the same JVM as Tomcat) could then receive the
> results, and make them available as a servlet context or session
> attribute.
>
> For the second, I've seen people set up a page that uses the meta-refresh
> capability in HTML to automatically keep sending a request every XX
> seconds.  The servlet that receives this request will check to see if the
> results are back yet - if they are, they are displayed, if they are not it
> shows a "Request in Progress ... please wait" page with the meta refresh
> tag.
>
> The key thing is that you won't be able to respond on the original HTTP
> request, since that has already been sent and your service() method has
> returned.
>
> Craig
>[...]


Thanks for your info!  if the processing of "asynchronous JMS calls" will be
responsed  in short time by JMS-Thread, is the following(half-synchronous
way) also possible?
- use javax.servlet.ServletResponse.flushBuffer() to show a
  info("please wait...") to client
- make a asynchronous JMS calls
- block this Servlet-Thread, wait for a "event" sent by JMS
- when the "event" comes, the blocking ends, then the results
  are responsed  to client, and the Servlet-Thread ends.

I am not sure about:
- can javax.servlet.ServletResponse.flushBuffer() always response
  info to client before the Servlet-Thread ends(so the client can get
"please wait...
  " info)?  in my testing, it works, but some emails say that sometimes it
can not
  work.
- is this half-synchronous way a good Servlet-DesignPattern if I can be sure
  that the blocking will  not need a long-time? or it is not good?

Thanks in advance!

Bo
Jan222002



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




how to separate SSL and non-SSL applications

2002-01-22 Thread Henry Lu

Now I setup the SSL with Tomcat 4.0 but there are number of applications running
tomcat-home/webapps/root
tomcat-home/webapps/examples
tomcat-home/webapps/my_project
tomcat-home/webapps/test
...

What I'd like to do is that I want tomcat-home/webapps/my_project is under SSL and 
rest of them are not,
or
All are under SSL.

What should I do?

Thanks, Henry


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Object streaming from applet to servlet - bad read from ajp13

2002-01-22 Thread Wigzell, Cathy

I'm running Catalina (TC4) as a servlet engine with IIS and I'm having
problems with object streaming. On the client side I have multiple threads
sending POST messages to the server, and on the server side I have a servlet
with a doPost catching the messages - all very standard. However, I often
get IOExceptions thrown on the client at out.close() and the message
'[Ajp13] bad read: -103' appears in the Catalina command window. I can't
find any information on the ajp bad read in the Tomcat documentation nor on
the web. The servlet doesn't implement SingleThreadModel so, theoretically,
a new servlet instance should be loaded for each doPost.

What is causing the bad read and why should out.close() throw an
IOException?

Many thanks for your help,
Cathy

Client:
private InputStream sendPostMessage(URL i_url) throws IOException
{
URLConnection con = i_url.openConnection();

// Prepare for both input and output
con.setDoInput(true);
con.setDoOutput(true);

// Turn off caching
con.setUseCaches(false);

// Set the content type to be java-internal/classname
con.setRequestProperty("Content-Type", "java-internal/" +
getClass().getName());

// Write the serialized object as post data
ObjectOutputStream out = new ObjectOutputStream(con.getOutputStream());
out.writeObject(this);
out.flush();
out.close();

return con.getInputStream();
}

Server:
public void doPost(HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException
{
ObjectInputStream in = new ObjectInputStream(request.getInputStream());
ObjectOutputStream out = new
ObjectOutputStream(response.getOutputStream());
MyObject obj = (APICall)in.readObject();
// do stuff with obj
}

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: applet deployment/access

2002-01-22 Thread Craig R. McClanahan



On Tue, 22 Jan 2002, Anton Brazhnyk wrote:

> Date: Tue, 22 Jan 2002 15:50:33 +0200
> From: Anton Brazhnyk <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: RE: applet deployment/access
>
> Hi,
>
> > -Original Message-
> > From: cazza [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, January 22, 2002 3:27 PM
> > To: [EMAIL PROTECTED]
> > Subject: applet deployment/access
> >
> >
> > I have a servlet that generates html which contains a reference to the
> > applet class under tomcat (the tomcat location is webapps/myapp/applet/)
> >
> > I understand that MyApplet.class cannot be under the web-inf directory for
> > security reasons, but I have two questions;
>
> I don't know any security reasons for applets to be not allowed in WEB-INF,
> there is only one reason for them: User won't be able to access them there.
> Applets are executed on client side, so browser's JVM should download .class
>

The security reason is that no client request (applet or not) is allowed
to access any resources under "/WEB-INF" (see Section 9.6 of the Servlet
2.3 spec, which you can get from
).

Applet developers must arrange that all files needed by the applet
(including the class or JAR files themselves) are available from someplace
in the web application *other* than the WEB-INF directory.

Craig McClanahan


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




source for mod_jk ??

2002-01-22 Thread Thad Humphries

Where can I download the latest source for mod_jk.so?

I once build mod_jk.so for Solaris to use with Tomcat 3.2.1.  I'm
testing an application in three Tomcat versions--3.2.4, 3.3a, and 4.01. 
I would like to build the latest version of mod_jk.so for 3.3a but I
cannot find the source.  I assume there are some difference between
3.2.x and 3.3a as the file sized under Linux are different.
-- 

Thad Humphries  "...no religious test shall ever be required
Web Development Manager  as a qualification to any office or public
Phone: 540/675-3015, x225trust under the United States." -Article VI


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Config/Startup problem contextInit() not running

2002-01-22 Thread Larry Isaacs

I think the most appropriate directory for a module is
"tomcat/lib/container", which is where most of the module
classes live.  A second possibility is "tomcat/lib/common".
"tomcat/lib" won't work, even after adding your class to the
classpath manually, because it can't see the BaseInterceptor
class in "tomcat/lib/common".  For details of the classloader
hierarchy, see:



Cheers,
Larry

> -Original Message-
> From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 12:57 PM
> To: Tomcat Users List
> Subject: RE: Config/Startup problem contextInit() not running
> 
> 
> I added the CustomRealm declaration into the modules.xml and 
> now I get a
> CNFE(ClassNotFound Exception).  This is a step in the right 
> direction, I
> know that at least my config directory is being read.  The 
> class is in a
> .jar file that is in /opt/local/tomcat/lib.  Is there 
> something that I need
> to do with the classpath somewhere to have this jar file included?
> 
> Thanks,
> Adam Paeth
> 
> > -Original Message-
> > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, January 22, 2002 11:40 AM
> > To: 'Tomcat Users List'
> > Subject: RE: Config/Startup problem contextInit() not running
> >
> >
> > More likely there is something going wrong with modules-myapp.xml.
> > Perhaps there is an problem reading a separate "modules" file and
> > context local modules. I recall something like this happening to
> > me a while back, but I forget exact problem and cause.  I'll try
> > investigating.  In the mean time, try adding the CustomRealm
> > declaration directly in modules.xml instead of using
> > modules-myapp.xml and see what happens.
> >
> > Cheers,
> > Larry
> >
> > > -Original Message-
> > > From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> > > Sent: Tuesday, January 22, 2002 12:21 PM
> > > To: Tomcat Users List
> > > Subject: RE: Config/Startup problem contextInit() not running
> > >
> > >
> > > OK, I have more clues, but no answer yet.  Here's what I did:
> > >
> > > 1> Change javaClass in modules-myapp.xml to a non-existant class.
> > >Result: no error messages.
> > >
> > > 2> change modules-myapp.xml to _modules-myapp.xml in an
> > > attempt to make TC
> > > think there is no such file
> > >Result: no error messages.
> > >
> > > 3> change  to  in apps-myapp.xml
> > >Result: no error messages.
> > >
> > > It appears to be ignoring my apps-myapp.xml file all
> > > together.  TOMCAT_HOME
> > > is set properly to /opt/local/tomcat.  I'm not sure what is
> > > happening.  I
> > > feel completely lost at this point.
> > >
> > > AP
> > >
> > > > -Original Message-
> > > > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > > > Sent: Tuesday, January 22, 2002 7:35 AM
> > > > To: 'Tomcat Users List'
> > > > Subject: RE: Config/Startup problem contextInit() not running
> > > >
> > > >
> > > > If there aren't any System.out.println's or log output being
> > > > generated by your CustomRealm, you can try temporarily removing
> > > > the myapp.tomcat.CustomRealm class from your installation and
> > > > see if Tomcat complains.  It should complain if it is acting on
> > > > your  entry but can't find the class.  An
> > > > alternative is to modify modules-myapp.xml to specify
> > > > an incorrect class name.
> > > >
> > > > Cheers,
> > > > Larry
> > > >
> > > > > -Original Message-
> > > > > From: Adam Paeth 
> [mailto:[EMAIL PROTECTED]]
> > > > > Sent: Monday, January 21, 2002 5:05 PM
> > > > > To: Tomcat Users List
> > > > > Subject: RE: Config/Startup problem contextInit() not running
> > > > >
> > > > >
> > > > > That is a great question, how do I check since I can't find
> > > > > anything in a
> > > > > log file?
> > > > >
> > > > > Thanks,
> > > > > Adam
> > > > >
> > > > > > -Original Message-
> > > > > > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > > > > > Sent: Monday, January 21, 2002 3:53 PM
> > > > > > To: 'Tomcat Users List'
> > > > > > Subject: RE: Config/Startup problem contextInit() 
> not running
> > > > > >
> > > > > >
> > > > > > I'll investigate for Tomcat 3.3a/3.3.1-dev.  Do you 
> know if your
> > > > > >  is being loaded, as opposed to 
> being ignored?
> > > > > >
> > > > > > Cheers,
> > > > > > Larry
> > > > > >
> > > > > > > -Original Message-
> > > > > > > From: Adam Paeth
> > > [mailto:[EMAIL PROTECTED]]
> > > > > > > Sent: Monday, January 21, 2002 4:10 PM
> > > > > > > To: Tomcat User List
> > > > > > > Subject: Config/Startup problem contextInit() not running
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > I'm going crazy trying to figure this out...
> > > > > > >
> > > > > > > I've re-written a customized realm that we used for our
> > > > > > > Tomcat 3.2.1 (now
> > > > > > > for 3.3).  For some reason the debug messages that I've
> > > > > put into the
> > > > > > > contextInit() method are not showing up on the 

Re: Asynchronous messages from servlets

2002-01-22 Thread Craig R. McClanahan

On Tue, 22 Jan 2002, Ronald Wildenberg wrote:

> Date: Tue, 22 Jan 2002 09:50:14 +0100
> From: Ronald Wildenberg <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Subject: Asynchronous messages from servlets
>
> Hi,
>
> I have the following problem. A simple form submits data
> to a servlet. The servlet sends a message via JMS to
> another application (in another JVM). Once the message
> has been sent, the 'service' method of the servlet ends.
> After a while, say five seconds, the other application would
> like to send back a response. How do I show this response
> to the user?
>
> Since the 'service' method has finished after sending the
> message, I have lost control over the output from the other
> application.
>
> What I need is a way to push the response to the browser. I
> would like the server to take the initiative in updating the browser
> window, not the user. Is this possible in any way?
>
> Thanks in advance,
> Ronald Wildenberg
>

There are two pieces to the answer for this kind of thing -- getting the
data back from the other JVM (I assume you are using asynchronous JMS
calls, right?), and displaying the data back to the user.

For the first step, doing an asynchronous JMS call in the other direction
(to a JMS receiver in the same JVM as Tomcat) could then receive the
results, and make them available as a servlet context or session
attribute.

For the second, I've seen people set up a page that uses the meta-refresh
capability in HTML to automatically keep sending a request every XX
seconds.  The servlet that receives this request will check to see if the
results are back yet - if they are, they are displayed, if they are not it
shows a "Request in Progress ... please wait" page with the meta refresh
tag.

The key thing is that you won't be able to respond on the original HTTP
request, since that has already been sent and your service() method has
returned.

Craig


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Tomcat 4.0 with SSL

2002-01-22 Thread Henry Lu

I followed the every steps in the doc for how-to do ssl. But I got
failure when I start the tomcat.
Since I couldn't see all error message, here is the on on the screen:

at java.lang.reflect.Method.invoke(Native Method)
at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243)
- Root Cause -
java.io.IOException: java.security.UnrecoverableKeyException: Cannot
recover key

at
org.apache.catalina.net.SSLServerSocketFactory.initProxy(SSLServerSoc
ketFactory.java:422)
at
org.apache.catalina.net.SSLServerSocketFactory.initialize(SSLServerSo
cketFactory.java:334)
at
org.apache.catalina.net.SSLServerSocketFactory.createSocket(SSLServer
SocketFactory.java:287)
at
org.apache.catalina.connector.http.HttpConnector.open(HttpConnector.j
ava:946)
at
org.apache.catalina.connector.http.HttpConnector.initialize(HttpConne
ctor.java:1114)
at
org.apache.catalina.core.StandardService.initialize(StandardService.j
ava:454)
at
org.apache.catalina.core.StandardServer.initialize(StandardServer.jav
a:552)
at
org.apache.catalina.startup.Catalina.start(Catalina.java:775)
at
org.apache.catalina.startup.Catalina.execute(Catalina.java:681)
at
org.apache.catalina.startup.Catalina.process(Catalina.java:179)
at java.lang.reflect.Method.invoke(Native Method)
at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:243)

Is there any answer?

Thanks, Henry

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Running Microsoft Stress Tool (WAS) with Tomcat

2002-01-22 Thread Larry Isaacs

This looks like Tomcat 3.2.x.  Bugs:



and



report this problem. Bug 1114 indicates this was fixed in
Tomcat 3.2.4. However, I believe the fix is that it doesn't
throw an exception, but simply ignores the cookie so the
request can continue.  I have vague recollections of this
error being reported as occurring when no one set the
cookie name to the reserved token.  We were never able to
duplicate this error and trace its cause.

Cookie handling was refactored in Tomcat 3.3 and I don't recall
this problem being reported against 3.3.  You might try
a newer version of Tomcat, 3.3.x or 4.x and see if this
problem is still present.

Cheers,
Larry

> -Original Message-
> From: David Cassidy [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 12:29 PM
> To: Tomcat Users List
> Subject: Re: Running Microsoft Stress Tool (WAS) with Tomcat
> 
> 
> your cookie isn't called 'path' by any chance ?
> 
> > > Cookie name Path is a reserved token
> 
> 
> 
> Sanjeev Joshi wrote:
> 
> > There is no problem with the code .  Using the Browser  the 
> pages are rendered without any
> > problem. Also the Same   web-app when deployed with Jrun  
> and WAS is run on that works
> > just fine 
> >
> > -Joshi
> >
> > David Cassidy wrote:
> >
> > > what does the source code of the affected page look like ?
> > >
> > > Does this happen with a 'HelloWorld.jsp' type page ?
> > >
> > > D
> > >
> > > Sanjeev Joshi wrote:
> > >
> > > > Hi all,
> > > >
> > > > On running  this stress tool with Tomcat I get these errors ;
> > > >
> > > > 2002-01-22 22:11:31 - Ctx( /uii-example ): Exception 
> in: R( /uii-example
> > > > + /index.jsp + null) -
> > > >  java.lang.IllegalArgumentException: Cookie name Path 
> is a reserved
> > > > token
> > > > at javax.servlet.http.Cookie.(Cookie.java:185)
> > > > at
> > > > 
> org.apache.tomcat.util.RequestUtil.processCookies(RequestUtil.
> java:189)
> > > > at
> > > > 
> org.apache.tomcat.core.RequestImpl.getCookieCount(RequestImpl.
> java:510)
> > > > at
> > > > 
> org.apache.tomcat.session.StandardSessionInterceptor.requestMa
> p(StandardSessionInter
> > > >
> > > > ceptor.java:145)
> > > > at
> > > > 
> org.apache.tomcat.core.ContextManager.processRequest(ContextMa
> nager.java:835)
> > > >
> > > > at
> > > > 
> org.apache.tomcat.core.ContextManager.internalService(ContextM
> anager.java:786)
> > > >
> > > > at
> > > > 
> org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
> > > > at
> > > > 
> org.apache.tomcat.service.http.HttpConnectionHandler.processCo
> nnection(HttpConnectio
> > > >
> > > > nHandler.java:213)
> > > > at
> > > > 
> org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoin
> t.java:416)
> > > >
> > > > at
> > > > 
> org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPo
> ol.java:501)
> > > >
> > > > at java.lang.Thread.run(Thread.java:484)
> > > >
> > > > The result in the Stress Tool show as   500 Inrenal 
> Server Error !!!
> > > >
> > > > Any ideas  what  is the reason ?? Is it a Bug with 
> Tomcat   ( not able
> > > > to handle multiple requests ! )
> > > >
> > > > -Joshi
> > > >
> > > > --
> > > > To unsubscribe:   
> 
> > > > For additional commands: 
> 
> > > > Troubles with the list: 
> 
> > >
> > > --
> > > To unsubscribe:   
> 
> > > For additional commands: 
> 
> > > Troubles with the list: 
> 
> >
> > --
> > To unsubscribe:   
> 
> > For additional commands: 
> 
> > Troubles with the list: 
> 
> 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Config/Startup problem contextInit() not running

2002-01-22 Thread Adam Paeth

I added the CustomRealm declaration into the modules.xml and now I get a
CNFE(ClassNotFound Exception).  This is a step in the right direction, I
know that at least my config directory is being read.  The class is in a
.jar file that is in /opt/local/tomcat/lib.  Is there something that I need
to do with the classpath somewhere to have this jar file included?

Thanks,
Adam Paeth

> -Original Message-
> From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 11:40 AM
> To: 'Tomcat Users List'
> Subject: RE: Config/Startup problem contextInit() not running
>
>
> More likely there is something going wrong with modules-myapp.xml.
> Perhaps there is an problem reading a separate "modules" file and
> context local modules. I recall something like this happening to
> me a while back, but I forget exact problem and cause.  I'll try
> investigating.  In the mean time, try adding the CustomRealm
> declaration directly in modules.xml instead of using
> modules-myapp.xml and see what happens.
>
> Cheers,
> Larry
>
> > -Original Message-
> > From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, January 22, 2002 12:21 PM
> > To: Tomcat Users List
> > Subject: RE: Config/Startup problem contextInit() not running
> >
> >
> > OK, I have more clues, but no answer yet.  Here's what I did:
> >
> > 1> Change javaClass in modules-myapp.xml to a non-existant class.
> >Result: no error messages.
> >
> > 2> change modules-myapp.xml to _modules-myapp.xml in an
> > attempt to make TC
> > think there is no such file
> >Result: no error messages.
> >
> > 3> change  to  in apps-myapp.xml
> >Result: no error messages.
> >
> > It appears to be ignoring my apps-myapp.xml file all
> > together.  TOMCAT_HOME
> > is set properly to /opt/local/tomcat.  I'm not sure what is
> > happening.  I
> > feel completely lost at this point.
> >
> > AP
> >
> > > -Original Message-
> > > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > > Sent: Tuesday, January 22, 2002 7:35 AM
> > > To: 'Tomcat Users List'
> > > Subject: RE: Config/Startup problem contextInit() not running
> > >
> > >
> > > If there aren't any System.out.println's or log output being
> > > generated by your CustomRealm, you can try temporarily removing
> > > the myapp.tomcat.CustomRealm class from your installation and
> > > see if Tomcat complains.  It should complain if it is acting on
> > > your  entry but can't find the class.  An
> > > alternative is to modify modules-myapp.xml to specify
> > > an incorrect class name.
> > >
> > > Cheers,
> > > Larry
> > >
> > > > -Original Message-
> > > > From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> > > > Sent: Monday, January 21, 2002 5:05 PM
> > > > To: Tomcat Users List
> > > > Subject: RE: Config/Startup problem contextInit() not running
> > > >
> > > >
> > > > That is a great question, how do I check since I can't find
> > > > anything in a
> > > > log file?
> > > >
> > > > Thanks,
> > > > Adam
> > > >
> > > > > -Original Message-
> > > > > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > > > > Sent: Monday, January 21, 2002 3:53 PM
> > > > > To: 'Tomcat Users List'
> > > > > Subject: RE: Config/Startup problem contextInit() not running
> > > > >
> > > > >
> > > > > I'll investigate for Tomcat 3.3a/3.3.1-dev.  Do you know if your
> > > > >  is being loaded, as opposed to being ignored?
> > > > >
> > > > > Cheers,
> > > > > Larry
> > > > >
> > > > > > -Original Message-
> > > > > > From: Adam Paeth
> > [mailto:[EMAIL PROTECTED]]
> > > > > > Sent: Monday, January 21, 2002 4:10 PM
> > > > > > To: Tomcat User List
> > > > > > Subject: Config/Startup problem contextInit() not running
> > > > > >
> > > > > >
> > > > > >
> > > > > > I'm going crazy trying to figure this out...
> > > > > >
> > > > > > I've re-written a customized realm that we used for our
> > > > > > Tomcat 3.2.1 (now
> > > > > > for 3.3).  For some reason the debug messages that I've
> > > > put into the
> > > > > > contextInit() method are not showing up on the console or any
> > > > > > log files.  It
> > > > > > doesn't appear that the method is running.  Can anyone tell
> > > > > > me why this is
> > > > > > happening and the best approach to fixing it?
> > > > > >
> > > > > > After getting some advice from a previous post I setup the
> > > > > > config files as
> > > > > > such:
> > > > > >
> > > > > > apps-myapp.xml
> > > > > > --
> > > > > > 
> > > > > > 
> > > > > > > > > > > docBase="webapps/myapp"
> > > > > > debug="1"
> > > > > > reloadable="true" >
> > > > > >   
> > > > > >> > > path="logs/myapp.log" />
> > > > > >> > > > >  path="logs/servlet_myapp.log"
> > > > > >  servletLogger="true"/>
> > > > > >   
> > > > > >
> > > > > > 
> > > > > >
> > > > > > modules-myapp.xml
> > > > > > -
> > > > > > 
> > > > > > 
> > > > 

help me please, mod_webapp.so not created.

2002-01-22 Thread Gabriel Lopez Millan

  Hi all.

   I have redhat 7.2 with apache 2.0.28 and tomcat-4.0.1
   I have download webapp-module-1.0.1-tc401-src.tar.gz

   In Readme.txt say:

1)
cvs -d :pserver:[EMAIL PROTECTED]:/home/cvspublic login
   (Logging in to [EMAIL PROTECTED] )
   CVS password: anoncvs
   cvs -d :pserver:[EMAIL PROTECTED]:/home/cvspublic \
   checkout jakarta-tomcat-connectors/webapp

   OK

2)
 cd ./jakarta-tomcat-connectors/webapp
   cvs -d :pserver:[EMAIL PROTECTED]:/home/cvspublic \
   checkout apr
   OK

3) ./support/buildconf.sh
   OK

4)
./configure --with-apxs=/usr/local/apache2/bin/apxs 
--with-tomcat=/usr/local/jakarta-tomcat-4.0.1/
--with-java=/usr/local/jdk/

   OK

5) make
IT SAY:
*** Warning: This library needs some functionality provided by -lwebapp.
*** I have the capability to make that library automatically link in when
*** you link to this library.  But I can only do this if you have a
*** shared version of the library, which you do not appear to have.

*** Warning: libtool could not satisfy all declared inter-library
*** dependencies of module mod_webapp.  Therefore, libtool will create
*** a static module, that should work as long as the dlopening
*** application is linked with the -dlopen flag.

in /usr/src/jakarta-tomcat-connectors/webapp/apache-2.0 have:
mod_webapp.c
-rw-r--r--1 root root  654 ene 21 17:05 mod_webapp.la
-rw-r--r--1 root root90196 ene 21 17:05 mod_webapp.lo
-rw-r--r--1 root root89980 ene 21 17:05 mod_webapp.o
-rw-r--r--1 root root0 ene 21 17:05 mod_webapp.slo

but thereisn't a mod_webapp.so file ¡¡

Can anybody tell me where is the fail¡¡

   Thanks in advance 
   



-- 
-
Gabriel Lopez Millan - Grupo ANTS-CIRCuS
Facultad de Informática
Universidad de Murcia (España) Tfo: +34 968367645



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: web.xml Question

2002-01-22 Thread Craig R. McClanahan



On Tue, 22 Jan 2002, Tom Bednarz wrote:

> Date: Tue, 22 Jan 2002 08:48:40 +0100
> From: Tom Bednarz <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Subject: web.xml Question
>
> Hi everybody,
>
> Usually the web.xml file of a web application starts with the following:
>
>  2.3//EN"
>  "http://java.sun.com/dtd/web-app_2_3.dtd";>
>
> This URL referst to the dtd file on SUN's server. I think most XML parsers
> like SAX need to read the dtd file to be able to parse the XML file.
>
> Questions:
>
> What happens if I deploy an application on an Intranet which allows access
> to the internet only through a proxy server (with username / password
> authentication)? The dtd cannot be accessed and must be someware on the
> local disk.
>

It's actually inside the servlet.jar file.  Tomcat registers a local copy
of the DTDs it uses, so as long as you spell the public identifier
correctly the internal copy will be used.

I use this mode of operation all the time, to run Tomcat on a disconnected
laptop.  The only other reason it might not work is if you are using an
XML parser that does not properly implement the SAX EntityResolver APIs.

> I found that TOMCAT has a web.xml in its conf directory. Could anybody
> explain me, which XML files I need to change and where do I need to put the
> downloaded web-app_2_3.dtd file?  Is the web.xml in the conf directory like
> a parent to all web.xml files found under webapps\\WEB-INF?
> (Something like the defaults for all web apps)?
>
> Could anybody help me out of this XML jungle?
>
> Many thanks!
>
> Thomas
>

Craig


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: How to capture authentication errors

2002-01-22 Thread Craig R. McClanahan

On Tue, 22 Jan 2002, Andrea Cervellati wrote:

> Date: Tue, 22 Jan 2002 08:36:41 +0100 (MET)
> From: Andrea Cervellati <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>,
>  Andrea Cervellati <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Subject: How to capture authentication errors
>
> Hi,
>
> I'm using JBoss and Tomcat to develop my web application.
>
> I have a security domain and the user must authenticate itself to access the
> restricted area.
>
> I'm using the DatabaseServer login module and I have defined the necessary
> tables.
>
> I want to display an error page when the user is not allowed to access instead
> of the HTTP-403 error message.
>
> The error.jsp page starts with the following:
>
> <%@ page language="java" session="false" isThreadSafe="false" info="Error Page"
> isErrorPage="true" %>
>
> In my jboss-web.xml I've specified that the security domain to be used is the
> same of the Jboss EJB container:
>
>  java:/jaas/modulojdbc
> 
>
> I've tried to add the following lines in the web.xml:
>
> 
>  403
>  /error.jsp
> 
>

This is the right way to do what you want.

> but I keep having the HTTP-403 message displaied.
>

Tomcat 4.0 and 4.0.1 did not support user-defined error pages for
authentication errors.  Could you please try this with Tomcat 4.0.2b2
instead?


> I've also tried to use the  tag like this:
>
> 
> FORM
> 
> /login.jsp
> /error.jsp
> 
> 
>
> , but still have the problem
>

That's because the form error page is only used when the username/pasword
combination is not recognized (essentially, it replaces a 401 status).
The 403 error means that the container figured out who the user was --
that person just doesn't have one of the required roles to access the
requested resource.

> What can I do?
> Should I add anything else in the jboss-web.xml?
>
> I've posted rhis question even in the Java Forums and someone answered me that
> he had to change the Tomcat source to fix the problem.
>
> Please help!
>
>Thanks in advance
>

Craig McClanahan


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: question on form login

2002-01-22 Thread Craig R. McClanahan



On Tue, 22 Jan 2002, Arion Yu wrote:

> Date: Tue, 22 Jan 2002 11:09:13 +0800
> From: Arion Yu <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: Re: question on form login
>
> Hi!
>
> Would the world becomes better if we can have this situation defineds in
> the next servlet specification?
>

If you want to see that happen, please provide feedback on the servlet
spec to <[EMAIL PROTECTED]>.  Otherwise, nobody in the
servlet spec expert group (JSR-154) will know that someone cares about
this.

> Thanks
>
> Arion
>

Craig


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Config/Startup problem contextInit() not running

2002-01-22 Thread Larry Isaacs

More likely there is something going wrong with modules-myapp.xml.
Perhaps there is an problem reading a separate "modules" file and
context local modules. I recall something like this happening to
me a while back, but I forget exact problem and cause.  I'll try
investigating.  In the mean time, try adding the CustomRealm
declaration directly in modules.xml instead of using
modules-myapp.xml and see what happens.

Cheers,
Larry

> -Original Message-
> From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 12:21 PM
> To: Tomcat Users List
> Subject: RE: Config/Startup problem contextInit() not running
> 
> 
> OK, I have more clues, but no answer yet.  Here's what I did:
> 
> 1> Change javaClass in modules-myapp.xml to a non-existant class.
>Result: no error messages.
> 
> 2> change modules-myapp.xml to _modules-myapp.xml in an 
> attempt to make TC
> think there is no such file
>Result: no error messages.
> 
> 3> change  to  in apps-myapp.xml
>Result: no error messages.
> 
> It appears to be ignoring my apps-myapp.xml file all 
> together.  TOMCAT_HOME
> is set properly to /opt/local/tomcat.  I'm not sure what is 
> happening.  I
> feel completely lost at this point.
> 
> AP
> 
> > -Original Message-
> > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, January 22, 2002 7:35 AM
> > To: 'Tomcat Users List'
> > Subject: RE: Config/Startup problem contextInit() not running
> >
> >
> > If there aren't any System.out.println's or log output being
> > generated by your CustomRealm, you can try temporarily removing
> > the myapp.tomcat.CustomRealm class from your installation and
> > see if Tomcat complains.  It should complain if it is acting on
> > your  entry but can't find the class.  An
> > alternative is to modify modules-myapp.xml to specify
> > an incorrect class name.
> >
> > Cheers,
> > Larry
> >
> > > -Original Message-
> > > From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> > > Sent: Monday, January 21, 2002 5:05 PM
> > > To: Tomcat Users List
> > > Subject: RE: Config/Startup problem contextInit() not running
> > >
> > >
> > > That is a great question, how do I check since I can't find
> > > anything in a
> > > log file?
> > >
> > > Thanks,
> > > Adam
> > >
> > > > -Original Message-
> > > > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > > > Sent: Monday, January 21, 2002 3:53 PM
> > > > To: 'Tomcat Users List'
> > > > Subject: RE: Config/Startup problem contextInit() not running
> > > >
> > > >
> > > > I'll investigate for Tomcat 3.3a/3.3.1-dev.  Do you know if your
> > > >  is being loaded, as opposed to being ignored?
> > > >
> > > > Cheers,
> > > > Larry
> > > >
> > > > > -Original Message-
> > > > > From: Adam Paeth 
> [mailto:[EMAIL PROTECTED]]
> > > > > Sent: Monday, January 21, 2002 4:10 PM
> > > > > To: Tomcat User List
> > > > > Subject: Config/Startup problem contextInit() not running
> > > > >
> > > > >
> > > > >
> > > > > I'm going crazy trying to figure this out...
> > > > >
> > > > > I've re-written a customized realm that we used for our
> > > > > Tomcat 3.2.1 (now
> > > > > for 3.3).  For some reason the debug messages that I've
> > > put into the
> > > > > contextInit() method are not showing up on the console or any
> > > > > log files.  It
> > > > > doesn't appear that the method is running.  Can anyone tell
> > > > > me why this is
> > > > > happening and the best approach to fixing it?
> > > > >
> > > > > After getting some advice from a previous post I setup the
> > > > > config files as
> > > > > such:
> > > > >
> > > > > apps-myapp.xml
> > > > > --
> > > > > 
> > > > > 
> > > > > > > > > docBase="webapps/myapp"
> > > > > debug="1"
> > > > > reloadable="true" >
> > > > >   
> > > > >> > path="logs/myapp.log" />
> > > > >> > > >  path="logs/servlet_myapp.log"
> > > > >  servletLogger="true"/>
> > > > >   
> > > > >
> > > > > 
> > > > >
> > > > > modules-myapp.xml
> > > > > -
> > > > > 
> > > > > 
> > > > >> > javaClass="myapp.tomcat.CustomRealm"/>
> > > > > 
> > > > >
> > > > > Thanks,
> > > > > Adam Paeth
> > > > >
> > > > >
> > > > > --
> > > > > To unsubscribe:
> > > 
> > > > > For additional commands:
> > > 
> > > > > Troubles with the list:
> > > 
> > > > >
> > > >
> > > > --
> > > > To unsubscribe:
> > > 
> > > > For additional commands:
> > > 
> > > > Troubles with the list:
> > > 
> > > >
> > > >
> > >
> > >
> > > --
> > > To unsubscribe:   
> 
> > > For additional commands: 
> 
> > > Troubles with the list: 
> 
> > >
> >
> > --
> > To unsubscribe:   
> 
> > For addi

Re: Running Microsoft Stress Tool (WAS) with Tomcat

2002-01-22 Thread David Cassidy

your cookie isn't called 'path' by any chance ?

> > Cookie name Path is a reserved token



Sanjeev Joshi wrote:

> There is no problem with the code .  Using the Browser  the pages are rendered 
>without any
> problem. Also the Same   web-app when deployed with Jrun  and WAS is run on that 
>works
> just fine 
>
> -Joshi
>
> David Cassidy wrote:
>
> > what does the source code of the affected page look like ?
> >
> > Does this happen with a 'HelloWorld.jsp' type page ?
> >
> > D
> >
> > Sanjeev Joshi wrote:
> >
> > > Hi all,
> > >
> > > On running  this stress tool with Tomcat I get these errors ;
> > >
> > > 2002-01-22 22:11:31 - Ctx( /uii-example ): Exception in: R( /uii-example
> > > + /index.jsp + null) -
> > >  java.lang.IllegalArgumentException: Cookie name Path is a reserved
> > > token
> > > at javax.servlet.http.Cookie.(Cookie.java:185)
> > > at
> > > org.apache.tomcat.util.RequestUtil.processCookies(RequestUtil.java:189)
> > > at
> > > org.apache.tomcat.core.RequestImpl.getCookieCount(RequestImpl.java:510)
> > > at
> > > 
>org.apache.tomcat.session.StandardSessionInterceptor.requestMap(StandardSessionInter
> > >
> > > ceptor.java:145)
> > > at
> > > org.apache.tomcat.core.ContextManager.processRequest(ContextManager.java:835)
> > >
> > > at
> > > org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:786)
> > >
> > > at
> > > org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
> > > at
> > > 
>org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectio
> > >
> > > nHandler.java:213)
> > > at
> > > org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
> > >
> > > at
> > > org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
> > >
> > > at java.lang.Thread.run(Thread.java:484)
> > >
> > > The result in the Stress Tool show as   500 Inrenal Server Error !!!
> > >
> > > Any ideas  what  is the reason ?? Is it a Bug with Tomcat   ( not able
> > > to handle multiple requests ! )
> > >
> > > -Joshi
> > >
> > > --
> > > To unsubscribe:   
> > > For additional commands: 
> > > Troubles with the list: 
> >
> > --
> > To unsubscribe:   
> > For additional commands: 
> > Troubles with the list: 
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Jasper error

2002-01-22 Thread Randy Layman


First, packages don't have to be used, but since not using packages
can lead to problems (name collision and difficulty of finding anything),
they are strongly discouraged.

WEB-INF\classes is where you put your individual class files (as in
not your JAR files).  For most applications this directory will have a few
other directories that will be the top level package.  Also any unpackaged
classes can go in this directory.  For example, if you had an unpackaged
class called UserData and a packaged class com.doradosoftware.UserData, your
classes directory would have a directory called com and a file
UserData.class.

In your JSP, practically speaking you must somehow import every
class that your JSP page will use.  If the classes are in a package you can
do a com.doradosoftware.*, but if they aren't in a package then you must
specifically import each class individually.

Randy

PS For the purpose of this email, packaged and unpackaged mean whether or
not the class file uses the package statement, not how the file might or
might not be bundled.


> -Original Message-
> From: Debby Dart [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 12:15 PM
> To: 'Tomcat Users List'
> Subject: RE: Jasper error
> 
> 
> Thanks for all the great response - but I'm still confused 
> about what the
> "WEB-INF\classes directory is for if packages have to be used.
> 
> Debby
> 
> -Original Message-
> From: Justin Rowles [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 5:21 AM
> To: 'Tomcat Users List'
> Subject: RE: Jasper error
> 
> 
> > I have looked at most of the documentation I can find and 
> tried to use
> > web.xml - going to this list with such a basic question is a
> > last resort.
> 
> Firstly well done - a decent effort with the docs is something to be
> congratulated upon.
> 
> > Class org.apache.jsp.UserData not found.
> 
> This is the line you need to pay attention to.  The line-fragment
> 'Class="UserData"' doesn't tell the compiler enough.  You 
> need to tell it
> more information about where to find the class, such as the 
> package, or it
> assumes it is in the same package as the thing it is 
> compiling - in this
> case org.apache.jsp.*
> 
> Justin.
> --
> You're only jealous cos the little penguins are talking to me.
> 
> 
> 
> ***
> For more information on Ordnance Survey products and services,
> visit our web site at http://www.ordnancesurvey.co.uk
> ***
> 
> 
> 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 
> 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Config/Startup problem contextInit() not running

2002-01-22 Thread Adam Paeth

OK, I have more clues, but no answer yet.  Here's what I did:

1> Change javaClass in modules-myapp.xml to a non-existant class.
   Result: no error messages.

2> change modules-myapp.xml to _modules-myapp.xml in an attempt to make TC
think there is no such file
   Result: no error messages.

3> change  to  in apps-myapp.xml
   Result: no error messages.

It appears to be ignoring my apps-myapp.xml file all together.  TOMCAT_HOME
is set properly to /opt/local/tomcat.  I'm not sure what is happening.  I
feel completely lost at this point.

AP

> -Original Message-
> From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 7:35 AM
> To: 'Tomcat Users List'
> Subject: RE: Config/Startup problem contextInit() not running
>
>
> If there aren't any System.out.println's or log output being
> generated by your CustomRealm, you can try temporarily removing
> the myapp.tomcat.CustomRealm class from your installation and
> see if Tomcat complains.  It should complain if it is acting on
> your  entry but can't find the class.  An
> alternative is to modify modules-myapp.xml to specify
> an incorrect class name.
>
> Cheers,
> Larry
>
> > -Original Message-
> > From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> > Sent: Monday, January 21, 2002 5:05 PM
> > To: Tomcat Users List
> > Subject: RE: Config/Startup problem contextInit() not running
> >
> >
> > That is a great question, how do I check since I can't find
> > anything in a
> > log file?
> >
> > Thanks,
> > Adam
> >
> > > -Original Message-
> > > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > > Sent: Monday, January 21, 2002 3:53 PM
> > > To: 'Tomcat Users List'
> > > Subject: RE: Config/Startup problem contextInit() not running
> > >
> > >
> > > I'll investigate for Tomcat 3.3a/3.3.1-dev.  Do you know if your
> > >  is being loaded, as opposed to being ignored?
> > >
> > > Cheers,
> > > Larry
> > >
> > > > -Original Message-
> > > > From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> > > > Sent: Monday, January 21, 2002 4:10 PM
> > > > To: Tomcat User List
> > > > Subject: Config/Startup problem contextInit() not running
> > > >
> > > >
> > > >
> > > > I'm going crazy trying to figure this out...
> > > >
> > > > I've re-written a customized realm that we used for our
> > > > Tomcat 3.2.1 (now
> > > > for 3.3).  For some reason the debug messages that I've
> > put into the
> > > > contextInit() method are not showing up on the console or any
> > > > log files.  It
> > > > doesn't appear that the method is running.  Can anyone tell
> > > > me why this is
> > > > happening and the best approach to fixing it?
> > > >
> > > > After getting some advice from a previous post I setup the
> > > > config files as
> > > > such:
> > > >
> > > > apps-myapp.xml
> > > > --
> > > > 
> > > > 
> > > > > > > docBase="webapps/myapp"
> > > > debug="1"
> > > > reloadable="true" >
> > > >   
> > > >> path="logs/myapp.log" />
> > > >> > >  path="logs/servlet_myapp.log"
> > > >  servletLogger="true"/>
> > > >   
> > > >
> > > > 
> > > >
> > > > modules-myapp.xml
> > > > -
> > > > 
> > > > 
> > > >> javaClass="myapp.tomcat.CustomRealm"/>
> > > > 
> > > >
> > > > Thanks,
> > > > Adam Paeth
> > > >
> > > >
> > > > --
> > > > To unsubscribe:
> > 
> > > > For additional commands:
> > 
> > > > Troubles with the list:
> > 
> > > >
> > >
> > > --
> > > To unsubscribe:
> > 
> > > For additional commands:
> > 
> > > Troubles with the list:
> > 
> > >
> > >
> >
> >
> > --
> > To unsubscribe:   
> > For additional commands: 
> > Troubles with the list: 
> >
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
>
>


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Tomcat 4.0.2-b2 + JSSE + Security Manager

2002-01-22 Thread Renato

Hi all,

I'm installing Tomcat 4.0.2B2. Everything is fine except for the following:

- I try to run a servlet that uses JSSE. If I start Catalina without the '-
security' it works fine, if I start with the '-security' it generates the 
error: 

java.net.SocketException: SSL implementation not available
(...)

The JSSE libraries are on ${java.home}/jre/lib/ext and this path has 
permission to all.

I also tried on Tomcat 3.3 and the servlet works with or without the 
security manager.

Any hint ?

Thanks
Renato - Brazil

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: running jar files

2002-01-22 Thread Cressatti, Dominique

May be I wasn't too clear.

actually something like:
 c:\> java -cp jarfile1.jar;jarfile2.jar; com.lansa.web.admin.WebAdmin
works very well and am just trying to reproduce that under
tomcat4.

I've even extracted all the content of lansa.jar and swingall.jar
and copied it under /webapps/lansa/WEB-INF/classes
but no matter I always seem to get the "dependency" issue.
I believe there's no classes missing cos I know those jar files
work using jserve but it seem that tomcat can't find the required
classes.

Thanks
Dom

-Original Message-
From: Reynir Hübner [mailto:[EMAIL PROTECTED]]
Sent: 22 January 2002 16:36
To: Tomcat Users List
Subject: RE: running jar files


To execute a Jar file I would do 
 c:\> java -jar jarfile.jar
 if I was trying to execute a specific class in a jar file I would do : 
 c:\> java -cp jarfile1.jar;jarfile2.jar; com.lansa.web.admin.WebAdmin

If that doesn´t work I would check if this class really exists in the
jarfiles I have, and if I have the correct path.
Anyways it seems that you are executing the correct class, but it does
not get to another class that should be in the jarfiles that you have in
your classpath.  So, I would check if I had this class
com.lansa.web.servlet in my jarfiles (the ones in my classpath). 
maybe it isn´t there, then you should head back to the download page or
something. 
I dont know this product and I´ve never used it. It seems like you´re
haveing problems with basic java stuff, really just pretty much off
topic for this list.

 hope it helps, 
  regards, 
[EMAIL PROTECTED]



 


-Original Message-
From: Cressatti, Dominique [mailto:[EMAIL PROTECTED]]
Sent: 22. janúar 2002 16:25
To: Tomcat Users List
Subject: running jar files


I have some jar files, swingall.jar and lansa.jar
How do I do the equivalent of:
java -cp ./:./lansa.jar:./swingall.jar com.lansa.web.admin.WebAbmin
which basically run manually  the WebAdmin applet.
I know it's an applet but there is a servlet equivalent.
 
Sorry if this is too much of a basic question but after 3 days
of trying just about every combination under the sun, am still getting
nowhere,
all I ever get is "java.lang.NoClassDefFoundError...
com/lansa/web/servlet"
  
Dom


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Jasper error

2002-01-22 Thread Debby Dart

Thanks for all the great response - but I'm still confused about what the
"WEB-INF\classes directory is for if packages have to be used.

Debby

-Original Message-
From: Justin Rowles [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 5:21 AM
To: 'Tomcat Users List'
Subject: RE: Jasper error


> I have looked at most of the documentation I can find and tried to use
> web.xml - going to this list with such a basic question is a
> last resort.

Firstly well done - a decent effort with the docs is something to be
congratulated upon.

> Class org.apache.jsp.UserData not found.

This is the line you need to pay attention to.  The line-fragment
'Class="UserData"' doesn't tell the compiler enough.  You need to tell it
more information about where to find the class, such as the package, or it
assumes it is in the same package as the thing it is compiling - in this
case org.apache.jsp.*

Justin.
--
You're only jealous cos the little penguins are talking to me.



***
For more information on Ordnance Survey products and services,
visit our web site at http://www.ordnancesurvey.co.uk
***




--
To unsubscribe:   
For additional commands: 
Troubles with the list: 



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Keystore format

2002-01-22 Thread Joaquín Sánchez Jiménez

Hi:

To do this you must create your own SSLSocketFactory. See 
org.apache.tomcat.net.SSLSocketFactory class from TOMCAT source.
You will see why you can only have JKS store type.
Once you have create it, you must config server.xml file:











To get PrivateKey you can use this lines:

// JKS format.
KeyStore ks = KeyStore.getInstance("JKS");
// PKCS12 format using JSSE 1.0.2.
Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());
KeyStore ks = KeyStore.getInstance("PKCS12");

ks.load(new FileInputStream("PATH_TO_KEY_STORE"), "storepass".toCharArray());
PrivateKey pk = (PrivateKey)ks.getKey("certificateAlias", "keypass".toCharArray());


- Original Message - 
From: "Jason Barr" <[EMAIL PROTECTED]>
To: "tomcat" <[EMAIL PROTECTED]>
Sent: Tuesday, January 22, 2002 5:41 PM
Subject: Keystore format


> Hi all,
> 
> Is one able to use a non-JKS type keystore with Tomcat? The docs don't
> get very specific about this and mention that only JKS type keystores
> can be used.
> 
> Has anyone figured out a way to extract a private key from a JKS (or for
> that matter, a pkcs12) type keystore?
> 
> Cheers,
> --
> Jason Barr
> Vendor Manager
> Thawte Tech Support
> www.thawte.com/cgi/support/contents.exe
> 
> 



Re: Running Microsoft Stress Tool (WAS) with Tomcat

2002-01-22 Thread Sanjeev Joshi

There is no problem with the code .  Using the Browser  the pages are rendered without 
any
problem. Also the Same   web-app when deployed with Jrun  and WAS is run on that works
just fine 

-Joshi

David Cassidy wrote:

> what does the source code of the affected page look like ?
>
> Does this happen with a 'HelloWorld.jsp' type page ?
>
> D
>
> Sanjeev Joshi wrote:
>
> > Hi all,
> >
> > On running  this stress tool with Tomcat I get these errors ;
> >
> > 2002-01-22 22:11:31 - Ctx( /uii-example ): Exception in: R( /uii-example
> > + /index.jsp + null) -
> >  java.lang.IllegalArgumentException: Cookie name Path is a reserved
> > token
> > at javax.servlet.http.Cookie.(Cookie.java:185)
> > at
> > org.apache.tomcat.util.RequestUtil.processCookies(RequestUtil.java:189)
> > at
> > org.apache.tomcat.core.RequestImpl.getCookieCount(RequestImpl.java:510)
> > at
> > 
>org.apache.tomcat.session.StandardSessionInterceptor.requestMap(StandardSessionInter
> >
> > ceptor.java:145)
> > at
> > org.apache.tomcat.core.ContextManager.processRequest(ContextManager.java:835)
> >
> > at
> > org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:786)
> >
> > at
> > org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
> > at
> > 
>org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectio
> >
> > nHandler.java:213)
> > at
> > org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
> >
> > at
> > org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
> >
> > at java.lang.Thread.run(Thread.java:484)
> >
> > The result in the Stress Tool show as   500 Inrenal Server Error !!!
> >
> > Any ideas  what  is the reason ?? Is it a Bug with Tomcat   ( not able
> > to handle multiple requests ! )
> >
> > -Joshi
> >
> > --
> > To unsubscribe:   
> > For additional commands: 
> > Troubles with the list: 
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




tomcat4.0 + apache1.3.22 + questions

2002-01-22 Thread Ashish kulkarni

Hi,
I have configured tomcat4.0 with apache 1.3.22, using
mod_jk as well as mod_web modules,
Does any one have any information about which one is
good for production purpose so i can conitnue using
it.
Also I have 3 directories on my win2000 and winnt
server, first is c:\prodution second is c:\testing and
third is c:\development.
now i have to create 3 virtual host which will server
3 web applications in these directories.
like. http://my.prod will get the jsp and servlets
from c:\production and http://my.test will get every
thing from c:\testing.
so what is the best way of doing it, i would like to
have 3 instance of tomcat so that i don have to stop
one while playing with the other, also i think there
will be only 1 instance of apache serving all request
from different tomcat server instance,
I think i should modify catalina_base varaible to
point at different directories. and have 3 nt services
but does anyone have an example which i can refer to
setup my system
Regards
Ashish


__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Keystore format

2002-01-22 Thread pixel


~Scott

Jason Barr wrote:

>Hi all,
>
>Is one able to use a non-JKS type keystore with Tomcat? The docs don't
>get very specific about this and mention that only JKS type keystores
>can be used.
>
Not sure about this one. From what I understand, Tomcat usess JSSE, 
which only supports the Java keystore format. See

http://java.sun.com/products/jsse/index.html

for full details on JSSE.

>
>
>Has anyone figured out a way to extract a private key from a JKS (or for
>that matter, a pkcs12) type keystore?
>
Here is a site that explains how to import a private / public key and 
certificate in .der format. There is example code, [import.java] which 
might provide some insight as to extracting the key instead. 

http://comu.de/docs/tomcat_ssl.htm

~Scott

>
>Cheers,
>--
>Jason Barr
>Vendor Manager
>Thawte Tech Support
>www.thawte.com/cgi/support/contents.exe
>




--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Running Microsoft Stress Tool (WAS) with Tomcat

2002-01-22 Thread David Cassidy

what does the source code of the affected page look like ?

Does this happen with a 'HelloWorld.jsp' type page ?

D

Sanjeev Joshi wrote:

> Hi all,
>
> On running  this stress tool with Tomcat I get these errors ;
>
> 2002-01-22 22:11:31 - Ctx( /uii-example ): Exception in: R( /uii-example
> + /index.jsp + null) -
>  java.lang.IllegalArgumentException: Cookie name Path is a reserved
> token
> at javax.servlet.http.Cookie.(Cookie.java:185)
> at
> org.apache.tomcat.util.RequestUtil.processCookies(RequestUtil.java:189)
> at
> org.apache.tomcat.core.RequestImpl.getCookieCount(RequestImpl.java:510)
> at
> org.apache.tomcat.session.StandardSessionInterceptor.requestMap(StandardSessionInter
>
> ceptor.java:145)
> at
> org.apache.tomcat.core.ContextManager.processRequest(ContextManager.java:835)
>
> at
> org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:786)
>
> at
> org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
> at
> org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectio
>
> nHandler.java:213)
> at
> org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
>
> at
> org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
>
> at java.lang.Thread.run(Thread.java:484)
>
> The result in the Stress Tool show as   500 Inrenal Server Error !!!
>
> Any ideas  what  is the reason ?? Is it a Bug with Tomcat   ( not able
> to handle multiple requests ! )
>
> -Joshi
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RES: Running Microsoft Stress Tool (WAS) with Tomcat

2002-01-22 Thread Jose Euclides da Silva Junior - DIGR.O

It seems to have a bug in your code, at a glance. Could you send this slice
of code! 
Euclides.

-Mensagem original-
De: Sanjeev Joshi [mailto:[EMAIL PROTECTED]]
Enviada em: terça-feira, 22 de janeiro de 2002 14:46
Para: Tomcat Users List
Assunto: Running Microsoft Stress Tool (WAS) with Tomcat 


Hi all,

On running  this stress tool with Tomcat I get these errors ;

2002-01-22 22:11:31 - Ctx( /uii-example ): Exception in: R( /uii-example
+ /index.jsp + null) -
 java.lang.IllegalArgumentException: Cookie name Path is a reserved
token
at javax.servlet.http.Cookie.(Cookie.java:185)
at
org.apache.tomcat.util.RequestUtil.processCookies(RequestUtil.java:189)
at
org.apache.tomcat.core.RequestImpl.getCookieCount(RequestImpl.java:510)
at
org.apache.tomcat.session.StandardSessionInterceptor.requestMap(StandardSess
ionInter

ceptor.java:145)
at
org.apache.tomcat.core.ContextManager.processRequest(ContextManager.java:835
)

at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:78
6)

at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC
onnectio

nHandler.java:213)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)

at java.lang.Thread.run(Thread.java:484)


The result in the Stress Tool show as   500 Inrenal Server Error !!!

Any ideas  what  is the reason ?? Is it a Bug with Tomcat   ( not able
to handle multiple requests ! )

-Joshi



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Running Microsoft Stress Tool (WAS) with Tomcat

2002-01-22 Thread Sanjeev Joshi

Hi all,

On running  this stress tool with Tomcat I get these errors ;

2002-01-22 22:11:31 - Ctx( /uii-example ): Exception in: R( /uii-example
+ /index.jsp + null) -
 java.lang.IllegalArgumentException: Cookie name Path is a reserved
token
at javax.servlet.http.Cookie.(Cookie.java:185)
at
org.apache.tomcat.util.RequestUtil.processCookies(RequestUtil.java:189)
at
org.apache.tomcat.core.RequestImpl.getCookieCount(RequestImpl.java:510)
at
org.apache.tomcat.session.StandardSessionInterceptor.requestMap(StandardSessionInter

ceptor.java:145)
at
org.apache.tomcat.core.ContextManager.processRequest(ContextManager.java:835)

at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:786)

at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectio

nHandler.java:213)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)

at java.lang.Thread.run(Thread.java:484)


The result in the Stress Tool show as   500 Inrenal Server Error !!!

Any ideas  what  is the reason ?? Is it a Bug with Tomcat   ( not able
to handle multiple requests ! )

-Joshi



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Please help! Unit test fails for Tomcat

2002-01-22 Thread kynn



   Date: Tue, 22 Jan 2002 06:18:33 -0800 (PST)
   From: Bruce Perryman <[EMAIL PROTECTED]>
   Subject: Re: Please help!  Unit test fails for Tomcat

   Did you download the correct JNDI package (JNDI 1.2.1
   Reference Implementation)?

I downloaded jndi1_2_1.zip from
http://java.sun.com/products/jndi/#DOWNLOAD12 (following the "Download
JNDI 1.2.1 & More" button).  I unzipped this file into
${base.path}/jndi-1.2.1:

  % ls jndi-1.2.1
  COPYRIGHT  README-LDAP.txt  README.txt  doc  examples  jndi1_2_1.zip  lib  schema

   Is it being picked up from
   the correct location in build.properties ({tomcat
   installation directory}/build.properties).

My build.properties file reads:

   # - Java Naming and Directory Interface (JNDI), version 1.2 or later -
   jndi.home=${base.path}/jndi-1.2.1
   jndi.lib=${jndi.home}/lib
   jndi.jar=${jndi.lib}/jndi.jar
   ldap.jar=${jndi.lib}/ldap.jar

   Are there any error msgs displayed
   during the build?

'ant -projecthelp' proceeds without a problem.  The first time I run
'ant dist' it fails, but (inexplicably) it succeeds the second time.
This behavior is reproducible:

   % ant clean
 < OK >
   % ant dist
 < fails >
   % ant dist
 < OK >

The error message 'ant dist' produces the first time around is:

   tomcat-docs:
   
   build-prepare:
   [mkdir] Created dir: 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   
   build-static:
[copy] Copying 3 files to 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
[copy] Copying 1 file to 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs/WEB-INF
[copy] Copying 2 files to 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs/appdev
[copy] Copying 6 files to 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs/appdev/sample
[copy] Copying 1 file to 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs/appdev/sample
   [mkdir] Created dir: 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs/catalina/funcspecs
   [mkdir] Created dir: 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs/images
[copy] Copying 2 files to 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs/images
   
   build-main:
   [style] Transforming into 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   [style] Transforming into 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   [style] Loading stylesheet 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/tomcat-docs/tomcat-docs.xsl
   [style] Transforming into 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   [style] Transforming into 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   [style] Transforming into 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   [style] Transforming into 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   [style] Transforming into 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   [style] Transforming into 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/build/tomcat-docs
   [style] Failed to process 
/usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/tomcat-docs/realm-howto.xml
   
   BUILD FAILED
   
   /usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/webapps/tomcat-docs/build.xml:80: 
javax.xml.transform.TransformerException: java.lang.NullPointerException
   
   Total time: 27 seconds


Thanks!

kynn

P.S.  Please Cc me in your response.



   --- [EMAIL PROTECTED] wrote:
   > 
   > 
   > When I try 'ant test' (after getting past 'ant
   > dist'), it fails
   > eventually with:
   > 
   > test-dir-context:
   > [echo] Running FileDirContext tests
   > [java] .F...
   > [java] Time: 0.164
   > [java] There was 1 failure:
   > [java] 1)
   >
   
testGetAttributesWebInf(org.apache.naming.resources.FileDirContextTestCase)junit.framework.AssertionFailedError:
   > WEB-INF attribute 'resourcetype' is expected
   > [java] at
   >
   
org.apache.naming.resources.BaseDirContextTestCase.checkWebInfAttributes(BaseDirContextTestCase.java:452)
   > [java] at
   >
   
org.apache.naming.resources.FileDirContextTestCase.testGetAttributesWebInf(FileDirContextTestCase.java:162)
   > [java]
   > [java] FAILURES!!!
   > [java] Tests run: 8,  Failures: 1,  Errors: 0
   > [java]
   > 
   > BUILD FAILED
   > 
   >
   >
   /usr/local/build/tomcat/jakarta-tomcat-4.0.1-src/catalina/build.xml:566:
   > Java returned: -1
   > 
   > Total time: 4 seconds
   > 
   > 
   > 
   > Any suggestions as to what to do to fix this would
   > be most welcome.
   > 
   > KJ
   > 
   > 

RE: running jar files

2002-01-22 Thread Reynir Hübner

To execute a Jar file I would do 
 c:\> java -jar jarfile.jar
 if I was trying to execute a specific class in a jar file I would do : 
 c:\> java -cp jarfile1.jar;jarfile2.jar; com.lansa.web.admin.WebAdmin

If that doesn´t work I would check if this class really exists in the
jarfiles I have, and if I have the correct path.
Anyways it seems that you are executing the correct class, but it does
not get to another class that should be in the jarfiles that you have in
your classpath.  So, I would check if I had this class
com.lansa.web.servlet in my jarfiles (the ones in my classpath). 
maybe it isn´t there, then you should head back to the download page or
something. 
I dont know this product and I´ve never used it. It seems like you´re
haveing problems with basic java stuff, really just pretty much off
topic for this list.

 hope it helps, 
  regards, 
[EMAIL PROTECTED]



 


-Original Message-
From: Cressatti, Dominique [mailto:[EMAIL PROTECTED]]
Sent: 22. janúar 2002 16:25
To: Tomcat Users List
Subject: running jar files


I have some jar files, swingall.jar and lansa.jar
How do I do the equivalent of:
java -cp ./:./lansa.jar:./swingall.jar com.lansa.web.admin.WebAbmin
which basically run manually  the WebAdmin applet.
I know it's an applet but there is a servlet equivalent.
 
Sorry if this is too much of a basic question but after 3 days
of trying just about every combination under the sun, am still getting
nowhere,
all I ever get is "java.lang.NoClassDefFoundError...
com/lansa/web/servlet"
  
Dom


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Custom Authentication

2002-01-22 Thread jerry . fang


You can try to extend the FormAuthenticator to add your extra thing. The class is 
declared as final. But it is very easy to make a turn around.

-Jerry


-Original Message-
From: Luke Studley [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 10:02 AM
To: 'Tomcat Users List'
Subject: RE: Custom Authentication


You need to write your own Realm implementation. Look at the source for the
JDBC Realm.

On another issue to do with Login - Does anyone know how to pass multiple
credentials using a FORM login.
E.g. the user needs to input a password and a passphrase - But the Realm
only get the j_password field.

Is it possible to get access to the HttpRequest in the Realm to check for
other parameters?

Cheers

Luke


-Original Message-
From: Ricardo Ramalho [mailto:[EMAIL PROTECTED]] 
Sent: 22 January 2002 14:51
To: Tomcat Users List
Subject: Custom Authentication

Hi ppl! Again

It looks like i wasn't very accurate in my first question here...
What i wanted to do is something like this: (hope you guys can help) This is
my actual Athentication class, with uses BASIC login.


import java.lang.*;
import java.sql.*;
import javax.sql.*;
import javax.naming.*;
import java.io.*;
import javax.servlet.*;
import javax.servlet.http.*;
import java.util.*;
import java.security.*;
import allaire.jrun.util.*;
import allaire.jrun.security.*;

public class Autentica implements AuthenticationInterface
{
/**
 * Initialize the authentication service
 * @param props The properties for the service
 */
public void init(OrderedProperties props) throws Exception
{
//Não se faz nada aki
}

/**
 * Destroy the service
 */
public void destroy()
{
//Não se faz nada aki
}

/**
 * Authenticate the given user with the given credentials (such
 * as a password).
 * @param req The servlet request
 * @param username The username to authenticate
 * @param method The type of authentication method (BASIC, DIGEST, FORM,
 * or CLIENT-CERT)
 * @param credentials Password and/or other credentials necessary
 * in authenticating the user
 * @return The Principal associated with the given username, or null
 * if authentication failed
 */
public Principal authenticate(HttpServletRequest req, String username,
String password) {
Principal principal = null;
  //tipos para a ligação à base de dados
  Connection dbCon = null;
  Statement dbStat = null;
  String sqlStat = null;
  ResultSet dbRes = null;

// If we have a password, attempt to validate it
if (password != null) {
try {
String dbPass = null;
//Acesso à base de dados - apanhar uma
conecção da pool de conexoes do JRun
   InitialContext ctx = new InitialContext();
   DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/test_db");
   dbCon = ds.getConnection();
   dbStat = dbCon.createStatement();
sqlStat = "SELECT passwd FROM users WHERE
user='" + username + "'";
dbRes = dbStat.executeQuery(sqlStat);
dbRes.next();
dbPass = dbRes.getString(1);
if (dbPass.equals(password)) {
principal = new
AuthenticatedPrincipal(username);
}
} catch (Exception e) {
e.printStackTrace();
}
}
return principal;
}

/**
 * Determines if the given principal (user) has been granted the
 * given role within this authentication realm.
 * @param principal The principal (user) to verify
 * @param role The role to verify
 * @return true if the principal is part of the given role
 */
public boolean isPrincipalInRole(Principal principal, String role)
{
return true;
}
}


Thank you for any help in advance

-
Ricardo Ramalho
Carcavelos Lisbon Portugal
EWorks Consulting
-



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Keystore format

2002-01-22 Thread Jason Barr

Hi all,

Is one able to use a non-JKS type keystore with Tomcat? The docs don't
get very specific about this and mention that only JKS type keystores
can be used.

Has anyone figured out a way to extract a private key from a JKS (or for
that matter, a pkcs12) type keystore?

Cheers,
--
Jason Barr
Vendor Manager
Thawte Tech Support
www.thawte.com/cgi/support/contents.exe




smime.p7s
Description: S/MIME Cryptographic Signature


running jar files

2002-01-22 Thread Cressatti, Dominique

I have some jar files, swingall.jar and lansa.jar
How do I do the equivalent of:
java -cp ./:./lansa.jar:./swingall.jar com.lansa.web.admin.WebAbmin
which basically run manually  the WebAdmin applet.
I know it's an applet but there is a servlet equivalent.
 
Sorry if this is too much of a basic question but after 3 days
of trying just about every combination under the sun, am still getting nowhere,
all I ever get is "java.lang.NoClassDefFoundError... com/lansa/web/servlet"
  
Dom




Re: Invoking a process on the server from a servlet

2002-01-22 Thread Stephen Clarke

OK. Thanks to all. The thread got discombobulated in my reader.

Anyway, I think I'll just write to a file and check it manually, or with a
perl doo dad.

TCP is a whole nother project. {:=o

Thanks again to all who replied.

--
Best,
sc


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Invoking a process on the server from a servlet

2002-01-22 Thread Brian Adams

Good points.
I would NOT use interactive desktop at all.  the program will die when you
log out.
don't do it! :)

-Original Message-
From: Randy Layman [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 9:21 AM
To: Tomcat Users List
Subject: RE: Invoking a process on the server from a servlet



A few other thoughts of accomplishing the same thing:
1.  You could enable Interact with desktop in the service that would
allow it to open windows (but open huge security holes).  Also if your site
gets popular this will consume lots of memory when you can't close the
windows as fast as they are opening.
2.  Instead of opening a process you could send a message (via TCP)
to an application that would catch it and display the message
3.  Instead of opening a process you could update some internal list
and then have a web page (access restricted if you want) that would display
the results.  Then you could do an auto-refresh header if you desired.
4.  Make Tomcat SNMP enabled and then pass messages to the monitor
interface.  Then have your corporate management application listen for the
events and display messages accordingly.

> -Original Message-
> From: Brian Adams [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 10:34 AM
> To: 'Tomcat Users List'
> Subject: RE: Invoking a process on the server from a servlet
> 
> 
> Mark is correct.  If you want you can have the servlet write 
> to a file every
> time you get a visitor and then write a seperate program that 
> runs in your
> tooltray. The other program should read the file and when a 
> new line is
> written then popup what ever it is you want to see.
>  If it is in the your tooltray then the program will only 
> work when you
> login. :)
> the servlet will just write to a special log file that is 
> read by your new
> little monitoring program.
> goodluck,
> Brian
> 
> -Original Message-
> From: Wagoner, Mark [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 9:46 AM
> To: 'Tomcat Users List'
> Subject: RE: Invoking a process on the server from a servlet
> 
> 
> The problem is due to NT (or 2000) not allowing the Tomcat service to
> interact with the desktop.  If you bring up Task Manager, you 
> will probably
> see your invoked process running, but it can't create window. 
>  In fact, the
> only way you will now be able to get rid of it will be to 
> kill it in Task
> Manager.
> 
> I don't know of any way around this.
> 
> -Original Message-
> From: Stephen Clarke [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 10:42 AM
> To: tomcat
> Subject: Invoking a process on the server from a servlet
> 
> 
> I have the following code in my servlet, where 'out' is the
> HttpServletResponse object.
> 
>   Runtime t = Runtime.getRuntime();
> 
>   try {
> 
>Process proc = t.exec( "c:\\TaskInfo.exe" );
> 
>out.write(" invoked " );
> 
>   } catch ( java.io.IOException ioe ) {
> 
>out.write( ioe.toString() );
> 
>   }
> 
> What I'm getting is "invoked" in the browser window, but 
> nothing visibly
> happens on my local machine( ie. server). I was hoping 
> TaskInfo would start
> up. What I really want to do is open a file in notepad to 
> tell me a visitor
> has just arrived. Am I barking up the wrong tree altogether. Should I
> generate an event and listen for it in another app running as 
> a listener in
> the background, or is there just no way of invoking a process 
> on localhost
> from a servlet.
> 
> Thanks.
> 
> If this is the wrong place to be asking these questions, 
> please let me know.
> 
> --
> cf
> 
> 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Invoking a process on the server from a servlet

2002-01-22 Thread Wagoner, Mark

If you want the messages to appear real-time, I think the previous
suggestion to send a TCP message to a waiting listener app would be you best
bet.  This app could just sit there with an open window that scrolls any
messages that it receives.

-Original Message-
From: Stephen Clarke [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 11:08 AM
To: Tomcat Users List
Subject: Re: Invoking a process on the server from a servlet


- Original Message -
From: "Wagoner, Mark" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>
Sent: Tuesday, January 22, 2002 3:45 PM
Subject: RE: Invoking a process on the server from a servlet


> The problem is due to NT (or 2000) not allowing the Tomcat service to
> interact with the desktop.  If you bring up Task Manager, you will
probably
> see your invoked process running, but it can't create window.  In fact,
the
> only way you will now be able to get rid of it will be to kill it in Task
> Manager.
>
> I don't know of any way around this.

OK. Can you tell me for sure that trying to generate an event and 'hear' it
in another infinitely looping application won't work?

Personally, I've never generated my own events before so I am guessing
wildly.

Thanks,

sc


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: wacky HTTPS->HTTP re-direct problem w/apache and tomcat 4

2002-01-22 Thread Dave North

I'm beginning to think it is in the server.xml.  here ya go.  I don't
think I've made any changes here but.

The relevant stuff is at the end I guess (the warp connector)









  

  
  

























  
  

  
  

  

  

  

  

  

  

  
  




















  
  
  
  
  
  
  
  
usersa
password
driverClassName
  org.hsql.jdbcDriver
driverName
  jdbc:HypersonicSQL:database
  
  
  

  mail.smtp.host
  localhost

  


  



  

  

  
  






  
  

  
  



  




-Original Message-
From: Denny Chambers [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 10:11 AM
To: Tomcat Users List
Subject: Re: wacky HTTPS->HTTP re-direct problem w/apache and tomcat 4


This is really strange. I have the same setup. I set the Server Name
directive once in the main portion of the httpd.conf. My  context is very similar to yours, except I don't have the
Server Name defined with in it. My WebAppConnection and WebAppDeploy
line are similar as well, I use localhost as my server name in the
WebAppConnection directive. What about your server.xml, let's see what
that looks like. I kind of running out of suggestions. sorry!

Dave North wrote:
> 
> Hi Denny,
> Just tried that - no joy.  It then complains about the
> webAppDeploy lines being an invalid serverName.
> 
> Cheers
> 
> Dave
> 
> -Original Message-
> From: Denny Chambers [mailto:[EMAIL PROTECTED]]
> Sent: Monday, January 21, 2002 4:52 PM
> To: Tomcat Users List
> Subject: Re: wacky HTTPS->HTTP re-direct problem w/apache and tomcat 4
> 
> Have you tried it with out the ServerName directive set in the
>  directive?
> 
> "Chambers, Norman (Denny)" wrote:
> >
> > If tomcat and apache are running on the try using localhost:8080
here:
> >
> > WebAppConnection myconn warp ottas13a.ott.signiant.com:8008
> >
> > Also do you have the ServerName and Port directive set in the
> > httpd.conf? The directives are required by SSL.
> >
> > Dave North wrote:
> > >
> > > sure.  Actually, back in the mailing list archive I just found
> someone
> > > who had the exact same problem...no solution alas.
> > >
> > > The server.xml file is the bog standard one with no changes from a
> > > tomcat install.
> > >
> > > My httpd.conf info (basically the standard mod_ssl config with the
> > > webAppDeploy stuff bolted in):
> > >
> > > ##
> > > ## SSL Virtual Host Context
> > > ##
> > >
> > > 
> > >
> > > #  General setup for the virtual host
> > > DocumentRoot "/usr/local/apache/htdocs"
> > > ServerName ottas13a.ott.signiant.com
> > > ServerAdmin [EMAIL PROTECTED]
> > > ErrorLog /usr/local/apache/logs/error_log
> > > TransferLog /usr/local/apache/logs/access_log
> > >
> > > #   SSL Engine Switch:
> > > #   Enable/Disable SSL for this virtual host.
> > > SSLEngine on
> > >
> > > #   SSL Cipher Suite:
> > > #   List the ciphers that the client is permitted to negotiate.
> > > #   See the mod_ssl documentation for a complete list.
> > > SSLCipherSuite
> > > ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
> > >
> > > #   Server Certificate:
> > > #   Point SSLCertificateFile at a PEM encoded certificate.  If
> > > #   the certificate is encrypted, then you will be prompted for a
> > > #   pass phrase.  Note that a kill -HUP will prompt again. A test
> > > #   certificate can be generated with `make certificate' under
> > > #   built time. Keep in mind that if you've both a RSA and a DSA
> > > #   certificate you can configure both in parallel (to also allow
> > > #   the use of DSA ciphers, etc.)
> > > SSLCertificateFile /usr/local/apache/conf/ssl.crt/server.crt
> > > #SSLCertificateFile /usr/local/apache/conf/ssl.crt/server-dsa.crt
> > >
> > > #   Server Private Key:
> > > #   If the key is not combined with the certificate, use this
> > > #   directive to point at the key file.  Keep in mind that if
> > > #   you've both a RSA and a DSA private key you can configure
> > > #   both in parallel (to also allow the use of DSA ciphers, etc.)
> > > SSLCertificateKeyFile /usr/local/apache/conf/ssl.key/server.key
> > > #SSLCertificateKeyFile
/usr/local/apache/conf/ssl.key/server-dsa.key
> > >
> > > #   Server Certificate Chain:
> > > #   Point SSLCertificateChainFile at a file containing the
> > > #   concatenation of PEM encoded CA certificates which form the
> > > #   certificate chain for the server certificate. Alternatively
> > > #   the referenced file can be the same as SSLCertificateFile
> > > #   when the CA certificates are directly appended to th

Re: Invoking a process on the server from a servlet

2002-01-22 Thread Stephen Clarke

- Original Message -
From: "Wagoner, Mark" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>
Sent: Tuesday, January 22, 2002 3:45 PM
Subject: RE: Invoking a process on the server from a servlet


> The problem is due to NT (or 2000) not allowing the Tomcat service to
> interact with the desktop.  If you bring up Task Manager, you will
probably
> see your invoked process running, but it can't create window.  In fact,
the
> only way you will now be able to get rid of it will be to kill it in Task
> Manager.
>
> I don't know of any way around this.

OK. Can you tell me for sure that trying to generate an event and 'hear' it
in another infinitely looping application won't work?

Personally, I've never generated my own events before so I am guessing
wildly.

Thanks,

sc


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Some problems

2002-01-22 Thread Archie Cameron

Hey... I may have spammed some/all of you.  My current config is messed up.
I have stopped it so y'all are safe from me once again.   

I am installing Windchill Infoengine from PTC.  It utilizes Apache and
Tomcat and Java 2.  

Later
Arch

Archie G Cameron
Polaris Industries Inc
IS Dept
218.463.4620



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Invoking a process on the server from a servlet

2002-01-22 Thread Randy Layman


A few other thoughts of accomplishing the same thing:
1.  You could enable Interact with desktop in the service that would
allow it to open windows (but open huge security holes).  Also if your site
gets popular this will consume lots of memory when you can't close the
windows as fast as they are opening.
2.  Instead of opening a process you could send a message (via TCP)
to an application that would catch it and display the message
3.  Instead of opening a process you could update some internal list
and then have a web page (access restricted if you want) that would display
the results.  Then you could do an auto-refresh header if you desired.
4.  Make Tomcat SNMP enabled and then pass messages to the monitor
interface.  Then have your corporate management application listen for the
events and display messages accordingly.

> -Original Message-
> From: Brian Adams [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 10:34 AM
> To: 'Tomcat Users List'
> Subject: RE: Invoking a process on the server from a servlet
> 
> 
> Mark is correct.  If you want you can have the servlet write 
> to a file every
> time you get a visitor and then write a seperate program that 
> runs in your
> tooltray. The other program should read the file and when a 
> new line is
> written then popup what ever it is you want to see.
>  If it is in the your tooltray then the program will only 
> work when you
> login. :)
> the servlet will just write to a special log file that is 
> read by your new
> little monitoring program.
> goodluck,
> Brian
> 
> -Original Message-
> From: Wagoner, Mark [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 9:46 AM
> To: 'Tomcat Users List'
> Subject: RE: Invoking a process on the server from a servlet
> 
> 
> The problem is due to NT (or 2000) not allowing the Tomcat service to
> interact with the desktop.  If you bring up Task Manager, you 
> will probably
> see your invoked process running, but it can't create window. 
>  In fact, the
> only way you will now be able to get rid of it will be to 
> kill it in Task
> Manager.
> 
> I don't know of any way around this.
> 
> -Original Message-
> From: Stephen Clarke [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 10:42 AM
> To: tomcat
> Subject: Invoking a process on the server from a servlet
> 
> 
> I have the following code in my servlet, where 'out' is the
> HttpServletResponse object.
> 
>   Runtime t = Runtime.getRuntime();
> 
>   try {
> 
>Process proc = t.exec( "c:\\TaskInfo.exe" );
> 
>out.write(" invoked " );
> 
>   } catch ( java.io.IOException ioe ) {
> 
>out.write( ioe.toString() );
> 
>   }
> 
> What I'm getting is "invoked" in the browser window, but 
> nothing visibly
> happens on my local machine( ie. server). I was hoping 
> TaskInfo would start
> up. What I really want to do is open a file in notepad to 
> tell me a visitor
> has just arrived. Am I barking up the wrong tree altogether. Should I
> generate an event and listen for it in another app running as 
> a listener in
> the background, or is there just no way of invoking a process 
> on localhost
> from a servlet.
> 
> Thanks.
> 
> If this is the wrong place to be asking these questions, 
> please let me know.
> 
> --
> cf
> 
> 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Does isapi_redirect support chunked data?

2002-01-22 Thread Rida Ligurs



After digging through the source code of isapi_redirect.dll, I've discovered
the following:

1. Transfer-Encoding isn't a supported header entry. Chunked data isn't
preserved as chunked data. 
2. I still don't know why the content-length of "dechunked" data isn't
getting stored in the response header.
2. isap_redirect doesn't support messages larger than 8K.

Are any of these issues scheduled to be address in the next release?  

My intent was to integrate with IIS in order to be able to restrict access
to a fixed set of IP addresses.  Due to the above limitations, I need to
look for another solution.  Is there any way to do this in standalone
Tomcat?


Rida

-Original Message-
From: Rida Ligurs 
Sent: Monday, January 21, 2002 11:52 AM
To: Tomcat-User (E-mail)
Subject: Does isapi_redirect support chunked data?


I have a servlet that returns a SOAP document in its output stream.

I have a Java client that posts a request using sockets and expects to read
the response (SOAP document) from the socket's input stream.

Everything works fine if I'm posting directly to Tomcat.  I get the
following data from the input stream:

HTTP/1.1 200 OK
Content-Type:text/xml
Date:Mon, 21 Jan 2002 15:19:54 GMT
Transfer-Encoding:chunked
Server:Apache Tomcat/4.0.1 (HTTP/1.1 Connector)

44  // chunk size

23  // chunk size.

0

But when I post to IIS running with isapi_redirect,  the input stream
contains the following:

HTTP/1.1 200 OK
Server:Microsoft-IIS/5.0
Date:Mon, 21 Jan 2002 15:25:54 GMT
Connection:Close
Content-Type:text/xml



Is chunked data supposed to get handled this way?





--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Custom Authentication

2002-01-22 Thread Luke Studley

You need to write your own Realm implementation. Look at the source for the
JDBC Realm.

On another issue to do with Login - Does anyone know how to pass multiple
credentials using a FORM login.
E.g. the user needs to input a password and a passphrase - But the Realm
only get the j_password field.

Is it possible to get access to the HttpRequest in the Realm to check for
other parameters?

Cheers

Luke


-Original Message-
From: Ricardo Ramalho [mailto:[EMAIL PROTECTED]] 
Sent: 22 January 2002 14:51
To: Tomcat Users List
Subject: Custom Authentication

Hi ppl! Again

It looks like i wasn't very accurate in my first question here...
What i wanted to do is something like this: (hope you guys can help) This is
my actual Athentication class, with uses BASIC login.


import java.lang.*;
import java.sql.*;
import javax.sql.*;
import javax.naming.*;
import java.io.*;
import javax.servlet.*;
import javax.servlet.http.*;
import java.util.*;
import java.security.*;
import allaire.jrun.util.*;
import allaire.jrun.security.*;

public class Autentica implements AuthenticationInterface
{
/**
 * Initialize the authentication service
 * @param props The properties for the service
 */
public void init(OrderedProperties props) throws Exception
{
//Não se faz nada aki
}

/**
 * Destroy the service
 */
public void destroy()
{
//Não se faz nada aki
}

/**
 * Authenticate the given user with the given credentials (such
 * as a password).
 * @param req The servlet request
 * @param username The username to authenticate
 * @param method The type of authentication method (BASIC, DIGEST, FORM,
 * or CLIENT-CERT)
 * @param credentials Password and/or other credentials necessary
 * in authenticating the user
 * @return The Principal associated with the given username, or null
 * if authentication failed
 */
public Principal authenticate(HttpServletRequest req, String username,
String password) {
Principal principal = null;
  //tipos para a ligação à base de dados
  Connection dbCon = null;
  Statement dbStat = null;
  String sqlStat = null;
  ResultSet dbRes = null;

// If we have a password, attempt to validate it
if (password != null) {
try {
String dbPass = null;
//Acesso à base de dados - apanhar uma
conecção da pool de conexoes do JRun
   InitialContext ctx = new InitialContext();
   DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/test_db");
   dbCon = ds.getConnection();
   dbStat = dbCon.createStatement();
sqlStat = "SELECT passwd FROM users WHERE
user='" + username + "'";
dbRes = dbStat.executeQuery(sqlStat);
dbRes.next();
dbPass = dbRes.getString(1);
if (dbPass.equals(password)) {
principal = new
AuthenticatedPrincipal(username);
}
} catch (Exception e) {
e.printStackTrace();
}
}
return principal;
}

/**
 * Determines if the given principal (user) has been granted the
 * given role within this authentication realm.
 * @param principal The principal (user) to verify
 * @param role The role to verify
 * @return true if the principal is part of the given role
 */
public boolean isPrincipalInRole(Principal principal, String role)
{
return true;
}
}


Thank you for any help in advance

-
Ricardo Ramalho
Carcavelos Lisbon Portugal
EWorks Consulting
-



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Invoking a process on the server from a servlet

2002-01-22 Thread Brian Adams

Mark is correct.  If you want you can have the servlet write to a file every
time you get a visitor and then write a seperate program that runs in your
tooltray. The other program should read the file and when a new line is
written then popup what ever it is you want to see.
 If it is in the your tooltray then the program will only work when you
login. :)
the servlet will just write to a special log file that is read by your new
little monitoring program.
goodluck,
Brian

-Original Message-
From: Wagoner, Mark [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 9:46 AM
To: 'Tomcat Users List'
Subject: RE: Invoking a process on the server from a servlet


The problem is due to NT (or 2000) not allowing the Tomcat service to
interact with the desktop.  If you bring up Task Manager, you will probably
see your invoked process running, but it can't create window.  In fact, the
only way you will now be able to get rid of it will be to kill it in Task
Manager.

I don't know of any way around this.

-Original Message-
From: Stephen Clarke [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 10:42 AM
To: tomcat
Subject: Invoking a process on the server from a servlet


I have the following code in my servlet, where 'out' is the
HttpServletResponse object.

  Runtime t = Runtime.getRuntime();

  try {

   Process proc = t.exec( "c:\\TaskInfo.exe" );

   out.write(" invoked " );

  } catch ( java.io.IOException ioe ) {

   out.write( ioe.toString() );

  }

What I'm getting is "invoked" in the browser window, but nothing visibly
happens on my local machine( ie. server). I was hoping TaskInfo would start
up. What I really want to do is open a file in notepad to tell me a visitor
has just arrived. Am I barking up the wrong tree altogether. Should I
generate an event and listen for it in another app running as a listener in
the background, or is there just no way of invoking a process on localhost
from a servlet.

Thanks.

If this is the wrong place to be asking these questions, please let me know.

--
cf



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Invoking a process on the server from a servlet

2002-01-22 Thread Wagoner, Mark

The problem is due to NT (or 2000) not allowing the Tomcat service to
interact with the desktop.  If you bring up Task Manager, you will probably
see your invoked process running, but it can't create window.  In fact, the
only way you will now be able to get rid of it will be to kill it in Task
Manager.

I don't know of any way around this.

-Original Message-
From: Stephen Clarke [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 10:42 AM
To: tomcat
Subject: Invoking a process on the server from a servlet


I have the following code in my servlet, where 'out' is the
HttpServletResponse object.

  Runtime t = Runtime.getRuntime();

  try {

   Process proc = t.exec( "c:\\TaskInfo.exe" );

   out.write(" invoked " );

  } catch ( java.io.IOException ioe ) {

   out.write( ioe.toString() );

  }

What I'm getting is "invoked" in the browser window, but nothing visibly
happens on my local machine( ie. server). I was hoping TaskInfo would start
up. What I really want to do is open a file in notepad to tell me a visitor
has just arrived. Am I barking up the wrong tree altogether. Should I
generate an event and listen for it in another app running as a listener in
the background, or is there just no way of invoking a process on localhost
from a servlet.

Thanks.

If this is the wrong place to be asking these questions, please let me know.

--
cf



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: multiple instance of tomcat4.0

2002-01-22 Thread Anton Brazhnyk

Hi,

> -Original Message-
> From: Ashish kulkarni [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 5:17 PM
> To: [EMAIL PROTECTED]
> Subject: multiple instance of tomcat4.0 
> 
> 
> Hi,
> I have tomcat4.0 on my win2000k and winnt server, i
> want to run multiple instance of it, like one instance
> for production, other for development, and the 3 for
> testing.
> so how can i do it??
> do i have to modify server.xml???

AFAIK, server.xml is config file for instance 
(and the root  there is singlton).
You should look through CATALINA_HOME and CATALINA_BASE
(try CATALINA_HOME/RUNNING.txt --- (4) Advanced configuration)
in your scripts (.bat files) or create several nt-services.


> if yes how?? 
> i would appreciate if some one has an example
> server.xml file for this purpose
> 
> Ashish
> 

Anton.

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Invoking a process on the server from a servlet

2002-01-22 Thread Stephen Clarke

I have the following code in my servlet, where 'out' is the
HttpServletResponse object.

  Runtime t = Runtime.getRuntime();

  try {

   Process proc = t.exec( "c:\\TaskInfo.exe" );

   out.write(" invoked " );

  } catch ( java.io.IOException ioe ) {

   out.write( ioe.toString() );

  }

What I'm getting is "invoked" in the browser window, but nothing visibly
happens on my local machine( ie. server). I was hoping TaskInfo would start
up. What I really want to do is open a file in notepad to tell me a visitor
has just arrived. Am I barking up the wrong tree altogether. Should I
generate an event and listen for it in another app running as a listener in
the background, or is there just no way of invoking a process on localhost
from a servlet.

Thanks.

If this is the wrong place to be asking these questions, please let me know.

--
cf



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Jasper error

2002-01-22 Thread Justin Rowles

> I have looked at most of the documentation I can find and tried to use
> web.xml - going to this list with such a basic question is a 
> last resort.

Firstly well done - a decent effort with the docs is something to be
congratulated upon.

> Class org.apache.jsp.UserData not found.

This is the line you need to pay attention to.  The line-fragment
'Class="UserData"' doesn't tell the compiler enough.  You need to tell it
more information about where to find the class, such as the package, or it
assumes it is in the same package as the thing it is compiling - in this
case org.apache.jsp.*

Justin.
-- 
You're only jealous cos the little penguins are talking to me. 



***
For more information on Ordnance Survey products and services,
visit our web site at http://www.ordnancesurvey.co.uk
***




--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Who starts tomcat??

2002-01-22 Thread Emerson

If I want to let users of a linux machine to have a unique context each,
and deploying and restart each app independently, is this possible???

At 15:21 21/1/2002 -0500, you wrote:
>
>In Linux...
>
>  Manually:
> Start & stop it via the startup.sh & shutdown.sh scripts in
>../Tomcat/bin.
>
>  Automatically:
> Create a script in /etc/rc.d/init.d which invokes the scripts mentioned
>above
>based on a single argument (start or stop) (pattern it after an
>existing one 
>such as httpd)
>Create links to it in the various directories for each run-level.
>  /etc/rc.d/rcX.d  where X is 0-6  (do a man init for info on the
>various levels)
>
>   Note: This script is executed as root, therefore Tomcat will run as root,
>if this
>is not desired use a command similar to the following:
>
> su tomcatUser -c$TOMCAT_HOME/bin/startup.sh
>
>  This will start it as user 'tomcatUser'.  Since your root, the
>user's
>   password won't be needed.
>
>HTH,
>Ron
>
>> -Original Message-
>> From:Emerson [SMTP:[EMAIL PROTECTED]]
>> Sent:Monday, January 21, 2002 3:14 PM
>> To:  Tomcat Users List
>> Subject: Re: Who starts tomcat??
>> 
>> but how do you start, automatically? where?
>> 
>> At 18:09 21/1/2002 +, you wrote:
>> > --- Emerson <[EMAIL PROTECTED]> wrote: > How you
>> >guys start tomcat in linux??? as root??? in
>> >> the initialization with
>> >> apache
>> >> 
>> >
>> >
>> >Well, during development phase its better to use
>> >plain tomcat without an apache.(unless you want to
>> >test apache's functionality too).
>> >
>> >Apache, since it binds to port 80, needs root.
>> >tomcat listens at 8080 and hence it doesnt need root.
>> >
>> >HTH,
>> >eb!
>> >
>> >__
>> >Do You Yahoo!?
>> >Everything you'll ever need on one web page
>> >from News and Sport to Email and Music Charts
>> >http://uk.my.yahoo.com
>> >
>> >--
>> >To unsubscribe:   
>> >For additional commands: 
>> >Troubles with the list: 
>> >
>> >
>> Emerson Cargnin
>> TRE-SC
>> Setor de Desenvolvimento 
>> Tel: (48) 251-3700 - Ramal 3134
>> 
>> --
>> To unsubscribe:   
>> For additional commands: 
>> Troubles with the list: 
>
>--
>To unsubscribe:   
>For additional commands: 
>Troubles with the list: 
>
>
Emerson Cargnin
TRE-SC
Setor de Desenvolvimento 
Tel: (48) 251-3700 - Ramal 3134

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Custom Authentication

2002-01-22 Thread Dan Kha


Hi Ricardo,

See if these help:
http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg35338.html
http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg41747.html

--
Dan Kha
Development Team
Computing & Network Services
York University, Toronto, Canada

On Tue, 22 Jan 2002, Ricardo Ramalho wrote:

> Hi ppl! Again
>
> It looks like i wasn't very accurate in my first question here...
> What i wanted to do is something like this: (hope you guys can help) This is
> my actual Athentication class, with uses BASIC login.
>
>
> import java.lang.*;
> import java.sql.*;
> import javax.sql.*;
> import javax.naming.*;
> import java.io.*;
> import javax.servlet.*;
> import javax.servlet.http.*;
> import java.util.*;
> import java.security.*;
> import allaire.jrun.util.*;
> import allaire.jrun.security.*;
>
> public class Autentica implements AuthenticationInterface
> {
> /**
>  * Initialize the authentication service
>  * @param props The properties for the service
>  */
> public void init(OrderedProperties props) throws Exception
> {
> //Não se faz nada aki
> }
>
> /**
>  * Destroy the service
>  */
> public void destroy()
> {
> //Não se faz nada aki
> }
>
> /**
>  * Authenticate the given user with the given credentials (such
>  * as a password).
>  * @param req The servlet request
>  * @param username The username to authenticate
>  * @param method The type of authentication method (BASIC, DIGEST, FORM,
>  * or CLIENT-CERT)
>  * @param credentials Password and/or other credentials necessary
>  * in authenticating the user
>  * @return The Principal associated with the given username, or null
>  * if authentication failed
>  */
> public Principal authenticate(HttpServletRequest req, String username,
> String password) {
> Principal principal = null;
>   //tipos para a ligação à base de dados
>   Connection dbCon = null;
>   Statement dbStat = null;
>   String sqlStat = null;
>   ResultSet dbRes = null;
>
> // If we have a password, attempt to validate it
> if (password != null) {
> try {
> String dbPass = null;
> //Acesso à base de dados - apanhar uma
> conecção da pool de conexoes do JRun
>InitialContext ctx = new InitialContext();
>DataSource ds =
> (DataSource)ctx.lookup("java:comp/env/jdbc/test_db");
>dbCon = ds.getConnection();
>dbStat = dbCon.createStatement();
> sqlStat = "SELECT passwd FROM users WHERE
> user='" + username + "'";
> dbRes = dbStat.executeQuery(sqlStat);
> dbRes.next();
> dbPass = dbRes.getString(1);
> if (dbPass.equals(password)) {
> principal = new
> AuthenticatedPrincipal(username);
> }
> } catch (Exception e) {
> e.printStackTrace();
> }
> }
> return principal;
> }
>
> /**
>  * Determines if the given principal (user) has been granted the
>  * given role within this authentication realm.
>  * @param principal The principal (user) to verify
>  * @param role The role to verify
>  * @return true if the principal is part of the given role
>  */
> public boolean isPrincipalInRole(Principal principal, String role)
> {
> return true;
> }
> }
>
>
> Thank you for any help in advance
>
> -
> Ricardo Ramalho
> Carcavelos Lisbon Portugal
> EWorks Consulting
> -
>
>
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
>


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: [ANNOUNCEMENT] Tomcat 4.0.2 beta 2 released

2002-01-22 Thread Emerson

One question...

The 4.0.1 didn't generate the mod_jk.conf-auto file automatically (that's
why I didn't use it in production), does this new version auto generate??

At 13:38 21/1/2002 -0800, you wrote:
>The Tomcat Team is proud to announce the second beta release of Tomcat
>4.0.2.
>
>Highligts for this release include:
>- updated AJP native connector
>- new release of the webapp native connector
>- bugfixes, including a fix for problems shutting down Tomcat
>
>Downloads (source and binaries):
>http://jakarta.apache.org/builds/jakarta-tomcat-4.0/release/v4.0.2-b2/
>Note: RPMs and native connectors builds for the JK and WARP protocols will
>be made available shortly.
>
>Release notes and full changelog:
>http://cvs.apache.org/viewcvs.cgi/~checkout~/jakarta-tomcat-4.0/Attic/RELEAS
>E-NOTES-4.0.2-B2.txt?rev=1.1.2.6
>
>Remy
>
>
>--
>To unsubscribe:   
>For additional commands: 
>Troubles with the list: 
>
>
Emerson Cargnin
TRE-SC
Setor de Desenvolvimento 
Tel: (48) 251-3700 - Ramal 3134

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Tomcat 3.2.4, Java 1.3.1, linux, and process usage

2002-01-22 Thread David Cassidy

If your OS has it have a try with pstree
its very illustrative on this ...


Denny Chambers wrote:

> They are not really seperate processes. They are threads off of a
> running process. Linux just shows them as process. Use this command here
> ( ps -faux | grep java )and you can see who is the parent and who is the
> child. As far as the memory usage, all of these threads are sharing this
> 14% of memory, so each one is not using that amount seperately.
>
> Brandon Cruz wrote:
> >
> > I am using the configuration above, and whenever someone accesses a jsp
> > page, it seems that several processes are created.  I am not an expert with
> > linux, but it seems that multiple processes are created, which are each
> > taking up the exact same amount of memory (around 14%).  Is this normal, and
> > does it mean that 3 processes taking 14% are using up 42% of my memory every
> > time someone accesses a jsp on my machine?
> >
> > Thanks in advance for any information!
> >
> > Brandon
> >
> > --
> > To unsubscribe:   
> > For additional commands: 
> > Troubles with the list: 
>
> --
> Denny Chambers
> Quantum Corporation, Inc.
> Network Attached Storage Division
> Java Linux Engineer
> Phone: 251-478-5730
> Cell: 251-605-3446
> IM: [EMAIL PROTECTED]
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: JBUilder and connectionn pool

2002-01-22 Thread Emerson

At 08:51 22/1/2002 +0100, you wrote:
>One question, which version of JBuilder is that? Professional or
Enterprize and how do you debug your web apps?
It's JBuilder Enterprise 5, and you create a  web app, so the ide simulates
a (one) context inside jbuilder, letting you even debug the JSP pages. Very
useful indeed. That´s why I don't wanna loose these feature using
centralized pool.

>
>Nix.
>
>
Emerson Cargnin
TRE-SC
Setor de Desenvolvimento 
Tel: (48) 251-3700 - Ramal 3134

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Tomcat 3.2.4, Java 1.3.1, linux, and process usage

2002-01-22 Thread Denny Chambers

They are not really seperate processes. They are threads off of a
running process. Linux just shows them as process. Use this command here
( ps -faux | grep java )and you can see who is the parent and who is the
child. As far as the memory usage, all of these threads are sharing this
14% of memory, so each one is not using that amount seperately.



Brandon Cruz wrote:
> 
> I am using the configuration above, and whenever someone accesses a jsp
> page, it seems that several processes are created.  I am not an expert with
> linux, but it seems that multiple processes are created, which are each
> taking up the exact same amount of memory (around 14%).  Is this normal, and
> does it mean that 3 processes taking 14% are using up 42% of my memory every
> time someone accesses a jsp on my machine?
> 
> Thanks in advance for any information!
> 
> Brandon
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 

-- 
Denny Chambers
Quantum Corporation, Inc.
Network Attached Storage Division
Java Linux Engineer
Phone: 251-478-5730
Cell: 251-605-3446
IM: [EMAIL PROTECTED]

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




multiple instance of tomcat4.0

2002-01-22 Thread Ashish kulkarni

Hi,
I have tomcat4.0 on my win2000k and winnt server, i
want to run multiple instance of it, like one instance
for production, other for development, and the 3 for
testing.
so how can i do it??
do i have to modify server.xml???
if yes how?? 
i would appreciate if some one has an example
server.xml file for this purpose

Ashish

__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 





multiple mod_webapp connections?

2002-01-22 Thread Chris Newland

Hi All,

I would like to set up multiple tomcat 4.0.1 instances (each running a cocoon 
webapp) all behind a single Apache server and use mod_webapp to connect 
between a URL path and a specific tomcat instance.

E.g. 

http://www.server.com/foo ---> localhost:8080/cocoon (first tomcat instance)
http://www.server.com/bar ---> localhost:8081/cocoon (second tomcat instance)

I've suceeded in getting the apache->mod_webapp->tomcat process to work fine 
with 1 instance of tomcat, but I don't know how to configure Apache to 
support 2 mod_webapp connectors. I can't find any information about this in 
the docs so I was wondering if it is even possible?

Has anybody suceeded in this configuration?

Thanks,

Chris
 


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Tomcat 3.2.4, Java 1.3.1, linux, and process usage

2002-01-22 Thread Brandon Cruz


I am using the configuration above, and whenever someone accesses a jsp
page, it seems that several processes are created.  I am not an expert with
linux, but it seems that multiple processes are created, which are each
taking up the exact same amount of memory (around 14%).  Is this normal, and
does it mean that 3 processes taking 14% are using up 42% of my memory every
time someone accesses a jsp on my machine?

Thanks in advance for any information!

Brandon






--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Apache / Tomcat 4.01/ Virtualhost

2002-01-22 Thread Ashish kulkarni

Hi,
I have done configured virtual host with apache 1.3.22
and tomcat 4.0.1 , on windows 2000 with mod_jk module,
here are the steps, hope it helps

#***
1) Tomcat 4.0 :
- Be carefull to do not install TC4 in a path with
spaces " " !
otherwise you should use the 8.3 directory names to
configure TC
- In the server/lib subdirectory of TC4 add the
ajp.jar and the
tomcat-util.jar
- in the conf subdirectory copy the workers.properties
from a TC 3.2. Edit
it and fill the lines :

workers.tomcat_home=C:\Programs\Tomcat4.0
workers.java_home=C:\Programs\jdk1.3.1

with your own configuration.
- Edit the server.xml and add the AJP connector like
this :




Now the tomcat server is ready

2) Apache
- firstly copy the mod_jk.dll from the TC3 distrib in
the apache modules
subdirectory
- Configure Apache
Contrary to TC3, TC4 do not generate the Apache
configuration. So you should
do it yourself.

At the end of your httpd.conf file you should add (and
adapt)

# TC 4.0 settings

#
# The following line instructs Apache to load the jk
module
#
LoadModule jk_module modules/mod_jk.dll

JkWorkersFile
"C:/Programs/Tomcat4.0/conf/workers.properties"
JkLogFile "C:/Programs/Tomcat4.0/logs/mod_jk.log"

#
# Log level to be used by mod_jk
#
JkLogLevel error

#
# Root context mounts for Tomcat
#
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13

Then for each Context you had created in tomcat you
should had a paragraph
like this (it's the same thong as in TC3):
Here my context is /pfe
and the directory of the web-app is
C:/Work/Dev/pfe/stock/gui/dist/pfe-gui

#
# The following line makes apache aware of the
location of the /pfe context
# Alias /pfe "C:/Work/Dev/pfe/stock/gui/dist/pfe-gui"

Options Indexes FollowSymLinks


#
# The following line mounts all JSP files and the
/servlet/ uri to tomcat #
JkMount /pfe/servlet/* ajp13 JkMount /pfe/*.jsp ajp13
JkMount /pfe/*.do
ajp13

#
# The following line prohibits users from directly
accessing WEB-INF #

AllowOverride None
deny from all

#
# Use Directory too. On Windows, Location doesn't work
unless case matches #

AllowOverride None
deny from all


#
# The following line prohibits users from directly
accessing META-INF #

AllowOverride None
deny from all

#
# Use Directory too. On Windows, Location doesn't work
unless case matches #

AllowOverride None
deny from all



You can also do the same type of things to deploy the
web-app directly as
the root of apache.

Ashish
--- [EMAIL PROTECTED] wrote:
> 
> I have looked all over the place and I have tried to
> duplicate
> what I did on earlier versions of Tomcat.  But I am
> getting
> anywhere.
> 
> Where is there a doc that tells me how to integrate
> Apache, Tomcat 4 with
> virtual hosts on Unix (Linux).
> 
> Thanks for any help.
> 
> Thanks,
> -Steve
> 
> 
> 
> --
> To unsubscribe:  
> 
> For additional commands:
> 
> Troubles with the list:
> 
> 


__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: wacky HTTPS->HTTP re-direct problem w/apache and tomcat 4

2002-01-22 Thread Denny Chambers

This is really strange. I have the same setup. I set the Server Name
directive once in the main portion of the httpd.conf. My  context is very similar to yours, except I don't have the
Server Name defined with in it. My WebAppConnection and WebAppDeploy
line are similar as well, I use localhost as my server name in the
WebAppConnection directive. What about your server.xml, let's see what
that looks like. I kind of running out of suggestions. sorry!

Dave North wrote:
> 
> Hi Denny,
> Just tried that - no joy.  It then complains about the
> webAppDeploy lines being an invalid serverName.
> 
> Cheers
> 
> Dave
> 
> -Original Message-
> From: Denny Chambers [mailto:[EMAIL PROTECTED]]
> Sent: Monday, January 21, 2002 4:52 PM
> To: Tomcat Users List
> Subject: Re: wacky HTTPS->HTTP re-direct problem w/apache and tomcat 4
> 
> Have you tried it with out the ServerName directive set in the
>  directive?
> 
> "Chambers, Norman (Denny)" wrote:
> >
> > If tomcat and apache are running on the try using localhost:8080 here:
> >
> > WebAppConnection myconn warp ottas13a.ott.signiant.com:8008
> >
> > Also do you have the ServerName and Port directive set in the
> > httpd.conf? The directives are required by SSL.
> >
> > Dave North wrote:
> > >
> > > sure.  Actually, back in the mailing list archive I just found
> someone
> > > who had the exact same problem...no solution alas.
> > >
> > > The server.xml file is the bog standard one with no changes from a
> > > tomcat install.
> > >
> > > My httpd.conf info (basically the standard mod_ssl config with the
> > > webAppDeploy stuff bolted in):
> > >
> > > ##
> > > ## SSL Virtual Host Context
> > > ##
> > >
> > > 
> > >
> > > #  General setup for the virtual host
> > > DocumentRoot "/usr/local/apache/htdocs"
> > > ServerName ottas13a.ott.signiant.com
> > > ServerAdmin [EMAIL PROTECTED]
> > > ErrorLog /usr/local/apache/logs/error_log
> > > TransferLog /usr/local/apache/logs/access_log
> > >
> > > #   SSL Engine Switch:
> > > #   Enable/Disable SSL for this virtual host.
> > > SSLEngine on
> > >
> > > #   SSL Cipher Suite:
> > > #   List the ciphers that the client is permitted to negotiate.
> > > #   See the mod_ssl documentation for a complete list.
> > > SSLCipherSuite
> > > ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
> > >
> > > #   Server Certificate:
> > > #   Point SSLCertificateFile at a PEM encoded certificate.  If
> > > #   the certificate is encrypted, then you will be prompted for a
> > > #   pass phrase.  Note that a kill -HUP will prompt again. A test
> > > #   certificate can be generated with `make certificate' under
> > > #   built time. Keep in mind that if you've both a RSA and a DSA
> > > #   certificate you can configure both in parallel (to also allow
> > > #   the use of DSA ciphers, etc.)
> > > SSLCertificateFile /usr/local/apache/conf/ssl.crt/server.crt
> > > #SSLCertificateFile /usr/local/apache/conf/ssl.crt/server-dsa.crt
> > >
> > > #   Server Private Key:
> > > #   If the key is not combined with the certificate, use this
> > > #   directive to point at the key file.  Keep in mind that if
> > > #   you've both a RSA and a DSA private key you can configure
> > > #   both in parallel (to also allow the use of DSA ciphers, etc.)
> > > SSLCertificateKeyFile /usr/local/apache/conf/ssl.key/server.key
> > > #SSLCertificateKeyFile /usr/local/apache/conf/ssl.key/server-dsa.key
> > >
> > > #   Server Certificate Chain:
> > > #   Point SSLCertificateChainFile at a file containing the
> > > #   concatenation of PEM encoded CA certificates which form the
> > > #   certificate chain for the server certificate. Alternatively
> > > #   the referenced file can be the same as SSLCertificateFile
> > > #   when the CA certificates are directly appended to the server
> > > #   certificate for convinience.
> > > #SSLCertificateChainFile /usr/local/apache/conf/ssl.crt/ca.crt
> > >
> > > #   Certificate Authority (CA):
> > > #   Set the CA certificate verification path where to find CA
> > > #   certificates for client authentication or alternatively one
> > > #   huge file containing all of them (file must be PEM encoded)
> > > #   Note: Inside SSLCACertificatePath you need hash symlinks
> > > # to point to the certificate files. Use the provided
> > > # Makefile to update the hash symlinks after changes.
> > > #SSLCACertificatePath /usr/local/apache/conf/ssl.crt
> > > #SSLCACertificateFile /usr/local/apache/conf/ssl.crt/ca-bundle.crt
> > >
> > > #   Certificate Revocation Lists (CRL):
> > > #   Set the CA revocation path where to find CA CRLs for client
> > > #   authentication or alternatively one huge file containing all
> > > #   of them (file must be PEM encoded)
> > > #   Note: Inside SSLCARevocationPath you need hash symlinks
> > > # to point to the certificate files. Use the provided
> > > # Makefile to update the hash symlinks after changes.
> > > #SSLCARevocationPath /usr/local/apache/conf/s

Custom Authentication

2002-01-22 Thread Ricardo Ramalho

Hi ppl! Again

It looks like i wasn't very accurate in my first question here...
What i wanted to do is something like this: (hope you guys can help) This is
my actual Athentication class, with uses BASIC login.


import java.lang.*;
import java.sql.*;
import javax.sql.*;
import javax.naming.*;
import java.io.*;
import javax.servlet.*;
import javax.servlet.http.*;
import java.util.*;
import java.security.*;
import allaire.jrun.util.*;
import allaire.jrun.security.*;

public class Autentica implements AuthenticationInterface
{
/**
 * Initialize the authentication service
 * @param props The properties for the service
 */
public void init(OrderedProperties props) throws Exception
{
//Não se faz nada aki
}

/**
 * Destroy the service
 */
public void destroy()
{
//Não se faz nada aki
}

/**
 * Authenticate the given user with the given credentials (such
 * as a password).
 * @param req The servlet request
 * @param username The username to authenticate
 * @param method The type of authentication method (BASIC, DIGEST, FORM,
 * or CLIENT-CERT)
 * @param credentials Password and/or other credentials necessary
 * in authenticating the user
 * @return The Principal associated with the given username, or null
 * if authentication failed
 */
public Principal authenticate(HttpServletRequest req, String username,
String password) {
Principal principal = null;
  //tipos para a ligação à base de dados
  Connection dbCon = null;
  Statement dbStat = null;
  String sqlStat = null;
  ResultSet dbRes = null;

// If we have a password, attempt to validate it
if (password != null) {
try {
String dbPass = null;
//Acesso à base de dados - apanhar uma
conecção da pool de conexoes do JRun
   InitialContext ctx = new InitialContext();
   DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/test_db");
   dbCon = ds.getConnection();
   dbStat = dbCon.createStatement();
sqlStat = "SELECT passwd FROM users WHERE
user='" + username + "'";
dbRes = dbStat.executeQuery(sqlStat);
dbRes.next();
dbPass = dbRes.getString(1);
if (dbPass.equals(password)) {
principal = new
AuthenticatedPrincipal(username);
}
} catch (Exception e) {
e.printStackTrace();
}
}
return principal;
}

/**
 * Determines if the given principal (user) has been granted the
 * given role within this authentication realm.
 * @param principal The principal (user) to verify
 * @param role The role to verify
 * @return true if the principal is part of the given role
 */
public boolean isPrincipalInRole(Principal principal, String role)
{
return true;
}
}


Thank you for any help in advance

-
Ricardo Ramalho
Carcavelos Lisbon Portugal
EWorks Consulting
-



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Please help! Unit test fails for Tomcat

2002-01-22 Thread Bruce Perryman

Did you download the correct JNDI package (JNDI 1.2.1
Reference Implementation)? Is it being picked up from
the correct location in build.properties ({tomcat
installation directory}/build.properties). Check the
build.properties file and make sure that it is being
refence properly. Are there any error msgs displayed
during the build?

--- [EMAIL PROTECTED] wrote:
> 
> 
> When I try 'ant test' (after getting past 'ant
> dist'), it fails
> eventually with:
> 
> test-dir-context:
>[echo] Running FileDirContext tests
>[java] .F...
>[java] Time: 0.164
>[java] There was 1 failure:
>[java] 1)
>
testGetAttributesWebInf(org.apache.naming.resources.FileDirContextTestCase)junit.framework.AssertionFailedError:
> WEB-INF attribute 'resourcetype' is expected
>[java] at
>
org.apache.naming.resources.BaseDirContextTestCase.checkWebInfAttributes(BaseDirContextTestCase.java:452)
>[java] at
>
org.apache.naming.resources.FileDirContextTestCase.testGetAttributesWebInf(FileDirContextTestCase.java:162)
>[java]
>[java] FAILURES!!!
>[java] Tests run: 8,  Failures: 1,  Errors: 0
>[java]
> 
> BUILD FAILED
> 
>
>
/home1/berriz/build/tomcat/jakarta-tomcat-4.0.1-src/catalina/build.xml:566:
> Java returned: -1
> 
> Total time: 4 seconds
> 
> 
> 
> Any suggestions as to what to do to fix this would
> be most welcome.
> 
> KJ
> 
> P.S.  Please Cc me in your response.
> 
> --
> To unsubscribe:  
> 
> For additional commands:
> 
> Troubles with the list:
> 
> 


__
Do You Yahoo!?
Send FREE video emails in Yahoo! Mail!
http://promo.yahoo.com/videomail/

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: web.xml Question

2002-01-22 Thread jeff . guttadauro


It's included in $CATALINA_HOME/common/lib/servlet.jar.



   

Tom Bednarz

 cc:   

 Subject: web.xml Question 

01/22/02   

01:48 AM   

Please 

respond to 

"Tomcat Users  

List"  

   

   





Hi everybody,

Usually the web.xml file of a web application starts with the following:

http://java.sun.com/dtd/web-app_2_3.dtd";>

This URL referst to the dtd file on SUN's server. I think most XML parsers
like SAX need to read the dtd file to be able to parse the XML file.

Questions:

What happens if I deploy an application on an Intranet which allows access
to the internet only through a proxy server (with username / password
authentication)? The dtd cannot be accessed and must be someware on the
local disk.

I found that TOMCAT has a web.xml in its conf directory. Could anybody
explain me, which XML files I need to change and where do I need to put the
downloaded web-app_2_3.dtd file?  Is the web.xml in the conf directory like
a parent to all web.xml files found under webapps\\WEB-INF?
(Something like the defaults for all web apps)?

Could anybody help me out of this XML jungle?

Many thanks!

Thomas


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 






--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Apache-tomcat configuration

2002-01-22 Thread Tamim, Samir

Hi all,
 
Still trying to let Apache SSL  / Tomcat with Warp Connector to Work on
Solaris 8. 
 
JDK 1.3.1_02 / Apache 1.3.22 / Tomcat 4.0.1 
 
So still having the following  :
 
[Fri Jan 18 15:27:44 2002] [error] Cannot receive handshake WARP packet
[Fri Jan 18 15:27:44 2002] [error] Cannot read packet (pr_warp_config.c:139)
[Fri Jan 18 15:27:44 2002] [error] Cannot configure connection "conn"
[Fri Jan 18 15:27:47 2002] [notice] child pid 4883 exit signal Segmentation
Fault (11)
[Fri Jan 18 15:27:47 2002] [notice] child pid 4882 exit signal Segmentation
Fault (11)
..
Any help will appreciated.
 
Thanks
 
Sam
 



RE: Custom Authentication

2002-01-22 Thread Sergei Batiuk

Hello,


If you mean a 'Login API', it doesn't exist in Tomcat You need to use
form-based login instead.


There is "InitialContext" in Tomcat. This is how I used it to set up
DataSource ( Tomcat 4.1.0) :



  
  

useryour_login

passwordyour_password
driverClassName
  sun.jdbc.odbc.JdbcOdbcDriver
driverName
  jdbc:odbc:OkeanTest
  




Sincerely,
Sergei Batiuk.



-Original Message-
From: Ricardo Ramalho [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 2:25 PM
To: Tomcat Users List
Cc: casa; [EMAIL PROTECTED]
Subject: Custom Authentication


Hi all! ;)

I have to migrate a Web Application from Allaire JRun to Tomcat 4.0.1.

I have a custom Authentication created by us. How can i use it under TomCat
4.0.1? Information is very non-existant or I'm just to dumb to find it!
:))

Another question: Do i have a "InitialContext" ? If i have so... where is
it? If it doesn't exist, it's no problemat all. I'll simply use the usual
method to access the MySQL database without aquiring the DataSources from
InitialContext (wich maybe it's something from J2EE).

Sorry for my poor English.

Thanks for any help you can give me! :)

Ricardo Ramalho
Carcavelos Lisbon Portugal
E-Works
http://www.eworks.pt



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Please help! Unit test fails for Tomcat

2002-01-22 Thread kynn



When I try 'ant test' (after getting past 'ant dist'), it fails
eventually with:

test-dir-context:
 [echo] Running FileDirContext tests
 [java] .F...
 [java] Time: 0.164
 [java] There was 1 failure:
 [java] 1) 
testGetAttributesWebInf(org.apache.naming.resources.FileDirContextTestCase)junit.framework.AssertionFailedError:
 WEB-INF attribute 'resourcetype' is expected
 [java] at 
org.apache.naming.resources.BaseDirContextTestCase.checkWebInfAttributes(BaseDirContextTestCase.java:452)
 [java] at 
org.apache.naming.resources.FileDirContextTestCase.testGetAttributesWebInf(FileDirContextTestCase.java:162)
 [java]
 [java] FAILURES!!!
 [java] Tests run: 8,  Failures: 1,  Errors: 0
 [java]

BUILD FAILED

/home1/berriz/build/tomcat/jakarta-tomcat-4.0.1-src/catalina/build.xml:566: Java 
returned: -1

Total time: 4 seconds



Any suggestions as to what to do to fix this would be most welcome.

KJ

P.S.  Please Cc me in your response.

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




AW: Jasper error

2002-01-22 Thread Ralph Einfeldt

Wrong!

What happens, is that UserData belongs to no package.
So the compiler tries to find it in the package for 
the generated servlet (which is org.apache.jsp for 
tomcat and may be any name with other jsp engines).

To use a bean that belongs to no package (not a good 
practice anyway) you have to import it like
<%@ page import="UserData" %>

(Not shure if that really works, because I never 
used a bean without a package.)

> -Ursprüngliche Nachricht-
> Von: dderry [mailto:[EMAIL PROTECTED]]
> Gesendet: Dienstag, 22. Januar 2002 12:56
> An: Tomcat Users List; [EMAIL PROTECTED]
> Betreff: Re: Jasper error
> 
> 
> Debby,
> 
> You need to import org.apache.jsp.UserData to use it in that 
> manner. (<%@
> page import="org.apache.jsp.UserData" %>).
> 
> the useBean declaration creates a scripting variable named 
> user, and does
> not require the import. But at line 3 (UserData user = null;) you are
> declaring a different variable (which will mask the variable 
> created by
> useBean). If you really intend to set the bean to null then just do an
> assignment rather than a declaration (user = null;).
> 
> Dave Derry

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: applet deployment/access

2002-01-22 Thread Anton Brazhnyk

Hi,

> -Original Message-
> From: cazza [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 3:27 PM
> To: [EMAIL PROTECTED]
> Subject: applet deployment/access
> 
> 
> I have a servlet that generates html which contains a reference to the
> applet class under tomcat (the tomcat location is webapps/myapp/applet/)
> 
> I understand that MyApplet.class cannot be under the web-inf directory for
> security reasons, but I have two questions;

I don't know any security reasons for applets to be not allowed in WEB-INF,
there is only one reason for them: User won't be able to access them there.
Applets are executed on client side, so browser's JVM should download .class

> 1) The applet class relies on other classes that are under the
> web-inf/classes directory.  How should my applet get access to these
> classes?
> 

You should consider packing classes your applet needs and applet itself
to .jar and using appropriate syntax in 

> 2) MyApplet.class is also part of a package, which therefore builds under
> Tomcat to webapps/myapp/applet/com/companyname/packagename/MyApplet.class.
> I would like to set up a filter in the web.xml so that any reference to
> /applet loads the applet class.  Do I do it as follows?
> 
> Applet Filter
> 
> com.companyname.packagename.MyApplet.class
> 
> 
> Applet Filter
> /applet
> 
> 
> 

Why it should be filter, it looks like you need servlet or even just let Tomcat
serve it for you with default servlet (see answer on first question).
And you'd better use class name without .class in  anyway. :)

Anton.

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Removing whitespace.

2002-01-22 Thread Larry Isaacs

The JSP spec, including JSP 1.2, states that whitespace should
be preserved.  Though the patch won't be implemented, you can
check Bug 5560:



for a suggested patch to remove the whitespace.  You are welcome
to customize Jasper if it suits your needs.


Cheers,
Larry

> -Original Message-
> From: Steve Mactaggart [mailto:[EMAIL PROTECTED]]
> Sent: Monday, January 21, 2002 10:28 PM
> To: Tomcat Users List
> Subject: Removing whitespace.
> 
> 
> Hi all,
>   I have some jsp's that are generate some larger html 
> files.  One of the
> reasons is the indenting of the code to manage development.  
> I was wondering
> if there is an option for tomcat to remove all whitespace 
> before it sent the
> data.  I know that the old Enhydra servlet server used to do 
> this and in my
> case this would save a large amount of size from the 
> generated html files.
> 
> I don't want to un-indent the code as it will be too hard to maintain.
> 
> FYI,
>   using Tomcat 3.3-dev on Win2000 and Linux but would be 
> happy to hear if it
> is a feature of 4.
> 
> Thanks for your help
> 
> 
> Steve Mactaggart
> Senior Java Developer /
> Team Leader
> 
> 303 Sport
> BH: 9620 7477
> FAX 9620 7377
> 
> 
> 
> 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Jasper error

2002-01-22 Thread dderry

Debby,

You need to import org.apache.jsp.UserData to use it in that manner. (<%@
page import="org.apache.jsp.UserData" %>).

the useBean declaration creates a scripting variable named user, and does
not require the import. But at line 3 (UserData user = null;) you are
declaring a different variable (which will mask the variable created by
useBean). If you really intend to set the bean to null then just do an
assignment rather than a declaration (user = null;).

Dave Derry


- Original Message -
From: "Debby Dart" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>
Sent: Monday, January 21, 2002 8:08 PM
Subject: Jasper error


> ...
> org.apache.jasper.JasperException: Unable to compile class for JSP
>
> An error occurred at line: 3 in the jsp file: /SaveName.jsp
>
> Generated servlet error:
> C:\java-apps\Apache Tomcat
4.0\work\localhost\testapp\SaveName$jsp.java:65:
> Class org.apache.jsp.UserData not found.
> UserData user = null;
> ...
>
> Line 3 in the script is :
> 
>
> I thought all I needed to do was to place the file UserData.class into the
> webapps\testapp\Web-inf\classes directory, but apparently I'm missing
> something.
>
>



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Config/Startup problem contextInit() not running

2002-01-22 Thread Larry Isaacs

If there aren't any System.out.println's or log output being
generated by your CustomRealm, you can try temporarily removing
the myapp.tomcat.CustomRealm class from your installation and
see if Tomcat complains.  It should complain if it is acting on
your  entry but can't find the class.  An
alternative is to modify modules-myapp.xml to specify
an incorrect class name.

Cheers,
Larry

> -Original Message-
> From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> Sent: Monday, January 21, 2002 5:05 PM
> To: Tomcat Users List
> Subject: RE: Config/Startup problem contextInit() not running
> 
> 
> That is a great question, how do I check since I can't find 
> anything in a
> log file?
> 
> Thanks,
> Adam
> 
> > -Original Message-
> > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> > Sent: Monday, January 21, 2002 3:53 PM
> > To: 'Tomcat Users List'
> > Subject: RE: Config/Startup problem contextInit() not running
> >
> >
> > I'll investigate for Tomcat 3.3a/3.3.1-dev.  Do you know if your
> >  is being loaded, as opposed to being ignored?
> >
> > Cheers,
> > Larry
> >
> > > -Original Message-
> > > From: Adam Paeth [mailto:[EMAIL PROTECTED]]
> > > Sent: Monday, January 21, 2002 4:10 PM
> > > To: Tomcat User List
> > > Subject: Config/Startup problem contextInit() not running
> > >
> > >
> > >
> > > I'm going crazy trying to figure this out...
> > >
> > > I've re-written a customized realm that we used for our
> > > Tomcat 3.2.1 (now
> > > for 3.3).  For some reason the debug messages that I've 
> put into the
> > > contextInit() method are not showing up on the console or any
> > > log files.  It
> > > doesn't appear that the method is running.  Can anyone tell
> > > me why this is
> > > happening and the best approach to fixing it?
> > >
> > > After getting some advice from a previous post I setup the
> > > config files as
> > > such:
> > >
> > > apps-myapp.xml
> > > --
> > > 
> > > 
> > > > > docBase="webapps/myapp"
> > > debug="1"
> > > reloadable="true" >
> > >   
> > >path="logs/myapp.log" />
> > >> >  path="logs/servlet_myapp.log"
> > >  servletLogger="true"/>
> > >   
> > >
> > > 
> > >
> > > modules-myapp.xml
> > > -
> > > 
> > > 
> > >javaClass="myapp.tomcat.CustomRealm"/>
> > > 
> > >
> > > Thanks,
> > > Adam Paeth
> > >
> > >
> > > --
> > > To unsubscribe:   
> 
> > > For additional commands: 
> 
> > > Troubles with the list: 
> 
> > >
> >
> > --
> > To unsubscribe:   
> 
> > For additional commands: 
> 
> > Troubles with the list: 
> 
> >
> >
> 
> 
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
> 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




applet deployment/access

2002-01-22 Thread cazza

I have a servlet that generates html which contains a reference to the
applet class under tomcat (the tomcat location is webapps/myapp/applet/)

I understand that MyApplet.class cannot be under the web-inf directory for
security reasons, but I have two questions;
1) The applet class relies on other classes that are under the
web-inf/classes directory.  How should my applet get access to these
classes?

2) MyApplet.class is also part of a package, which therefore builds under
Tomcat to webapps/myapp/applet/com/companyname/packagename/MyApplet.class.
I would like to set up a filter in the web.xml so that any reference to
/applet loads the applet class.  Do I do it as follows?

Applet Filter
com.companyname.packagename.MyApplet.class


Applet Filter
/applet




--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Jasper error

2002-01-22 Thread RSEQUEIRA







"Debby Dart" <[EMAIL PROTECTED]> on 01/21/2002 07:08:32 PM

Please respond to "Tomcat Users List" <[EMAIL PROTECTED]>

To:   "'Tomcat Users List'" <[EMAIL PROTECTED]>
cc:

Subject:  Jasper error


I'm a newbie to Tomcat and JSP and fairly new to Java.  While running a
test
script with Tomcat 4.0, I get the following error:

...
org.apache.jasper.JasperException: Unable to compile class for JSP

An error occurred at line: 3 in the jsp file: /SaveName.jsp

Generated servlet error:
C:\java-apps\Apache Tomcat 4.0\work\localhost\testapp\SaveName$jsp.java:65:
Class org.apache.jsp.UserData not found.
UserData user = null;
...

Line 3 in the script is :


I thought all I needed to do was to place the file UserData.class into the
webapps\testapp\Web-inf\classes directory, but apparently I'm missing
something.

The "WEB-INF" should be in uppercase rather than mixed case.

I have looked at most of the documentation I can find and tried to use
web.xml - going to this list with such a basic question is a last resort.

Thanks for your patience and all help you can provide.


Hope this helps.
Thanks.
RS

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 









--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Custom Authentication

2002-01-22 Thread Ricardo Ramalho

Hi all! ;)

I have to migrate a Web Application from Allaire JRun to Tomcat 4.0.1.

I have a custom Authentication created by us. How can i use it under TomCat
4.0.1? Information is very non-existant or I'm just to dumb to find it!
:))

Another question: Do i have a "InitialContext" ? If i have so... where is
it? If it doesn't exist, it's no problemat all. I'll simply use the usual
method to access the MySQL database without aquiring the DataSources from
InitialContext (wich maybe it's something from J2EE).

Sorry for my poor English.

Thanks for any help you can give me! :)

Ricardo Ramalho
Carcavelos Lisbon Portugal
E-Works
http://www.eworks.pt



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Problem when creating mod_webapp under hpux11

2002-01-22 Thread Jeff Ong

thanks jeffrey, hope to get the file from u soon .


- Original Message -
From: "PELOQUIN,JEFFREY (Non-HP-Boise,ex1)" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>
Sent: Tuesday, January 22, 2002 8:12 PM
Subject: RE: Problem when creating mod_webapp under hpux11


> Jeff,
>
> the problem you are experiening results from the fact the Korn shell on
> HP-UX does not keep zero length strings in memory as far as I can tell,
> MYVAR = "" is null for all practical purposes. The configure file sets a
> number of variables to "" for one purpose or another.  However then the
> configure file tries to use these variables in test statements, which is
why
> you get the /usr/bin/test[7]: test: Specify a parameter with this command
> errors.  I am currently trying to rewrite the file and others for HP-UX.
>
> I have had mod_webapp working for the past five days and will send it to
you
> in a separate email.
> Anybody else want it?
>
> Jeff
>
> -Original Message-
> From: Jeff Ong [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 22, 2002 1:58 AM
> To: Tomcat Users List
> Subject: Re: Problem when creating mod_webapp under hpux11
>
>
> Anyone own the mod_webapp for hpux11? can you please send it to me if you
> dont mind?
>
>
> - Original Message -
> From: "Jeff Ong" <[EMAIL PROTECTED]>
> To: "Tomcat Users List" <[EMAIL PROTECTED]>
> Sent: Tuesday, January 22, 2002 4:52 PM
> Subject: Problem when creating mod_webapp under hpux11
>
>
> > Hi all,
> >
> > i am currently try to integrate tomcat with apache. I am using tomcat
> 4.0.1
> > and apache 1.3.22. Both of the apache and tomcat run smoothly. When i
surf
> > to port 80 and 8080, both gave me the expected result.
> >
> > However, when i tried to create mod_webapp, it always hangs in a
process.
> >
> >
> > # ./configure --with-apxs=/usr/local/apache/bin/apxs
> > loading cache ./config.cache
> > checking for test... /usr/bin/test
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for true... /usr/bin/true
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for echo... /usr/bin/echo
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for grep... /usr/bin/grep
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for cat... /usr/bin/cat
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for sed... /usr/bin/sed
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for ln... /usr/bin/ln
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for rm... /usr/bin/rm
> > checking host system type... hppa1.1-hp-hpux11.00
> > checking for sources directory... /var/jeff/webapp-module-1.0-tc40
> > checking for targets directory... /var/jeff/webapp-module-1.0-tc40
> >
> > C-Language compilation tools
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for ar... /usr/bin/ar
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for ranlib... /usr/bin/ranlib
> > checking for gcc... gcc
> > checking whether the C compiler (gcc  ) works... yes
> > checking whether the C compiler (gcc  ) is a cross-compiler... no
> > checking whether we are using GNU C... yes
> > checking whether gcc accepts -g... yes
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking for gcc... /opt/gcc/bin/gcc
> > checking whether /opt/gcc/bin/gcc and cc understand -c and -o
together...
> > yes
> > checking how to run the C preprocessor... /opt/gcc/bin/gcc -E
> > checking for debug build... no
> >
> > JAVA-Language compilation tools
> > checking for java support... no
> >
> > API documentation generation
> > checking for C API documentation... no
> > checking for Java API documentation... no
> >
> > Target web-server
> > checking for Apache apxs... yes
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> > checking target module... apache-1.3
> > /usr/bin/test[7]: test: Specify a parameter with this command.
> >
> > Finishing up
> > checking for APR compilation flags... /usr/bin/test[7]: test: Specify a
> > parameter with this command.
> > ok
> > (IT ALWAYS HANGs HERE )
> >
> >
> > anyone know what is happening? I have tried to compile
> > "webapp-module-1.0.1-tc401-src.tar.gz" and
> > "webapp-module-1.0.1-tc40-src.tar.gz" but both of them gave me same
> > problems.
> >
> >
> >
> > --
> > To unsubscribe:   
> > For additional commands: 
> > Troubles with the list: 
> >
>
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
>
> --
> To unsubscribe:   
> For additional commands: 
> Trou

RE: Problem when creating mod_webapp under hpux11

2002-01-22 Thread PELOQUIN,JEFFREY (Non-HP-Boise,ex1)

Jeff,

the problem you are experiening results from the fact the Korn shell on
HP-UX does not keep zero length strings in memory as far as I can tell,
MYVAR = "" is null for all practical purposes. The configure file sets a
number of variables to "" for one purpose or another.  However then the
configure file tries to use these variables in test statements, which is why
you get the /usr/bin/test[7]: test: Specify a parameter with this command
errors.  I am currently trying to rewrite the file and others for HP-UX.

I have had mod_webapp working for the past five days and will send it to you
in a separate email.  
Anybody else want it?

Jeff

-Original Message-
From: Jeff Ong [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 22, 2002 1:58 AM
To: Tomcat Users List
Subject: Re: Problem when creating mod_webapp under hpux11


Anyone own the mod_webapp for hpux11? can you please send it to me if you
dont mind?


- Original Message -
From: "Jeff Ong" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Tuesday, January 22, 2002 4:52 PM
Subject: Problem when creating mod_webapp under hpux11


> Hi all,
>
> i am currently try to integrate tomcat with apache. I am using tomcat
4.0.1
> and apache 1.3.22. Both of the apache and tomcat run smoothly. When i surf
> to port 80 and 8080, both gave me the expected result.
>
> However, when i tried to create mod_webapp, it always hangs in a process.
>
>
> # ./configure --with-apxs=/usr/local/apache/bin/apxs
> loading cache ./config.cache
> checking for test... /usr/bin/test
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for true... /usr/bin/true
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for echo... /usr/bin/echo
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for grep... /usr/bin/grep
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for cat... /usr/bin/cat
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for sed... /usr/bin/sed
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for ln... /usr/bin/ln
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for rm... /usr/bin/rm
> checking host system type... hppa1.1-hp-hpux11.00
> checking for sources directory... /var/jeff/webapp-module-1.0-tc40
> checking for targets directory... /var/jeff/webapp-module-1.0-tc40
>
> C-Language compilation tools
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for ar... /usr/bin/ar
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for ranlib... /usr/bin/ranlib
> checking for gcc... gcc
> checking whether the C compiler (gcc  ) works... yes
> checking whether the C compiler (gcc  ) is a cross-compiler... no
> checking whether we are using GNU C... yes
> checking whether gcc accepts -g... yes
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking for gcc... /opt/gcc/bin/gcc
> checking whether /opt/gcc/bin/gcc and cc understand -c and -o together...
> yes
> checking how to run the C preprocessor... /opt/gcc/bin/gcc -E
> checking for debug build... no
>
> JAVA-Language compilation tools
> checking for java support... no
>
> API documentation generation
> checking for C API documentation... no
> checking for Java API documentation... no
>
> Target web-server
> checking for Apache apxs... yes
> /usr/bin/test[7]: test: Specify a parameter with this command.
> /usr/bin/test[7]: test: Specify a parameter with this command.
> checking target module... apache-1.3
> /usr/bin/test[7]: test: Specify a parameter with this command.
>
> Finishing up
> checking for APR compilation flags... /usr/bin/test[7]: test: Specify a
> parameter with this command.
> ok
> (IT ALWAYS HANGs HERE )
>
>
> anyone know what is happening? I have tried to compile
> "webapp-module-1.0.1-tc401-src.tar.gz" and
> "webapp-module-1.0.1-tc40-src.tar.gz" but both of them gave me same
> problems.
>
>
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
>


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: IIS or Apache

2002-01-22 Thread Martin van den Bemt

Don't worry about me dude ;). I only use open source for my efforts and I
don't have a boss ;) . Just don't forget that a lot of companies (especially
bigger ones) don't make a technical decision, but a political, which leads
to the story you are telling me.. I'm seeing a huge increase at customers
for choosing .net which is still beta quality, and all those decisisions
MUST be based on politics or emotions, not on what their company requires
(talking about companies with eg windows, solaris, mainframe and as/400
combined in 1 environment).
But yeah, we can fill a huge newsgroup with this topic I guess...

Mvgr,
Martin

> -Original Message-
> From: Cressatti, Dominique [mailto:[EMAIL PROTECTED]]
> Sent: Monday, January 21, 2002 18:31
> To: Tomcat Users List
> Subject: RE: IIS or Apache
>
>
> >>Ever heard of managers ;)
> yes and what do they pay you for?
> tell you how to do your job or letting
> you do your job ie finding the best web server.
>
> If he willing to put his butt on the line for
> deploying the worth web server and take full
> responsibilities for breaking into your site,
> fine.
>
> Again do your job, compare which of apache and IIS
> had the most bug/securities hols issues which
> one tie you up to a specific platform ,which one
> makes it difficult to replicate/migrate to a different
> PC.
>
> As well if you go for IIS you gonna have to patch and
> keep up with them fairly frequently (look at how many
> patches had been released for IIS in the last year),
> therefore it means more down time.
>
> Apache is open source = if you find a bug that prevent
> your site to stay up or compromise it, providing that
> can code in C you can fix it there and then.
> With IIS pray that MS 1) can be asked to fix it 2) they
> do it quickly.
>
> If apache/Linux is good enough for amazon.com to commit
> there business on it why can't it be good enough for your
> boss?
>
> Dom
> -Original Message-
> From: Martin van den Bemt [mailto:[EMAIL PROTECTED]]
> Sent: 21 January 2002 17:09
> To: Tomcat Users List
> Subject: RE: IIS or Apache
>
>
> Ever heard of managers ;)
>
> > -Original Message-
> > From: Cressatti, Dominique [mailto:[EMAIL PROTECTED]]
> > Sent: Monday, January 21, 2002 18:08
> > To: Tomcat Users List
> > Subject: RE: IIS or Apache
> >
> >
> > From stability/bugs/security point of view the choice is easy,
> > use apache.
> > Why on earth anyone would run IIS? given it track record (code
> > red, nimba, etc...).
> > apache is portable, try to replicate a config on another platform
> > using IIS,
> > even on another MS platform it's not that easy.
> > With Apache on the other hand you bearly need to copy the structure and
> > httpd.conf
> >
> > Apache has 60% market share and IIS about 20%
> > yet IIS is top notch when it comes to the amount of bugs/security
> > holls uncovered, apache bearly none.
> >
> > Again why on earth anyone with a bit of common sense would consider
> > running IIS.
> >
> > Dom
> >
> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > Sent: 21 January 2002 16:51
> > To: [EMAIL PROTECTED]
> > Subject: IIS or Apache
> >
> >
> > Hi,
> > I have a JSP application (with java classes) to run on Windows 2000
> > server. For JSP i am using tomcat container. Can anyone please
> let me know
> > should I use Microsoft IIS web server or Apache web server for my
> > application. Please tell me which is better IIS or Apache on
> the following
> > basis:
> > 1. Stability
> > 2. Speed
> > 3. Load
> > 4. Overall (considering any other parameters)
> >
> > Sumit.
> > The information contained in this e-mail and any files
> transmitted with it
> > may be privileged and confidential.  If the reader of this message,
> > regardless of the address or routing, is not an intended
> > recipient, you are
> > hereby notified that you have received this transmittal in error and any
> > review, use, distribution, dissemination or copying is strictly
> > prohibited.
> > If you have received this message in error, please delete this
> e-mail and
> > all files transmitted with it from your system and notify the sender by
> > reply e-mail or by calling 1-888-338-6076.
> >
> > --
> > To unsubscribe:   
> > For additional commands: 
> > Troubles with the list: 
> >
> >
> > --
> > To unsubscribe:   
> > For additional commands: 
> > Troubles with the list: 
> >
> >
>
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
>
>
> --
> To unsubscribe:   
> For additional commands: 
> Troubles with the list: 
>
>


--
To unsubscribe:   
For additional commands: 
Troubles w

RE: wacky HTTPS->HTTP re-direct problem w/apache and tomcat 4

2002-01-22 Thread Dave North

Hi Denny,
Just tried that - no joy.  It then complains about the
webAppDeploy lines being an invalid serverName.

Cheers

Dave

-Original Message-
From: Denny Chambers [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 21, 2002 4:52 PM
To: Tomcat Users List
Subject: Re: wacky HTTPS->HTTP re-direct problem w/apache and tomcat 4


Have you tried it with out the ServerName directive set in the
 directive?


"Chambers, Norman (Denny)" wrote:
> 
> If tomcat and apache are running on the try using localhost:8080 here:
> 
> WebAppConnection myconn warp ottas13a.ott.signiant.com:8008
> 
> Also do you have the ServerName and Port directive set in the
> httpd.conf? The directives are required by SSL.
> 
> Dave North wrote:
> >
> > sure.  Actually, back in the mailing list archive I just found
someone
> > who had the exact same problem...no solution alas.
> >
> > The server.xml file is the bog standard one with no changes from a
> > tomcat install.
> >
> > My httpd.conf info (basically the standard mod_ssl config with the
> > webAppDeploy stuff bolted in):
> >
> > ##
> > ## SSL Virtual Host Context
> > ##
> >
> > 
> >
> > #  General setup for the virtual host
> > DocumentRoot "/usr/local/apache/htdocs"
> > ServerName ottas13a.ott.signiant.com
> > ServerAdmin [EMAIL PROTECTED]
> > ErrorLog /usr/local/apache/logs/error_log
> > TransferLog /usr/local/apache/logs/access_log
> >
> > #   SSL Engine Switch:
> > #   Enable/Disable SSL for this virtual host.
> > SSLEngine on
> >
> > #   SSL Cipher Suite:
> > #   List the ciphers that the client is permitted to negotiate.
> > #   See the mod_ssl documentation for a complete list.
> > SSLCipherSuite
> > ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
> >
> > #   Server Certificate:
> > #   Point SSLCertificateFile at a PEM encoded certificate.  If
> > #   the certificate is encrypted, then you will be prompted for a
> > #   pass phrase.  Note that a kill -HUP will prompt again. A test
> > #   certificate can be generated with `make certificate' under
> > #   built time. Keep in mind that if you've both a RSA and a DSA
> > #   certificate you can configure both in parallel (to also allow
> > #   the use of DSA ciphers, etc.)
> > SSLCertificateFile /usr/local/apache/conf/ssl.crt/server.crt
> > #SSLCertificateFile /usr/local/apache/conf/ssl.crt/server-dsa.crt
> >
> > #   Server Private Key:
> > #   If the key is not combined with the certificate, use this
> > #   directive to point at the key file.  Keep in mind that if
> > #   you've both a RSA and a DSA private key you can configure
> > #   both in parallel (to also allow the use of DSA ciphers, etc.)
> > SSLCertificateKeyFile /usr/local/apache/conf/ssl.key/server.key
> > #SSLCertificateKeyFile /usr/local/apache/conf/ssl.key/server-dsa.key
> >
> > #   Server Certificate Chain:
> > #   Point SSLCertificateChainFile at a file containing the
> > #   concatenation of PEM encoded CA certificates which form the
> > #   certificate chain for the server certificate. Alternatively
> > #   the referenced file can be the same as SSLCertificateFile
> > #   when the CA certificates are directly appended to the server
> > #   certificate for convinience.
> > #SSLCertificateChainFile /usr/local/apache/conf/ssl.crt/ca.crt
> >
> > #   Certificate Authority (CA):
> > #   Set the CA certificate verification path where to find CA
> > #   certificates for client authentication or alternatively one
> > #   huge file containing all of them (file must be PEM encoded)
> > #   Note: Inside SSLCACertificatePath you need hash symlinks
> > # to point to the certificate files. Use the provided
> > # Makefile to update the hash symlinks after changes.
> > #SSLCACertificatePath /usr/local/apache/conf/ssl.crt
> > #SSLCACertificateFile /usr/local/apache/conf/ssl.crt/ca-bundle.crt
> >
> > #   Certificate Revocation Lists (CRL):
> > #   Set the CA revocation path where to find CA CRLs for client
> > #   authentication or alternatively one huge file containing all
> > #   of them (file must be PEM encoded)
> > #   Note: Inside SSLCARevocationPath you need hash symlinks
> > # to point to the certificate files. Use the provided
> > # Makefile to update the hash symlinks after changes.
> > #SSLCARevocationPath /usr/local/apache/conf/ssl.crl
> > #SSLCARevocationFile /usr/local/apache/conf/ssl.crl/ca-bundle.crl
> >
> > #   Client Authentication (Type):
> > #   Client certificate verification type and depth.  Types are
> > #   none, optional, require and optional_no_ca.  Depth is a
> > #   number which specifies how deeply to verify the certificate
> > #   issuer chain before deciding the certificate is not valid.
> > #SSLVerifyClient require
> > #SSLVerifyDepth  10
> >
> > #   Access Control:
> > #   With SSLRequire you can do per-directory access control based
> > #   on arbitrary complex boolean expressions containing server
> > #   variable checks and other lookup directives.  The syntax is a
> > #   mix

Re: New ROOT

2002-01-22 Thread Guillermo Labatte

John Kolvereid wrote:

>Hi GL,
>I tried it again.  This time it worked.  Now, instead of tricking Tom,
>how can I simply change the default directory from webapps/ROOT to (say)
>/home/httpd/jsp.  And then how can I address jsp files from non-jsp files.
>Do I have to
>http://hostname/a.jsp:8080>
>
The URL should be http://hostname:8080/a.jsp

>
>And if so, how do I return.  Must I then
>http://hostname/a.htm>
>Any thoughts.  Please advise.  Thanks.
>
That's right.

Now, I think it is better to maintain all content (static and non 
static) under the same roof (i.e. use the same URL space)

After all, you are building a web application. That application consists 
of dynamic content (.jsp, servlets) and static content (html, images). 
Why separate them? If you keep your application together it would be 
easier to manage it (backups, version control, relocation, etc.)

Tomcat can serve static content by itself, so you can put all .html and 
image files alongside your .jsp files. You can also instruct Tomcat to 
use the port 80. This would be the simplest setup and you would not have 
to worry about that :8080 in URLS. Here at work we use this setup for 
individual developer's PCs. So each developer has his own Tomcat server 
in his own PC.

We deploy our application in an intranet server. Since that server also 
uses Apache, there is a conflict with port 80. So we added another IP 
address to that server and make Apache use one of the IP, and Tomcat the 
other. So our webapp still uses port 80 and we do not have to worry 
about the URLs. This setup is still fairly simple.

If you cannot add a IP address to your server, or find Tomcat too slow 
for static content, you can still integrate Tomcat and Apache (using 
mod_jk), and make Apache serve the static content, and Tomcat the 
dynamic content using the same URL space. Since this setup proved to be 
cumbersome (at least for me) we sticked to the previous setup, since we 
did not encounter any performance problem serving our (relativelly 
small) static content with Tomcat.













--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Asynchronous messages from servlets

2002-01-22 Thread David Hewlett

On Tuesday 22 January 2002 8:50 am, you wrote:
> Hi,
>
> I have the following problem. A simple form submits data
> to a servlet. The servlet sends a message via JMS to
> another application (in another JVM). Once the message
> has been sent, the 'service' method of the servlet ends.
> After a while, say five seconds, the other application would
> like to send back a response. How do I show this response
> to the user?
>
> Since the 'service' method has finished after sending the
> message, I have lost control over the output from the other
> application.
>
> What I need is a way to push the response to the browser. I
> would like the server to take the initiative in updating the browser
> window, not the user. Is this possible in any way?
>
> Thanks in advance,
> Ronald Wildenberg
You could do the following. If the client has JVM and permissions can be 
arranged to listen on a specific port (and any firewalls are going to allow 
the traffic etc)  then:
When sending your small form include a java applet that creates a task that 
simply listens on  a specific port.
Your asynchronous process can then return a message to that port. 

This has been done. (with IBM MQSeries java API)

Good Luck & regards,

David.

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: web.xml Question

2002-01-22 Thread John Wadkin

I'm no expert on XML, but I do write documents in XML which are then
parsed/interpreted by a servlet (which I didn't write).

As far as I know, any XML document will parse without a DTD. A DTD just
provides the syntax - e.g. tag names, tag attributes, tag structures (list
of tags that a tag can contain). Without a DTD, the document is just checked
for "well-formedness" - e.g. that all start tags have an end tag. It should
be possible to store the web.xml DTD locally and modify the identifier to
point to it. Don't ask me what the syntax of the identifier is - all I know
is that it's different for DTDs that are local! Look in a good XML book
(e.g. New Riders, Inside XML).

I guess that having the DTD locally would also help when creating server.xml
and web.xml files: you'd be able to use an XML editor with the DTD and
therefore guarantee that all your , , etc. tags where in
the right order, with the right attributes.

Thanks,
 
John
 
Quote for the week:
 
The men with the muck-rakes are often indispensable to the well-being of
society; but only if they know when to stop raking the muck.
 
Theodore Roosevelt, Speech in New York, 11 Nov. 1902
 


-Original Message-
From: Tom Bednarz [mailto:[EMAIL PROTECTED]]
Sent: 22 January 2002 07:49
To: [EMAIL PROTECTED]
Subject: web.xml Question


Hi everybody,

Usually the web.xml file of a web application starts with the following:

http://java.sun.com/dtd/web-app_2_3.dtd";>

This URL referst to the dtd file on SUN's server. I think most XML parsers 
like SAX need to read the dtd file to be able to parse the XML file.

Questions:

What happens if I deploy an application on an Intranet which allows access 
to the internet only through a proxy server (with username / password 
authentication)? The dtd cannot be accessed and must be someware on the 
local disk.

I found that TOMCAT has a web.xml in its conf directory. Could anybody 
explain me, which XML files I need to change and where do I need to put the 
downloaded web-app_2_3.dtd file?  Is the web.xml in the conf directory like 
a parent to all web.xml files found under webapps\\WEB-INF? 
(Something like the defaults for all web apps)?

Could anybody help me out of this XML jungle?

Many thanks!

Thomas


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




re: canno startup Tomcat 4.0.1

2002-01-22 Thread David Hewlett



Despite the good advice to carefully go through the documentation again the 
'problem' still persists :  It appears neither to start nor to fail?
glibc version is 2.2.4-21
jdk is 1.3.1

i have set: ulimit -s 2048
and: export LD_ASSUME_KERNEL=2.2.5

I see i am not alone as two others report similar problem. 
Yet a colleague of mine on, i am quite sure, the same level of suse 7.3 jdk 
etc has succeeded immediately. The only known difference is that my colleague 
has made a clean install while mine was an upgrade from 7.2  Q. Can there be 
a remnant from an older installation of tomcat that could be the cause?

The log for the startup gives just a one line comment as follows: 

2002-01-22 09:55:43 HttpConnector Opening server socket on all host IP 
addresses

but their is no reported failure! Indeed an active process is created.

but despite the implication tht it is listening on the specified port an http 
request cannot connect to the port. (Other ports are working fine. e.g 
apache/jserv)

I have also tried setting another unused port other than 8080 to no avail...
The problem appears to be something more basic?

Regards,

David.

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Asynchronous messages from servlets

2002-01-22 Thread Hans Schlenker

Ronald Wildenberg wrote:
> 
> What I need is a way to push the response to the browser. I
> would like the server to take the initiative in updating the browser
> window, not the user. Is this possible in any way?
> 
No way. HTTP is a pull-mechanism: information is always requested by the
client. Solutions: push a mail to the user or let the generated HTML
page repeatedly update itself. 

The latter is an HTTP/HTML feature that is not part of the W3C standards
but works quite well with most standard browsers, nevertheless. Add
http://selfhtml.teamone.de/";>
to your HTML page header, and the browser will replace the page after
five seconds by the one specified in the URL.

Regards,

Hans

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: How to configure IIS5 with Tomcat 4.0

2002-01-22 Thread Reynir Hübner


try reading the article at following url :

http://jakarta.apache.org/tomcat/tomcat-4.0-doc/config/ajp.html

it should help
-hope so.
[EMAIL PROTECTED]


-Original Message-
From: Peter Cimring [mailto:[EMAIL PROTECTED]]
Sent: 22. janúar 2002 10:54
To: [EMAIL PROTECTED]
Subject: How to configure IIS5 with Tomcat 4.0


Please advise me on how to configure IIS5 with Tomcat.

I found an article at:
http://jakarta.apache.org/tomcat/tomcat-3.2-doc/tomcat-iis-howto.html -
the
article refers to Tomcat 3.2. Is the procedure the same for Tomcat 4.0?

Help!?

Thanks
Pete


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




How to configure IIS5 with Tomcat 4.0

2002-01-22 Thread Peter Cimring

Please advise me on how to configure IIS5 with Tomcat.

I found an article at:
http://jakarta.apache.org/tomcat/tomcat-3.2-doc/tomcat-iis-howto.html - the
article refers to Tomcat 3.2. Is the procedure the same for Tomcat 4.0?

Help!?

Thanks
Pete


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: Tomcat4 Ajp12

2002-01-22 Thread Reynir Hubner

I think only ajp1.3
it does not work with ajp 1.2

-hope it helps
[EMAIL PROTECTED]



-Original Message-
From: Skondras P. [mailto:[EMAIL PROTECTED]]
Sent: 22. januar 2002 10:24
To: [EMAIL PROTECTED]
Subject: Tomcat4 Ajp12


Hi i would like to know if
tomcat4 works ok with ajp12
or it needs only ajp13


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Tomcat4 Ajp12

2002-01-22 Thread Skondras P.

Hi i would like to know if
tomcat4 works ok with ajp12
or it needs only ajp13



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 


Re: Urgent Disable Directory browse

2002-01-22 Thread Galbayar

i'm changed web.xml but tomcat error
how to disable this error?

Apache Tomcat/4.0.1 - HTTP Status 404 - /




type Status report

message /

description The requested resource (/) is not available.


- Original Message -
From: "Reynir Hübner" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Saturday, January 19, 2002 21:04
Subject: RE: Urgent Disable Directory browse


well just change the global web.xml (in your tomcat/conf/ directory).

change the mapping for default servlet so listings are false:


default

org.apache.catalina.servlets.DefaultServlet

  debug
  0


  listings
  false

1


hope it helps
[EMAIL PROTECTED]


-Original Message-
From: Galbayar [mailto:[EMAIL PROTECTED]]
Sent: 19. janúar 2002 04:47
To: Tomcat Users List
Subject: Urgent Disable Directory browse


Hello All !

How to disable directory browse on Tomcat?
if i rename webapps/ROOT/index.jsp to webapps/ROOT/index2.jsp Tomcat
browse ROOT directory.

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 






--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




problem with getting a connection to tomcat

2002-01-22 Thread Birgit Greiffenberg

Hi,
just found the mailinglist :-))
I have a problem with the connection to Tomcat. I am using Tomcat 3.2.3
as a standalone solution.
System: win2000
I want to start a servlet not from a webapplication but from a
conventional java application.
I have a simple frame with a button to start the servlet, it works fine.

But if I have an application with a loginservice, that connects to a
database (in combination with a trustedlogin from the NT-server to which
I connect), I can't connect to  Tomcat.
I don't get any exception, my application just crashes and will not come
back any more...
does anybody know whats going on?
thanks
Birgit



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 


  1   2   >