Servlet is not working

2001-09-04 Thread Kennice Low

Hi,

I am using apache as a web server and servlet is work fine all the time.  I 
am able to view page located in the apache directory /var/www, but not 
servlet. Msg : The page cannot be displayed.
1) I try to shutdown tomcat, message display :

Using classpath: 
/var/jakarta-tomcat-3.2.2/lib/META-INF:/var/jakarta-tomcat-3.2.2/lib/ant.jar:/var/jakarta-tomcat-3.2.2/lib/jasper.jar:/var/jakarta-tomcat-3.2.2/lib/jaxp.jar:/var/jakarta-tomcat-3.2.2/lib/jaxp_org.jar:/var/jakarta-tomcat-3.2.2/lib/mm.mysql-2.0.6.jar:/var/jakarta-tomcat-3.2.2/lib/parser.jar:/var/jakarta-tomcat-3.2.2/lib/servlet.jar:/var/jakarta-tomcat-3.2.2/lib/struts.jar:/var/jakarta-tomcat-3.2.2/lib/test:/var/jakarta-tomcat-3.2.2/lib/webserver.jar:/local/pkg/jdk/1.3/lib/tools.jar:/var/jakarta-tomcat-3.2.2/lib/mm.mysql-2.0.6.jar:/var/jakarta-tomcat-3.2.2/conn:/var/jakarta-tomcat-3.2.2/lib
Stop tomcat
java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:312)
at 
java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:125)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:112)
at java.net.Socket.(Socket.java:273)
at java.net.Socket.(Socket.java:100)
at org.apache.tomcat.task.StopTomcat.execute(StopTomcat.java:104)
at org.apache.tomcat.startup.Tomcat.stopTomcat(Tomcat.java:267)
at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:174)
at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)

2) log error :

/var/jakarta-tomcat-3.2.2/logs>more servlet.log
2001-09-04 10:33:38 - path="/examples" :jsp: init
2001-09-04 10:33:38 - path="/admin" :jsp: init
2001-09-04 10:33:38 - path="" :jsp: init
2001-09-04 10:33:38 - path="" :traffic: init
2001-09-04 10:33:38 - path="" :setup: init
2001-09-04 10:33:38 - path="/test" :jsp: init
2001-09-04 10:33:38 - path="/ch15" :jsp: init
2001-09-04 10:33:38 - path="/test_org" :jsp: init
2001-09-04 10:33:38 - path="/hungryminds" :jsp: init
2001-09-04 10:33:38 - path="/about.html" :jsp: init
2001-09-04 10:33:38 - path="/article.jsp" :jsp: init
2001-09-04 10:33:38 - path="/authentication.html" :jsp: init
2001-09-04 10:33:38 - path="/badlogin.html" :jsp: init
2001-09-04 10:33:38 - path="/META-INF" :jsp: init
2001-09-04 10:33:38 - path="/WEB-INF" :jsp: init
2001-09-04 10:33:38 - path="/data.jsp" :jsp: init
2001-09-04 10:33:38 - path="/download.html" :jsp: init
2001-09-04 10:33:39 - path="/deweb.zip" :jsp: init
2001-09-04 10:33:39 - path="/footer.htm" :jsp: init
2001-09-04 10:33:39 - path="/images" :jsp: init
2001-09-04 10:33:39 - path="/hungryminds.war..zip" :jsp: init
2001-09-04 10:33:39 - path="/index.html" :jsp: init
2001-09-04 10:33:39 - path="/index.jsp" :jsp: init
2001-09-04 10:33:39 - path="/index2.jsp" :jsp: init
2001-09-04 10:33:39 - path="/notauthorized.html" :jsp: init
2001-09-04 10:33:39 - path="/notfound.html" :jsp: init
2001-09-04 10:33:39 - path="/protected.html" :jsp: init
2001-09-04 10:33:39 - path="/sidebar.jsp" :jsp: init
2001-09-04 10:33:39 - path="/simplejsp.jsp" :jsp: init
2001-09-04 10:33:39 - path="/simpletag.jsp" :jsp: init
2001-09-04 10:33:39 - path="/survey.jsp" :jsp: init
2001-09-04 10:33:39 - path="/struts-example" :jsp: init
2001-09-04 10:33:39 - path="/struts-example" :database: init
2001-09-04 10:33:39 - path="/struts-example" :database: Initializing 
database servlet
2001-09-04 10:33:39 - path="/struts-example" :database: Loading database 
from '/WEB-INF/database.xml'
2001-09-04 10:33:39 - path="/struts-example" :database: Database load 
exception - java.lang.ClassNotFoundException: 
org.apache.struts.webapp.example.User
at 
org.apache.commons.digester.Digester.startElement(Digester.java:627)
at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1449)
at org.apache.crimson.parser.Parser2.content(Parser2.java:1700)
at org.apache.crimson.parser.Parser2.maybeElement(Parser2.java:1468)
at org.apache.crimson.parser.Parser2.parseInternal(Parser2.java:499)
at org.apache.crimson.parser.Parser2.parse(Parser2.java:304)
at 
org.apache.crimson.parser.XMLReaderImpl.parse(XMLReaderImpl.java:433)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:346)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:158)
at org.apache.commons.digester.Digester.parse(Digester.java:859)
at 
org.apache.struts.webapp.example.DatabaseServlet.load(DatabaseServlet.java:252)
at 
org.apache.struts.webapp.example.DatabaseServlet.init(DatabaseServlet.java:175)
at javax.servlet.GenericServlet.init(GenericServlet.java:258)
at 
org.apache.tomcat.core.ServletWrapper.doInit(ServletWrapper.java:317)
at org.apache.tomcat.core.Handler.init(Handler.java:215)
at 
org.apache.tomcat.core.ServletWrapper.init(ServletWrapper.java:296)
at org.apache.tomcat.context.LoadOnStartupInterceptor.contextInit


cvs commit: jakarta-tomcat-connectors/webapp/apache-2.0 .cvsignore

2001-09-04 Thread jfclere

jfclere 01/09/04 02:36:00

  Added:   webapp/apache-2.0 .cvsignore
  Log:
  Was missing.
  
  Revision  ChangesPath
  1.1  jakarta-tomcat-connectors/webapp/apache-2.0/.cvsignore
  
  Index: .cvsignore
  ===
  .libs
  Makefile
  mod_webapp.la
  mod_webapp.lo
  mod_webapp.slo
  
  
  



RE: Configuring contexts and using separate web servers / connectors

2001-09-04 Thread Colin Wilson-Salt

I guess my belief then, is that as a web application requires a context
path, there should be no requirement that the context path that it is
deployed under in Tomcat should match the URL-prefix that it is served from
by the web server.

This would mean that it would be more sensible to sort this out in the web
server, by adding a separate parameter that says where the application is
served from:

WebAppDeploy classbrowser conn /classbrowser
/deep/within/my/site/classbrowser

Still, I can see your point, that if a servlet does
request.getContextPath(), it needs to get something that it can sensibly
use, and perhaps I should just accept that this is the way things are.

It does seem a shame though that I can't, for instance, have an application
deployed in one tomcat instance, but with two webservers serving the
application under different URL prefixes.

For instance:

http://www.mycompany.com/deep/within/my/site/classbrowser/

and

http://classbrowser.mycompany.com/

Thanks for listening, anyhow.

> -Original Message-
> From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
> Sent: Monday, September 03, 2001 19:21
> To: [EMAIL PROTECTED]
> Subject: Re: Configuring contexts and using separate web servers /
> connectors
> 
> 
> Hi Colin,
> 
> Thanks for the contribution!  See below for some comments on your
> suggestions.
> 
> On Mon, 3 Sep 2001, Colin Wilson-Salt wrote:
> 
> > Date: Mon, 3 Sep 2001 10:06:59 +0100
> > From: Colin Wilson-Salt <[EMAIL PROTECTED]>
> > Reply-To: [EMAIL PROTECTED]
> > To: [EMAIL PROTECTED]
> > Subject: Configuring contexts and using separate web 
> servers / connectors
> >
> > I hope some of you will bear with me through this email as 
> I share my
> > thoughts and try to be persuasive.
> >
> > In a live environment, I probably would not have any HTTP 
> connector enabled
> > in Tomcat, instead Apache or iPlanet would listen to HTTP 
> and talk a fast,
> > efficient and proprietary protocol to Tomcat for any web-application
> > requests.
> >
> > Let's say that I have an application deployed in Tomcat. 
> Let's call it
> > "classbrowser". I can deploy it with a line in server.xml like:
> >
> >  >  docBase="/home/colin/work/classbrowser.war"/>
> >
> > I can then point my browser to 
> http://localhost:8080/urlprefix/ and get
> > pages back from my application. Woohoo.
> >
> > Now I go to configure my webserver (in this case iPlanet 
> with a plugin based
> > on the mod_webapp stuff). I give it this configuration:
> >
> > WebAppConnection conn warp localhost:8008
> > WebAppDeploy classbrowser conn /classbrowser
> >
> > Which means deploy an application, named "classbrowser" to 
> appear below the
> > URL /classbrowser on the port that my iPlanet is listening 
> to. So I should
> > be able to point my browser to 
http://localhost:81/classbrowser/ and have
> stuff work.
>
> However, although the iPlanet / mod_webapp stuff knows that that means an
> application named "classbrowser" that needs to be delegated to Tomcat,
> Tomcat doesn't know what I'm talking about.
>

In the Apache-connected case, you need to have the appropriate 
entry in your server.xml file (or let Tomcat auto-configure the context if
it's in the "webapps" directory).  Wouldn't the same thing work here?

> I need to be able to give an application a name when I deploy it to
Tomcat,
> and have that name and the name used to configure the mod_webapp stuff
used
> to connect the two halves together.
>

The context path ("/classbrowser") can do that for you.

> In the case where Tomcat is not doing HTTP itself, the path attribute in
the
> Context entry is irrelevant, and should be able to be replaced with a name
> attribute. This name attribute, plus any extra path information after the
> url-prefix used to match requests on the web server side, should be what
> gets sent to Tomcat.
>
> The above example would then become:
>
>   docBase="/home/colin/work/classbrowser.war"/>
>
> Is this something that people generally agree with?
>

The servlet API requires that a web application have a context path
(visible to the application via request.getContextPath()).  So, Tomcat
would have to create such a context path based on this entry, and it's not
clear how you would define the rules.  If it's something simple like "add
a slash at the beginning", it seems to me that this entry is equivalent:

  

and the "path" attribute serves two purposes:
* It provides the context path to which this app will be attached
* It provides a unique identifier that can be used by a web connector
  to select this application.

I guess I'm not understanding why this might not be sufficient.

Craig




cvs commit: jakarta-tomcat-connectors/jk/native/apache-2.0 mod_jk.c

2001-09-04 Thread jfclere

jfclere 01/09/04 03:57:04

  Modified:jk/native/apache-2.0 mod_jk.c
  Log:
  The code was not prepared for windows.
  And ap_server_root_relative does the ap_pstrdup for us.
  
  Revision  ChangesPath
  1.18  +5 -11 jakarta-tomcat-connectors/jk/native/apache-2.0/mod_jk.c
  
  Index: mod_jk.c
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native/apache-2.0/mod_jk.c,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -r1.17 -r1.18
  --- mod_jk.c  2001/09/03 10:08:11 1.17
  +++ mod_jk.c  2001/09/04 10:57:03 1.18
  @@ -60,7 +60,7 @@
* Description: Apache 2 plugin for Jakarta/Tomcat *
* Author:  Gal Shachor <[EMAIL PROTECTED]>   *
*   Henri Gomez <[EMAIL PROTECTED]>   *
  - * Version: $Revision: 1.17 $   *
  + * Version: $Revision: 1.18 $   *
***/
   
   /*
  @@ -645,11 +645,8 @@
   jk_server_conf_t *conf =
   (jk_server_conf_t *)ap_get_module_config(s->module_config, &jk_module);
   
  -if ( worker_file[0] != '/' ) {
  -/* we need an absolut path */
  -conf->worker_file = ap_server_root_relative(cmd->pool,worker_file);
  -} else
  -conf->worker_file = ap_pstrdup(cmd->pool,worker_file);
  +/* we need an absolut path (ap_server_root_relative does the ap_pstrdup) */
  +conf->worker_file = ap_server_root_relative(cmd->pool,worker_file);

   if (conf->worker_file == NULL)
   return "JkWorkersFile file_name invalid";
  @@ -674,11 +671,8 @@
   jk_server_conf_t *conf =
   (jk_server_conf_t *)ap_get_module_config(s->module_config, &jk_module);
   
  -if ( log_file[0] != '/' ) {
  -/* we need an absolut path */
  -conf->log_file = ap_server_root_relative(cmd->pool,log_file);
  -} else
  -conf->log_file = ap_pstrdup(cmd->pool,log_file);
  +/* we need an absolut path */
  +conf->log_file = ap_server_root_relative(cmd->pool,log_file);

   if (conf->log_file == NULL)
   return "JkLogFile file_name invalid";
  
  
  



