jspc
Hello, I wish compile ahead automatically the files java starting from the files jsp, using the command jspc.bat. But I muddle myself with the syntax of the command. My directories are organized in the following way: " D:\folders\projets\calc\web ": sources jsp. Example of file name: marcsslst.jsp " C:\jakarta-tomcat\webapps\calc ": pages jsp (result of the build all) " C:\jakarta-tomcat\work\localhost_8080%2Fcalc ": work of tomcat. Examples of file name: _ 0002fmarcsslst_000ejspmarcsslst_jsp_0.java and _ 0002fmarcsslst_000ejspmarcsslst.class software used: Tomcat Web server v3.2.1 / NT 4 Server How do I have to write my command jspc.bat to obtain same the result? Good reception, Claude Couderc Technical director CORIOLYS Park Activity Mill Last nines 1 avenue Michael Faraday 44812 SAINT-herblain Cedex Tel.. 02 40 92 24 95 (direct) Tel.. 02 40 92 25 00 (standard) Faxes 02 40 92 24 94 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
RE: [PATCH] JDBCRealm on Tomcat 3.2.1 does not work with MS SQL Server
That problem should only happen with the CHAR type, but with the CHAR type it can happen in other databases too. AFAIK, the use of VARCHAR doesn't cause trailing spaces to be added in MS SQL Server. Although I only used SQL Server trough BDE, ODBC and ADO, it is hard to imagine that a JDBC driver would cause such thing. (Anyway, I think it is a good fix.) Have fun, Paulo -Original Message- From: Larry Rogers [mailto:[EMAIL PROTECTED]] Sent: Monday, February 19, 2001 06:39 This is my first patch to submit. I'm sorry I don't have a diff file to go with it. Anyway, when using Tomcat 3.2.1 JDBCRealm with Microsoft SQL Server, the credential check fails when the correct username and password are submitted by the user. After Tomcat receives the credentials from the user, it queries the user table in the database for what the password should be for the username received from the browser. When it compares the password from the browser to the one from the database, the comparison does not pass, even though the password is correct. This is caused by the way SQL Server returns a string with trailing spaces for the password query. The problem occurs for column type of char or varchar as well. The patch involves changing the following line from JDBCRealm.java if (credentials.equals(rs1.getString(1))) { to read as follows if (credentials.equals(rs1.getString(1).trim())) { This will trim the padded spaces from the password received from SQL Server before comparing it to the password submitted by the user, and the comparison will pass. Thanks, Larry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
RE: [PATCH] JDBCRealm on Tomcat 3.2.1 does not work with MS SQL Server
It's done on CVS, about 2 weeks ago.. It's solved for 3.2.2 and up, and in 4.0 and up... Saludos , Ignacio J. Ortega -Mensaje original- De: Larry Rogers [mailto:[EMAIL PROTECTED]] Enviado el: lunes 19 de febrero de 2001 6:39 Para: [EMAIL PROTECTED] Asunto: [PATCH] JDBCRealm on Tomcat 3.2.1 does not work with MS SQL Server This is my first patch to submit. I'm sorry I don't have a diff file to go with it. Anyway, when using Tomcat 3.2.1 JDBCRealm with Microsoft SQL Server, the credential check fails when the correct username and password are submitted by the user. After Tomcat receives the credentials from the user, it queries the user table in the database for what the password should be for the username received from the browser. When it compares the password from the browser to the one from the database, the comparison does not pass, even though the password is correct. This is caused by the way SQL Server returns a string with trailing spaces for the password query. The problem occurs for column type of char or varchar as well. The patch involves changing the following line from JDBCRealm.java if (credentials.equals(rs1.getString(1))) { to read as follows if (credentials.equals(rs1.getString(1).trim())) { This will trim the padded spaces from the password received from SQL Server before comparing it to the password submitted by the user, and the comparison will pass. Thanks, Larry - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
BugRat Report #3 - doPost results in jasper.runtime.PageContextImp.handlePageException 7/27 nightly build
Report #3 Details Project: Tomcat Category: Bug Report SubCategory: New Bug Report Class: swbug State: closed Priority: high Severity: critical Confidence: public Environment: Release: Tomcat 7/27 build JVM Release: 1.2.2 Operating System: AIX OS Release: 4.3 Platform: Risc6000 Synopsis: doPost results in jasper.runtime.PageContextImp.handlePageException 7/27 nightly build Description: 2000-07-31 03:03:04 - Context: Exception in R( + /enroll/enroll.jsp + null) - javax.servlet.ServletException at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:450) at enroll._0002fenroll_0002fenroll_0002ejspenroll_jsp_0._jspService(_0002fenroll_0002fenroll_0002ejspenroll_jsp_0.java:526) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:179) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:298) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:371) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:372) at org.apache.tomcat.core.Handler.service(Handler.java:262) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:360) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:191) at com.tivoli.tsm.enroll.EnrollServlet.doPost(EnrollServlet.java:110) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:372) at org.apache.tomcat.core.Handler.service(Handler.java:262) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:360) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:719) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:665) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:195) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:369) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498) at java.lang.Thread.run(Thread.java:481) Root cause: java.lang.NullPointerException at enroll._0002fenroll_0002fenroll_0002ejspenroll_jsp_0.getLogo(_0002fenroll_0002fenroll_0002ejspenroll_jsp_0.java:65) at enroll._0002fenroll_0002fenroll_0002ejspenroll_jsp_0._jspService(_0002fenroll_0002fenroll_0002ejspenroll_jsp_0.java:150) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:179) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:298) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:371) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:372) at org.apache.tomcat.core.Handler.service(Handler.java:262) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:360) at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:191) at com.tivoli.tsm.enroll.EnrollServlet.doPost(EnrollServlet.java:110) at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:372) at org.apache.tomcat.core.Handler.service(Handler.java:262) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:360) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:719) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:665) at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:195) at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:369) at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498) at java.lang.Thread.run(Thread.java:481) Title: BugRat Report # 3 BugRat Report # 3 Project: Tomcat Release: Tomcat 7/27 build Category: Bug Report SubCategory: New Bug Report Class: swbug State: closed Priority: high Severity: critical Confidence: public Submitter: _Anonymous ([EMAIL PROTECTED]) Date Submitted: Aug 1 2000, 06:03:32 CDT Responsible: Z_Tomcat Alias ([EMAIL
TC3.3: Testing
As you may noticed, we had few changes in the testing area: - you can run the test from the web interface - no special configuration - you just install the test.war and admin.war, no more command line tweeking. - the test .wars are built independently - we can add more tests for the current milestone/release We also did some tests with existing webapps ( I tested jetspeed, slide, I know other had run other apps ). But - we want to make sure those tests are run on multiple platforms/configurations, and we can easily test for regressions. I'm proposing that for M2 we start including the .war for the apps we test, and add some "black-box" test cases. ( i.e. in test-tomcat.xml we add test cases for the existing applications - making sure they work fine under tomcat ) We should also encourage people reporting bugs to contribute small .war files that can reproduce the bug ( or additions to /test ). More applications we test, more confidence we can have in the product. Even if automating some tests is difficult, at least having a small "manual test scenario" and making easy to run it ( by providing a common place for all tested applications that people just have to deploy ) will greatly enhance tc3.3 testing. -- Costin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
RE: TC3.3: Profiles
Hi Costin, I'm in favor of this, though I would like to add one more issue to deal with. I have a need to have the Tomcat "home" (i.e. the directory where "conf", "webapps", and "work" are found by default) be different from Tomcat "install" (i.e. where the "lib" directory and the jars are found). The new class loader scheme is finding jars using "tomcat.home" so Tomcat "home" and "install" have to be the same. If this is something you can easily include in the changes, please do so. If not, I can take a look after your changes. Larry -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Monday, February 19, 2001 12:59 PM To: [EMAIL PROTECTED] Subject: TC3.3: Profiles Hi, As I mentioned some time ago, there is one configuration change I would like to get in before any code freeze. The idea is to define a "context profile" - containing common settings for a group of contexts. In order to implement this, there are few minimal changes in the code ( use new paths ) and the packaging ( different way to package the jars ). The change will be in the lib/ layout, and few additions to the server.xml file. Benefits: 1. Simpler configuration: you don't have to manually configure each individual context ( or force the same config for all applications ). It is already common to define different log files and authentication for different contexts, etc. Instead, you can define properties (i.e. modules and module configurations ) for groups of applications. 2. Fix few issues with the new class loader ( confusion between common/shared, classes duplicated in diferent directories, etc ) 3. Inter-context calls. You can call getContext() and invoke requests in different contexts - but that will fail if you use any atribute that belongs to the context class loader. A solution is to have the jars in the common CLASSPATH - but that's very bad because it'll force all applications to see that jar. With profiles, you can define what jars a group of contexts will share. 4. Jars provided to applications. A number of webapps expect jaxp, other don't - you'll be able to define what libs are available to a group of servlets ( the default will probably remain "nothing" ). I am proposing the following layout for lib/: lib/ - executable jars used to start tomcat ( start-tomcat.jar, stop-tomcat.jar, etc) lib/common - jars shared by container and all webapplications ( similar with the global CLASSPATH ). ( tomcat-core.jar ) lib/container - modules and jars used by modules ( including jaxp.jar, etc) lib/webapps - jars shared by all web apps ( minimal set ) lib/webapps/foo - jars specific to each group of web applications lib/container/foo - modules specific to a group of web applications I am also proposing few changes in the jar structure: - tomcat.utils: move all the top level "org.apache.tomcat.utils" in specific packages ( require changes in import lines ). - Split tomcat-utils in few components. - jasper.jar will be separated in jasper-runtime.jar and jasper.jar ( to follow the general structure of tomcat, jasper.jar will contain the translator, jasper-runtime will be similar with facade.jar ) Overall, I expect the impact on the current code to be minimal ( i.e. cosmetic changes - different package names, diferent layoyt ), with no major code change. The change will also address few security issues ( in sandboxed environment, fewer permissions to classes visible in the web application). This is probably the most significant change in the "usablity enhancement" category. All changes will be completed in about a week. Costin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
Re: Clarification on Catalina TODO item: CGI emulation servlet
Martin T Dengler wrote: Craig R. McClanahan wrote: That was exactly the original thinking -- create a servlet that would be able to execute external applications in conformance with the CGI spec requirements (principally related to environment variables, and connecting standard input and output of the application program to the request and response streams appropriately. Excellent. I suppose the right thing to do now is propose a design to this list with specification references for review. If that is too heavyweight I can just run the code by somebody (you, Craig?) after testing on my own Catalina build. The details of offering code to be included are covered on the Jakarta web site http://jakarta.apache.org/site/getinvolved.html but basically, you'll post the code itself (in a zip file or something) to the TOMCAT-DEV list so that we can all look at it and comment. Once the committers are OK with it, one of us will check it in. Having this functionality implemented as a servlet means that you can map it to a directory path ("/cgi-bin/*") and/or a filename extension ("*.cgi"), in the same way that you would do so in a web server. Or, in a security conscious environment, you could just remove the mappings to make CGI service unavailable. Exactly, and I suppose the directory path w/could obviously be web app-specific, giving the normal encapsulation benefits. It would pretty much have to be, because that's the only way your servlet would ever get invoked. Would there be any scope for extra web-app-related information being available in the spawned-process' environment, so it (the CGI) could figure out the context path, etc.? I would tend to start with all the standard CGI spec environment variables, so that the CGI scripts you invoke can remain portable. CGI doesn't really have the concept of a "context path", but there are probably sufficient variables (like DOCUMENT_ROOT) to accomplish what you would be after. That would be great! I will sign you up for that item. Thanks, I look forward to helping out; if I do something wrong please let me know. Craig McClanahan Chrs, Martin Craig - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
cvs commit: jakarta-tomcat build.xml
costin 01/02/19 11:45:14 Modified:.build.xml Log: - removed unused target ( modules.xml auto-generation experiment, too much work for this release ) - stop-tomcat.jar includes IntrospectionUtils, guess TOMCAT_HOME ( no need to set it in the command line, can start from any dir ) Revision ChangesPath 1.118 +4 -25 jakarta-tomcat/build.xml Index: build.xml === RCS file: /home/cvs/jakarta-tomcat/build.xml,v retrieving revision 1.117 retrieving revision 1.118 diff -u -r1.117 -r1.118 --- build.xml 2001/02/16 05:37:50 1.117 +++ build.xml 2001/02/19 19:45:11 1.118 @@ -129,7 +129,8 @@ !-- no dependencies -- include name="org/apache/tomcat/startup/Main.java"/ include name="org/apache/tomcat/util/compat/**"/ - exclude name="**/util/compat/Jdk12Support.java" unless="jdk12.present"/ include name="org/apache/tomcat/util/IntrospectionUtils.java"/ + exclude name="**/util/compat/Jdk12Support.java" unless="jdk12.present"/ + include name="org/apache/tomcat/util/IntrospectionUtils.java"/ /javac jar jarfile="${tomcat.build}/lib/tomcat.jar" basedir="${tomcat.build}/classes" @@ -149,6 +150,7 @@ srcdir="src/share" !-- no dependencies -- include name="org/apache/tomcat/startup/StopTomcat.java"/ + include name="org/apache/tomcat/util/IntrospectionUtils.java"/ /javac copy todir="${tomcat.build}/classes/org/apache/tomcat/resources" fileset dir="src/share/org/apache/tomcat/resources" @@ -162,6 +164,7 @@ include name="org/apache/tomcat/startup/StopTomcat.class"/ include name="org/apache/tomcat/util/StringManager.class"/ include name="org/apache/tomcat/resources/LocalStrings*"/ + include name="org/apache/tomcat/util/IntrospectionUtils**"/ /jar /target @@ -431,30 +434,6 @@ chmod perm="+x" file="${tomcat.dist}/bin/startup.sh"/ chmod perm="+x" file="${tomcat.dist}/bin/shutdown.sh"/ /target - - target name="modulesDoc.xml" -!-- using alexandria'x XMLDoclet -- -javac srcdir="src/build" -destdir="${tomcat.build}/classes" -debug="${debug}" -optimize="${optimize}" -deprecation="off" - classpath - pathelement location="${java.home}/../lib/tools.jar"/ - /classpath -/javac -javadoc packagenames="org.apache.tomcat.modules.*,org.apache.tomcat.facade.*" - sourcepath="src/share;src/facade22" - destdir="${tomcat.dist}/webapps/ROOT/javadoc" - author="true" - version="true" -doclet name="XMLDoclet" path="${tomcat.build}/classes" - param name="-file" value="${tomcat.build}/conf/modulesDoc.xml" / -/doclet -/javadoc - /target - - !-- === -- !-- Packages the distribution with ZIP -- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/log Log.java
costin 01/02/19 11:49:48 Modified:src/share/org/apache/tomcat/util/log Log.java Log: Missed this one - flush() must be defined in Log. Revision ChangesPath 1.3 +5 -1 jakarta-tomcat/src/share/org/apache/tomcat/util/log/Log.java Index: Log.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/log/Log.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- Log.java 2001/02/03 05:29:50 1.2 +++ Log.java 2001/02/19 19:49:47 1.3 @@ -218,7 +218,11 @@ loggerTemp.log(msg, t, level); } - +public void flush() { + if( logger!=null ) + logger.flush(); +} + // Extra configuration stuff // The real logger object ( that knows to write to // files, optimizations, etc) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
TC3.3: modules
I was reviewing the "crypted password" auth module ( ok, digested, not crypted ) and few other modules, and I think it would be a bad idea to commit it as part of the current tomcat. The module is in an early stage of development ( it provide a very usefull thing ), and is not required for normal functionality. I would like to propose puting them in a new directory ( /modules ) and building sepparate jar(s) for them. The modules will depend on the 3.3 internal APIs, but will not be part of the 3.3 release - but distributed as a separate add-on jar. Again, this will reduce the need for a 3.3.1 release ( every major release requires a lot of work, while a module release is much simpler ), will reduce the ammount of code that is part of the tomcat release to what is functionally needed to implement a servlet container, and reduce the "featurism" syndrome ( keep the product small and focused ). ( you can think of those modules as mini-"revolutions" - when the code is stable we can discuss including them in the standard distribution. ) We could place them under /proposals, but I feel it's better to just use a /modules directory. -- Costin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/core Handler.java ServerSession.java package.html
costin 01/02/19 12:22:42 Modified:src/share/org/apache/tomcat/core Handler.java ServerSession.java package.html Log: Update core documentation ( package.html ) Added a section with core dependencies, removed unused imports. This prepares for more core review. Revision ChangesPath 1.37 +0 -1 jakarta-tomcat/src/share/org/apache/tomcat/core/Handler.java Index: Handler.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/Handler.java,v retrieving revision 1.36 retrieving revision 1.37 diff -u -r1.36 -r1.37 --- Handler.java 2001/02/06 06:37:37 1.36 +++ Handler.java 2001/02/19 20:22:36 1.37 @@ -60,7 +60,6 @@ import org.apache.tomcat.util.Counters; import org.apache.tomcat.util.log.*; -import org.apache.tomcat.util.collections.EmptyEnumeration; /** * The class that will generate the actual response or response fragment. 1.4 +3 -2 jakarta-tomcat/src/share/org/apache/tomcat/core/ServerSession.java Index: ServerSession.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/ServerSession.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- ServerSession.java2001/01/01 00:17:23 1.3 +++ ServerSession.java2001/02/19 20:22:38 1.4 @@ -65,8 +65,9 @@ import java.util.Enumeration; import java.util.Hashtable; import java.util.Vector; -import org.apache.tomcat.util.*; -import org.apache.tomcat.util.threads.*; +import org.apache.tomcat.util.MessageBytes; +import org.apache.tomcat.util.Counters; +import org.apache.tomcat.util.threads.TimeStamp; /** * Server representation of a Session. 1.5 +76 -81jakarta-tomcat/src/share/org/apache/tomcat/core/package.html Index: package.html === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/package.html,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- package.html 2000/05/09 17:56:19 1.4 +++ package.html 2001/02/19 20:22:38 1.5 @@ -5,6 +5,23 @@ /head body bgcolor="#FF" +h2Architecture/h2 + +pTomcat core defines a number of base abstractions ( Request, Response, +Context, etc ) and a simple interface for modules./p + +pAll server functionality is implemented in modules, using callbacks in + a model similar with Apache and other servers. /p + +pThe ServletAPI and all specific contracts are implemented in + special module(s) - that allows to keep the core simple and + permits more flexibility. /p + +pThe callbacks are defined in BaseInterceptor. A module will + extend that class and possibly Handler if it wants to generate + content. The module will use the information and API provided in Request, + Response, Context, Container. + h2Components/h2 dl @@ -12,104 +29,82 @@ dtContextManager/dt dd ul - limaintains a list of adapters/li - liis the entry point for adapters and any component that can generate - a Request/Response and wants to use servlets./li - liis the control point that handles callback calls and notifications./li - limaintains a list of webapps that are configured in the system./li + licontrol point for callback calls and notifications./li + limanages server startup/shudown/li + limanages request execution (entry point,coordinates modules)/li + limaintains a list of global modules/li + limaintains a list of webapps/li /ul /dd dtRequest,Response/dt - ddInternal representations, containing various attributes associated with - the request during processing. + ddInternal representations for HTTP request/response, including + common attributes. Tuned for memory use ( recycling ) and performance, + with minimal contracts. /dd - dtInterceptors/dt + dtModule base ( BaseInterceptor )/dt dd - Request processing involves several stages - parsing, matching using url - patterns, authentication and authorization, calling the handler and various - callbacks before, after and during the handler. - An interceptor defines callbacks ( or hooks ) for one or several actions - and is able to alter that function. - In fact, most of the processing logic is implemented as interceptor - callbacks, in an event-based system. + An interceptor defines
Problem executing external programs
I'm having a problem using the keytool distributed with the JDK from a servlet running on Tomcat. Using the keytool from the command line requires a command like the following: /usr/local/jdk1.2.2/bin/keytool -genkey -dname "cn=eForms Demo " -alias demoAlias -keypass demoPassword -keystore /us/local/tomcat/webapps/eform/WEB-INF/keystore/file.keystore -storepass irgkeystore -validity 365". When I enter the command at the comman line, it works perfectly. When I try to run it from the Servlet, it doesn't work. To run it from the servlet, I used the Runtime.exec(String [] cmd) wherecmd is a array holding each of the commands. It lookslike the following: cmd[0] = KEY_TOOL_PATH;cmd[1] = COMMAND_GENERATE_KEY;cmd[2] = COMMAND_DISTINGUISHED_NAME + "\"cn=" + userName + "\"";cmd[3] = COMMAND_ALIAS + keyAlias;cmd[4] = COMMAND_KEY_PASSWORD + keyPassword;cmd[5] = COMMAND_KEY_STORE_PATH + keyStorePath;cmd[6] = COMMAND_KEY_STORE_PASSWORD + keyStorePassword;cmd[7] = COMMAND_DAYS_VALID + numberOfDaysKeyIsValid; I even tried sending the command as one String using the Runtime.exec(command.toString()) method where command is a StringBufger like th following: StringBuffer command = new StringBuffer();command.append(KEY_TOOL_PATH);command.append(COMMAND_GENERATE_KEY);command.append(COMMAND_DISTINGUISHED_NAME);command.append("\"cn=");command.append(userName);command.append("\"");command.append(COMMAND_ALIAS);command.append(keyAlias);command.append(COMMAND_KEY_PASSWORD);command.append(keyPassword);command.append(COMMAND_KEY_STORE_PATH);command.append(keyStorePath);command.append(COMMAND_KEY_STORE_PASSWORD);command.append(keyStorePassword);command.append(COMMAND_DAYS_VALID);command.append(numberOfDaysKeyIsValid); I even tried using the examplefrom Jason Hunter's Servlet book that says use a shell and that didn't work either. The array is constructed like the following where command is the StringBuffer above: String [] cmd = new String[3];cmd[0] = "/bin/csh";cmd[1] = "-c";cmd[2] = command.toString(); In all my attemps, an exception is not thrown,the keystore is not created, and the exit value of the process is not 0.An exit value of 0would indicate that the command was executed properly. Is this a tomcat bug?
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/io - New directory
costin 01/02/19 16:07:56 jakarta-tomcat/src/share/org/apache/tomcat/util/io - New directory - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/buf - New directory
costin 01/02/19 16:07:41 jakarta-tomcat/src/share/org/apache/tomcat/util/buf - New directory - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/res - New directory
costin 01/02/19 16:07:48 jakarta-tomcat/src/share/org/apache/tomcat/util/res - New directory - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/res StringManager.java
costin 01/02/19 19:12:46 Added: src/share/org/apache/tomcat/util/res StringManager.java Log: Package move Revision ChangesPath 1.1 jakarta-tomcat/src/share/org/apache/tomcat/util/res/StringManager.java Index: StringManager.java === /* * * * The Apache Software License, Version 1.1 * * Copyright (c) 1999 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 * http://www.apache.org/. * * [Additional notices, if required by prior licensing conditions] * */ package org.apache.tomcat.util.res; import java.text.MessageFormat; import java.util.*; /** * An internationalization / localization helper class which reduces * the bother of handling ResourceBundles and takes care of the * common cases of message formating which otherwise require the * creation of Object arrays and such. * * pThe StringManager operates on a package basis. One StringManager * per package can be created and accessed via the getManager method * call. * * pThe StringManager will look for a ResourceBundle named by * the package name given plus the suffix of "LocalStrings". In * practice, this means that the localized information will be contained * in a LocalStrings.properties file located in the package * directory of the classpath. * * pPlease see the documentation for java.util.ResourceBundle for * more information. * * @author James Duncan Davidson [[EMAIL PROTECTED]] * @author James Todd [[EMAIL PROTECTED]] */ public class StringManager { /** * The ResourceBundle for this StringManager. */ private ResourceBundle bundle; /** * Creates a new StringManager for a given package. This is a * private method and all access to it is arbitrated by the * static getManager method call so that only one StringManager * per package will be created. * * @param packageName Name of package to create StringManager for. */ private StringManager(String packageName) { String bundleName = packageName + ".LocalStrings"; try { bundle = ResourceBundle.getBundle(bundleName); } catch( MissingResourceException ex ) { bundle= ResourceBundle.getBundle(
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/io FileUtil.java RecycleBufferedInputStream.java
costin 01/02/19 19:12:59 Added: src/share/org/apache/tomcat/util/io FileUtil.java RecycleBufferedInputStream.java Log: Package move Revision ChangesPath 1.1 jakarta-tomcat/src/share/org/apache/tomcat/util/io/FileUtil.java Index: FileUtil.java === /* * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/io/FileUtil.java,v 1.1 2001/02/20 03:12:59 costin Exp $ * $Revision: 1.1 $ * $Date: 2001/02/20 03:12:59 $ * * * * The Apache Software License, Version 1.1 * * Copyright (c) 1999 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 * http://www.apache.org/. * * [Additional notices, if required by prior licensing conditions] * */ package org.apache.tomcat.util.io; import java.io.*; import java.util.zip.*; import org.apache.tomcat.util.log.*; /* * FileUtil contains utils for dealing with Files. Some of these are * already present in JDK 1.2 but since we can rely on that and need * to run on both JDK 1.1.x and JDK 1.2, we are replicating some of * that code here. * * FileUtil also takes care of File.getAbsolutePath() and * File.getNamePath() troubles when running on JDK 1.1.x/Windows * * @author James Todd [[EMAIL PROTECTED]] * @author Anil K. Vijendran [[EMAIL PROTECTED]] */ public class FileUtil { public static File[] listFiles(File dir) { String[] ss = dir.list(); if (ss == null) return null; int n = ss.length; File[] fs = new File[n]; for(int i = 0; i n; i++) { fs[i] = new File(dir.getPath(), ss[i]); } return fs; } /** Will concatenate 2 paths, dealing with .. * ( /a/b/c + d = /a/b/d, /a/b/c + ../d = /a/d ) * Used in Request.getRD * @return null if error occurs */ public static String catPath(String lookupPath, String path) { // Cut off the last slash and everything beyond int index = lookupPath.lastIndexOf("/"); lookupPath = lookupPath.substring(0, index); // Deal with .. by chopping dirs off the lookup path while (path.startsWith("../")) { if (lookupPath.length() 0) { index =
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/http LocaleToCharsetMap.java
costin 01/02/19 19:15:48 Added: src/share/org/apache/tomcat/util/http LocaleToCharsetMap.java Log: Package move. Also: remove Headers.java ( an attempt to rewrite MimeHeaders - too late to add it ) to avoid confusion. I'll keep it around. Revision ChangesPath 1.1 jakarta-tomcat/src/share/org/apache/tomcat/util/http/LocaleToCharsetMap.java Index: LocaleToCharsetMap.java === /* * * * The Apache Software License, Version 1.1 * * Copyright (c) 1999 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 * http://www.apache.org/. * * [Additional notices, if required by prior licensing conditions] * */ /* * * This class was originally written by Jason Hunter [EMAIL PROTECTED] * as part of the book "Java Servlet Programming" (O'Reilly). * See http://www.servlets.com/book for more information. * Used by Sun Microsystems with permission. * */ package org.apache.tomcat.util.http; import java.util.*; /** * A mapping to determine the (somewhat arbitrarily) preferred charset for * a given locale. Supports all locales recognized in JDK 1.1. * This class was originally written by Jason Hunter [[EMAIL PROTECTED]] * as part of the book "Java Servlet Programming" (O'Reilly). * See a href="http://www.servlets.com/book" * http://www.servlets.com/book/a for more information. * Used by Sun Microsystems with permission. */ public class LocaleToCharsetMap { private static Hashtable map; static { map = new Hashtable(); map.put("ar", "ISO-8859-6"); map.put("be", "ISO-8859-5"); map.put("bg", "ISO-8859-5"); map.put("ca", "ISO-8859-1"); map.put("cs", "ISO-8859-2"); map.put("da", "ISO-8859-1"); map.put("de", "ISO-8859-1"); map.put("el", "ISO-8859-7"); map.put("en", "ISO-8859-1"); map.put("es", "ISO-8859-1"); map.put("et", "ISO-8859-1"); map.put("fi", "ISO-8859-1"); map.put("fr", "ISO-8859-1"); map.put("hr", "ISO-8859-2"); map.put("hu", "ISO-8859-2"); map.put("is", "ISO-8859-1"); map.put("it", "ISO-8859-1"); map.put("iw", "ISO-8859-8"); map.put("ja", "Shift_JIS"); map.put("ko", "EUC-KR"); // Requires JDK 1.1.6
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/modules/server Ajp13.java Http10.java Http10Interceptor.java
costin 01/02/19 19:16:53 Modified:src/share/org/apache/tomcat/modules/aaa AccessInterceptor.java CredentialsInterceptor.java JDBCRealm.java src/share/org/apache/tomcat/modules/config ApacheConfig.java AutoDeploy.java ContextXmlReader.java LogSetter.java NSConfig.java PathSetter.java PolicyInterceptor.java ServerXmlReader.java src/share/org/apache/tomcat/modules/generators ErrorHandler.java StaticInterceptor.java src/share/org/apache/tomcat/modules/mappers SimpleMapper1.java src/share/org/apache/tomcat/modules/server Ajp13.java Http10.java Http10Interceptor.java Log: Changed import statements, explicit imports. Revision ChangesPath 1.7 +2 -1 jakarta-tomcat/src/share/org/apache/tomcat/modules/aaa/AccessInterceptor.java Index: AccessInterceptor.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/aaa/AccessInterceptor.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- AccessInterceptor.java2001/02/16 19:37:09 1.6 +++ AccessInterceptor.java2001/02/20 03:16:51 1.7 @@ -60,7 +60,8 @@ package org.apache.tomcat.modules.aaa; import org.apache.tomcat.core.*; -import org.apache.tomcat.util.*; +import org.apache.tomcat.util.buf.MessageBytes; +import org.apache.tomcat.util.io.FileUtil; import org.apache.tomcat.util.http.*; import java.util.*; import java.io.*; 1.3 +1 -2 jakarta-tomcat/src/share/org/apache/tomcat/modules/aaa/CredentialsInterceptor.java Index: CredentialsInterceptor.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/aaa/CredentialsInterceptor.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- CredentialsInterceptor.java 2001/01/06 23:25:55 1.2 +++ CredentialsInterceptor.java 2001/02/20 03:16:51 1.3 @@ -59,8 +59,7 @@ package org.apache.tomcat.modules.aaa; import org.apache.tomcat.core.*; -import org.apache.tomcat.util.*; -//import org.apache.tomcat.session.ServerSession; +import org.apache.tomcat.util.buf.Base64; import org.apache.tomcat.util.xml.*; import java.io.*; import java.net.*; 1.4 +5 -4 jakarta-tomcat/src/share/org/apache/tomcat/modules/aaa/JDBCRealm.java Index: JDBCRealm.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/aaa/JDBCRealm.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- JDBCRealm.java2001/02/06 02:05:46 1.3 +++ JDBCRealm.java2001/02/20 03:16:51 1.4 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/aaa/JDBCRealm.java,v 1.3 2001/02/06 02:05:46 nacho Exp $ - * $Revision: 1.3 $ - * $Date: 2001/02/06 02:05:46 $ + * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/aaa/JDBCRealm.java,v 1.4 2001/02/20 03:16:51 costin Exp $ + * $Revision: 1.4 $ + * $Date: 2001/02/20 03:16:51 $ * * The Apache Software License, Version 1.1 * @@ -62,7 +62,8 @@ package org.apache.tomcat.modules.aaa; import org.apache.tomcat.core.*; -import org.apache.tomcat.util.*; +import org.apache.tomcat.util.res.StringManager; +import org.apache.tomcat.util.buf.HexUtils; import java.security.*; //import java.security.Principal; //import java.io.File; 1.5 +1 -1 jakarta-tomcat/src/share/org/apache/tomcat/modules/config/ApacheConfig.java Index: ApacheConfig.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/config/ApacheConfig.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- ApacheConfig.java 2001/02/05 23:29:56 1.4 +++ ApacheConfig.java 2001/02/20 03:16:51 1.5 @@ -59,7 +59,7 @@ package org.apache.tomcat.modules.config; import org.apache.tomcat.core.*; -import org.apache.tomcat.util.*; +import org.apache.tomcat.util.io.FileUtil; import org.apache.tomcat.util.log.*; import java.io.*; import java.net.*; 1.3 +1 -1 jakarta-tomcat/src/share/org/apache/tomcat/modules/config/AutoDeploy.java Index: AutoDeploy.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/config/AutoDeploy.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util LocaleToCharsetMap.java
costin 01/02/19 19:17:57 Modified:src/share/org/apache/tomcat/core BaseInterceptor.java Container.java Context.java ContextManager.java Handler.java Request.java Response.java ServerSession.java package.html src/share/org/apache/tomcat/startup StopTomcat.java Tomcat.java Removed: src/share/org/apache/tomcat/util LocaleToCharsetMap.java Log: Package move, explicit imports. Revision ChangesPath 1.42 +2 -2 jakarta-tomcat/src/share/org/apache/tomcat/core/BaseInterceptor.java Index: BaseInterceptor.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/BaseInterceptor.java,v retrieving revision 1.41 retrieving revision 1.42 diff -u -r1.41 -r1.42 --- BaseInterceptor.java 2001/02/06 06:40:06 1.41 +++ BaseInterceptor.java 2001/02/20 03:17:56 1.42 @@ -60,8 +60,8 @@ package org.apache.tomcat.core; -import org.apache.tomcat.util.log.*; -import org.apache.tomcat.util.hooks.*; +import org.apache.tomcat.util.log.Log; +import org.apache.tomcat.util.hooks.Hooks; /** Implement "Chain of Responsiblity" pattern ( == hooks ). * 1.47 +1 -1 jakarta-tomcat/src/share/org/apache/tomcat/core/Container.java Index: Container.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/Container.java,v retrieving revision 1.46 retrieving revision 1.47 diff -u -r1.46 -r1.47 --- Container.java2001/02/06 06:40:06 1.46 +++ Container.java2001/02/20 03:17:56 1.47 @@ -59,7 +59,7 @@ package org.apache.tomcat.core; -import org.apache.tomcat.util.hooks.*; +import org.apache.tomcat.util.hooks.Hooks; import java.util.Hashtable; import java.util.Enumeration; 1.139 +2 -2 jakarta-tomcat/src/share/org/apache/tomcat/core/Context.java Index: Context.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/Context.java,v retrieving revision 1.138 retrieving revision 1.139 diff -u -r1.138 -r1.139 --- Context.java 2001/02/06 06:41:07 1.138 +++ Context.java 2001/02/20 03:17:56 1.139 @@ -61,8 +61,8 @@ package org.apache.tomcat.core; import org.apache.tomcat.util.depend.*; -import org.apache.tomcat.util.MimeMap; -import org.apache.tomcat.util.log.*; +import org.apache.tomcat.util.http.MimeMap; +import org.apache.tomcat.util.log.Log; import java.io.File; import java.net.FileNameMap; 1.169 +1 -1 jakarta-tomcat/src/share/org/apache/tomcat/core/ContextManager.java Index: ContextManager.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/ContextManager.java,v retrieving revision 1.168 retrieving revision 1.169 diff -u -r1.168 -r1.169 --- ContextManager.java 2001/02/13 16:05:31 1.168 +++ ContextManager.java 2001/02/20 03:17:56 1.169 @@ -59,7 +59,7 @@ package org.apache.tomcat.core; -import org.apache.tomcat.util.log.*; +import org.apache.tomcat.util.log.Log; import java.util.Hashtable; import java.util.Vector; 1.38 +1 -1 jakarta-tomcat/src/share/org/apache/tomcat/core/Handler.java Index: Handler.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/Handler.java,v retrieving revision 1.37 retrieving revision 1.38 diff -u -r1.37 -r1.38 --- Handler.java 2001/02/19 20:22:36 1.37 +++ Handler.java 2001/02/20 03:17:56 1.38 @@ -59,7 +59,7 @@ package org.apache.tomcat.core; import org.apache.tomcat.util.Counters; -import org.apache.tomcat.util.log.*; +import org.apache.tomcat.util.log.Log; /** * The class that will generate the actual response or response fragment. 1.91 +7 -4 jakarta-tomcat/src/share/org/apache/tomcat/core/Request.java Index: Request.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/Request.java,v retrieving revision 1.90 retrieving revision 1.91 diff -u -r1.90 -r1.91 --- Request.java 2001/02/09 07:47:48 1.90 +++ Request.java 2001/02/20 03:17:56 1.91 @@ -60,14 +60,17 @@ package org.apache.tomcat.core; -import org.apache.tomcat.util.MimeHeaders; +import org.apache.tomcat.util.http.MimeHeaders; +import org.apache.tomcat.util.http.Parameters; +import org.apache.tomcat.util.http.ContentType; +import
cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/util/buf Ascii.java Base64.java ByteChunk.java CharChunk.java DateTool.java HexUtils.java MessageBytes.java
costin 01/02/19 19:12:14 Added: src/share/org/apache/tomcat/util/buf Ascii.java Base64.java ByteChunk.java CharChunk.java DateTool.java HexUtils.java MessageBytes.java Log: Moving files from tomcat.util in sub-packages. This avoids name polution and makes easy to understand the dependencies. Revision ChangesPath 1.1 jakarta-tomcat/src/share/org/apache/tomcat/util/buf/Ascii.java Index: Ascii.java === /* * * * The Apache Software License, Version 1.1 * * Copyright (c) 1999 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 * http://www.apache.org/. * * [Additional notices, if required by prior licensing conditions] * */ package org.apache.tomcat.util.buf; /** * This class implements some basic ASCII character handling functions. * * @author [EMAIL PROTECTED] * @author James Todd [[EMAIL PROTECTED]] */ public final class Ascii { /* * Character translation tables. */ private static final byte[] toUpper = new byte[256]; private static final byte[] toLower = new byte[256]; /* * Character type tables. */ private static final boolean[] isAlpha = new boolean[256]; private static final boolean[] isUpper = new boolean[256]; private static final boolean[] isLower = new boolean[256]; private static final boolean[] isWhite = new boolean[256]; private static final boolean[] isDigit = new boolean[256]; /* * Initialize character translation and type tables. */ static { for (int i = 0; i 256; i++) { toUpper[i] = (byte)i; toLower[i] = (byte)i; } for (int lc = 'a'; lc = 'z'; lc++) { int uc = lc + 'A' - 'a'; toUpper[lc] = (byte)uc; toLower[uc] = (byte)lc; isAlpha[lc] = true; isAlpha[uc] = true; isLower[lc] = true; isUpper[uc] = true; } isWhite[ ' '] = true; isWhite['\t'] = true; isWhite['\r'] = true; isWhite['\n'] = true; isWhite['\f'] = true; isWhite['\b'] = true; for (int d = '0'; d = '9'; d++) { isDigit[d] = true; }
cvs commit: jakarta-tomcat/src/share/org/apache/jasper/servlet JspServlet.java
costin 01/02/19 19:36:01 Modified:src/share/org/apache/jasper Constants.java JspC.java src/share/org/apache/jasper/compiler JasperMangler.java src/share/org/apache/jasper/servlet JspServlet.java Log: Changes for the new package names, plus use of Log. Revision ChangesPath 1.16 +4 -4 jakarta-tomcat/src/share/org/apache/jasper/Constants.java Index: Constants.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/jasper/Constants.java,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- Constants.java2000/12/04 23:40:46 1.15 +++ Constants.java2001/02/20 03:36:00 1.16 @@ -60,8 +60,8 @@ import java.util.MissingResourceException; import java.text.MessageFormat; -import org.apache.tomcat.util.log.*; - +import org.apache.tomcat.util.log.Log; + /** * Some constants and other global data that are used by the compiler and the runtime. * @@ -257,12 +257,12 @@ */ public static final void message(String key, Object[] args, int verbosityLevel) { if (jasperLog == null) - jasperLog = Logger.getLogger("JASPER_LOG"); + jasperLog = Log.getLog("JASPER_LOG", null); if (jasperLog != null) jasperLog.log(getString(key, args), verbosityLevel); } -public static Logger jasperLog = null; +public static Log jasperLog = null; } 1.20 +18 -16jakarta-tomcat/src/share/org/apache/jasper/JspC.java Index: JspC.java === RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/jasper/JspC.java,v retrieving revision 1.19 retrieving revision 1.20 diff -u -r1.19 -r1.20 --- JspC.java 2001/01/14 20:45:40 1.19 +++ JspC.java 2001/02/20 03:36:00 1.20 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/jasper/JspC.java,v 1.19 2001/01/14 20:45:40 larryi Exp $ - * $Revision: 1.19 $ - * $Date: 2001/01/14 20:45:40 $ + * $Header: /home/cvs/jakarta-tomcat/src/share/org/apache/jasper/JspC.java,v 1.20 2001/02/20 03:36:00 costin Exp $ + * $Revision: 1.20 $ + * $Date: 2001/02/20 03:36:00 $ * * * @@ -116,7 +116,7 @@ boolean largeFile = false; boolean mappedFile = false; -int jspVerbosityLevel = Logger.INFORMATION; +int jspVerbosityLevel = Log.INFORMATION; File scratchDir; @@ -245,15 +245,15 @@ args = arg; String tok; -int verbosityLevel = Logger.WARNING; +int verbosityLevel = Log.WARNING; dieLevel = NO_DIE_LEVEL; die = dieLevel; while ((tok = nextArg()) != null) { if (tok.equals(SWITCH_QUIET)) { -verbosityLevel = Logger.WARNING; +verbosityLevel = Log.WARNING; } else if (tok.equals(SWITCH_VERBOSE)) { -verbosityLevel = Logger.INFORMATION; +verbosityLevel = Log.INFORMATION; } else if (tok.startsWith(SWITCH_VERBOSE)) { try { verbosityLevel @@ -322,8 +322,10 @@ } } -Constants.jasperLog = new QueueLogger(); -Constants.jasperLog.setVerbosityLevel(verbosityLevel); + QueueLogger ql = new QueueLogger(); + ql.setVerbosityLevel(verbosityLevel); +Constants.jasperLog = Log.getLog("JASPER_LOG", this ); +Constants.jasperLog.setLogger( ql ); } @@ -400,16 +402,16 @@ } catch (JasperException je) { //je.printStackTrace(log); Constants.message("jspc.error.jasperException", -new Object[] {file, je}, Logger.ERROR); +new Object[] {file, je}, Log.ERROR); if (dieLevel != NO_DIE_LEVEL) { dieOnExit = true; } } catch (FileNotFoundException fne) { Constants.message("jspc.error.fileDoesNotExist", -new Object[] {fne.getMessage()}, Logger.WARNING); +new Object[] {fne.getMessage()}, Log.WARNING); } catch (Exception e) { Constants.message("jspc.error.generalException", -new Object[] {file, e}, Logger.ERROR); +new Object[] {file, e}, Log.ERROR); if (dieLevel != NO_DIE_LEVEL) { dieOnExit = true; } @@ -443,13 +445,13 @@ } else { // end of arguments, nothing left to parse Constants.message("jspc.error.emptyWebApp", -