cvs commit: jakarta-tomcat-connectors/jk/native/apache-1.3 mod_jk.c

2001-09-04 Thread jfclere

jfclere 01/09/04 06:04:03

  Modified:jk/native/apache-1.3 mod_jk.c
  Log:
  Arrange the handle of relative pathes.
  
  Revision  ChangesPath
  1.13  +8 -10 jakarta-tomcat-connectors/jk/native/apache-1.3/mod_jk.c
  
  Index: mod_jk.c
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native/apache-1.3/mod_jk.c,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- mod_jk.c  2001/09/03 10:08:11 1.12
  +++ mod_jk.c  2001/09/04 13:04:03 1.13
  @@ -61,7 +61,7 @@
* Author:  Gal Shachor <[EMAIL PROTECTED]>   *
*  Dan Milstein <[EMAIL PROTECTED]>*
*  Henri Gomez <[EMAIL PROTECTED]>   *
  - * Version: $Revision: 1.12 $   *
  + * Version: $Revision: 1.13 $   *
***/
   
   /*
  @@ -645,13 +645,12 @@
   jk_server_conf_t *conf =
   (jk_server_conf_t *)ap_get_module_config(s->module_config, &jk_module);
   
  -if ( worker_file[0] != '/' ) {
  -/* we need an absolut path */
  -conf->worker_file = ap_server_root_relative(cmd->pool,worker_file);
  -} else
  +/* we need an absolut path */
  +conf->worker_file = ap_server_root_relative(cmd->pool,worker_file);
  +if (conf->worker_file == worker_file)
   conf->worker_file = ap_pstrdup(cmd->pool,worker_file);

  -if (conf->log_file == NULL)
  +if (conf->worker_file == NULL)
   return "JkWorkersFile file_name invalid";
   
   if (stat(conf->worker_file, &statbuf) == -1)
  @@ -674,10 +673,9 @@
   jk_server_conf_t *conf =
   (jk_server_conf_t *)ap_get_module_config(s->module_config, &jk_module);
   
  -if ( log_file[0] != '/' ) {
  -/* we need an absolut path */
  -conf->log_file = ap_server_root_relative(cmd->pool,log_file);
  -} else
  +/* we need an absolut path */
  +conf->log_file = ap_server_root_relative(cmd->pool,log_file);
  +if ( conf->log_file == log_file)
   conf->log_file = ap_pstrdup(cmd->pool,log_file);

   if (conf->log_file == NULL)
  
  
  



Re: [Q] About Jakarta-Tomcat with IIS !

2001-09-04 Thread Pier Fumagalli

"???" <[EMAIL PROTECTED]> wrote:

> Hi!
> I'm trying Tomcat with IIS on Win2000 Server machine.
> 
> Tomcat is running as NT service.
> Tomcat and IIS is connected via "isapi_redirect.dll"
> IIS's default pages are "index.jsp", index.htm, and index.html.
> The website's name is http://some.website/
> 
> If I open http://some.website/index.jsp , then OK.
> But if I open http://some.website/index.jsp%00 or
> http://some.website/index.jsp%cc , then
> the JSP source is delivered to Explorer!!
> And if I open http://some.website/ , then again the JSP source is delivered to
> Explorer!
> 
> How can I manage this?? Please answer this...
> Btw, The Tomcat is version 3.2.3 and Windows is Win2000 Server service pack 2.

File a bug report in BugZilla 

Pier




FW: JSP, performance analysis?

2001-09-04 Thread Israel Olalla

Hi,
 
Trying to understand a problem or performance that we have in our
application, we've seen some data of interest, Those files are the result of
OptimizeIt CPU profiler output - Sampler, Those files show the execution of
the same JSP and logic in three moments.(well i send a file by mail ...
cause the mailer doent accept more than 100 kb)

When working with JSP we have a serious degradation problem with acces
to filesystem:
 
- java.io.Win32FileSystem.getLastModifiedTime 
 
There's some way to desactivate the control of changes in JSP file's?.
In order to avoid access to FileSystem.?
 
 
Finally our problem was with Taglibs iterate ... logic ... it creates
thousands... of objects ... and the GC eats the whole machine but that's
an advise to other list.

Thanks for you patience and time

This message and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
No confidentiality or privilege is waived or lost by any wrong transmission.
If you have received this message in error, please immediately destroy it
and kindly notify the sender by reply email.
You must not, directly or indirectly, use, disclose, distribute, print, or
copy any part of this message if you are not the intended recipient.
Opinions, conclusions and other information in this message that do not
relate to the official business of Newknow shall be understood as neither
given nor endorsed by it. 

  




FW: JSP, performance analysis? (Sorry if inconvenient)

2001-09-04 Thread Israel Olalla


Hi,
 
Trying to understand a problem or performance that we have in our
application, we've seen some data of interest, Those files are the result of
OptimizeIt CPU profiler output - Sampler, Those files show the execution of
the same JSP and logic in three moments.

When working with JSP we have a serious degradation problem with acces
to filesystem:
 
- java.io.Win32FileSystem.getLastModifiedTime 
 
There's some way to desactivate the control of changes in JSP file's?.
In order to avoid access to FileSystem.?
 
 
Finally our problem was with Taglibs iterate ... logic ... it creates
thousands... of objects ... and the GC eats the whole machine but that's
an advise to other list.

Thanks for you patience and time

This message and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
No confidentiality or privilege is waived or lost by any wrong transmission.
If you have received this message in error, please immediately destroy it
and kindly notify the sender by reply email.
You must not, directly or indirectly, use, disclose, distribute, print, or
copy any part of this message if you are not the intended recipient.
Opinions, conclusions and other information in this message that do not
relate to the official business of Newknow shall be understood as neither
given nor endorsed by it. 

  




FW: JSP, performance analysis? (the last...)

2001-09-04 Thread Israel Olalla



Hi,
 
Trying to understand a problem or performance that we have in our
application, we've seen some data of interest, Those files are the result of
OptimizeIt CPU profiler output - Sampler, Those files show the execution of
the same JSP and logic in three moments.

When working with JSP we have a serious degradation problem with acces
to filesystem:
 
- java.io.Win32FileSystem.getLastModifiedTime 
 
There's some way to desactivate the control of changes in JSP file's?.
In order to avoid access to FileSystem.?
 
 
Finally our problem was with Taglibs iterate ... logic ... it creates
thousands... of objects ... and the GC eats the whole machine but that's
an advise to other list.

Thanks for you patience and time

This message and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
No confidentiality or privilege is waived or lost by any wrong transmission.
If you have received this message in error, please immediately destroy it
and kindly notify the sender by reply email.
You must not, directly or indirectly, use, disclose, distribute, print, or
copy any part of this message if you are not the intended recipient.
Opinions, conclusions and other information in this message that do not
relate to the official business of Newknow shall be understood as neither
given nor endorsed by it. 

  




Re: FW: JSP, performance analysis? (the last...)

2001-09-04 Thread Marcel May

Hi!

java.io.Win32FileSystem.getLastModifiedTime:
Try to turn of automatic reloading (s.th. like "reloadable"
in the webapp context in the server.xml).

Concerning tags, I believe tomcat does not yet implement tag pooling.

Good luck,
Marcel

On Tue, Sep 04, 2001 at 05:56:56PM +0200, Israel Olalla wrote:
> 
> 
> Hi,
>  
> Trying to understand a problem or performance that we have in our
> application, we've seen some data of interest, Those files are the result of
> OptimizeIt CPU profiler output - Sampler, Those files show the execution of
> the same JSP and logic in three moments.
> 
> When working with JSP we have a serious degradation problem with acces
> to filesystem:
>  
> - java.io.Win32FileSystem.getLastModifiedTime 
>  
> There's some way to desactivate the control of changes in JSP file's?.
> In order to avoid access to FileSystem.?
>  
>  
> Finally our problem was with Taglibs iterate ... logic ... it creates
> thousands... of objects ... and the GC eats the whole machine but that's
> an advise to other list.
> 
> Thanks for you patience and time
> 
> This message and any files transmitted with it are confidential and intended
> solely for the use of the individual or entity to whom they are addressed.
> No confidentiality or privilege is waived or lost by any wrong transmission.
> If you have received this message in error, please immediately destroy it
> and kindly notify the sender by reply email.
> You must not, directly or indirectly, use, disclose, distribute, print, or
> copy any part of this message if you are not the intended recipient.
> Opinions, conclusions and other information in this message that do not
> relate to the official business of Newknow shall be understood as neither
> given nor endorsed by it. 
> 
>   
> 


-- 
Marcel May
Development
ConSol* GmbH

 PGP signature


Security Manager, Embedded and Class Loading

2001-09-04 Thread Nick Betteridge

I've a problem that I don't really understand.

I'm in the process of getting the security manager to work with an
Embedded setup and the bootstrap is virtually the same as Catalina's.

If I create, for example, a (Standard)Server and (Standard)Service, I
get objects generated. If I attempt to create an engine, the classloader
(catalinaLoader) finds the (Standard)Engine class, but is unable to
create a newInstance.

ie ...



/**
 * Create a new server instance.
 */
public void serverCreate() {
try {
Class serverClass =
catalinaClassLoader.loadClass("org.apache.catalina.core.StandardServer");
Object server = serverClass.newInstance();
} catch (Exception ex) {
}
}

... will create a : org.apache.catalina.core.StandardServer@5d56d5


but a 



public void engineCreate() {
try {
Class engineClass =
catalinaClassLoader.loadClass("org.apache.catalina.core.StandardEngine");
Object engine = engineClass.newInstance();
} catch (Exception ex) {
}
}


will give a : StandardEngine[null]


. note that the full package name is missing and that engineClass is
found.


If anybody can shed any light on this, I'd be very grateful for comment

nick



Unnecessary creation of session data...

2001-09-04 Thread Vishy Kasar

Hi,

Here is an improvement suggestion.

Assume a TomCat instance is serving a session which is
being backed up in a Database. That TomCat instance dies
and another comes up. When browser sends another request
pertaining to the session it has already established with
previous instance of tomcat, the current tomcat instance
rightly goes to Database, gets back the session data and
continues to serve the session. However there are some
inefficiencies in how it does that.

First of all, ManagerBase.createSession is going to create
a full fledged session with all the data including the
generation of a new session ID. Almost immediately, all
these data gets overwritten with the real data that we read
from the database. This full fledged creation is
unnecessary.

Secondly, StandardSession.setId which is attempting to set
the new session ID to the one that is read from DB,
realizes that session already has another ID and it tries
to remove it from DB. This results in another distributed
call. This again is totally unnecessary as there  is
nothing to remove from DB.

IMO, both of the above problems can be corrected by
allowing to create an empty session. We can add a new API
createEmptySession() to catalina.Manager interface and
implementation will return a new uninitialized session with
the understanding that it will be immedietly filled with
real data.

Another way could be to add
createSession(ObjectInputStream) to catalina.Manager which
allows it to create a full fledged session from the data in
input stream.

Comments?


--
Cheers!






cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/authenticator FormAuthenticator.java

2001-09-04 Thread craigmcc

craigmcc01/09/04 10:49:17

  Modified:catalina/src/share/org/apache/catalina/authenticator
FormAuthenticator.java
  Log:
  Do not double up query-string based parameters when restoring the original
  request after a form based login.  This was only happening on GET requests
  -- POST requests were (and continue to be) processed correctly.
  
  PR: Bugzilla #3306
  Submitted by: Vincente Salvador <[EMAIL PROTECTED]>
  
  Revision  ChangesPath
  1.17  +12 -10
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/authenticator/FormAuthenticator.java
  
  Index: FormAuthenticator.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/authenticator/FormAuthenticator.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -r1.16 -r1.17
  --- FormAuthenticator.java2001/08/01 03:04:04 1.16
  +++ FormAuthenticator.java2001/09/04 17:49:17 1.17
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/authenticator/FormAuthenticator.java,v
 1.16 2001/08/01 03:04:04 craigmcc Exp $
  - * $Revision: 1.16 $
  - * $Date: 2001/08/01 03:04:04 $
  + * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/authenticator/FormAuthenticator.java,v
 1.17 2001/09/04 17:49:17 craigmcc Exp $
  + * $Revision: 1.17 $
  + * $Date: 2001/09/04 17:49:17 $
*
* 
*
  @@ -88,7 +88,7 @@
* Authentication, as described in the Servlet API Specification, Version 2.2.
*
* @author Craig R. McClanahan
  - * @version $Revision: 1.16 $ $Date: 2001/08/01 03:04:04 $
  + * @version $Revision: 1.17 $ $Date: 2001/09/04 17:49:17 $
*/
   
   public final class FormAuthenticator
  @@ -368,12 +368,14 @@
   request.addLocale((Locale) locales.next());
   }
   request.clearParameters();
  -Iterator paramNames = saved.getParameterNames();
  -while (paramNames.hasNext()) {
  -String paramName = (String) paramNames.next();
  -String paramValues[] =
  -  (String[]) saved.getParameterValues(paramName);
  -request.addParameter(paramName, paramValues);
  +if ("POST".equalsIgnoreCase(saved.getMethod())) {
  +Iterator paramNames = saved.getParameterNames();
  +while (paramNames.hasNext()) {
  +String paramName = (String) paramNames.next();
  +String paramValues[] =
  +(String[]) saved.getParameterValues(paramName);
  +request.addParameter(paramName, paramValues);
  +}
   }
   request.setMethod(saved.getMethod());
   request.setQueryString(saved.getQueryString());
  
  
  



RE: cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/modules/server Ajp13.java

2001-09-04 Thread Schreibman, David

It's great to see this work on chunked input progressing!

It's hard for me to see if it's covered here, so I wanted to double check
whether this code addresses a subtle bug that I ran into while getting
chunked input working on 3.2.2

For me, the problem came up when read_fully_from_server() would call read()
with a very small value of len.

The bug would not manifest itself all the time so I didn't notice it for a
while.  The problem occurs only when you happen to call
ap_get_client_block() with a very small value of len and
ap_get_client_block() needs to start a new chunk.  By small value, I mean
anything less than the length of "chunk-size [ chunk-ext ] CRLF", as defined
in rfc 2069.  That's because ap_get_client_block() actually uses the buffer
that is passed in, to read the chunk-size data.

The comments for ap_get_client_block in http_protocol.c indicate the
requirement for the caller to provide enough buffer space to deal with this.
You can luck out a lot of the time, but if you hit this case
ap_get_client_block() will fail.  I only spotted this while doing a stress
test that was repeatedly posting 100MB.

It know it was heavy handed but this is what lead me to set up a separate
read buffer for each endpoint.  That way I would be sure to always call
ap_get_client_block() with a generously sized buffer.  I don't blame you for
avoiding this approach.

Again, my apologies is this is obviously covered.  Just wanted to make sure
this was addressed in the latest changes (and bring it up while my memory on
the topic is still fresh).

Thanks,

-David



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Friday, August 31, 2001 6:53 PM
To: [EMAIL PROTECTED]
Subject: cvs commit:
jakarta-tomcat/src/share/org/apache/tomcat/modules/server Ajp13.java


keith   01/08/31 18:53:25

  Modified:src/native/mod_jk/apache1.3 mod_jk.c
   src/native/mod_jk/common jk_ajp13_worker.c jk_service.h
jk_util.c
   src/share/org/apache/tomcat/modules/server Ajp13.java
  Log:
  Upgrade mod_jk to support chunked input from Apache 1.3.
  TODO: port to Apache 2.0 module. (And forward port to j-t-c)
  
  Revision  ChangesPath
  1.10  +22 -11jakarta-tomcat/src/native/mod_jk/apache1.3/mod_jk.c
  
  Index: mod_jk.c
  ===
  RCS file: /home/cvs/jakarta-tomcat/src/native/mod_jk/apache1.3/mod_jk.c,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- mod_jk.c  2001/06/01 08:41:13 1.9
  +++ mod_jk.c  2001/09/01 01:53:25 1.10
  @@ -267,16 +267,19 @@
   if(s && s->ws_private && b && actually_read) {
   apache_private_data_t *p = s->ws_private;
   if(!p->read_body_started) {
  -if(!ap_setup_client_block(p->r, REQUEST_CHUNKED_DECHUNK)) {
  -if(ap_should_client_block(p->r)) { 
  -p->read_body_started = JK_TRUE; 
  -}
  +if(ap_should_client_block(p->r)) { 
  +p->read_body_started = JK_TRUE; 
   }
   }
   
  -if(p->read_body_started) {
  -*actually_read = ap_get_client_block(p->r, b, len);
  -return JK_TRUE;
  +if(p->read_body_started) {
  + long rv;
  + if ((rv = ap_get_client_block(p->r, b, len)) < 0) {
  + *actually_read = 0;
  + } else {
  + *actually_read = (unsigned) rv;
  + }
  +return JK_TRUE;
   }
   }
   return JK_FALSE;
  @@ -454,7 +457,9 @@
   s->server_software = (char *)ap_get_server_version();
   
   s->method   = (char *)r->method;
  -s->content_length = get_content_length(r);
  +s->content_length = get_content_length(r);
  +s->is_chunked   = r->read_chunked;
  +s->no_more_chunks = 0;
   s->query_string = r->args;
   s->req_uri  = r->uri;
   
  @@ -784,10 +789,16 @@
   {   
   /* Retrieve the worker name stored by jk_translate() */
   const char *worker_name = ap_table_get(r->notes, JK_WORKER_ID);
  +int rc;
   
   if(r->proxyreq) {
   return HTTP_INTERNAL_SERVER_ERROR;
  -}
  +}
  +
  +/* Set up r->read_chunked flags for chunked encoding, if present */
  +if(rc = ap_setup_client_block(r, REQUEST_CHUNKED_DECHUNK)) {
  + return rc;
  +}
 
   if(worker_name) {
   jk_server_conf_t *conf =
  @@ -820,12 +831,12 @@
 l, 
 &is_recoverable_error);
   
  -if (s.content_read < s.content_length) {
  +if (s.content_read < s.content_length ||
s.is_chunked) {
   /*
* If the servlet engine didn't consume all of
the
* request data, consume and discard all further
   

cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup ContextConfig.java

2001-09-04 Thread craigmcc

craigmcc01/09/04 11:15:31

  Modified:catalina/src/share/org/apache/catalina/core
StandardContext.java
   catalina/src/share/org/apache/catalina/startup
ContextConfig.java
  Log:
  When an application's deployment descriptor file specifies one or more
   elements, *replace* any existing list defined in the
  default "conf/web.xml" file, rather than appending to it.
  
  PR: Bugzilla #3082
  Submitted by: Michael Rimov <[EMAIL PROTECTED]>
  
  Revision  ChangesPath
  1.75  +46 -4 
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/StandardContext.java
  
  Index: StandardContext.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/StandardContext.java,v
  retrieving revision 1.74
  retrieving revision 1.75
  diff -u -r1.74 -r1.75
  --- StandardContext.java  2001/08/27 19:10:25 1.74
  +++ StandardContext.java  2001/09/04 18:15:30 1.75
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/StandardContext.java,v
 1.74 2001/08/27 19:10:25 craigmcc Exp $
  - * $Revision: 1.74 $
  - * $Date: 2001/08/27 19:10:25 $
  + * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/StandardContext.java,v
 1.75 2001/09/04 18:15:30 craigmcc Exp $
  + * $Revision: 1.75 $
  + * $Date: 2001/09/04 18:15:30 $
*
* 
*
  @@ -142,7 +142,7 @@
*
* @author Craig R. McClanahan
* @author Remy Maucherat
  - * @version $Revision: 1.74 $ $Date: 2001/08/27 19:10:25 $
  + * @version $Revision: 1.75 $ $Date: 2001/09/04 18:15:30 $
*/
   
   public class StandardContext
  @@ -378,6 +378,16 @@
   
   
   /**
  + * Should the next call to addWelcomeFile() cause replacement
  + * of any existing welcome files?  This will be set before processing the
  + * web application's deployment descriptor, so that application specified
  + * choices replace, rather than append to, those defined in
  + * the global descriptor.
  + */
  +private boolean replaceWelcomeFiles = false;
  +
  +
  +/**
* The resource environment references for this web application,
* keyed by name.
*/
  @@ -973,6 +983,32 @@
   
   
   /**
  + * Return the "replace welcome files" property.
  + */
  +public boolean isReplaceWelcomeFiles() {
  +
  +return (this.replaceWelcomeFiles);
  +
  +}
  +
  +
  +/**
  + * Set the "replace welcome files" property.
  + *
  + * @param replaceWelcomeFiles The new property value
  + */
  +public void setReplaceWelcomeFiles(boolean replaceWelcomeFiles) {
  +
  +boolean oldReplaceWelcomeFiles = this.replaceWelcomeFiles;
  +this.replaceWelcomeFiles = replaceWelcomeFiles;
  +support.firePropertyChange("replaceWelcomeFiles",
  +   new Boolean(oldReplaceWelcomeFiles),
  +   new Boolean(this.replaceWelcomeFiles));
  +
  +}
  +
  +
  +/**
* Return the servlet context for which this Context is a facade.
*/
   public synchronized ServletContext getServletContext() {
  @@ -1638,6 +1674,12 @@
   public void addWelcomeFile(String name) {
   
   synchronized (welcomeFiles) {
  +// Welcome files from the application deployment descriptor
  +// completely replace those from the default conf/web.xml file
  +if (replaceWelcomeFiles) {
  +welcomeFiles = new String[0];
  +setReplaceWelcomeFiles(false);
  +}
   String results[] =new String[welcomeFiles.length + 1];
   for (int i = 0; i < welcomeFiles.length; i++)
   results[i] = welcomeFiles[i];
  
  
  
  1.52  +8 -4  
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/ContextConfig.java
  
  Index: ContextConfig.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/ContextConfig.java,v
  retrieving revision 1.51
  retrieving revision 1.52
  diff -u -r1.51 -r1.52
  --- ContextConfig.java2001/08/27 19:10:25 1.51
  +++ ContextConfig.java2001/09/04 18:15:30 1.52
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/ContextConfig.java,v
 1.51 2001/08/27 19:10:25 craigmcc Exp $
  - * $Revision: 1.51 $
  - * $Date: 2001/08/27 19:10:25 $
  + * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/ContextConfig.java,v
 1.52 2001/09/04 18:15:30 craigmcc Exp $
  + * $Revision: 1.52 $
  + * $Date: 2001/09/04 18:15:30 $
*
* =

RE: cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/modules/server Ajp13.java

2001-09-04 Thread Schreibman, David

Oops.  Sorry for the typo.

About

>... "chunk-size [ chunk-ext ] CRLF", as defined in rfc 2069.  That's ...

I meant rfc 2068!

-David

-Original Message-
From: Schreibman, David 
Sent: Tuesday, September 04, 2001 11:03 AM
To: '[EMAIL PROTECTED]'; [EMAIL PROTECTED]
Subject: RE: cvs commit:
jakarta-tomcat/src/share/org/apache/tomcat/modules/server Ajp13.java


It's great to see this work on chunked input progressing!

It's hard for me to see if it's covered here, so I wanted to double check
whether this code addresses a subtle bug that I ran into while getting
chunked input working on 3.2.2

For me, the problem came up when read_fully_from_server() would call read()
with a very small value of len.

The bug would not manifest itself all the time so I didn't notice it for a
while.  The problem occurs only when you happen to call
ap_get_client_block() with a very small value of len and
ap_get_client_block() needs to start a new chunk.  By small value, I mean
anything less than the length of "chunk-size [ chunk-ext ] CRLF", as defined
in rfc 2069.  That's because ap_get_client_block() actually uses the buffer
that is passed in, to read the chunk-size data.

The comments for ap_get_client_block in http_protocol.c indicate the
requirement for the caller to provide enough buffer space to deal with this.
You can luck out a lot of the time, but if you hit this case
ap_get_client_block() will fail.  I only spotted this while doing a stress
test that was repeatedly posting 100MB.

It know it was heavy handed but this is what lead me to set up a separate
read buffer for each endpoint.  That way I would be sure to always call
ap_get_client_block() with a generously sized buffer.  I don't blame you for
avoiding this approach.

Again, my apologies is this is obviously covered.  Just wanted to make sure
this was addressed in the latest changes (and bring it up while my memory on
the topic is still fresh).

Thanks,

-David



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Friday, August 31, 2001 6:53 PM
To: [EMAIL PROTECTED]
Subject: cvs commit:
jakarta-tomcat/src/share/org/apache/tomcat/modules/server Ajp13.java


keith   01/08/31 18:53:25

  Modified:src/native/mod_jk/apache1.3 mod_jk.c
   src/native/mod_jk/common jk_ajp13_worker.c jk_service.h
jk_util.c
   src/share/org/apache/tomcat/modules/server Ajp13.java
  Log:
  Upgrade mod_jk to support chunked input from Apache 1.3.
  TODO: port to Apache 2.0 module. (And forward port to j-t-c)
  
  Revision  ChangesPath
  1.10  +22 -11jakarta-tomcat/src/native/mod_jk/apache1.3/mod_jk.c
  
  Index: mod_jk.c
  ===
  RCS file: /home/cvs/jakarta-tomcat/src/native/mod_jk/apache1.3/mod_jk.c,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- mod_jk.c  2001/06/01 08:41:13 1.9
  +++ mod_jk.c  2001/09/01 01:53:25 1.10
  @@ -267,16 +267,19 @@
   if(s && s->ws_private && b && actually_read) {
   apache_private_data_t *p = s->ws_private;
   if(!p->read_body_started) {
  -if(!ap_setup_client_block(p->r, REQUEST_CHUNKED_DECHUNK)) {
  -if(ap_should_client_block(p->r)) { 
  -p->read_body_started = JK_TRUE; 
  -}
  +if(ap_should_client_block(p->r)) { 
  +p->read_body_started = JK_TRUE; 
   }
   }
   
  -if(p->read_body_started) {
  -*actually_read = ap_get_client_block(p->r, b, len);
  -return JK_TRUE;
  +if(p->read_body_started) {
  + long rv;
  + if ((rv = ap_get_client_block(p->r, b, len)) < 0) {
  + *actually_read = 0;
  + } else {
  + *actually_read = (unsigned) rv;
  + }
  +return JK_TRUE;
   }
   }
   return JK_FALSE;
  @@ -454,7 +457,9 @@
   s->server_software = (char *)ap_get_server_version();
   
   s->method   = (char *)r->method;
  -s->content_length = get_content_length(r);
  +s->content_length = get_content_length(r);
  +s->is_chunked   = r->read_chunked;
  +s->no_more_chunks = 0;
   s->query_string = r->args;
   s->req_uri  = r->uri;
   
  @@ -784,10 +789,16 @@
   {   
   /* Retrieve the worker name stored by jk_translate() */
   const char *worker_name = ap_table_get(r->notes, JK_WORKER_ID);
  +int rc;
   
   if(r->proxyreq) {
   return HTTP_INTERNAL_SERVER_ERROR;
  -}
  +}
  +
  +/* Set up r->read_chunked flags for chunked encoding, if present */
  +if(rc = ap_setup_client_block(r, REQUEST_CHUNKED_DECHUNK)) {
  + return rc;
  +}
 
   if(worker_name) {
   jk_server_conf_t *conf =
  @@ -820,12 +831,12 @@
 l, 
 &is_recoverable_erro

Re: FW: JSP, performance analysis?

2001-09-04 Thread cmanolache

On Tue, 4 Sep 2001, Israel Olalla wrote:

> When working with JSP we have a serious degradation problem with acces
> to filesystem:
>
> - java.io.Win32FileSystem.getLastModifiedTime

Try again with 3.3.

Tag pooling is not enabled by default because many tags are buggy, so
you'll need to edit server.xml and enable it. Reloading has been rewritten
and now it shouldn't add any overhead.

Few bigger optimizations are on the works and will be available as a
separate module - togheter with 1.2 features ( jasper34 )

Costin

>
> There's some way to desactivate the control of changes in JSP file's?.
> In order to avoid access to FileSystem.?
>
>
> Finally our problem was with Taglibs iterate ... logic ... it creates
> thousands... of objects ... and the GC eats the whole machine but that's
> an advise to other list.
>
> Thanks for you patience and time
>
> This message and any files transmitted with it are confidential and intended
> solely for the use of the individual or entity to whom they are addressed.
> No confidentiality or privilege is waived or lost by any wrong transmission.
> If you have received this message in error, please immediately destroy it
> and kindly notify the sender by reply email.
> You must not, directly or indirectly, use, disclose, distribute, print, or
> copy any part of this message if you are not the intended recipient.
> Opinions, conclusions and other information in this message that do not
> relate to the official business of Newknow shall be understood as neither
> given nor endorsed by it.
>
>
>
>




cvs commit: jakarta-tomcat-4.0 RELEASE-PLAN-4.0.txt

2001-09-04 Thread craigmcc

craigmcc01/09/04 13:04:02

  Added:   .RELEASE-PLAN-4.0.txt
  Log:
  Initial draft of a release plan for Tomcat 4.0 final release.
  
  Revision  ChangesPath
  1.1  jakarta-tomcat-4.0/RELEASE-PLAN-4.0.txt
  
  Index: RELEASE-PLAN-4.0.txt
  ===
  $Id: RELEASE-PLAN-4.0.txt,v 1.1 2001/09/04 20:04:02 craigmcc Exp $
  
Release Plan for Apache Tomcat 4.0
==
  
  
  Introduction:
  
  
  This document is a release plan for the *final* release of Apache Tomcat 4.0.
  We've been waiting for the underlying specifications (Servlet 2.3 and JSP 1.2)
  to go final.  As these specifications are now in the Executive Committee voting
  step of the Java Community Process, this time is now at hand.
  
  The goal of the Apache Tomcat 4.0 final release is to provide a stable
  container that supports 100% of the mandatory requirements of the Servlet 2.3
  and JSP 1.2 specifications, as well as many useful additional features.  To
  that end, a series of beta releases have been distributed, and the focus has
  been primarily on specification compliance and other bug fixes, rather than
  adding functionality.
  
  This Release Plan proposes the following schedule:
  
Monday, September 9, 2001  Tomcat 4.0 Release Candidate 1
  
Thursday, September 12, 2001   Tomcat 4.0 Release Candidate 2
  
Monday, September 17, 2001 Tomcat 4.0 Final Release
  
  In order to complete final release, all outstanding Bugzilla bug reports
  against Tomcat 4.0 need to be fixed or deferred for later releases.  This
  Release Plan proposes the following classification of current outstanding
  bug reports in the bug tracking system, sorted by component and their ID
  numbers in our bug tracking system at:
  
http://nagoya.apache.org/bugzilla/
  
  Please review the bug reports, and their classification as "must have",
  "nice to have", or "address later".  Lobbying for changes in classification
  can take place on the TOMCAT-DEV mailling list.  In addition, if you have a
  bug report or enhancement that you wish to have considered prior to final
  release, please submit a bug report as quickly as possible.
  
  
  
  Bugs That Must Be Addressed Before Final Release:
  
  
  Catalina2883Error page for 401 error code is not populated
  
  Catalina3093Base64.decode returns extra 0's at end of array
  
  Catalina3232Cookie values are URLDecoded but not URLEncoded
  
  Catalina3292Class reloading fails
  
  Connectors  1788mod_webapp errors on Win2k
  
  Connectors  2334Tomcat 4.0-b5 + Apache 1.3.12?
  
  Connectors  2997Webapp connector should recover when Tomcat is restarted
  
  Connectors  2999Linking trouble: webapp connectors and Apache 1.3 apxs
  
  Connectors  3160mod_webapp performance issues
  
  Jasper  2693Syntax errors in JSP source generate NumberFormatException
  
  Jasper  2917JSP compiled file name is not correct
  
  Jasper  3019Jasper generates bad custom tag variable names
  
  Jasper  3079NullPointerException in JakartaCommentGenerator.generateEnd
  
  Jasper  3127 not supported
  
  Jasper  3174XML view of JSP document is incorrect
  
  Jasper  3235JSPC command line compiler does not support taglibs
  
  Jasper  3350Using XML syntax causes content rearrangement
  
  Jasper  3351JSP documents in XML syntax produce invalid XML
  
  Jasper  3366Character tag attributes
  
  Jasper  3381Tag attributes of type short not working
  
  Jasper  3398Jasper does not support primitive types for tag variables
  
  Webapps 3009Manager cannot install web app
  
  Webapps 3336ArrayIndexOutOfBounds exception when starting and stopping
  an app several times through Manager
  
  Webapps 3383CompressionFilter problem in Catalina
  
  
  Nice To Have Fixes Before Final Release:
  ---
  
  Catalina2949Tomcat 4.0/Solaris follow soft links for public_html
  
  Catalina3114Spanish translations of LocalString.properties files
  
  Catalina3194Javadoc errors during build
  
  Catalina3285Tomcat 4.0-b5 class loader fails on IBM JDK
  
  Catalina3293Allow content lengths > 2^31
  
  Jasper  3055 tag ignores the name attribute
  
  Jasper  3195Javadoc errors during build
  
  Jasper  3340sun.tools.javac.Main has been deprecated in JDK 1.4-beta-2
  
  Servletapi  3196Javadoc errors during build
  
  Servletapi  3344Typo in javadocs
  
  
  Enhancement Requests To Be Addressed Later:
  --
  
  Catalina1400SSLServerSocketFactory.java does not support multiple
   

[VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Craig R. McClanahan

Well, it's just about that time ... the Servlet 2.3 and JSP 1.2
specifications are going final soon (they are being voted on in the Java
Community Process as we speak).  Therefore, I've just submitted an initial
draft of a Release Plan document for final release of Tomcat 4.0, which
can be viewed online via:

http://cvs.apache.org/viewcvs/~checkout~/jakarta-tomcat-4.0/RELEASE-PLAN-4.0.txt

Please review this proposal, and the associated Bugzilla bug reports, and
cast your vote:

-- Release Plan for Apache Tomcat 4.0 (final release) --
[ ] +1I am in favor of this plan, and will help
[ ] +0I am in favor of this plan, but am unable to help
[ ] -0I not in favor of this plan
[ ] -1I am opposed to this plan, and my reason(s) are:




Craig McClanahan







cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util CookieTools.java

2001-09-04 Thread craigmcc

craigmcc01/09/04 14:02:35

  Modified:catalina/src/share/org/apache/catalina/util CookieTools.java
  Log:
  Call URLEncode on cookie names and values, to correspond with the fact
  that we call URLDecode when *reading* the returned values.
  
  PR: Bugzilla #3232
  Submitted by: [EMAIL PROTECTED]
  
  Revision  ChangesPath
  1.4   +7 -6  
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util/CookieTools.java
  
  Index: CookieTools.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util/CookieTools.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- CookieTools.java  2001/07/22 20:25:13 1.3
  +++ CookieTools.java  2001/09/04 21:02:35 1.4
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util/CookieTools.java,v
 1.3 2001/07/22 20:25:13 pier Exp $
  - * $Revision: 1.3 $
  - * $Date: 2001/07/22 20:25:13 $
  + * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util/CookieTools.java,v
 1.4 2001/09/04 21:02:35 craigmcc Exp $
  + * $Revision: 1.4 $
  + * $Date: 2001/09/04 21:02:35 $
*
* 
*
  @@ -63,6 +63,7 @@
   
   
   package org.apache.catalina.util;
  +import java.net.URLEncoder;
   import java.text.*;
   import java.util.*;
   
  @@ -107,7 +108,7 @@
   
   // this part is the same for all cookies
   
  -buf.append(cookie.getName());
  +buf.append(URLEncoder.encode(cookie.getName()));
   buf.append("=");
   maybeQuote(version, buf, cookie.getValue());
   
  @@ -165,10 +166,10 @@
   String value)
   {
   if (version == 0 || isToken (value))
  -  buf.append (value);
  +  buf.append (URLEncoder.encode(value));
   else {
   buf.append ('"');
  -buf.append (value);
  +buf.append (URLEncoder.encode(value));
   buf.append ('"');
   }
   }
  
  
  



cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util Base64.java

2001-09-04 Thread craigmcc

craigmcc01/09/04 14:49:55

  Modified:catalina/src/share/org/apache/catalina/util Base64.java
  Log:
  Update Base64 implementation (matches the one in the commons util package)
  to eliminate trailing 00 bytes on the output from decode().
  
  PR: Bugzilla #3093
  Submitted by: Kevin Brown <[EMAIL PROTECTED]>
  
  Revision  ChangesPath
  1.4   +133 -103  
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util/Base64.java
  
  Index: Base64.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util/Base64.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- Base64.java   2001/07/22 20:25:13 1.3
  +++ Base64.java   2001/09/04 21:49:55 1.4
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util/Base64.java,v 
1.3 2001/07/22 20:25:13 pier Exp $
  - * $Revision: 1.3 $
  - * $Date: 2001/07/22 20:25:13 $
  + * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/util/Base64.java,v 
1.4 2001/09/04 21:49:55 craigmcc Exp $
  + * $Revision: 1.4 $
  + * $Date: 2001/09/04 21:49:55 $
*
* 
*
  @@ -61,23 +61,20 @@
*
*/
   
  -
   package org.apache.catalina.util;
   
  -
   /**
  - * This class provides encode/decode for RFC 2045 Base64 as
  - * defined by RFC 2045, N. Freed and N. Borenstein.
  - * RFC 2045: Multipurpose Internet Mail Extensions (MIME)
  - * Part One: Format of Internet Message Bodies. Reference
  - * 1996 Available at: http://www.ietf.org/rfc/rfc2045.txt
  - * This class is used by XML Schema binary format validation
  + * This class provides encode/decode for RFC 2045 Base64 as defined by
  + * RFC 2045, N. Freed and N. Borenstein.  http://www.ietf.org/rfc/rfc2045.txt";>RFC 2045:
  + * Multipurpose Internet Mail Extensions (MIME) Part One: Format of
  + * Internet Message Bodies. Reference 1996
*
* @author Jeffrey Rodriguez
  - * @version $Id: Base64.java,v 1.3 2001/07/22 20:25:13 pier Exp $
  + * @version $Id: Base64.java,v 1.4 2001/09/04 21:49:55 craigmcc Exp $
*/
  -
  -public final class  Base64 {
  +public final class  Base64
  +{
   static private final int  BASELENGTH = 255;
   static private final int  LOOKUPLENGTH   = 64;
   static private final int  TWENTYFOURBITGROUP = 24;
  @@ -86,207 +83,240 @@
   static private final int  SIXBIT = 6;
   static private final int  FOURBYTE   = 4;
   static private final int  SIGN   = -128;
  -static private final byte PAD= ( byte ) '=';
  -static private final boolean fDebug  = false;
  +static private final byte PAD= (byte) '=';
   static private byte [] base64Alphabet   = new byte[BASELENGTH];
   static private byte [] lookUpBase64Alphabet = new byte[LOOKUPLENGTH];
  -
  -
  -static {
  +//static private final Log log = 
LogSource.getInstance("org.apache.commons.util.Base64");
   
  -for (int i = 0; i= 'A'; i-- ) {
  -base64Alphabet[i] = (byte) (i-'A');
  +for (int i = 'Z'; i >= 'A'; i--)
  +{
  +base64Alphabet[i] = (byte) (i - 'A');
   }
  -for ( int i = 'z'; i>= 'a'; i--) {
  -base64Alphabet[i] = (byte) ( i-'a' + 26);
  +for (int i = 'z'; i>= 'a'; i--)
  +{
  +base64Alphabet[i] = (byte) (i - 'a' + 26);
   }
  -
  -for ( int i = '9'; i >= '0'; i--) {
  -base64Alphabet[i] = (byte) (i-'0' + 52);
  +for (int i = '9'; i >= '0'; i--)
  +{
  +base64Alphabet[i] = (byte) (i - '0' + 52);
   }
   
   base64Alphabet['+']  = 62;
   base64Alphabet['/']  = 63;
  +
  +for (int i = 0; i <= 25; i++ )
  +lookUpBase64Alphabet[i] = (byte) ('A' + i);
   
  -for (int i = 0; i<=25; i++ )
  -lookUpBase64Alphabet[i] = (byte) ('A'+i );
  +for (int i = 26,  j = 0; i <= 51; i++, j++ )
  +lookUpBase64Alphabet[i] = (byte) ('a'+ j);
   
  -for (int i = 26,  j = 0; i<=51; i++, j++ )
  -lookUpBase64Alphabet[i] = (byte) ('a'+ j );
  +for (int i = 52,  j = 0; i <= 61; i++, j++ )
  +lookUpBase64Alphabet[i] = (byte) ('0' + j);
   
  -for (int i = 52,  j = 0; i<=61; i++, j++ )
  -lookUpBase64Alphabet[i] = (byte) ('0' + j );
   lookUpBase64Alphabet[62] = (byte) '+';
   lookUpBase64Alphabet[63] = (byte) '/';
  -
   }
   
  -public static boolean isBase64( String isValidString ){
  -return( isArrayByteBase64( isValidString.getBytes()));
  +public static boolean isBase64( String isValidString )
  +{
  +return isArrayByteBase64(isValidString.getBytes());
  

Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Andy Armstrong



"Craig R. McClanahan" wrote:
> 
> Well, it's just about that time ... the Servlet 2.3 and JSP 1.2
> specifications are going final soon (they are being voted on in the Java
> Community Process as we speak).  Therefore, I've just submitted an initial
> draft of a Release Plan document for final release of Tomcat 4.0, which
> can be viewed online via:
> 
> http://cvs.apache.org/viewcvs/~checkout~/jakarta-tomcat-4.0/RELEASE-PLAN-4.0.txt
> 
> Please review this proposal, and the associated Bugzilla bug reports, and
> cast your vote:
> 
> -- Release Plan for Apache Tomcat 4.0 (final release) --
> [X] +1I am in favor of this plan, and will help
> [ ] +0I am in favor of this plan, but am unable to help
> [ ] -0I not in favor of this plan
> [ ] -1I am opposed to this plan, and my reason(s) are:
> 
> Craig McClanahan

-- 
Andy Armstrong, Tagish



Re: Security Manager, Embedded and Class Loading

2001-09-04 Thread Craig R. McClanahan

This is actually pretty easy to understand.

When you do something like

  StandardEngine engine = ...;
  System.out.println("My engine is " + engine);

Java automatically calls engine.toString() for you.  Most (but not quite
all, obviously) of the core Catalina components override toString() to
print out something reasonable.  If you get

  StandardEngine[null]

that just means you have not called engine.getName() yet -- afterwards, it
will print whatever name you've assigned it inside the square brackets.

Craig


On Tue, 4 Sep 2001, Nick Betteridge wrote:

> Date: Tue, 04 Sep 2001 18:27:10 +0100
> From: Nick Betteridge <[EMAIL PROTECTED]>
> Reply-To: [EMAIL PROTECTED]
> To: [EMAIL PROTECTED]
> Subject: Security Manager, Embedded and Class Loading
>
> I've a problem that I don't really understand.
>
> I'm in the process of getting the security manager to work with an
> Embedded setup and the bootstrap is virtually the same as Catalina's.
>
> If I create, for example, a (Standard)Server and (Standard)Service, I
> get objects generated. If I attempt to create an engine, the classloader
> (catalinaLoader) finds the (Standard)Engine class, but is unable to
> create a newInstance.
>
> ie ...
>
>
>
> /**
>  * Create a new server instance.
>  */
> public void serverCreate() {
> try {
> Class serverClass =
> catalinaClassLoader.loadClass("org.apache.catalina.core.StandardServer");
> Object server = serverClass.newInstance();
> } catch (Exception ex) {
> }
> }
>
> ... will create a : org.apache.catalina.core.StandardServer@5d56d5
>
>
> but a
>
>
>
> public void engineCreate() {
> try {
> Class engineClass =
> catalinaClassLoader.loadClass("org.apache.catalina.core.StandardEngine");
> Object engine = engineClass.newInstance();
> } catch (Exception ex) {
> }
> }
>
>
> will give a : StandardEngine[null]
>
>
> . note that the full package name is missing and that engineClass is
> found.
>
>
> If anybody can shed any light on this, I'd be very grateful for comment
>
> nick
>




cvs commit: jakarta-tomcat-4.0 RELEASE-PLAN-4.0.txt

2001-09-04 Thread craigmcc

craigmcc01/09/04 15:59:28

  Modified:.RELEASE-PLAN-4.0.txt
  Log:
  Update to remove a couple of bugs that have already been fixed.
  
  Revision  ChangesPath
  1.2   +1 -5  jakarta-tomcat-4.0/RELEASE-PLAN-4.0.txt
  
  Index: RELEASE-PLAN-4.0.txt
  ===
  RCS file: /home/cvs/jakarta-tomcat-4.0/RELEASE-PLAN-4.0.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- RELEASE-PLAN-4.0.txt  2001/09/04 20:04:02 1.1
  +++ RELEASE-PLAN-4.0.txt  2001/09/04 22:59:28 1.2
  @@ -1,4 +1,4 @@
  -$Id: RELEASE-PLAN-4.0.txt,v 1.1 2001/09/04 20:04:02 craigmcc Exp $
  +$Id: RELEASE-PLAN-4.0.txt,v 1.2 2001/09/04 22:59:28 craigmcc Exp $
   
 Release Plan for Apache Tomcat 4.0
 ==
  @@ -47,10 +47,6 @@
   
   
   Catalina2883Error page for 401 error code is not populated
  -
  -Catalina3093Base64.decode returns extra 0's at end of array
  -
  -Catalina3232Cookie values are URLDecoded but not URLEncoded
   
   Catalina3292Class reloading fails
   
  
  
  



Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Pier Fumagalli

"Craig R. McClanahan" <[EMAIL PROTECTED]> wrote:

> -- Release Plan for Apache Tomcat 4.0 (final release) --
> [X] +1I am in favor of this plan, and will help
> [ ] +0I am in favor of this plan, but am unable to help
> [ ] -0I not in favor of this plan
> [ ] -1I am opposed to this plan, and my reason(s) are:

Purrfect, as my vacation week starts on the 22nd (San Diego here we come :)

Pier (sticking out his Cubans for celebration)




Tomcat logging and xml

2001-09-04 Thread Deacon Marcus

Hi,
I was wondering, why Tomcat isn't using JDOM and/or Log4j? They're great
APIs, much clearer than what's used currently.

Greetings, deacon Marcus




cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup LocalStrings.properties UserConfig.java

2001-09-04 Thread craigmcc

craigmcc01/09/04 17:31:50

  Modified:catalina/src/share/org/apache/catalina/connector/http
HttpProcessor.java
   catalina/src/share/org/apache/catalina/startup
LocalStrings.properties UserConfig.java
  Log:
  Re-fix the "User Web Applications" feature that allows you to
  automatically configure context paths for user public_html directories.
  It got broken when adding some request URI normalization code.
  
  The criteria for publishing a user web applcation is now simply that the
  public_html directory exists and is readable.  Previously, UserConfig was
  also requiring that a WEB-INF/web.xml file be present, but this would not
  generally be true for users publishing simple static web sites under their
  user directories.
  
  PR: Bugzilla #2949
  Submitted by: Robert Evans <[EMAIL PROTECTED]>
  
  Revision  ChangesPath
  1.36  +9 -4  
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/connector/http/HttpProcessor.java
  
  Index: HttpProcessor.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/connector/http/HttpProcessor.java,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -r1.35 -r1.36
  --- HttpProcessor.java2001/08/09 19:43:00 1.35
  +++ HttpProcessor.java2001/09/05 00:31:50 1.36
  @@ -1,6 +1,6 @@
  -/* * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/connector/http/HttpProcessor.java,v
 1.35 2001/08/09 19:43:00 craigmcc Exp $
  - * $Revision: 1.35 $
  - * $Date: 2001/08/09 19:43:00 $
  +/* * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/connector/http/HttpProcessor.java,v
 1.36 2001/09/05 00:31:50 craigmcc Exp $
  + * $Revision: 1.36 $
  + * $Date: 2001/09/05 00:31:50 $
*
* 
*
  @@ -106,7 +106,7 @@
*
* @author Craig R. McClanahan
* @author Remy Maucherat
  - * @version $Revision: 1.35 $ $Date: 2001/08/09 19:43:00 $
  + * @version $Revision: 1.36 $ $Date: 2001/09/05 00:31:50 $
*/
   
   final class HttpProcessor
  @@ -828,6 +828,11 @@
   
   // Create a place for the normalized path
   String normalized = path;
  +
  +// Normalize "/%7E" and "/%7e" at the beginning to "/~"
  +if (normalized.startsWith("/%7E") ||
  +normalized.startsWith("/%7e"))
  +normalized = "/~" + normalized.substring(4);
   
   // Prevent encoding '%', '/', '.' and '\', which are special reserved
   // characters
  
  
  
  1.12  +1 -0  
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/LocalStrings.properties
  
  Index: LocalStrings.properties
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/LocalStrings.properties,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- LocalStrings.properties   2000/10/18 04:19:08 1.11
  +++ LocalStrings.properties   2001/09/05 00:31:50 1.12
  @@ -44,6 +44,7 @@
   hostConfig.undeploying=Undeploying deployed web applications
   userConfig.database=Exception loading user database
   userConfig.deploy=Deploying web application for user {0}
  +userConfig.deploying=Deploying user web applications
   userConfig.error=Error deploying web application for user {0}
   userConfig.start=UserConfig: Processing START
   userConfig.stop=UserConfig: Processing STOP
  
  
  
  1.3   +7 -5  
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/UserConfig.java
  
  Index: UserConfig.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/UserConfig.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- UserConfig.java   2001/07/22 20:25:13 1.2
  +++ UserConfig.java   2001/09/05 00:31:50 1.3
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/UserConfig.java,v
 1.2 2001/07/22 20:25:13 pier Exp $
  - * $Revision: 1.2 $
  - * $Date: 2001/07/22 20:25:13 $
  + * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/startup/UserConfig.java,v
 1.3 2001/09/05 00:31:50 craigmcc Exp $
  + * $Revision: 1.3 $
  + * $Date: 2001/09/05 00:31:50 $
*
* 
*
  @@ -85,7 +85,7 @@
* x is the username of the owning user for that web application
*
* @author Craig R. McClanahan
  - * @version $Revision: 1.2 $ $Date: 2001/07/22 20:25:13 $
  + * @version $Revision: 1.3 $ $Date: 2001/09/05 00:31:50 $
*/
   
   public final class UserConfig
  @@ -349,15 +349,1

Re: Tomcat logging and xml

2001-09-04 Thread Craig R. McClanahan



On Wed, 5 Sep 2001, Deacon Marcus wrote:

> Date: Wed, 5 Sep 2001 02:23:39 +0200
> From: Deacon Marcus <[EMAIL PROTECTED]>
> Reply-To: [EMAIL PROTECTED]
> To: [EMAIL PROTECTED]
> Subject: Tomcat logging and xml
>
> Hi,
> I was wondering, why Tomcat isn't using JDOM and/or Log4j? They're great
> APIs, much clearer than what's used currently.
>
> Greetings, deacon Marcus
>
>

I can give you some personal thoughts, relevant only to Tomcat 4.x
development:

Regarding JDOM:

* JDOM is not a stable API yet.  It seems unwise to me to commit to
  an API that is still subject to change when we're trying to release
  a stable container soon.

* The amount of XML processing done within Tomcat itself is pretty
  small, so using JDOM wouldn't add much value:

  - Parsing web.xml and server.xml files is done with XmlMapper, which
is a nice wrapper around SAX events.  This seems quite sufficient.

  - Parsing JSP pages in XML syntax might benefit from some sort of a
DOM view of the world, but this is a pretty major change -- and only
seems worthwhile in the context of an optimizing compiler that will
go scan the tree and modify it prior to code generation.

* JDOM isn't the only DOM-like API gaining popularity -- DOM4J seems to be
  gaining mindshare as well.  Choosing one or the other will need some
  careful comparisons.

Regarding Log4J:

* The existing model of logging in Tomcat 4 (where you can override
  loggers at the context or host level) does not map very well to Log4J's
  "category" concept, although (as Ceki has pointed out) it is feasible
  to establish such a mapping that at least works.

* I don't care for the performance impact of the programming approach
  that lets the logger decide to throw away a log message that is not
  wanted *after* the component has paid the performance penalty for doing
  all the string concatenations in a typical log message.  There's a way
  around this (seeing if debug is enabled, for example), but it is *much*
  more cumbersome to type than the current "if (debug >= 1)" type tests.

* Overall, migrating to Log4J is something worth considering in a
  Tomcat 4.1 time frame, but it's medium-to-low on my personal priority
  list.

None of the above, of course, has anything to do with the use of JDOM
and/or LOG4J in web applications that run on top of Tomcat.  They are free
to do whatever they want.

Craig





Bug report for Tomcat 4 [2001/09/04]

2001-09-04 Thread bugzilla

+---+
| Bugzilla Bug ID   |
| +-+
| | Status: UNC=Unconfirmed NEW=New ASS=Assigned|
| | OPN=ReopenedVER=Verified(Skipped Closed/Resolved)   |
| |   +-+
| |   | Severity: BLK=Blocker CRI=CriticalMAJ=Major |
| |   |   MIN=Minor   NOR=Normal  EHN=Ehnancement   |
| |   |   +-+
| |   |   | Date Posted |
| |   |   |  +--+
| |   |   |  | Description  |
| |   |   |  |  |
| 3336|New|Blk|2001-08-29|Exception in servletloader|
| 3398|New|Blk|2001-09-03|Jasper does not support primitive type for tag var|
| 2917|New|Cri|2001-07-31|JSP compiled file name is not correct |
| 3009|New|Maj|2001-08-06|Web manager cannot install web app - system cannot|
| 3160|New|Maj|2001-08-17|mod_webapp performace issues... NT4, Apache 1.3.20|
| 3285|New|Maj|2001-08-27|Tomcat 4.0-b5 ClassLoader fails on IBM JDK, but wo|
| 3292|New|Maj|2001-08-27|class reloading fails |
| 1237|New|Nor|2001-04-05|org.apache.catalina.net.SSLServerSocketFactory cla|
| 2949|New|Nor|2001-08-01|Tomcat 4.0/Solaris tomcat follow soft links for pu|
| 3019|New|Nor|2001-08-07|Jasper generates bad custom tag variable names|
| 3055|New|Nor|2001-08-09|jsp:plugin tag ignores the name attribute |
| 3127|New|Nor|2001-08-14| not supported   |
| 3174|New|Nor|2001-08-20|XML View for JSP Document Incorrect   |
| 3194|New|Nor|2001-08-20|javadoc errors|
| 3195|New|Nor|2001-08-20|javadoc errors|
| 3196|New|Nor|2001-08-20|javadoc errors|
| 3235|New|Nor|2001-08-22|jspc commandline compiler does not support taglibs|
| 3350|New|Nor|2001-08-29|Using XML syntax causes content rearrangement |
| 3351|New|Nor|2001-08-29|JSP documents in XML syntax produce invalid XML   |
| 3366|New|Nor|2001-09-01|Character tag attributes  |
| 3381|New|Nor|2001-09-03|Tag attributes of type short not working  |
| 3383|New|Nor|2001-09-03|CompressionFilter problem in Catalina |
| 3079|New|Min|2001-08-10|NullPointer exception in JakartaCommentGenerator.g|
| 3114|New|Min|2001-08-14|Spanish traslations of LocalStrings.properties|
| 3293|New|Min|2001-08-27|Please refer to Tomcat 3.x bug URL -- see if appli|
| 3340|New|Min|2001-08-29|sun.tools.javac.Main has been deprecated on JDK 1.|
| 3344|New|Min|2001-08-29|A typo in jakarta-servletapi-4/src/share/javax/ser|
| 1400|New|Enh|2001-04-19|SSLServerSocketFactory.java does not support the s|
| 1575|New|Enh|2001-04-29|Slow server start due to SAX Parsing  |
| 2500|New|Enh|2001-07-08|FileNotFoundException from service() unintentional|
| 2570|New|Enh|2001-07-11|Add the ability to configure a default error handl|
| 1788|Ass|Cri|2001-05-16|mod_webapp errors in Win2k|
| 2999|Ass|Maj|2001-08-06|Linking trouble : webapp connectors and apache1.3 |
| 2334|Ass|Nor|2001-06-26|Does tomcat 4.0 Beta 5 work with apache 1.3.12?   |
| 2883|Ass|Nor|2001-07-30|error page for 401 error code is not populated|
| 2622|Ass|Enh|2001-07-13|Jasper is not taking advantage of bodyContetn == e|
| 2823|Ass|Enh|2001-07-26|RFE: Allow a Manager inside DefaultContext|
| 2997|Ass|Enh|2001-08-05|webapp connector should recover when tomcat is res|
| 2693|Opn|Maj|2001-07-19|Syntax errors in JSP source generate NumberFormatE|
|  821|Ver|Maj|2001-03-02|JSPC doesn't like NT paths|
+-+---+---+--+--+
| Total   40 bugs   |
+---+



Bug report for Tomcat 3 [2001/09/04]

2001-09-04 Thread bugzilla

+---+
| Bugzilla Bug ID   |
| +-+
| | Status: UNC=Unconfirmed NEW=New ASS=Assigned|
| | OPN=ReopenedVER=Verified(Skipped Closed/Resolved)   |
| |   +-+
| |   | Severity: BLK=Blocker CRI=CriticalMAJ=Major |
| |   |   MIN=Minor   NOR=Normal  EHN=Ehnancement   |
| |   |   +-+
| |   |   | Date Posted |
| |   |   |  +--+
| |   |   |  | Description  |
| |   |   |  |  |
| 2610|Unc|Blk|2001-07-13|String index out of range: -1 |
|  592|Unc|Cri|2001-02-13|tomcat crashes on its own after few days  |
|  611|Unc|Cri|2001-02-14|Init Parms does not work. |
|  177|Unc|Maj|2000-10-11|Race condition during servlet initialization BugRa|
|  468|Unc|Maj|2001-01-17|Waiting 1 minute for response after Netscape issue|
|  612|Unc|Maj|2001-02-14|getServetName always returns jsp  |
|  926|Unc|Maj|2001-03-10|ServletRequestInterface request.getParameter("elem|
| 1663|Unc|Maj|2001-05-08|Tomcat -SSL problem   |
|   78|Unc|Nor|2000-08-26|HttpSessionContext BugRat Report#41   |
|   81|Unc|Nor|2000-08-28|Servlet API Javadoc is missing @since BugRat Repor|
|   82|Unc|Nor|2000-08-29|Jasper not affected by mod_rewrite BugRat Report#4|
|   97|Unc|Nor|2000-09-08|If 'default servlet' defined, I can't refer to sta|
|  100|Unc|Nor|2000-09-08|wild card mapping to servlet doesn't work through |
|  101|Unc|Nor|2000-09-11|BUG: in JSP, application.getRequestDispatcher alwa|
|  110|Unc|Nor|2000-09-14|JCE 1.2.1 support is not handled correctly BugRat |
|  111|Unc|Nor|2000-09-14|after httpd reload mod_jk fails to find a worker B|
|  116|Unc|Nor|2000-09-15|mod_jk Makefile.linux always redefines APACHE_HOME|
|  117|Unc|Nor|2000-09-15|IllegalStateException when error in jsp servlet in|
|  141|Unc|Nor|2000-09-24|Directory directive being ignored BugRat Report#15|
|  142|Unc|Nor|2000-09-25|Feature to forward requests using request dispatch|
|  154|Unc|Nor|2000-09-29|Setting Last-Modified within doGet results in dupl|
|  182|Unc|Nor|2000-10-12|JSP error-page doesn't work with virtual hosts Bug|
|  190|Unc|Nor|2000-10-18|Indexed property setter does not get called if fir|
|  215|Unc|Nor|2000-11-02|.java Package names that start with a '.' BugRat R|
|  218|Unc|Nor|2000-11-02|IIS & in-process tomcat BugRat Report#333 |
|  223|Unc|Nor|2000-11-06|security.authentication port must be True or False|
|  243|Unc|Nor|2000-11-15|NullPointerExceptions caused by javax.servlet.Serv|
|  246|Unc|Nor|2000-11-16|MIME-TYPE handling BugRat Report#398  |
|  251|Unc|Nor|2000-11-17|Add getContextPath() method to ServletContext BugR|
|  258|Unc|Nor|2000-11-27|response.SendRedirect() resets/destroys Cookies th|
|  259|Unc|Nor|2000-11-27|failure with 


Bug report for Tomcat 4 [2001/09/04]

2001-09-04 Thread bugzilla

+---+
| Bugzilla Bug ID   |
| +-+
| | Status: UNC=Unconfirmed NEW=New ASS=Assigned|
| | OPN=ReopenedVER=Verified(Skipped Closed/Resolved)   |
| |   +-+
| |   | Severity: BLK=Blocker CRI=CriticalMAJ=Major |
| |   |   MIN=Minor   NOR=Normal  EHN=Ehnancement   |
| |   |   +-+
| |   |   | Date Posted |
| |   |   |  +--+
| |   |   |  | Description  |
| |   |   |  |  |
| 3336|New|Blk|2001-08-29|Exception in servletloader|
| 3398|New|Blk|2001-09-03|Jasper does not support primitive type for tag var|
| 2917|New|Cri|2001-07-31|JSP compiled file name is not correct |
| 3009|New|Maj|2001-08-06|Web manager cannot install web app - system cannot|
| 3160|New|Maj|2001-08-17|mod_webapp performace issues... NT4, Apache 1.3.20|
| 3285|New|Maj|2001-08-27|Tomcat 4.0-b5 ClassLoader fails on IBM JDK, but wo|
| 3292|New|Maj|2001-08-27|class reloading fails |
| 1237|New|Nor|2001-04-05|org.apache.catalina.net.SSLServerSocketFactory cla|
| 3019|New|Nor|2001-08-07|Jasper generates bad custom tag variable names|
| 3055|New|Nor|2001-08-09|jsp:plugin tag ignores the name attribute |
| 3127|New|Nor|2001-08-14| not supported   |
| 3174|New|Nor|2001-08-20|XML View for JSP Document Incorrect   |
| 3194|New|Nor|2001-08-20|javadoc errors|
| 3195|New|Nor|2001-08-20|javadoc errors|
| 3196|New|Nor|2001-08-20|javadoc errors|
| 3235|New|Nor|2001-08-22|jspc commandline compiler does not support taglibs|
| 3350|New|Nor|2001-08-29|Using XML syntax causes content rearrangement |
| 3351|New|Nor|2001-08-29|JSP documents in XML syntax produce invalid XML   |
| 3366|New|Nor|2001-09-01|Character tag attributes  |
| 3381|New|Nor|2001-09-03|Tag attributes of type short not working  |
| 3383|New|Nor|2001-09-03|CompressionFilter problem in Catalina |
| 3079|New|Min|2001-08-10|NullPointer exception in JakartaCommentGenerator.g|
| 3114|New|Min|2001-08-14|Spanish traslations of LocalStrings.properties|
| 3293|New|Min|2001-08-27|Please refer to Tomcat 3.x bug URL -- see if appli|
| 3340|New|Min|2001-08-29|sun.tools.javac.Main has been deprecated on JDK 1.|
| 3344|New|Min|2001-08-29|A typo in jakarta-servletapi-4/src/share/javax/ser|
| 1400|New|Enh|2001-04-19|SSLServerSocketFactory.java does not support the s|
| 1575|New|Enh|2001-04-29|Slow server start due to SAX Parsing  |
| 2500|New|Enh|2001-07-08|FileNotFoundException from service() unintentional|
| 2570|New|Enh|2001-07-11|Add the ability to configure a default error handl|
| 1788|Ass|Cri|2001-05-16|mod_webapp errors in Win2k|
| 2999|Ass|Maj|2001-08-06|Linking trouble : webapp connectors and apache1.3 |
| 2334|Ass|Nor|2001-06-26|Does tomcat 4.0 Beta 5 work with apache 1.3.12?   |
| 2883|Ass|Nor|2001-07-30|error page for 401 error code is not populated|
| 2622|Ass|Enh|2001-07-13|Jasper is not taking advantage of bodyContetn == e|
| 2823|Ass|Enh|2001-07-26|RFE: Allow a Manager inside DefaultContext|
| 2997|Ass|Enh|2001-08-05|webapp connector should recover when tomcat is res|
| 2693|Opn|Maj|2001-07-19|Syntax errors in JSP source generate NumberFormatE|
|  821|Ver|Maj|2001-03-02|JSPC doesn't like NT paths|
+-+---+---+--+--+
| Total   39 bugs   |
+---+



Re: Bug report for Tomcat 4 [2001/09/04]

2001-09-04 Thread Pier Fumagalli

Great... They get thru... :) (Sorry for the duplicate post on TC4, had to
try it somehow!)...

They're going to come every week...

Pier (as always!)


"[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:
> 
> +---+
> | Bugzilla Bug ID   |
> | +-+
> | | Status: UNC=Unconfirmed NEW=New ASS=Assigned|
> | | OPN=ReopenedVER=Verified(Skipped Closed/Resolved)   |
> | |   +-+
> | |   | Severity: BLK=Blocker CRI=CriticalMAJ=Major |
> | |   |   MIN=Minor   NOR=Normal  EHN=Ehnancement   |
> | |   |   +-+
> | |   |   | Date Posted |
> | |   |   |  +--+
> | |   |   |  | Description  |
> | |   |   |  |  |
> +-+---+---+--+--+
> | Total   40 bugs   |
> +---+




Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Remy Maucherat

> Well, it's just about that time ... the Servlet 2.3 and JSP 1.2
> specifications are going final soon (they are being voted on in the Java
> Community Process as we speak).  Therefore, I've just submitted an initial
> draft of a Release Plan document for final release of Tomcat 4.0, which
> can be viewed online via:
>
>
http://cvs.apache.org/viewcvs/~checkout~/jakarta-tomcat-4.0/RELEASE-PLAN-4.0
.txt
>
> Please review this proposal, and the associated Bugzilla bug reports, and
> cast your vote:
>
> -- Release Plan for Apache Tomcat 4.0 (final release) --
> [X] +1I am in favor of this plan, and will help
> [ ] +0I am in favor of this plan, but am unable to help
> [ ] -0I not in favor of this plan
> [ ] -1I am opposed to this plan, and my reason(s) are:

Remy




Re: cvs commit: jakarta-tomcat-connectors/webapp/apache-2.0Makefile.in

2001-09-04 Thread Pier Fumagalli

"[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:

> jfclere 01/08/31 03:26:24
> 
> Modified:webapp   Makefile.in configure.in
>  webapp/apache-1.3 Makefile.in
>  webapp/apache-2.0 Makefile.in
> Log:
> Merge Ryan's changes with mines.


JF, make install doesn¹t work :) Also, when modifying targets, please update
also the readme, as that's the only source of knowledge :)

Pier




cvs commit: jakarta-tomcat-4.0 RELEASE-PLAN-4.0.txt

2001-09-04 Thread craigmcc

craigmcc01/09/04 19:27:23

  Modified:.RELEASE-PLAN-4.0.txt
  Log:
  More bugs that have been dealt with (and a couple of status updates).
  
  Revision  ChangesPath
  1.3   +4 -10 jakarta-tomcat-4.0/RELEASE-PLAN-4.0.txt
  
  Index: RELEASE-PLAN-4.0.txt
  ===
  RCS file: /home/cvs/jakarta-tomcat-4.0/RELEASE-PLAN-4.0.txt,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- RELEASE-PLAN-4.0.txt  2001/09/04 22:59:28 1.2
  +++ RELEASE-PLAN-4.0.txt  2001/09/05 02:27:23 1.3
  @@ -1,4 +1,4 @@
  -$Id: RELEASE-PLAN-4.0.txt,v 1.2 2001/09/04 22:59:28 craigmcc Exp $
  +$Id: RELEASE-PLAN-4.0.txt,v 1.3 2001/09/05 02:27:23 craigmcc Exp $
   
 Release Plan for Apache Tomcat 4.0
 ==
  @@ -47,19 +47,15 @@
   
   
   Catalina2883Error page for 401 error code is not populated
  +(Not a spec issue, so likely to be downgraded to
  +"enhancement request")
   
  -Catalina3292Class reloading fails
  +Catalina3292Class reloading fails (awaiting test case)
   
   Connectors  1788mod_webapp errors on Win2k
   
  -Connectors  2334Tomcat 4.0-b5 + Apache 1.3.12?
  -
   Connectors  2997Webapp connector should recover when Tomcat is restarted
   
  -Connectors  2999Linking trouble: webapp connectors and Apache 1.3 apxs
  -
  -Connectors  3160mod_webapp performance issues
  -
   Jasper  2693Syntax errors in JSP source generate NumberFormatException
   
   Jasper  2917JSP compiled file name is not correct
  @@ -94,8 +90,6 @@
   
   Nice To Have Fixes Before Final Release:
   ---
  -
  -Catalina2949Tomcat 4.0/Solaris follow soft links for public_html
   
   Catalina3114Spanish translations of LocalString.properties files
   
  
  
  



cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util SessionIdGenerator.java

2001-09-04 Thread marcsaeg

marcsaeg01/09/04 19:42:14

  Modified:src/share/org/apache/tomcat/startup Tag: tomcat_32
Tomcat.java
   src/share/org/apache/tomcat/util Tag: tomcat_32
SessionIdGenerator.java
  Log:
  Switch back to the default PRNG seed generator to avoid security weakness
  in the manual seed generator.  The PRNG is now initialized when the container
  starts so that we don't take the hit on the first request.
  
  Submitted by: Kevin E. Fu ([EMAIL PROTECTED])
  
  Revision  ChangesPath
  No   revision
  
  
  No   revision
  
  
  1.31.2.2  +5 -0  jakarta-tomcat/src/share/org/apache/tomcat/startup/Tomcat.java
  
  Index: Tomcat.java
  ===
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/startup/Tomcat.java,v
  retrieving revision 1.31.2.1
  retrieving revision 1.31.2.2
  diff -u -r1.31.2.1 -r1.31.2.2
  --- Tomcat.java   2000/11/28 00:19:20 1.31.2.1
  +++ Tomcat.java   2001/09/05 02:42:13 1.31.2.2
  @@ -199,6 +199,11 @@
// auto-configured contexts are initialized.
generateServerConfig( cm );
   
  +// Initialize the Session ID Generator.  Generating the PRNG seed
  +// can be very time consuming so do we want to do this before 
  +// we start handling requests
  +SessionIdGenerator.initialize();
  +
cm.start(); // start serving
   }
   
  
  
  
  No   revision
  
  
  No   revision
  
  
  1.3.2.4   +41 -33
jakarta-tomcat/src/share/org/apache/tomcat/util/SessionIdGenerator.java
  
  Index: SessionIdGenerator.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/SessionIdGenerator.java,v
  retrieving revision 1.3.2.3
  retrieving revision 1.3.2.4
  diff -u -r1.3.2.3 -r1.3.2.4
  --- SessionIdGenerator.java   2000/12/22 17:35:05 1.3.2.3
  +++ SessionIdGenerator.java   2001/09/05 02:42:14 1.3.2.4
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/SessionIdGenerator.java,v 
1.3.2.3 2000/12/22 17:35:05 marcsaeg Exp $
  - * $Revision: 1.3.2.3 $
  - * $Date: 2000/12/22 17:35:05 $
  + * $Header: 
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/SessionIdGenerator.java,v 
1.3.2.4 2001/09/05 02:42:14 marcsaeg Exp $
  + * $Revision: 1.3.2.4 $
  + * $Date: 2001/09/05 02:42:14 $
*
* 
*
  @@ -125,35 +125,23 @@
* Return the entropy increaser value, or compute a semi-useful value
* if this String has not yet been set.
*/
  -public static String getEntropy() {
  -
  - // Calculate a semi-useful value if this has not been set
  - if (entropy == null)
  - setEntropy((new Object()).toString());
  -
  - return (entropy);
  -
  +public static String getEntropy()
  +{
  +return (entropy);
   }
   
  -
   /**
* Set the entropy increaser value.
*
* @param entropy The new entropy increaser value
*/
  -public static void setEntropy(String newEntropy) {
  -
  - entropy = newEntropy;
  -
  +public static void setEntropy(String newEntropy)
  +{
  +entropy = newEntropy;
   }
  -
   
  -  // ** NOTE that this must work together with get_jserv_session_balance()
  -// ** in jserv_balance.c
  -static synchronized public String getIdentifier (String jsIdent)
  +public static void initialize()
   {
  -StringBuffer sessionId = new StringBuffer();
  -
   if (randomSource == null) {
   String className = System.getProperty("tomcat.sessionid.randomclass");
   if (className != null) {
  @@ -168,19 +156,39 @@
   if (randomSource == null)
   randomSource = new java.security.SecureRandom();
   
  - // Set the seed PRNG's seed value
  - long seed = System.currentTimeMillis();
  - char entropy[] = getEntropy().toCharArray();
  - for (int i = 0; i < entropy.length; i++) {
  -  long update = ((byte) entropy[i]) << ((i % 8) 
* 8);
  -  seed ^= update;
  - }
  - randomSource.setSeed(seed);
  -   }
  +String entropyValue = getEntropy();
  +if(entropyValue != null){
  +/*
  + *  We only do the manual seed generation if there is a user
  + * supplied entropy value.  This is only for backwards 
  + * compatibility.  It is expected that very few people
  + * ever took adv

RE: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Marc Saegesser

-- Release Plan for Apache Tomcat 4.0 (final release) --
[ ] +1I am in favor of this plan, and will help
[X] +0I am in favor of this plan, but am unable to help
[ ] -0I not in favor of this plan
[ ] -1I am opposed to this plan, and my reason(s) are:


One of these days I'll put tomcat_32 behind me and move on to some of this
new stuff.

Congratulations to everyone who has worked on this.  You guys have done
really great job.

Marc Saegesser





Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Amy Roh

> -- Release Plan for Apache Tomcat 4.0 (final release) --
> [X] +1I am in favor of this plan, and will help
> [ ] +0I am in favor of this plan, but am unable to help
> [ ] -0I not in favor of this plan
> [ ] -1I am opposed to this plan, and my reason(s) are:

Amy




Another funny thought this time about PHP

2001-09-04 Thread Deacon Marcus

Hi,
Some of my co-workers are pushing for php support. While I'm strongly
opposing the idea (who needs php when jsp is available? imo that's plain
ridicilous), I thought, is it - theoretically - or would it be possible - to
set up Tomcat + Apache in a way where instead of standard model, all files
processed by Apache except those meant for Tomcat, reverse the roles - make
Apache "slave" of Tomcat, and use it only for, for example, php, while using
Tomcat for everything else including static content.

Greetings, deacon Marcus




cvs commit: jakarta-tomcat-4.0/webapps/examples/WEB-INF/validators - New directory

2001-09-04 Thread craigmcc

craigmcc01/09/04 20:40:18

  jakarta-tomcat-4.0/webapps/examples/WEB-INF/validators - New directory



cvs commit: jakarta-tomcat-4.0/webapps/examples/WEB-INF/classes/validators - New directory

2001-09-04 Thread craigmcc

craigmcc01/09/04 20:40:44

  jakarta-tomcat-4.0/webapps/examples/WEB-INF/classes/validators - New directory



Tomcat fan-sites, plushies, etc

2001-09-04 Thread Deacon Marcus

Hi,
Are there any Tomcat fan-sites? Not support, help, etc, but _fan_ sites?
Are there any Tomcat mugs, posters, plushies, etc? One of my co-workers
threatens me she'll hurt me if I won't get a Tomcat plushie for her... ;/

Greetings,
 deacon Marcus

p.s. Great work. Great-great-great work. I love you guys. Always remember I
have enough faith in your work to use your latest beta versions in
production environment :)




Re: Tomcat fan-sites, plushies, etc

2001-09-04 Thread Christopher Cain

Quoting Deacon Marcus <[EMAIL PROTECTED]>:

> p.s. Great work. Great-great-great work. I love you guys. Always
> remember I
> have enough faith in your work to use your latest beta versions in
> production environment :)

Ahhh ... is that all? If you _really_ had faith in us, you'd use the nightlies 
in production. And if you _really_, *really* had faith in us, you'd compile 
from cvs at random and use *that* in production =)

(Obligatory parental warning label: That was a joke. _Please_ don't use a 
nightly or cvs build in a serious production environment ... unless you like to 
kiss the razor's edge ;-)

- Christopher

/**
 * Pleurez, pleurez, mes yeux, et fondez vous en eau!
 * La moitié de ma vie a mis l'autre au tombeau.
 *---Cornelle
 */



Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Christopher Cain


> -- Release Plan for Apache Tomcat 4.0 (final release)
> --
> [X] +1I am in favor of this plan, and will help
> [ ] +0I am in favor of this plan, but am unable to help
> [ ] -0I not in favor of this plan
> [ ] -1I am opposed to this plan, and my reason(s) are:

- Christopher

/**
 * Pleurez, pleurez, mes yeux, et fondez vous en eau!
 * La moitié de ma vie a mis l'autre au tombeau.
 *---Cornelle
 */



RE: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Golash Rahul

[X] +1I am in favor of this plan, and will help

rahul

-Original Message-
From: Christopher Cain [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, September 05, 2001 9:48 AM
To: [EMAIL PROTECTED]
Subject: Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)



> -- Release Plan for Apache Tomcat 4.0 (final release)
> --
> [X] +1I am in favor of this plan, and will help
> [ ] +0I am in favor of this plan, but am unable to help
> [ ] -0I not in favor of this plan
> [ ] -1I am opposed to this plan, and my reason(s) are:

- Christopher

/**
 * Pleurez, pleurez, mes yeux, et fondez vous en eau!
 * La moitié de ma vie a mis l'autre au tombeau.
 *---Cornelle
 */



Re: Tomcat fan-sites, plushies, etc

2001-09-04 Thread Pier Fumagalli

"Deacon Marcus" <[EMAIL PROTECTED]> wrote:

> Hi,
> Are there any Tomcat fan-sites? Not support, help, etc, but _fan_ sites?
> Are there any Tomcat mugs, posters, plushies, etc? One of my co-workers
> threatens me she'll hurt me if I won't get a Tomcat plushie for her... ;/

I got several T-Shirts and mugs... :) But they ran out a long time ago
(and mine are not for sharing! g :)

Pier




Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Pier Fumagalli

"Golash Rahul" <[EMAIL PROTECTED]> wrote:

> [X] +1I am in favor of this plan, and will help

Errr... Ehemmm... Thanks for volunteering, but voting is for people with
commit privileges only :) You're more than welcome to send patches, though!

Pier




Re: Tomcat fan-sites, plushies, etc

2001-09-04 Thread Christopher Cain

Quoting Deacon Marcus <[EMAIL PROTECTED]>:

> Hi,
> Are there any Tomcat fan-sites? Not support, help, etc, but _fan_
> sites?
> Are there any Tomcat mugs, posters, plushies, etc?

Personally, I think we should lobby the appropriate electronics company for our 
very own "Special Edition Tomcat Furbee" doll. Instead of talking in normal 
babble:

   Mee ti-ti, doma dee ...

It could instead talk in Jakarta babble:

   JSP Mangler, valve realm context loader ...

Just think of it. Rather than spending hours trying to teach a fuzzy, inamimate 
object to speak English, you could instead spend hours having it teach you to 
speak Jakarta. =)

(Plus, the Tomcat guy isn't nearly creepy as that Duke thingy, so it wouldn't 
frighten the children.)

- Christopher

/**
 * Pleurez, pleurez, mes yeux, et fondez vous en eau!
 * La moitié de ma vie a mis l'autre au tombeau.
 *---Cornelle
 */



Re: cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util SessionIdGenerator.java

2001-09-04 Thread David Rees

On Wed, Sep 05, 2001 at 02:42:14AM -, [EMAIL PROTECTED] wrote:
> marcsaeg01/09/04 19:42:14
> 
>   Modified:src/share/org/apache/tomcat/startup Tag: tomcat_32
> Tomcat.java
>src/share/org/apache/tomcat/util Tag: tomcat_32
> SessionIdGenerator.java
>   Log:
>   Switch back to the default PRNG seed generator to avoid security weakness
>   in the manual seed generator.  The PRNG is now initialized when the container
>   starts so that we don't take the hit on the first request.
>   
>   Submitted by:   Kevin E. Fu ([EMAIL PROTECTED])

Does this prevent Tomcat from accepting requests until after the PRNG is
initialized?  If so, IMHO Tomcat should accept requests ASAP, even if it can't
completely serve them until the PRNG is accepted.  Isn't that better than
rejecting requests?

-Dave



Re: Another funny thought this time about PHP

2001-09-04 Thread David Rees

On Wed, Sep 05, 2001 at 05:38:56AM +0200, Deacon Marcus wrote:
> Hi,
> Some of my co-workers are pushing for php support. While I'm strongly
> opposing the idea (who needs php when jsp is available? imo that's plain
> ridicilous), I thought, is it - theoretically - or would it be possible - to
> set up Tomcat + Apache in a way where instead of standard model, all files
> processed by Apache except those meant for Tomcat, reverse the roles - make
> Apache "slave" of Tomcat, and use it only for, for example, php, while using
> Tomcat for everything else including static content.

You could easily do this by mapping *.php to a servlet, and have the
servlet translate the requests to Apache.

Not sure why you'd want to do this, isn't the performance hit with Apache in
front of Tomcat negligible?

-Dave





Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)

2001-09-04 Thread Craig R. McClanahan



On Wed, 5 Sep 2001, Pier Fumagalli wrote:

> Date: Wed, 05 Sep 2001 05:23:03 +0100
> From: Pier Fumagalli <[EMAIL PROTECTED]>
> Reply-To: [EMAIL PROTECTED]
> To: [EMAIL PROTECTED]
> Subject: Re: [VOTE] Release Plan for Apache Tomcat 4.0 (final release)
>
> "Golash Rahul" <[EMAIL PROTECTED]> wrote:
>
> > [X] +1I am in favor of this plan, and will help
>
> Errr... Ehemmm... Thanks for volunteering, but voting is for people with
> commit privileges only :) You're more than welcome to send patches, though!
>

Doing testing and submitting bug reports (as well as patches) counts as
helping in my book :-).

> Pier
>
>

Craig





cvs commit: jakarta-tomcat-4.0/webapps/examples/jsp/simpletag foo.jsp

2001-09-04 Thread craigmcc

craigmcc01/09/04 22:14:01

  Modified:webapps/examples/WEB-INF web.xml
   webapps/examples/WEB-INF/jsp example-taglib.tld
   webapps/examples/jsp/simpletag foo.jsp
  Added:   webapps/examples/WEB-INF/classes/validators
DebugValidator.java
  Log:
  Update the example tag library descriptor to JSP 1.2 syntax.
  
  Add a debug tag library whose sole purpose is to dump the XML view of the
  JSP page to standard output (normally $CATALINA_HOME/logs/catalina.out on
  a Unix-ish system) when the corresponding taglib directive is included.
  
  Revision  ChangesPath
  1.19  +10 -1 jakarta-tomcat-4.0/webapps/examples/WEB-INF/web.xml
  
  Index: web.xml
  ===
  RCS file: /home/cvs/jakarta-tomcat-4.0/webapps/examples/WEB-INF/web.xml,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- web.xml   2001/08/27 20:57:21 1.18
  +++ web.xml   2001/09/05 05:14:00 1.19
  @@ -159,7 +159,16 @@
   
   
   
  -http://java.apache.org/tomcat/examples-taglib
  +http://jakarta.apache.org/tomcat/debug-taglib
  +
  +
  +   /WEB-INF/jsp/debug-taglib.tld
  +
  +
  +
  +
  +
  +http://jakarta.apache.org/tomcat/examples-taglib
   
   
  /WEB-INF/jsp/example-taglib.tld
  
  
  
  1.1  
jakarta-tomcat-4.0/webapps/examples/WEB-INF/classes/validators/DebugValidator.java
  
  Index: DebugValidator.java
  ===
  /*
   * $Header: 
/home/cvs/jakarta-tomcat-4.0/webapps/examples/WEB-INF/classes/validators/DebugValidator.java,v
 1.1 2001/09/05 05:14:01 craigmcc Exp $
   * $Revision: 1.1 $
   * $Date: 2001/09/05 05:14:01 $
   *
   * 
   *
   * The Apache Software License, Version 1.1
   *
   * Copyright (c) 1999-2001 The Apache Software Foundation.  All rights
   * reserved.
   *
   * Redistribution and use in source and binary forms, with or without
   * modification, are permitted provided that the following conditions
   * are met:
   *
   * 1. Redistributions of source code must retain the above copyright
   *notice, this list of conditions and the following disclaimer.
   *
   * 2. Redistributions in binary form must reproduce the above copyright
   *notice, this list of conditions and the following disclaimer in
   *the documentation and/or other materials provided with the
   *distribution.
   *
   * 3. The end-user documentation included with the redistribution, if
   *any, must include the following acknowlegement:
   *   "This product includes software developed by the
   *Apache Software Foundation (http://www.apache.org/)."
   *Alternately, this acknowlegement may appear in the software itself,
   *if and wherever such third-party acknowlegements normally appear.
   *
   * 4. The names "The Jakarta Project", "Tomcat", and "Apache Software
   *Foundation" must not be used to endorse or promote products derived
   *from this software without prior written permission. For written
   *permission, please contact [EMAIL PROTECTED]
   *
   * 5. Products derived from this software may not be called "Apache"
   *nor may "Apache" appear in their names without prior written
   *permission of the Apache Group.
   *
   * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
   * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
   * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
   * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
   * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
   * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
   * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
   * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
   * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
   * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
   * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   * SUCH DAMAGE.
   * 
   *
   * This software consists of voluntary contributions made by many
   * individuals on behalf of the Apache Software Foundation.  For more
   * information on the Apache Software Foundation, please see
   * .
   *
   * [Additional notices, if required by prior licensing conditions]
   *
   */
  
  
  package validators;
  
  
  import java.io.InputStream;
  import java.io.IOException;
  import javax.servlet.jsp.tagext.PageData;
  import javax.servlet.jsp.tagext.TagLibraryValidator;
  import javax.servlet.jsp.tagext.ValidationMessage;
  
  
  /**
   * Example tag library vali

Re: cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util SessionIdGenerator.java

2001-09-04 Thread Christopher Cain

Quoting [EMAIL PROTECTED]:

> marcsaeg01/09/04 19:42:14
> 
>   Modified:src/share/org/apache/tomcat/startup Tag: tomcat_32
> Tomcat.java
>src/share/org/apache/tomcat/util Tag: tomcat_32
> SessionIdGenerator.java

[snip]

>   -   // Set the seed PRNG's seed value
>   -   long seed = System.currentTimeMillis();
>   -   char entropy[] = getEntropy().toCharArray();
>   -   for (int i = 0; i < entropy.length; i++) {
>   -long update = ((byte) entropy[i]) << 
((i % 8) * 8);
>   -seed ^= update;
>   -   }
>   -   randomSource.setSeed(seed);
>   - }
>   +String entropyValue = getEntropy();
>   +if(entropyValue != null){
>   +/*
>   + *  We only do the manual seed generation if there is
> a user
>   + * supplied entropy value.  This is only for
> backwards 
>   + * compatibility.  It is expected that very few
> people
>   + * ever took advantage of this feature and
> defaulting
>   + * to the normal PRNG seed generator is more secure
> than this 
>   + * calculation.
>   + */
>   +long seed = System.currentTimeMillis();
>   +char entropy[] = entropyValue.toCharArray();
>   +for (int i = 0; i < entropy.length; i++) {
>   +long update = ((byte) entropy[i]) << ((i % 8) *
> 8);
>   +seed ^= update;
>   +}
>   +randomSource.setSeed(seed);
>   +}else{
>   +randomSource.nextInt();
>   +}
>   +}
>   +}

First off, let me say that the above patch is a _really_ good idea, as far as 
letting the PRNG default to its own entropy-collection routine, so that 
definitely need to be done IMO.

Now I know that what I am about to suggest falls under the category of a trying-
to-save-users-from-themselves enhancement, and not an actual bug fix as would 
be appropriate for the 3.2 branch, but it never hurts to offer, right? =)

The problem (which has nothing to do with the above patch other than having 
brought the existing algorithm to my attention :-) is that the for{} loop here 
serves no real purpose. If the user passes an insecure seed value, this for{} 
loop provides absolutely no additional security value. Now it doesn't really 
degrade security either, which is why it's not really a "bug" per se. My only 
concern is this: It's probably not patently obvious to someone without prior 
cryptography experience that this additional pass is merely smoke-and-mirrors 
with no practical benefit. I also know that users are _always_ trying to find 
shortcuts around the delay in Java's PRNG initalization (in fact, that alone 
accounts for at least 50% of the security flaws in Java crypto based on my 
experience). My concern is that people will start investigating startup delays, 
track it down to this, see that the internal Tomcat code is doing some kind of 
mumbo-jumbo with a user-provided seed value, try it (to find that they shaved 
~10 seconds off their startup), and assume that whatever Tocmat is doing is 
probably "sufficient for my application". IMHO, it's much safer to just remove 
this for{} loop voodoo in order to avoid the implication that it does anything 
meaningful.

Anyway, that's my take. Usually, bad crypto is worse than no crypto at all. In 
this case, it will probably result in a few less people trying to outsmart the 
PRNG.

- Christopher

/**
 * Pleurez, pleurez, mes yeux, et fondez vous en eau!
 * La moitié de ma vie a mis l'autre au tombeau.
 *---Cornelle
 */