diff --git a/centos8_tomcat/Dockerfile b/centos8_tomcat/Dockerfile new file mode 100644 index 0000000..c161563 --- /dev/null +++ b/centos8_tomcat/Dockerfile @@ -0,0 +1,36 @@ +FROM centos:8 +MAINTAINER Donfig + +# My comment here +RUN echo '1. Base packages install' +RUN dnf install -y glibc-langpack-ko + +RUN echo '2. Locale and Timezone environment' +ENV LANG ko_KR.utf8 +RUN echo 'LANG="$LANG"' > /etc/locale.conf +RUN unlink /etc/localtime +RUN ln -s /usr/share/zoneinfo/Asia/Tokyo /etc/localtime +RUN echo 'set encoding=utf-8' >> /etc/vimrc +RUN echo 'set encoding=utf-8' >> /etc/virc +RUN echo 'set fileencodings=utf-8,cp949' >> /etc/vimrc +RUN echo 'set fileencodings=utf-8,cp949' >> /etc/virc +RUN echo 'set softtabstop=4' >> /etc/vimrc +RUN echo 'set softtabstop=4' >> /etc/virc +RUN echo 'set shiftwidth=4' >> /etc/vimrc +RUN echo 'set shiftwidth=4' >> /etc/virc +RUN echo 'set tabstop=4' >> /etc/vimrc +RUN echo 'set tabstop=4' >> /etc/virc +RUN echo 'set paste' >> /etc/vimrc +RUN echo 'set paste' >> /etc/virc +RUN echo 'export LANG="$LANG"' >> /etc/bashrc +RUN echo 'export LANGUAGE="$LANG"' >> /etc/bashrc +RUN source /etc/bashrc + +RUN echo '2. Install need Package' +RUN dnf -y install java + +RUN echo '3. Setting Supervisor for Web' +COPY apache-tomcat-7.0.108 /usr/local/tomcat + +EXPOSE 8080 +CMD [ "/usr/local/tomcat/bin/catalina.sh","run"] diff --git a/centos8_tomcat/apache-tomcat-7.0.108.tar.gz b/centos8_tomcat/apache-tomcat-7.0.108.tar.gz new file mode 100644 index 0000000..2d3a556 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108.tar.gz differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/BUILDING.txt b/centos8_tomcat/apache-tomcat-7.0.108/BUILDING.txt new file mode 100644 index 0000000..a5b96f5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/BUILDING.txt @@ -0,0 +1,522 @@ +================================================================================ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +================================================================================ + + ==================================================== + Building The Apache Tomcat 7.0 Servlet/JSP Container + ==================================================== + +This subproject contains the source code for Tomcat 7.0, a container that +implements the Servlet 3.0, JSP 2.2, EL 2.2 and WebSocket 1.1 specifications +from the Java Community Process . + +Note: If you just need to run Apache Tomcat, it is not necessary to build +it. You may simply download a binary distribution. It is cross-platform. +Read RUNNING.txt for the instruction on how to run it. + +In order to build a binary distribution version of Apache Tomcat from a +source distribution, do the following: + + +(1) Download and Install a Java 6 and Java 7 Development Kit + + 1. If the JDKs are already installed, skip to (2). + + 2. Download a version 6 of the Java Development Kit (JDK) release (use the + latest update available for your chosen version) from + + http://www.oracle.com/technetwork/java/javase/downloads/index.html + or from another JDK vendor. + + Note regarding later versions of Java: + + As documented elsewhere, one of the components in Apache Tomcat includes + a private copy of the Apache Commons DBCP 1.x library. The source code + for this library is downloaded, processed by the build script + (renaming the packages) and compiled. + + Due to changes in JDBC interfaces implemented by the library between + versions of Java SE specification, the library has to target specific + version of Java and can be compiled only with the JDK version + implementing this version of specification. Therefore, the build Tomcat + build process must be executed with a Java 6 JDK. + + See Apache Commons DBCP 1.x project web site for more details on + available versions of the library and its requirements, + + https://commons.apache.org/dbcp/ + + If you really want to use a later version of JDK to build Tomcat, + several workarounds are possible. One of them is to skip building + the component (tomcat-dbcp.jar). + + 3. Install the Java 6 JDK according to the instructions included with the + release. + + 4. Set an environment variable JAVA_HOME to the pathname of the directory + into which you installed the JDK release. + + 5. Download a version 7 of the Java Development Kit (JDK) release (use the + latest update available for your chosen version) from + + http://www.oracle.com/technetwork/java/javase/downloads/index.html + or from another JDK vendor. + + 6. Install the Java 7 JDK according to the instructions included with the + release. + +* NOTE: The Java 7 JDK is only required if you wish to build Tomcat with + JSR-356 (Java WebSocket 1.1) support. + + +(2) Install Apache Ant version 1.9.1 or later on your computer + + 1. If Apache Ant version 1.9.1 or later is already installed on your computer, skip to (3). + + 2. Download a binary distribution of Ant from: + + https://ant.apache.org/bindownload.cgi + + 3. Unpack the binary distribution into a convenient location so that the + Ant release resides in its own directory (conventionally named + "apache-ant-[version]"). + + For the purposes of the remainder of this document, the symbolic name + "${ant.home}" is used to refer to the full pathname of the release + directory. + + 4. Create an ANT_HOME environment variable to point the directory + ${ant.home}. + + 5. Modify the PATH environment variable to include the directory + ${ant.home}/bin in its list. This makes the "ant" command line script + available, which will be used to actually perform the build. + + +(3) Building Tomcat 7.0 + +(3.1) Checkout or obtain the source code for Tomcat 7.0 + +Clone the source using git, then checkout a specific major branch or +master for the latest code development, or download and unpack a source +package. + + * Tomcat GitHub repository URL: + + https://github.com/apache/tomcat + + * Source packages can be downloaded from: + + https://tomcat.apache.org/download-70.cgi + +The location where the source has been placed will be further referred as +${tomcat.source}. + +The Tomcat local build process does not modify line-endings. The svn repository +is configured so that all files will be checked out with the line-ending +appropriate for the current platform. When using a source package you should +ensure that you use the source package that has the appropriate line-ending +for your platform: + + zip -> CRLF + tar.gz -> LF + +Note that the release build process does modify line-endings to ensure that +each release package has the appropriate line-endings. + +(3.2) Building + + 1. The build is controlled by creating a ${tomcat.source}/build.properties + file. + + It is recommended to always create the file, because of unfortunate + default value of base.path property. You may start with the following + content for the file: + + # ----- Default Base Path for Dependent Packages ----- + # Replace this path with the directory path where dependencies binaries + # should be downloaded + base.path=/home/me/some-place-to-download-to + + 2. Configure base.path property by adding it to the + ${tomcat.source}/build.properties file. + + The base.path property specifies the place where Tomcat dependencies + required by the build are downloaded. It is recommended to place this + directory outside of the source tree, so that you do not waste your + time re-downloading the libraries. + +* NOTE: The default value of the base.path property configures the build script + to download the libraries required to build Tomcat to the + ${user.home}/tomcat-build-libs directory. + +* NOTE: Users accessing the Internet through a proxy must use the properties + file to indicate to Ant the proxy configuration. + + The following properties should be added to the ${tomcat.source}/build.properties + file. + + proxy.use=on + proxy.host=proxy.domain + proxy.port=8080 + proxy.user=username + proxy.password=password + + See Apache Ant documentation for the task for details. + +* NOTE: Users wishing to build Tomcat with JSR-356 (Java WebSocket 1.1) support + must also set the java.7.home build property to the location of the Java 7 JDK + installation. + + 3. Go to the sources directory and run Ant: + + cd ${tomcat.source} + ant + + This will execute the "deploy" target in build.xml. + + Once the build has completed successfully, a usable Tomcat installation + will have been produced in the ${tomcat.source}/output/build directory, + and can be started and stopped with the usual scripts. + + Note that the build includes Tomcat documentation, which can be found + in the output/build/webapps/docs directory. + + The path of the output directory can be controlled by specifying the + "tomcat.output" property in the build.properties file. + +* NOTE: Do not run the build as the root user. Building and running Tomcat + does not require root privileges. + + +(4) Updating sources and rebuilding + +It is recommended that you regularly update the downloaded Tomcat 7.0 +sources using your SVN client. + +For a quick rebuild of only modified code you can use: + + cd ${tomcat.source} + ant + + +(5) Special builds + +There are several targets in Tomcat build files that are useful to be +called separately. They build components that you may want to build +quickly, or ones that are included in the full release and are not built +during the default "deploy" build. + +(5.1) Building documentation + +The documentation web application is built during the default "deploy" +build. + +It can be built quickly by using the following commands: + + cd ${tomcat.source} + ant build-docs + +The output of this command will be found in the following directory: + + output/build/webapps/docs + + +The API documentation (Javadoc) is built during a "release" build. It is +easy to build it separately by using the following commands: + + cd ${tomcat.source} + ant javadoc + +The output of this command will be found in the following directories: + + output/dist/webapps/docs/api + output/dist/webapps/docs/elapi + output/dist/webapps/docs/jspapi + output/dist/webapps/docs/servletapi + + +(5.2) Building the extras (commons-logging, webservices etc.) + +These components are documented on the "Additional Components" +(extras.html) page of documentation. They are built during a "release" +build. + +You can build them by using the following commands: + + cd ${tomcat.source} + ant extras + +(5.3) Building the embedded packages + +These are built during a "release" build. + +You can build them by using the following commands: + + cd ${tomcat.source} + ant embed + + +(6) Building a full release (as provided via the ASF download pages) + + A full release includes the Windows installer which requires a Windows + environment to be available to create it. If not building in a Windows + environment, the build scripts assume that Wine is available. If this is not + the case, the skip.installer property may be set to skip the creation of the + Windows installer. + + 1. Configure GPG, if needed + + If the released artifacts have to be cryptographically signed with a + PGP signature, like the official ASF releases are, the following + property can be added to the build.properties file: + + # Location of GPG executable (used only for releases) + gpg.exec=/path/to/gpg + + You do not need it if you do not plan to sign the release. + + If "gpg.exec" property does not point to an existing file, it will be + ignored and this feature will be disabled. + + You will be prompted for the GPG passphrase when the release build + starts, unless "gpg.passphrase" property is set. + + 2. Build the release: + + cd ${tomcat.source} + ant release + + +(7) Tests + +(7.1) Running Tomcat tests + +Tomcat includes a number of junit tests. The tests are not run when a +release is built. There is separate command to run them. + +To run the testsuite use the following command: + + cd ${tomcat.source} + ant test + +It is advisable to redirect output of the above command to a file for later +inspection. + +The JUnit reports generated by the tests will be written to the following +directory: + + output/build/logs + +By default the testsuite is run three times to test 3 different +implementations of Tomcat connectors: BIO, NIO and APR. (If you are not +familiar with Tomcat connectors, see config/http.html in documentation for +details). + +The 3 runs are enabled and disabled individually by the following +properties, which all are "true" by default: + + execute.test.bio=true + execute.test.nio=true + execute.test.apr=true + +The APR connector can be tested only if Tomcat-Native library binaries are +found by the testsuite. The "test.apr.loc" property specifies the directory +where the library binaries are located. + +By default the "test.apr.loc" property specifies the following location: + + output/build/bin/native/ + +If you are on Windows and want to test the APR connector you can put the +tcnative-1.dll file into ${tomcat.source}/bin/native/ and it will be copied +into the above directory when the build runs. + +* NOTE: If you configured the build to use a Java 7 JDK (if the +"java.7.home" property has been defined) the tests will be run with Java 7. + +The version of Java that was actually used to run the tests is reported by +"org.apache.catalina.util.TestServerInfo" test class. + + +(7.2) Running a single test + +It is possible to run a single JUnit test class by adding the "test.entry" +property to the build.properties file. The property specifies the name of +the test class. + +For example: + + test.entry=org.apache.catalina.util.TestServerInfo + +It is possible to further limit such run to a number of selected test +methods by adding "test.entry.methods" property. The property specifies a +comma-separated list of test case methods. + +For example: + + test.entry=org.apache.el.lang.TestELArithmetic + test.entry.methods=testMultiply01,testMultiply02 + + +(7.3) Running a set of tests + +It is possible to run a set of JUnit test classes by adding the "test.name" +property to the build.properties file. The property specifies an Ant +includes pattern for the fileset of test class files to run. + +The default value is "**/Test*.java", so all test classes are being +executed (with few exceptions - see build.xml for several exclude patterns). + +You can include multiple patterns by concatenating them with a comma (",") +as the separator. + +For example: + + test.name=**/TestSsl.java,**/TestWebSocketFrameClientSSL.java + +You can exclude specific JUnit test classes by adding the "test.exclude" +property to the build.properties file. The property specifies an Ant +excludes pattern for the fileset of test class files to exclude form the run. +The default value is empty, so no classes are excluded. The syntax is the same +as for the property "test.name". + + +(7.4) Other configuration options + + 1. It is possible to configure the directory where JUnit reports are + written to. It is configured by "test.reports" property. The default + value is + + output/build/logs + + 2. It is possible to enable generation of access log file when the tests + are run. This is off by default and can be enabled by the following + property: + + test.accesslog=true + + The "access_log." file will be written to the same directory as + JUnit reports, + + output/build/logs + + 3. The testsuite respects logging configuration as configured by + ${tomcat.source}/conf/logging.properties + + The log files will be written to the temporary directory used by the + tests, + + output/test-tmp/logs + + 4. It is possible to configure formatter used by JUnit reports. + Configuration properties are "junit.formatter.type", + "junit.formatter.extension" and "junit.formatter.usefile". + + For example the following property disables generation of separate report + files: + + junit.formatter.usefile=false + + 5. Optional support is provided for the Cobertura code coverage tool. + +* NOTE: Cobertura is licensed under GPL v2 with parts of it being under + Apache License v1.1. See http://cobertura.sf.net for details. Using it + during Tomcat build is optional and is off by default. + + Cobertura can be enabled using the following property: + + test.cobertura=true + + The report files by default are written to + + output/coverage + + 6. The performance tests are written to run reasonably powerful machines (such + as a developer may use day to day) assuming no other resource hungry + processes are running. + + These assumptions are not always true (e.g. on CI systems running in a + virtual machine) so the performance tests may be disabled by using the + following property: + + test.excludePerformance=true + + 7. Some tests include checks that the access log valve entries are as expected. + These checks include timings. On slower / loaded systems these checks will + often fail. The checks may be relaxed by using the following property: + + test.relaxTiming=true + + 8. It is known that some platforms (e.g. OSX El Capitan) require IPv4 to + be the default for the multicast tests to work. This is configured by + the following property: + + java.net.preferIPv4Stack=true + + 9. It is possible to control whether the output of the tests is displayed + on the console or not. By default it is displayed and can be disabled + by the following property: + + test.verbose=true + +(8) Source code checks + +(8.1) Checkstyle + +* NOTE: Checkstyle is licensed under LGPL. Using Checkstyle during Tomcat + build is optional and is off by default. + + See http://checkstyle.sourceforge.net/ for more information. + +Tomcat comes with a Checkstyle configuration that tests its source code +for certain conventions, like presence of the license header. + +To enable Checkstyle, add the following property to build.properties file: + + execute.validate=true + +Once Checkstyle is enabled, the check will be performed automatically +during the build. The check is run before compilation of the source code. + +To speed-up repeated runs of this check, a cache is configured. The cache +is located in the following directory: + + output/res/checkstyle + +It is possible to run the check separately by calling the "validate" +target. The command is: + + cd ${tomcat.source} + ant -Dexecute.validate=true validate + + +(8.2) End-of-line conventions check + +You usually would not need to run this check. You can skip this section. + +Apache Tomcat project has convention that all of its textual source files, +stored in the Git repository, use Unix style LF line endings. + +This test is used by developers to check that the source code adheres to +this convention. It verifies that the ends of lines in textual files are +appropriate. The idea is to run this check regularly and notify developers +when an inconsistency is detected. + +The command to run this test is: + + cd ${tomcat.source} + ant validate-eoln diff --git a/centos8_tomcat/apache-tomcat-7.0.108/CONTRIBUTING.md b/centos8_tomcat/apache-tomcat-7.0.108/CONTRIBUTING.md new file mode 100644 index 0000000..83968b2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/CONTRIBUTING.md @@ -0,0 +1,141 @@ +# Contributing to Apache Tomcat + +Firstly, thanks for your interest in contributing! I hope that this will be a +pleasant experience for you, and that you will return to continue +contributing. + +Please visit our [Get Involved page](https://tomcat.apache.org/getinvolved.html) +for more information on how to contribute. + +## Code of Conduct + +This project and everyone participating in it are governed by the Apache +software Foundation's +[Code of Conduct](https://www.apache.org/foundation/policies/conduct.html). By +participating, you are expected to adhere to this code. If you are aware of +unacceptable behavior, please visit the +[Reporting Guidelines page](https://www.apache.org/foundation/policies/conduct.html#reporting-guidelines) +and follow the instructions there. + +## How Can I Contribute? + +Most of the contributions that we receive are code contributions, but you can +also contribute to the documentation, wiki, etc., or simply report solid bugs +for us to fix. + +### Reporting Bugs + +Please review our [guide](https://tomcat.apache.org/bugreport.html) on how to +submit a bug report. This page also has links to other resources to assist +you. + +### Reporting Translation improvements + +Apache Tomcat project uses POEditor for managing the localization files. +Please see more at https://cwiki.apache.org/confluence/x/vIPzBQ + +### Your First Code Contribution + +### Trouble Deciding How to Contribute? + +Unsure where to begin contributing to Tomcat? You can start by taking a look at +the issues marked 'Beginner', link below. Please note that the Beginner keyword +is pretty new to the project, so if there aren't any issues in the filter feel +free to ask on the [dev list](https://tomcat.apache.org/lists.html#tomcat-dev). + +* [Beginner issues](https://bz.apache.org/bugzilla/buglist.cgi?bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=NEEDINFO&keywords=Beginner&keywords_type=allwords&list_id=160824&product=Tomcat%207&product=Tomcat%208.5&product=Tomcat%209&query_format=advanced) - +issues which should only require a few lines of code, and a test or two to +resolve. + +The list above shows all bugs that are marked 'Beginner' and are open in the +currently supported Tomcat versions (7, 8.5, and 9). + +If you prefer C over Java, you may also take a look at the tomcat-native and +Tomcat Connectors products in Bugzilla. + +### How to Provide Your First Patch + +Excited yet? This section will guide you through providing a patch to the +committers of the project for review and acceptance. + +##### Choose Your Method of Submission + +You can provide a patch in one of the following ways (in order of preference): + +* GitHub Pull Request +* Patch attachment to the Bugzilla issue +* Email the patch to the developer list. This is not preferred, but if no bug +is associated with the patch, or you would like a developer review, an email +may be appropriate. + +##### Get the Sources + +Now that you've chosen how you want to submit a patch, you need to get the +source code. + +###### Download The Source Distribution + +This method works if you want to submit a patch via email, but +the difference in using the sources distribution and a VCS is that you have to +manually generate the patch file by using diff. If this is what you want, you +can download the sources from the "Source Code Distributions" section of the +Download Page. There is one such page for every major Tomcat version: + +- [Tomcat 9](https://tomcat.apache.org/download-90.cgi) +- [Tomcat 8](https://tomcat.apache.org/download-80.cgi) +- [Tomcat 7](https://tomcat.apache.org/download-70.cgi) + +##### Manual Patch Generation + +If you have chosen to attach a patch to the Bugzilla issue (or email +one), then you'll need to download the sources as noted above, make your +desired changes and then manually generate your patch using diff (other +other tool). + +##### GitHub + +To submit a GitHub Pull Request you'll need to fork the +[repository](https://github.com/apache/tomcat), clone your fork to do the work: + +``` +$ git clone https://github.com/$USERNAME/tomcat.git +``` + +and then push your changes, and submit a Pull Request via the GitHub UI. + +#### Submitting Your Patch! + +After you've chosen your method of submission, retrieved the sources, and +fixed the issue it's time to submit your work. At this point, just follow +the method of submission you chose earlier. + +* GitHub PR - after resolving the issue in your local fork and pushing to your +copy of the repository, open a GitHub PR for review. +* Bugzilla attachment - attach the patch to the Bugzilla issue +* Email - again, not preferred, but you may send an email to the developer list +with a patch attached for review. + +#### Waiting For Feedback + +It may take a while for committers to review. Please be patient during this +time as all committers are volunteers on the project. If a significant amount +of time has lapsed since your submission, such as a couple of months, feel free +to either update your BZ, PR, or email the dev list with a message to bump your +issue. Sometimes things get lost in all the work and we need a reminder :smile: + +## Style Guide + +Apache Tomcat has very loosely defined coding conventions, but the following +guidelines will be useful: + +* Use spaces for indenting, not tabs +* 100 char line width for Java source, 80 char line width for documentation +source (.txt, .xml) +* Java source: { at end of line, 4 space indents +* XML source: 2 space indents + +## Did we miss something? + +Have you reviewed this guide and found it lacking? Or are you confused about +some particular step? If so, please let us know! Or better yet, submit a PR to +address the issue :wink: diff --git a/centos8_tomcat/apache-tomcat-7.0.108/LICENSE b/centos8_tomcat/apache-tomcat-7.0.108/LICENSE new file mode 100644 index 0000000..142f0b6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/LICENSE @@ -0,0 +1,1050 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + + +APACHE TOMCAT SUBCOMPONENTS: + +Apache Tomcat includes a number of subcomponents with separate copyright notices +and license terms. Your use of these subcomponents is subject to the terms and +conditions of the following licenses. + + +For the Eclipse JDT Core Batch Compiler (ecj-x.x.x.jar) component: + +Eclipse Public License - v 1.0 + +THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC +LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM +CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. + +1. DEFINITIONS + +"Contribution" means: + +a) in the case of the initial Contributor, the initial code and documentation +distributed under this Agreement, and + +b) in the case of each subsequent Contributor: + +i) changes to the Program, and + +ii) additions to the Program; + +where such changes and/or additions to the Program originate from and are +distributed by that particular Contributor. A Contribution 'originates' from a +Contributor if it was added to the Program by such Contributor itself or anyone +acting on such Contributor's behalf. Contributions do not include additions to +the Program which: (i) are separate modules of software distributed in +conjunction with the Program under their own license agreement, and (ii) are not +derivative works of the Program. + +"Contributor" means any person or entity that distributes the Program. + +"Licensed Patents" mean patent claims licensable by a Contributor which are +necessarily infringed by the use or sale of its Contribution alone or when +combined with the Program. + +"Program" means the Contributions distributed in accordance with this Agreement. + +"Recipient" means anyone who receives the Program under this Agreement, +including all Contributors. + +2. GRANT OF RIGHTS + +a) Subject to the terms of this Agreement, each Contributor hereby grants +Recipient a non-exclusive, worldwide, royalty-free copyright license to +reproduce, prepare derivative works of, publicly display, publicly perform, +distribute and sublicense the Contribution of such Contributor, if any, and such +derivative works, in source code and object code form. + +b) Subject to the terms of this Agreement, each Contributor hereby grants +Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed +Patents to make, use, sell, offer to sell, import and otherwise transfer the +Contribution of such Contributor, if any, in source code and object code form. +This patent license shall apply to the combination of the Contribution and the +Program if, at the time the Contribution is added by the Contributor, such +addition of the Contribution causes such combination to be covered by the +Licensed Patents. The patent license shall not apply to any other combinations +which include the Contribution. No hardware per se is licensed hereunder. + +c) Recipient understands that although each Contributor grants the licenses to +its Contributions set forth herein, no assurances are provided by any +Contributor that the Program does not infringe the patent or other intellectual +property rights of any other entity. Each Contributor disclaims any liability to +Recipient for claims brought by any other entity based on infringement of +intellectual property rights or otherwise. As a condition to exercising the +rights and licenses granted hereunder, each Recipient hereby assumes sole +responsibility to secure any other intellectual property rights needed, if any. +For example, if a third party patent license is required to allow Recipient to +distribute the Program, it is Recipient's responsibility to acquire that license +before distributing the Program. + +d) Each Contributor represents that to its knowledge it has sufficient copyright +rights in its Contribution, if any, to grant the copyright license set forth in +this Agreement. + +3. REQUIREMENTS + +A Contributor may choose to distribute the Program in object code form under its +own license agreement, provided that: + +a) it complies with the terms and conditions of this Agreement; and + +b) its license agreement: + +i) effectively disclaims on behalf of all Contributors all warranties and +conditions, express and implied, including warranties or conditions of title and +non-infringement, and implied warranties or conditions of merchantability and +fitness for a particular purpose; + +ii) effectively excludes on behalf of all Contributors all liability for +damages, including direct, indirect, special, incidental and consequential +damages, such as lost profits; + +iii) states that any provisions which differ from this Agreement are offered by +that Contributor alone and not by any other party; and + +iv) states that source code for the Program is available from such Contributor, +and informs licensees how to obtain it in a reasonable manner on or through a +medium customarily used for software exchange. + +When the Program is made available in source code form: + +a) it must be made available under this Agreement; and + +b) a copy of this Agreement must be included with each copy of the Program. + +Contributors may not remove or alter any copyright notices contained within the +Program. + +Each Contributor must identify itself as the originator of its Contribution, if +any, in a manner that reasonably allows subsequent Recipients to identify the +originator of the Contribution. + +4. COMMERCIAL DISTRIBUTION + +Commercial distributors of software may accept certain responsibilities with +respect to end users, business partners and the like. While this license is +intended to facilitate the commercial use of the Program, the Contributor who +includes the Program in a commercial product offering should do so in a manner +which does not create potential liability for other Contributors. Therefore, if +a Contributor includes the Program in a commercial product offering, such +Contributor ("Commercial Contributor") hereby agrees to defend and indemnify +every other Contributor ("Indemnified Contributor") against any losses, damages +and costs (collectively "Losses") arising from claims, lawsuits and other legal +actions brought by a third party against the Indemnified Contributor to the +extent caused by the acts or omissions of such Commercial Contributor in +connection with its distribution of the Program in a commercial product +offering. The obligations in this section do not apply to any claims or Losses +relating to any actual or alleged intellectual property infringement. In order +to qualify, an Indemnified Contributor must: a) promptly notify the Commercial +Contributor in writing of such claim, and b) allow the Commercial Contributor +to control, and cooperate with the Commercial Contributor in, the defense and +any related settlement negotiations. The Indemnified Contributor may +participate in any such claim at its own expense. + +For example, a Contributor might include the Program in a commercial product +offering, Product X. That Contributor is then a Commercial Contributor. If that +Commercial Contributor then makes performance claims, or offers warranties +related to Product X, those performance claims and warranties are such +Commercial Contributor's responsibility alone. Under this section, the +Commercial Contributor would have to defend claims against the other +Contributors related to those performance claims and warranties, and if a court +requires any other Contributor to pay any damages as a result, the Commercial +Contributor must pay those damages. + +5. NO WARRANTY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN +"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR +IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, +NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each +Recipient is solely responsible for determining the appropriateness of using and +distributing the Program and assumes all risks associated with its exercise of +rights under this Agreement , including but not limited to the risks and costs +of program errors, compliance with applicable laws, damage to or loss of data, +programs or equipment, and unavailability or interruption of operations. + +6. DISCLAIMER OF LIABILITY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY +CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST +PROFITS), 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 OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS +GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +7. GENERAL + +If any provision of this Agreement is invalid or unenforceable under applicable +law, it shall not affect the validity or enforceability of the remainder of the +terms of this Agreement, and without further action by the parties hereto, such +provision shall be reformed to the minimum extent necessary to make such +provision valid and enforceable. + +If Recipient institutes patent litigation against any entity (including a +cross-claim or counterclaim in a lawsuit) alleging that the Program itself +(excluding combinations of the Program with other software or hardware) +infringes such Recipient's patent(s), then such Recipient's rights granted under +Section 2(b) shall terminate as of the date such litigation is filed. + +All Recipient's rights under this Agreement shall terminate if it fails to +comply with any of the material terms or conditions of this Agreement and does +not cure such failure in a reasonable period of time after becoming aware of +such noncompliance. If all Recipient's rights under this Agreement terminate, +Recipient agrees to cease use and distribution of the Program as soon as +reasonably practicable. However, Recipient's obligations under this Agreement +and any licenses granted by Recipient relating to the Program shall continue and +survive. + +Everyone is permitted to copy and distribute copies of this Agreement, but in +order to avoid inconsistency the Agreement is copyrighted and may only be +modified in the following manner. The Agreement Steward reserves the right to +publish new versions (including revisions) of this Agreement from time to time. +No one other than the Agreement Steward has the right to modify this Agreement. +The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation +may assign the responsibility to serve as the Agreement Steward to a suitable +separate entity. Each new version of the Agreement will be given a +distinguishing version number. The Program (including Contributions) may always +be distributed subject to the version of the Agreement under which it was +received. In addition, after a new version of the Agreement is published, +Contributor may elect to distribute the Program (including its Contributions) +under the new version. Except as expressly stated in Sections 2(a) and 2(b) +above, Recipient receives no rights or licenses to the intellectual property of +any Contributor under this Agreement, whether expressly, by implication, +estoppel or otherwise. All rights in the Program not expressly granted under +this Agreement are reserved. + +This Agreement is governed by the laws of the State of New York and the +intellectual property laws of the United States of America. No party to this +Agreement will bring a legal action under this Agreement more than one year +after the cause of action arose. Each party waives its rights to a jury trial in +any resulting litigation. + + +For the Windows Installer component: + + * All NSIS source code, plug-ins, documentation, examples, header files and + graphics, with the exception of the compression modules and where + otherwise noted, are licensed under the zlib/libpng license. + * The zlib compression module for NSIS is licensed under the zlib/libpng + license. + * The bzip2 compression module for NSIS is licensed under the bzip2 license. + * The lzma compression module for NSIS is licensed under the Common Public + License version 1.0. + +zlib/libpng license + +This software is provided 'as-is', without any express or implied warranty. In +no event will the authors be held liable for any damages arising from the use of +this software. + +Permission is granted to anyone to use this software for any purpose, including +commercial applications, and to alter it and redistribute it freely, subject to +the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not claim + that you wrote the original software. If you use this software in a + product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + +bzip2 license + +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. The origin of this software must not be misrepresented; you must not claim + that you wrote the original software. If you use this software in a + product, an acknowledgment in the product documentation would be + appreciated but is not required. + 3. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 4. The name of the author may not be used to endorse or promote products + derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS AND ANY EXPRESS 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 AUTHOR 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. + +Julian Seward, Cambridge, UK. + +jseward@acm.org +Common Public License version 1.0 + +THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS COMMON PUBLIC +LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM +CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. + +1. DEFINITIONS + +"Contribution" means: + +a) in the case of the initial Contributor, the initial code and documentation +distributed under this Agreement, and b) in the case of each subsequent +Contributor: + +i) changes to the Program, and + +ii) additions to the Program; + +where such changes and/or additions to the Program originate from and are +distributed by that particular Contributor. A Contribution 'originates' from a +Contributor if it was added to the Program by such Contributor itself or anyone +acting on such Contributor's behalf. Contributions do not include additions to +the Program which: (i) are separate modules of software distributed in +conjunction with the Program under their own license agreement, and (ii) are not +derivative works of the Program. + +"Contributor" means any person or entity that distributes the Program. + +"Licensed Patents " mean patent claims licensable by a Contributor which are +necessarily infringed by the use or sale of its Contribution alone or when +combined with the Program. + +"Program" means the Contributions distributed in accordance with this Agreement. + +"Recipient" means anyone who receives the Program under this Agreement, +including all Contributors. + +2. GRANT OF RIGHTS + +a) Subject to the terms of this Agreement, each Contributor hereby grants +Recipient a non-exclusive, worldwide, royalty-free copyright license to +reproduce, prepare derivative works of, publicly display, publicly perform, +distribute and sublicense the Contribution of such Contributor, if any, and such +derivative works, in source code and object code form. + +b) Subject to the terms of this Agreement, each Contributor hereby grants +Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed +Patents to make, use, sell, offer to sell, import and otherwise transfer the +Contribution of such Contributor, if any, in source code and object code form. +This patent license shall apply to the combination of the Contribution and the +Program if, at the time the Contribution is added by the Contributor, such +addition of the Contribution causes such combination to be covered by the +Licensed Patents. The patent license shall not apply to any other combinations +which include the Contribution. No hardware per se is licensed hereunder. + +c) Recipient understands that although each Contributor grants the licenses to +its Contributions set forth herein, no assurances are provided by any +Contributor that the Program does not infringe the patent or other intellectual +property rights of any other entity. Each Contributor disclaims any liability to +Recipient for claims brought by any other entity based on infringement of +intellectual property rights or otherwise. As a condition to exercising the +rights and licenses granted hereunder, each Recipient hereby assumes sole +responsibility to secure any other intellectual property rights needed, if any. +For example, if a third party patent license is required to allow Recipient to +distribute the Program, it is Recipient's responsibility to acquire that license +before distributing the Program. + +d) Each Contributor represents that to its knowledge it has sufficient copyright +rights in its Contribution, if any, to grant the copyright license set forth in +this Agreement. + +3. REQUIREMENTS + +A Contributor may choose to distribute the Program in object code form under its +own license agreement, provided that: + +a) it complies with the terms and conditions of this Agreement; and + +b) its license agreement: + +i) effectively disclaims on behalf of all Contributors all warranties and +conditions, express and implied, including warranties or conditions of title and +non-infringement, and implied warranties or conditions of merchantability and +fitness for a particular purpose; + +ii) effectively excludes on behalf of all Contributors all liability for +damages, including direct, indirect, special, incidental and consequential +damages, such as lost profits; + +iii) states that any provisions which differ from this Agreement are offered by +that Contributor alone and not by any other party; and + +iv) states that source code for the Program is available from such Contributor, +and informs licensees how to obtain it in a reasonable manner on or through a +medium customarily used for software exchange. + +When the Program is made available in source code form: + +a) it must be made available under this Agreement; and + +b) a copy of this Agreement must be included with each copy of the Program. + +Contributors may not remove or alter any copyright notices contained within the +Program. + +Each Contributor must identify itself as the originator of its Contribution, if +any, in a manner that reasonably allows subsequent Recipients to identify the +originator of the Contribution. + +4. COMMERCIAL DISTRIBUTION + +Commercial distributors of software may accept certain responsibilities with +respect to end users, business partners and the like. While this license is +intended to facilitate the commercial use of the Program, the Contributor who +includes the Program in a commercial product offering should do so in a manner +which does not create potential liability for other Contributors. Therefore, if +a Contributor includes the Program in a commercial product offering, such +Contributor ("Commercial Contributor") hereby agrees to defend and indemnify +every other Contributor ("Indemnified Contributor") against any losses, damages +and costs (collectively "Losses") arising from claims, lawsuits and other legal +actions brought by a third party against the Indemnified Contributor to the +extent caused by the acts or omissions of such Commercial Contributor in +connection with its distribution of the Program in a commercial product +offering. The obligations in this section do not apply to any claims or Losses +relating to any actual or alleged intellectual property infringement. In order +to qualify, an Indemnified Contributor must: a) promptly notify the Commercial +Contributor in writing of such claim, and b) allow the Commercial Contributor to +control, and cooperate with the Commercial Contributor in, the defense and any +related settlement negotiations. The Indemnified Contributor may participate in +any such claim at its own expense. + +For example, a Contributor might include the Program in a commercial product +offering, Product X. That Contributor is then a Commercial Contributor. If that +Commercial Contributor then makes performance claims, or offers warranties +related to Product X, those performance claims and warranties are such +Commercial Contributor's responsibility alone. Under this section, the +Commercial Contributor would have to defend claims against the other +Contributors related to those performance claims and warranties, and if a court +requires any other Contributor to pay any damages as a result, the Commercial +Contributor must pay those damages. + +5. NO WARRANTY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN +"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR +IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, +NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each +Recipient is solely responsible for determining the appropriateness of using and +distributing the Program and assumes all risks associated with its exercise of +rights under this Agreement, including but not limited to the risks and costs of +program errors, compliance with applicable laws, damage to or loss of data, +programs or equipment, and unavailability or interruption of operations. + +6. DISCLAIMER OF LIABILITY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY +CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST +PROFITS), 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 OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS +GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +7. GENERAL + +If any provision of this Agreement is invalid or unenforceable under applicable +law, it shall not affect the validity or enforceability of the remainder of the +terms of this Agreement, and without further action by the parties hereto, such +provision shall be reformed to the minimum extent necessary to make such +provision valid and enforceable. + +If Recipient institutes patent litigation against a Contributor with respect to +a patent applicable to software (including a cross-claim or counterclaim in a +lawsuit), then any patent licenses granted by that Contributor to such Recipient +under this Agreement shall terminate as of the date such litigation is filed. In +addition, if Recipient institutes patent litigation against any entity +(including a cross-claim or counterclaim in a lawsuit) alleging that the Program +itself (excluding combinations of the Program with other software or hardware) +infringes such Recipient's patent(s), then such Recipient's rights granted under +Section 2(b) shall terminate as of the date such litigation is filed. + +All Recipient's rights under this Agreement shall terminate if it fails to +comply with any of the material terms or conditions of this Agreement and does +not cure such failure in a reasonable period of time after becoming aware of +such noncompliance. If all Recipient's rights under this Agreement terminate, +Recipient agrees to cease use and distribution of the Program as soon as +reasonably practicable. However, Recipient's obligations under this Agreement +and any licenses granted by Recipient relating to the Program shall continue and +survive. + +Everyone is permitted to copy and distribute copies of this Agreement, but in +order to avoid inconsistency the Agreement is copyrighted and may only be +modified in the following manner. The Agreement Steward reserves the right to +publish new versions (including revisions) of this Agreement from time to time. +No one other than the Agreement Steward has the right to modify this Agreement. +IBM is the initial Agreement Steward. IBM may assign the responsibility to serve +as the Agreement Steward to a suitable separate entity. Each new version of the +Agreement will be given a distinguishing version number. The Program (including +Contributions) may always be distributed subject to the version of the Agreement +under which it was received. In addition, after a new version of the Agreement +is published, Contributor may elect to distribute the Program (including its +Contributions) under the new version. Except as expressly stated in Sections +2(a) and 2(b) above, Recipient receives no rights or licenses to the +intellectual property of any Contributor under this Agreement, whether +expressly, by implication, estoppel or otherwise. All rights in the Program not +expressly granted under this Agreement are reserved. + +This Agreement is governed by the laws of the State of New York and the +intellectual property laws of the United States of America. No party to this +Agreement will bring a legal action under this Agreement more than one year +after the cause of action arose. Each party waives its rights to a jury trial in +any resulting litigation. + +Special exception for LZMA compression module + +Igor Pavlov and Amir Szekely, the authors of the LZMA compression module for +NSIS, expressly permit you to statically or dynamically link your code (or bind +by name) to the files from the LZMA compression module for NSIS without +subjecting your linked code to the terms of the Common Public license version +1.0. Any modifications or additions to files from the LZMA compression module +for NSIS, however, are subject to the terms of the Common Public License version +1.0. + + +For the following XML Schemas for Java EE Deployment Descriptors: + - javaee_5.xsd + - javaee_web_services_1_2.xsd + - javaee_web_services_client_1_2.xsd + - javaee_6.xsd + - javaee_web_services_1_3.xsd + - javaee_web_services_client_1_3.xsd + - jsp_2_2.xsd + - web-app_3_0.xsd + - web-common_3_0.xsd + - web-fragment_3_0.xsd + +COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.0 + +1. Definitions. + + 1.1. Contributor. means each individual or entity that creates or contributes + to the creation of Modifications. + + 1.2. Contributor Version. means the combination of the Original Software, + prior Modifications used by a Contributor (if any), and the + Modifications made by that particular Contributor. + + 1.3. Covered Software. means (a) the Original Software, or (b) Modifications, + or (c) the combination of files containing Original Software with files + containing Modifications, in each case including portions thereof. + + 1.4. Executable. means the Covered Software in any form other than Source + Code. + + 1.5. Initial Developer. means the individual or entity that first makes + Original Software available under this License. + + 1.6. Larger Work. means a work which combines Covered Software or portions + thereof with code not governed by the terms of this License. + + 1.7. License. means this document. + + 1.8. Licensable. means having the right to grant, to the maximum extent + possible, whether at the time of the initial grant or subsequently + acquired, any and all of the rights conveyed herein. + + 1.9. Modifications. means the Source Code and Executable form of any of the + following: + + A. Any file that results from an addition to, deletion from or + modification of the contents of a file containing Original Software + or previous Modifications; + + B. Any new file that contains any part of the Original Software or + previous Modification; or + + C. Any new file that is contributed or otherwise made available under + the terms of this License. + + 1.10. Original Software. means the Source Code and Executable form of + computer software code that is originally released under this License. + + 1.11. Patent Claims. means any patent claim(s), now owned or hereafter + acquired, including without limitation, method, process, and apparatus + claims, in any patent Licensable by grantor. + + 1.12. Source Code. means (a) the common form of computer software code in + which modifications are made and (b) associated documentation included + in or with such code. + + 1.13. You. (or .Your.) means an individual or a legal entity exercising + rights under, and complying with all of the terms of, this License. For + legal entities, .You. includes any entity which controls, is controlled + by, or is under common control with You. For purposes of this + definition, .control. means (a) the power, direct or indirect, to cause + the direction or management of such entity, whether by contract or + otherwise, or (b) ownership of more than fifty percent (50%) of the + outstanding shares or beneficial ownership of such entity. + +2. License Grants. + + 2.1. The Initial Developer Grant. + + Conditioned upon Your compliance with Section 3.1 below and subject to + third party intellectual property claims, the Initial Developer hereby + grants You a world-wide, royalty-free, non-exclusive license: + + (a) under intellectual property rights (other than patent or trademark) + Licensable by Initial Developer, to use, reproduce, modify, display, + perform, sublicense and distribute the Original Software (or + portions thereof), with or without Modifications, and/or as part of + a Larger Work; and + + (b) under Patent Claims infringed by the making, using or selling of + Original Software, to make, have made, use, practice, sell, and + offer for sale, and/or otherwise dispose of the Original Software + (or portions thereof). + + (c) The licenses granted in Sections 2.1(a) and (b) are effective on the + date Initial Developer first distributes or otherwise makes the + Original Software available to a third party under the terms of this + License. + + (d) Notwithstanding Section 2.1(b) above, no patent license is granted: + (1) for code that You delete from the Original Software, or (2) for + infringements caused by: (i) the modification of the Original + Software, or (ii) the combination of the Original Software with + other software or devices. + + 2.2. Contributor Grant. + + Conditioned upon Your compliance with Section 3.1 below and subject to third + party intellectual property claims, each Contributor hereby grants You a + world-wide, royalty-free, non-exclusive license: + + (a) under intellectual property rights (other than patent or trademark) + Licensable by Contributor to use, reproduce, modify, display, + perform, sublicense and distribute the Modifications created by such + Contributor (or portions thereof), either on an unmodified basis, + with other Modifications, as Covered Software and/or as part of a + Larger Work; and + + (b) under Patent Claims infringed by the making, using, or selling of + Modifications made by that Contributor either alone and/or in + combination with its Contributor Version (or portions of such + combination), to make, use, sell, offer for sale, have made, and/or + otherwise dispose of: (1) Modifications made by that Contributor (or + portions thereof); and (2) the combination of Modifications made by + that Contributor with its Contributor Version (or portions of such + combination). + + (c) The licenses granted in Sections 2.2(a) and 2.2(b) are effective on + the date Contributor first distributes or otherwise makes the + Modifications available to a third party. + + (d) Notwithstanding Section 2.2(b) above, no patent license is granted: + (1) for any code that Contributor has deleted from the Contributor + Version; (2) for infringements caused by: (i) third party + modifications of Contributor Version, or (ii) the combination of + Modifications made by that Contributor with other software (except + as part of the Contributor Version) or other devices; or (3) under + Patent Claims infringed by Covered Software in the absence of + Modifications made by that Contributor. + +3. Distribution Obligations. + + 3.1. Availability of Source Code. + Any Covered Software that You distribute or otherwise make available in + Executable form must also be made available in Source Code form and that + Source Code form must be distributed only under the terms of this License. + You must include a copy of this License with every copy of the Source Code + form of the Covered Software You distribute or otherwise make available. + You must inform recipients of any such Covered Software in Executable form + as to how they can obtain such Covered Software in Source Code form in a + reasonable manner on or through a medium customarily used for software + exchange. + + 3.2. Modifications. + The Modifications that You create or to which You contribute are governed + by the terms of this License. You represent that You believe Your + Modifications are Your original creation(s) and/or You have sufficient + rights to grant the rights conveyed by this License. + + 3.3. Required Notices. + You must include a notice in each of Your Modifications that identifies + You as the Contributor of the Modification. You may not remove or alter + any copyright, patent or trademark notices contained within the Covered + Software, or any notices of licensing or any descriptive text giving + attribution to any Contributor or the Initial Developer. + + 3.4. Application of Additional Terms. + You may not offer or impose any terms on any Covered Software in Source + Code form that alters or restricts the applicable version of this License + or the recipients. rights hereunder. You may choose to offer, and to + charge a fee for, warranty, support, indemnity or liability obligations to + one or more recipients of Covered Software. However, you may do so only on + Your own behalf, and not on behalf of the Initial Developer or any + Contributor. You must make it absolutely clear that any such warranty, + support, indemnity or liability obligation is offered by You alone, and + You hereby agree to indemnify the Initial Developer and every Contributor + for any liability incurred by the Initial Developer or such Contributor as + a result of warranty, support, indemnity or liability terms You offer. + + 3.5. Distribution of Executable Versions. + You may distribute the Executable form of the Covered Software under the + terms of this License or under the terms of a license of Your choice, + which may contain terms different from this License, provided that You are + in compliance with the terms of this License and that the license for the + Executable form does not attempt to limit or alter the recipient.s rights + in the Source Code form from the rights set forth in this License. If You + distribute the Covered Software in Executable form under a different + license, You must make it absolutely clear that any terms which differ + from this License are offered by You alone, not by the Initial Developer + or Contributor. You hereby agree to indemnify the Initial Developer and + every Contributor for any liability incurred by the Initial Developer or + such Contributor as a result of any such terms You offer. + + 3.6. Larger Works. + You may create a Larger Work by combining Covered Software with other code + not governed by the terms of this License and distribute the Larger Work + as a single product. In such a case, You must make sure the requirements + of this License are fulfilled for the Covered Software. + +4. Versions of the License. + + 4.1. New Versions. + Sun Microsystems, Inc. is the initial license steward and may publish + revised and/or new versions of this License from time to time. Each + version will be given a distinguishing version number. Except as provided + in Section 4.3, no one other than the license steward has the right to + modify this License. + + 4.2. Effect of New Versions. + You may always continue to use, distribute or otherwise make the Covered + Software available under the terms of the version of the License under + which You originally received the Covered Software. If the Initial + Developer includes a notice in the Original Software prohibiting it from + being distributed or otherwise made available under any subsequent version + of the License, You must distribute and make the Covered Software + available under the terms of the version of the License under which You + originally received the Covered Software. Otherwise, You may also choose + to use, distribute or otherwise make the Covered Software available under + the terms of any subsequent version of the License published by the + license steward. + + 4.3. Modified Versions. + When You are an Initial Developer and You want to create a new license for + Your Original Software, You may create and use a modified version of this + License if You: (a) rename the license and remove any references to the + name of the license steward (except to note that the license differs from + this License); and (b) otherwise make it clear that the license contains + terms which differ from this License. + +5. DISCLAIMER OF WARRANTY. + + COVERED SOFTWARE IS PROVIDED UNDER THIS LICENSE ON AN .AS IS. BASIS, WITHOUT + WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT + LIMITATION, WARRANTIES THAT THE COVERED SOFTWARE IS FREE OF DEFECTS, + MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR NON-INFRINGING. THE ENTIRE RISK + AS TO THE QUALITY AND PERFORMANCE OF THE COVERED SOFTWARE IS WITH YOU. SHOULD + ANY COVERED SOFTWARE PROVE DEFECTIVE IN ANY RESPECT, YOU (NOT THE INITIAL + DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY + SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN + ESSENTIAL PART OF THIS LICENSE. NO USE OF ANY COVERED SOFTWARE IS AUTHORIZED + HEREUNDER EXCEPT UNDER THIS DISCLAIMER. + +6. TERMINATION. + + 6.1. This License and the rights granted hereunder will terminate + automatically if You fail to comply with terms herein and fail to + cure such breach within 30 days of becoming aware of the breach. + Provisions which, by their nature, must remain in effect beyond the + termination of this License shall survive. + + 6.2. If You assert a patent infringement claim (excluding declaratory + judgment actions) against Initial Developer or a Contributor (the + Initial Developer or Contributor against whom You assert such claim + is referred to as .Participant.) alleging that the Participant + Software (meaning the Contributor Version where the Participant is a + Contributor or the Original Software where the Participant is the + Initial Developer) directly or indirectly infringes any patent, then + any and all rights granted directly or indirectly to You by such + Participant, the Initial Developer (if the Initial Developer is not + the Participant) and all Contributors under Sections 2.1 and/or 2.2 + of this License shall, upon 60 days notice from Participant terminate + prospectively and automatically at the expiration of such 60 day + notice period, unless if within such 60 day period You withdraw Your + claim with respect to the Participant Software against such + Participant either unilaterally or pursuant to a written agreement + with Participant. + + 6.3. In the event of termination under Sections 6.1 or 6.2 above, all end + user licenses that have been validly granted by You or any + distributor hereunder prior to termination (excluding licenses + granted to You by any distributor) shall survive termination. + +7. LIMITATION OF LIABILITY. + + UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT (INCLUDING + NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE INITIAL DEVELOPER, ANY + OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED SOFTWARE, OR ANY SUPPLIER OF + ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON FOR ANY INDIRECT, SPECIAL, + INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT + LIMITATION, DAMAGES FOR LOST PROFITS, LOSS OF GOODWILL, WORK STOPPAGE, + COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER COMMERCIAL DAMAGES OR + LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF THE POSSIBILITY OF + SUCH DAMAGES. THIS LIMITATION OF LIABILITY SHALL NOT APPLY TO LIABILITY FOR + DEATH OR PERSONAL INJURY RESULTING FROM SUCH PARTY.S NEGLIGENCE TO THE EXTENT + APPLICABLE LAW PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE + EXCLUSION OR LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS + EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU. + +8. U.S. GOVERNMENT END USERS. + + The Covered Software is a .commercial item,. as that term is defined in 48 + C.F.R. 2.101 (Oct. 1995), consisting of .commercial computer software. (as + that term is defined at 48 C.F.R. ? 252.227-7014(a)(1)) and commercial + computer software documentation. as such terms are used in 48 C.F.R. 12.212 + (Sept. 1995). Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 + through 227.7202-4 (June 1995), all U.S. Government End Users acquire Covered + Software with only those rights set forth herein. This U.S. Government Rights + clause is in lieu of, and supersedes, any other FAR, DFAR, or other clause or + provision that addresses Government rights in computer software under this + License. + +9. MISCELLANEOUS. + + This License represents the complete agreement concerning subject matter + hereof. If any provision of this License is held to be unenforceable, such + provision shall be reformed only to the extent necessary to make it + enforceable. This License shall be governed by the law of the jurisdiction + specified in a notice contained within the Original Software (except to the + extent applicable law, if any, provides otherwise), excluding such + jurisdiction's conflict-of-law provisions. Any litigation relating to this + License shall be subject to the jurisdiction of the courts located in the + jurisdiction and venue specified in a notice contained within the Original + Software, with the losing party responsible for costs, including, without + limitation, court costs and reasonable attorneys. fees and expenses. The + application of the United Nations Convention on Contracts for the + International Sale of Goods is expressly excluded. Any law or regulation + which provides that the language of a contract shall be construed against + the drafter shall not apply to this License. You agree that You alone are + responsible for compliance with the United States export administration + regulations (and the export control laws and regulation of any other + countries) when You use, distribute or otherwise make available any Covered + Software. + +10. RESPONSIBILITY FOR CLAIMS. + + As between Initial Developer and the Contributors, each party is responsible + for claims and damages arising, directly or indirectly, out of its + utilization of rights under this License and You agree to work with Initial + Developer and Contributors to distribute such responsibility on an equitable + basis. Nothing herein is intended or shall be deemed to constitute any + admission of liability. + + NOTICE PURSUANT TO SECTION 9 OF THE COMMON DEVELOPMENT AND DISTRIBUTION + LICENSE (CDDL) + + The code released under the CDDL shall be governed by the laws of the State + of California (excluding conflict-of-law provisions). Any litigation relating + to this License shall be subject to the jurisdiction of the Federal Courts of + the Northern District of California and the state courts of the State of + California, with venue lying in Santa Clara County, California. + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/NOTICE b/centos8_tomcat/apache-tomcat-7.0.108/NOTICE new file mode 100644 index 0000000..a782b4a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/NOTICE @@ -0,0 +1,38 @@ +Apache Tomcat +Copyright 1999-2021 The Apache Software Foundation + +This product includes software developed at +The Apache Software Foundation (https://www.apache.org/). + +The Windows Installer is built with the Nullsoft +Scriptable Install System (NSIS), which is +open source software. The original software and +related information is available at +http://nsis.sourceforge.net. + +Java compilation software for JSP pages is provided by the Eclipse +JDT Core Batch Compiler component, which is open source software. +The original software and related information is available at +https://www.eclipse.org/jdt/core/. + +For the bayeux implementation +The org.apache.cometd.bayeux API is derivative work originating at the Dojo Foundation +* Copyright 2007-2008 Guy Molinari +* Copyright 2007-2008 Filip Hanik +* Copyright 2007 Dojo Foundation +* Copyright 2007 Mort Bay Consulting Pty. Ltd. + +The original XML Schemas for Java EE Deployment Descriptors: + - javaee_5.xsd + - javaee_web_services_1_2.xsd + - javaee_web_services_client_1_2.xsd + - javaee_6.xsd + - javaee_web_services_1_3.xsd + - javaee_web_services_client_1_3.xsd + - jsp_2_2.xsd + - web-app_3_0.xsd + - web-common_3_0.xsd + - web-fragment_3_0.xsd + +may be obtained from: +http://www.oracle.com/webfolder/technetwork/jsc/xml/ns/javaee/index.html diff --git a/centos8_tomcat/apache-tomcat-7.0.108/README.md b/centos8_tomcat/apache-tomcat-7.0.108/README.md new file mode 100644 index 0000000..9a8e002 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/README.md @@ -0,0 +1,79 @@ +## Welcome to Apache Tomcat! + +### What Is It? + +The Apache Tomcat® software is an open source implementation of the Java +Servlet, JavaServer Pages, Java Expression Language and Java WebSocket +technologies. The Java Servlet, JavaServer Pages, Java Expression Language and +Java WebSocket specifications are developed under the +[Java Community Process](https://jcp.org/en/introduction/overview). + +The Apache Tomcat software is developed in an open and participatory +environment and released under the +[Apache License version 2](https://www.apache.org/licenses/). The Apache Tomcat +project is intended to be a collaboration of the best-of-breed developers from +around the world. We invite you to participate in this open development +project. To learn more about getting involved, +[click here](https://tomcat.apache.org/getinvolved.html) or keep reading. + +Apache Tomcat software powers numerous large-scale, mission-critical web +applications across a diverse range of industries and organizations. Some of +these users and their stories are listed on the +[PoweredBy wiki page](https://wiki.apache.org/tomcat/PoweredBy). + +Apache Tomcat, Tomcat, Apache, the Apache feather, and the Apache Tomcat +project logo are trademarks of the Apache Software Foundation. + +### Get It + +For every major Tomcat version there is one download page containing +links to the latest binary and source code downloads, but also +links for browsing the download directories and archives: +- [Tomcat 9](https://tomcat.apache.org/download-90.cgi) +- [Tomcat 8](https://tomcat.apache.org/download-80.cgi) +- [Tomcat 7](https://tomcat.apache.org/download-70.cgi) + +To facilitate choosing the right major Tomcat version one, we have provided a +[version overview page](https://tomcat.apache.org/whichversion.html). + +### Documentation + +The documentation available as of the date of this release is +included in the docs webapp which ships with tomcat. You can access that webapp +by starting tomcat and visiting in your browser. +The most up-to-date documentation for each version can be found at: +- [Tomcat 9](https://tomcat.apache.org/tomcat-9.0-doc/) +- [Tomcat 8](https://tomcat.apache.org/tomcat-8.5-doc/) +- [Tomcat 7](https://tomcat.apache.org/tomcat-7.0-doc/) + +### Installation + +Please see [RUNNING.txt](RUNNING.txt) for more info. + +### Licensing + +Please see [LICENSE](LICENSE) for more info. + +### Support and Mailing List Information + +* Free community support is available through the +[tomcat-users](https://tomcat.apache.org/lists.html#tomcat-users) email list and +a dedicated [IRC channel](https://tomcat.apache.org/irc.html) (#tomcat on +Freenode). + +* If you want freely available support for running Apache Tomcat, please see the +resources page [here](https://tomcat.apache.org/findhelp.html). + +* If you want to be informed about new code releases, bug fixes, +security fixes, general news and information about Apache Tomcat, please +subscribe to the +[tomcat-announce](https://tomcat.apache.org/lists.html#tomcat-announce) email +list. + +* If you have a concrete bug report for Apache Tomcat, please see the +instructions for reporting a bug +[here](https://tomcat.apache.org/bugreport.html). + +### Contributing + +Please see [CONTRIBUTING](CONTRIBUTING.md) for more info. diff --git a/centos8_tomcat/apache-tomcat-7.0.108/RELEASE-NOTES b/centos8_tomcat/apache-tomcat-7.0.108/RELEASE-NOTES new file mode 100644 index 0000000..c4582d1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/RELEASE-NOTES @@ -0,0 +1,237 @@ +================================================================================ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +================================================================================ + + + Apache Tomcat Version 7.0.108 + Release Notes + + +========= +CONTENTS: +========= + +* Dependency Changes +* API Stability +* JNI Based Applications +* Bundled APIs +* Web application reloading and static fields in shared libraries +* Tomcat on Linux +* Enabling SSI and CGI Support +* Security manager URLs +* Symlinking static resources +* Viewing the Tomcat Change Log +* Cryptographic software notice +* When all else fails + + +=================== +Dependency Changes: +=================== +Tomcat 7.0 is designed to run on Java 6 and later. + +In addition, Tomcat 7.0 uses the Eclipse JDT Java compiler for +compiling JSP pages. This means you no longer need to have the complete +Java Development Kit (JDK) to run Tomcat, but a Java Runtime Environment +(JRE) is sufficient. The Eclipse JDT Java compiler is bundled with the +binary Tomcat distributions. Tomcat can also be configured to use the +compiler from the JDK to compile JSPs, or any other Java compiler supported +by Apache Ant. + + +============== +API Stability: +============== +The public interfaces for the following classes are fixed and will not be +changed at all during the remaining lifetime of the 7.x series: +- javax/**/* + +The public interfaces for the following classes may be added to in order to +resolve bugs and/or add new features. No existing interface will be removed or +changed although it may be deprecated. +- org/apache/catalina/* +- org/apache/catalina/comet/* + +Note: As Tomcat 7 matures, the above list will be added to. The list is not + considered complete at this time. + +The remaining classes are considered part of the Tomcat internals and may change +without notice between point releases. + + +======================= +JNI Based Applications: +======================= +Applications that require native libraries must ensure that the libraries have +been loaded prior to use. Typically, this is done with a call like: + + static { + System.loadLibrary("path-to-library-file"); + } + +in some class. However, the application must also ensure that the library is +not loaded more than once. If the above code were placed in a class inside +the web application (i.e. under /WEB-INF/classes or /WEB-INF/lib), and the +application were reloaded, the loadLibrary() call would be attempted a second +time. + +To avoid this problem, place classes that load native libraries outside of the +web application, and ensure that the loadLibrary() call is executed only once +during the lifetime of a particular JVM. + + +============= +Bundled APIs: +============= +A standard installation of Tomcat 7.0 makes all of the following APIs available +for use by web applications (by placing them in "lib"): +* annotations-api.jar (Common Annotations 1.1 package) +* catalina.jar (Tomcat Catalina implementation) +* catalina-ant.jar (Tomcat Catalina Ant tasks) +* catalina-ha.jar (High availability package) +* catalina-tribes.jar (Group communication) +* ecj-4.4.2.jar (Eclipse JDT Java compiler) +* el-api.jar (EL 2.2 API) +* jasper.jar (Jasper 2 Compiler and Runtime) +* jasper-el.jar (Jasper 2 EL implementation) +* jsp-api.jar (JSP 2.2 API) +* servlet-api.jar (Servlet 3.0 API) +* tomcat7-websocket.jar (WebSocket 1.1 implementation) +* tomcat-api.jar (Interfaces shared by Catalina and Jasper) +* tomcat-coyote.jar (Tomcat connectors and utility classes) +* tomcat-dbcp.jar (package renamed database connection pool based on Commons DBCP 1.x) +* tomcat-jdbc.jar (Tomcat's database connection pooling solution) +* tomcat-util.jar (Various utilities) +* websocket-api.jar (WebSocket 1.1 API) + +You can make additional APIs available to all of your web applications by +putting unpacked classes into a "classes" directory (not created by default), +or by placing them in JAR files in the "lib" directory. + +To override the XML parser implementation or interfaces, use the Endorsed +Standards Override mechanism of the JVM. The default configuration defines +JARs located in "$CATALINA_HOME/endorsed" as endorsed. This mechanism is +no longer supported with Java 9. + +When running on Java 6, the Common Annotations 1.0 implementation provided +by the JRE will be used. To use the Common Annotations 1.1 provided by +Tomcat, use the Endorsed Standards Override mechanism of the JVM. The +default configuration defines JARs located in "$CATALINA_HOME/endorsed" as +endorsed. + + +================================================================ +Web application reloading and static fields in shared libraries: +================================================================ +Some shared libraries (many are part of the JDK) keep references to objects +instantiated by the web application. To avoid class loading related problems +(ClassCastExceptions, messages indicating that the classloader +is stopped, etc.), the shared libraries state should be reinitialized. + +Something which might help is to avoid putting classes which would be +referenced by a shared static field in the web application classloader, +and putting them in the shared classloader instead (JARs should be put in the +"lib" folder, and classes should be put in the "classes" folder). + + +================ +Tomcat on Linux: +================ +GLIBC 2.2 / Linux 2.4 users should define an environment variable: +export LD_ASSUME_KERNEL=2.2.5 + +Redhat Linux 9.0 users should use the following setting to avoid +stability problems: +export LD_ASSUME_KERNEL=2.4.1 + +There are some Linux bugs reported against the NIO sendfile behavior, make sure you +have a JDK that is up to date, or disable sendfile behavior in the Connector.
+6427312: (fc) FileChannel.transferTo() throws IOException "system call interrupted"
+5103988: (fc) FileChannel.transferTo should return -1 for EAGAIN instead throws IOException
+6253145: (fc) FileChannel.transferTo on Linux fails when going beyond 2GB boundary
+6470086: (fc) FileChannel.transferTo(2147483647, 1, channel) cause "Value too large" exception
+ + +============================= +Enabling SSI and CGI Support: +============================= +Because of the security risks associated with CGI and SSI available +to web applications, these features are disabled by default. + +To enable and configure CGI support, please see the cgi-howto.html page. + +To enable and configure SSI support, please see the ssi-howto.html page. + + +====================== +Security manager URLs: +====================== +In order to grant security permissions to JARs located inside the +web application repository, use URLs of the following format +in your policy file: + +file:${catalina.base}/webapps/examples/WEB-INF/lib/driver.jar + + +============================ +Symlinking static resources: +============================ +By default, Unix symlinks will not work when used in a web application to link +resources located outside the web application root directory. + +This behavior is optional, and the "allowLinking" flag may be used to disable +the check. + + +============================== +Viewing the Tomcat Change Log: +============================== +See changelog.html in this directory. + + +============================= +Cryptographic software notice +============================= +This distribution includes cryptographic software. The country in +which you currently reside may have restrictions on the import, +possession, use, and/or re-export to another country, of +encryption software. BEFORE using any encryption software, please +check your country's laws, regulations and policies concerning the +import, possession, or use, and re-export of encryption software, to +see if this is permitted. See for more +information. + +The U.S. Government Department of Commerce, Bureau of Industry and +Security (BIS), has classified this software as Export Commodity +Control Number (ECCN) 5D002.C.1, which includes information security +software using or performing cryptographic functions with asymmetric +algorithms. The form and manner of this Apache Software Foundation +distribution makes it eligible for export under the License Exception +ENC Technology Software Unrestricted (TSU) exception (see the BIS +Export Administration Regulations, Section 740.13) for both object +code and source code. + +The following provides more details on the included cryptographic +software: + - Tomcat includes code designed to work with JSSE + - Tomcat includes code designed to work with OpenSSL + + +==================== +When all else fails: +==================== +See the FAQ +https://tomcat.apache.org/faq/ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/RUNNING.txt b/centos8_tomcat/apache-tomcat-7.0.108/RUNNING.txt new file mode 100644 index 0000000..f66f9ae --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/RUNNING.txt @@ -0,0 +1,493 @@ +================================================================================ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +================================================================================ + + =================================================== + Running The Apache Tomcat 7.0 Servlet/JSP Container + =================================================== + +Apache Tomcat 7.0 requires a Java Standard Edition Runtime +Environment (JRE) version 6 or later. + +============================= +Running With JRE 6 Or Later +============================= + +(1) Download and Install a Java SE Runtime Environment (JRE) + +(1.1) Download a Java SE Runtime Environment (JRE), + release version 6 or later, from + http://www.oracle.com/technetwork/java/javase/downloads/index.html + + NOTE: Java WebSocket API (JSR-356) is supported only when running + with Java 7 or later. + +(1.2) Install the JRE according to the instructions included with the + release. + + You may also use a full Java Development Kit (JDK) rather than just + a JRE. + +(1.3) When running on Java 6, the Common Annotations 1.0 implementation + provided by the JRE will be used. To use the Common Annotations 1.1 + provided by Tomcat, use the Endorsed Standards Override mechanism + of the JVM. The default configuration defines JARs located in + "$CATALINA_HOME/endorsed" as endorsed. + + NOTE: Java 6 includes a subset of Common Annotations 1.0 classes. + + The only known difference between versions 1.0 and 1.1 of those + classes is introduction of "lookup" element on Resource annotation. + + Majority of web applications will not notice the difference. + +(2) Download and Install Apache Tomcat + +(2.1) Download a binary distribution of Tomcat from: + + https://tomcat.apache.org/ + +(2.2) Unpack the binary distribution so that it resides in its own + directory (conventionally named "apache-tomcat-[version]"). + + For the purposes of the remainder of this document, the name + "CATALINA_HOME" is used to refer to the full pathname of that + directory. + +NOTE: As an alternative to downloading a binary distribution, you can +create your own from the Tomcat source code, as described in +"BUILDING.txt". You can either + + a) Do the full "release" build and find the created distribution in the + "output/release" directory and then proceed with unpacking as above, or + + b) Do a simple build and use the "output/build" directory as + "CATALINA_HOME". Be warned that there are some differences between the + contents of the "output/build" directory and a full "release" + distribution. + + +(3) Configure Environment Variables + +Tomcat is a Java application and does not use environment variables directly. +Environment variables are used by the Tomcat startup scripts. The scripts use +the environment variables to prepare the command that starts Tomcat. + +(3.1) Set CATALINA_HOME (required) and CATALINA_BASE (optional) + +The CATALINA_HOME environment variable should be set to the location of the +root directory of the "binary" distribution of Tomcat. + +The Tomcat startup scripts have some logic to set this variable +automatically if it is absent, based on the location of the startup script +in *nix and on the current directory in Windows. That logic might not work +in all circumstances, so setting the variable explicitly is recommended. + +The CATALINA_BASE environment variable specifies location of the root +directory of the "active configuration" of Tomcat. It is optional. It +defaults to be equal to CATALINA_HOME. + +Using distinct values for the CATALINA_HOME and CATALINA_BASE variables is +recommended to simplify further upgrades and maintenance. It is documented +in the "Multiple Tomcat Instances" section below. + + +(3.2) Set JRE_HOME or JAVA_HOME (required) + +These variables are used to specify location of a Java Runtime +Environment or of a Java Development Kit that is used to start Tomcat. + +The JRE_HOME variable is used to specify location of a JRE. The JAVA_HOME +variable is used to specify location of a JDK. + +Using JAVA_HOME provides access to certain additional startup options that +are not allowed when JRE_HOME is used. + +If both JRE_HOME and JAVA_HOME are specified, JRE_HOME is used. + +The recommended place to specify these variables is a "setenv" script. See +below. + + +(3.3) Other variables (optional) + +Other environment variables exist, besides the four described above. +See the comments at the top of catalina.bat or catalina.sh scripts for +the list and a description of each of them. + +One frequently used variable is CATALINA_OPTS. It allows specification of +additional options for the java command that starts Tomcat. + +See the Java documentation for the options that affect the Java Runtime +Environment. + +See the "System Properties" page in the Tomcat Configuration Reference for +the system properties that are specific to Tomcat. + +A similar variable is JAVA_OPTS. It is used less frequently. It allows +specification of options that are used both to start and to stop Tomcat as well +as for other commands. + +Note: Do not use JAVA_OPTS to specify memory limits. You do not need much +memory for a small process that is used to stop Tomcat. Those settings +belong to CATALINA_OPTS. + +Another frequently used variable is CATALINA_PID (on *nix only). It +specifies the location of the file where process id of the forked Tomcat +java process will be written. This setting is optional. It will enable the +following features: + + * better protection against duplicate start attempts and + * allows forceful termination of Tomcat process when it does not react to + the standard shutdown command. + + +(3.4) Using the "setenv" script (optional, recommended) + +Apart from CATALINA_HOME and CATALINA_BASE, all environment variables can +be specified in the "setenv" script. The script is placed either into +CATALINA_BASE/bin or into CATALINA_HOME/bin directory and is named +setenv.bat (on Windows) or setenv.sh (on *nix). The file has to be +readable. + +By default the setenv script file is absent. If the script file is present +both in CATALINA_BASE and in CATALINA_HOME, the one in CATALINA_BASE is +preferred. + +For example, to configure the JRE_HOME and CATALINA_PID variables you can +create the following script file: + +On Windows, %CATALINA_BASE%\bin\setenv.bat: + + set "JRE_HOME=%ProgramFiles%\Java\jre6" + exit /b 0 + +On *nix, $CATALINA_BASE/bin/setenv.sh: + + JRE_HOME=/usr/java/latest + CATALINA_PID="$CATALINA_BASE/tomcat.pid" + + +The CATALINA_HOME and CATALINA_BASE variables cannot be configured in the +setenv script, because they are used to locate that file. + +All the environment variables described here and the "setenv" script are +used only if you use the standard scripts to launch Tomcat. For example, if +you have installed Tomcat as a service on Windows, the service wrapper +launches Java directly and does not use the script files. + + +(4) Start Up Tomcat + +(4.1) Tomcat can be started by executing one of the following commands: + + On Windows: + + %CATALINA_HOME%\bin\startup.bat + + or + + %CATALINA_HOME%\bin\catalina.bat start + + On *nix: + + $CATALINA_HOME/bin/startup.sh + + or + + $CATALINA_HOME/bin/catalina.sh start + +(4.2) After startup, the default web applications included with Tomcat will be + available by visiting: + + http://localhost:8080/ + +(4.3) Further information about configuring and running Tomcat can be found in + the documentation included here, as well as on the Tomcat web site: + + https://tomcat.apache.org/ + + +(5) Shut Down Tomcat + +(5.1) Tomcat can be shut down by executing one of the following commands: + + On Windows: + + %CATALINA_HOME%\bin\shutdown.bat + + or + + %CATALINA_HOME%\bin\catalina.bat stop + + On *nix: + + $CATALINA_HOME/bin/shutdown.sh + + or + + $CATALINA_HOME/bin/catalina.sh stop + +================================================== +Advanced Configuration - Multiple Tomcat Instances +================================================== + +In many circumstances, it is desirable to have a single copy of a Tomcat +binary distribution shared among multiple users on the same server. To make +this possible, you can set the CATALINA_BASE environment variable to the +directory that contains the files for your 'personal' Tomcat instance. + +When running with a separate CATALINA_HOME and CATALINA_BASE, the files +and directories are split as following: + +In CATALINA_BASE: + + * bin - Only the following files: + + * setenv.sh (*nix) or setenv.bat (Windows), + * tomcat-juli.jar + + The setenv scripts were described above. The tomcat-juli library + is documented in the Logging chapter in the User Guide. + + * conf - Server configuration files (including server.xml) + + * lib - Libraries and classes, as explained below + + * logs - Log and output files + + * webapps - Automatically loaded web applications + + * work - Temporary working directories for web applications + + * temp - Directory used by the JVM for temporary files (java.io.tmpdir) + + +In CATALINA_HOME: + + * bin - Startup and shutdown scripts + + The following files will be used only if they are absent in + CATALINA_BASE/bin: + + setenv.sh (*nix), setenv.bat (Windows), tomcat-juli.jar + + * lib - Libraries and classes, as explained below + + * endorsed - Libraries that override standard "Endorsed Standards" + libraries provided by JRE. See Classloading documentation + in the User Guide for details. + No longer supported with Java 9. + + By default this "endorsed" directory is absent. + +In the default configuration the JAR libraries and classes both in +CATALINA_BASE/lib and in CATALINA_HOME/lib will be added to the common +classpath, but the ones in CATALINA_BASE will be added first and thus will +be searched first. + +The idea is that you may leave the standard Tomcat libraries in +CATALINA_HOME/lib and add other ones such as database drivers into +CATALINA_BASE/lib. + +In general it is advised to never share libraries between web applications, +but put them into WEB-INF/lib directories inside the applications. See +Classloading documentation in the User Guide for details. + + +It might be useful to note that the values of CATALINA_HOME and +CATALINA_BASE can be referenced in the XML configuration files processed +by Tomcat as ${catalina.home} and ${catalina.base} respectively. + +For example, the standard manager web application can be kept in +CATALINA_HOME/webapps/manager and loaded into CATALINA_BASE by copying +its deployment descriptor into the desired virtual host: + + * Copy the CATALINA_HOME/webapps/manager/META-INF/context.xml + file as CATALINA_BASE/conf/Catalina/localhost/manager.xml + + * Add docBase attribute as shown below. + +The file will look like the following: + + + + + + + +See Deployer chapter in User Guide and Context and Host chapters in the +Configuration Reference for more information on contexts and web +application deployment. + + +================ +Troubleshooting +================ + +There are only really 2 things likely to go wrong during the stand-alone +Tomcat install: + +(1) The most common hiccup is when another web server (or any process for that + matter) has laid claim to port 8080. This is the default HTTP port that + Tomcat attempts to bind to at startup. To change this, open the file: + + $CATALINA_HOME/conf/server.xml + + and search for '8080'. Change it to a port that isn't in use, and is + greater than 1024, as ports less than or equal to 1024 require superuser + access to bind under UNIX. + + Restart Tomcat and you're in business. Be sure that you replace the "8080" + in the URL you're using to access Tomcat. For example, if you change the + port to 1977, you would request the URL http://localhost:1977/ in your + browser. + +(2) The 'localhost' machine isn't found. This could happen if you're behind a + proxy. If that's the case, make sure the proxy configuration for your + browser knows that you shouldn't be going through the proxy to access the + "localhost". + + In Firefox, this is under Tools/Preferences -> Advanced/Network -> + Connection -> Settings..., and in Internet Explorer it is Tools -> + Internet Options -> Connections -> LAN Settings. + + +==================== +Optional Components +==================== + +The following optional components may be included with the Apache Tomcat binary +distribution. If they are not included, you can install them separately. + + 1. Apache Tomcat Native library + + 2. Apache Commons Daemon service launcher + +Both of them are implemented in C language and as such have to be compiled +into binary code. The binary code will be specific for a platform and CPU +architecture and it must match the Java Runtime Environment executables +that will be used to launch Tomcat. + +The Windows-specific binary distributions of Apache Tomcat include binary +files for these components. On other platforms you would have to look for +binary versions elsewhere or compile them yourself. + +If you are new to Tomcat, do not bother with these components to start with. +If you do use them, do not forget to read their documentation. + + +Apache Tomcat Native library +----------------------------- + +It is a library that allows to use the "Apr" variant of HTTP and AJP +protocol connectors in Apache Tomcat. It is built around OpenSSL and Apache +Portable Runtime (APR) libraries. Those are the same libraries as used by +Apache HTTPD Server project. + +This feature was especially important in the old days when Java performance +was poor. It is less important nowadays, but it is still used and respected +by many. See Tomcat documentation for more details. + +For further reading: + + - Apache Tomcat documentation + + * Documentation for APR/Native library in the Tomcat User's Guide + + https://tomcat.apache.org/tomcat-7.0-doc/apr.html + + * Documentation for the HTTP and AJP protocol connectors in the Tomcat + Configuration Reference + + https://tomcat.apache.org/tomcat-7.0-doc/config/http.html + + https://tomcat.apache.org/tomcat-7.0-doc/config/ajp.html + + - Apache Tomcat Native project home + + https://tomcat.apache.org/native-doc/ + + - Other projects + + * OpenSSL + + https://www.openssl.org/ + + * Apache Portable Runtime + + https://apr.apache.org/ + + * Apache HTTP Server + + https://httpd.apache.org/ + +To disable Apache Tomcat Native library: + + - To disable Apache Tomcat Native library when it is installed, or + - To remove the warning that is logged during Tomcat startup when the + library is not installed: + + Edit the "conf/server.xml" file and remove "AprLifecycleListener" from + it. + +The binary file of Apache Tomcat Native library is usually named + + - "tcnative-1.dll" on Windows + - "libtcnative-1.so" on *nix systems + + +Apache Commons Daemon +---------------------- + +Apache Commons Daemon project provides wrappers that can be used to +install Apache Tomcat as a service on Windows or as a daemon on *nix +systems. + +The Windows-specific implementation of Apache Commons Daemon is called +"procrun". The *nix-specific one is called "jsvc". + +For further reading: + + - Apache Commons Daemon project + + https://commons.apache.org/daemon/ + + - Apache Tomcat documentation + + * Installing Apache Tomcat + + https://tomcat.apache.org/tomcat-7.0-doc/setup.html + + * Windows service HOW-TO + + https://tomcat.apache.org/tomcat-7.0-doc/windows-service-howto.html + +The binary files of Apache Commons Daemon in Apache Tomcat distributions +for Windows are named: + + - "tomcat7.exe" + - "tomcat7w.exe" + +These files are renamed copies of "prunsrv.exe" and "prunmgr.exe" from +Apache Commons Daemon distribution. The file names have a meaning: they are +used as the service name to register the service in Windows, as well as the +key name to store distinct configuration for this installation of +"procrun". If you would like to install several instances of Tomcat 7.0 +in parallel, you have to further rename those files, using the same naming +scheme. diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/bootstrap.jar b/centos8_tomcat/apache-tomcat-7.0.108/bin/bootstrap.jar new file mode 100644 index 0000000..ee42b90 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/bin/bootstrap.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina-tasks.xml b/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina-tasks.xml new file mode 100644 index 0000000..c7c9c28 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina-tasks.xml @@ -0,0 +1,39 @@ + + + + + + Catalina Ant Manager, JMX and JSPC Tasks + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina.bat b/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina.bat new file mode 100644 index 0000000..0acd52e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina.bat @@ -0,0 +1,385 @@ +@echo off +rem Licensed to the Apache Software Foundation (ASF) under one or more +rem contributor license agreements. See the NOTICE file distributed with +rem this work for additional information regarding copyright ownership. +rem The ASF licenses this file to You under the Apache License, Version 2.0 +rem (the "License"); you may not use this file except in compliance with +rem the License. You may obtain a copy of the License at +rem +rem http://www.apache.org/licenses/LICENSE-2.0 +rem +rem Unless required by applicable law or agreed to in writing, software +rem distributed under the License is distributed on an "AS IS" BASIS, +rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +rem See the License for the specific language governing permissions and +rem limitations under the License. + +rem --------------------------------------------------------------------------- +rem Start/Stop Script for the CATALINA Server +rem +rem For supported commands call "catalina.bat help" or see the usage section +rem towards the end of this file. +rem +rem Environment Variable Prerequisites +rem +rem Do not set the variables in this script. Instead put them into a script +rem setenv.bat in CATALINA_BASE/bin to keep your customizations separate. +rem +rem WHEN RUNNING TOMCAT AS A WINDOWS SERVICE: +rem Note that the environment variables that affect the behavior of this +rem script will have no effect at all on Windows Services. As such, any +rem local customizations made in a CATALINA_BASE/bin/setenv.bat script +rem will also have no effect on Tomcat when launched as a Windows Service. +rem The configuration that controls Windows Services is stored in the Windows +rem Registry, and is most conveniently maintained using the "tomcat7w.exe" +rem maintenance utility. +rem +rem CATALINA_HOME May point at your Catalina "build" directory. +rem +rem CATALINA_BASE (Optional) Base directory for resolving dynamic portions +rem of a Catalina installation. If not present, resolves to +rem the same directory that CATALINA_HOME points to. +rem +rem CATALINA_OPTS (Optional) Java runtime options used when the "start", +rem "run" or "debug" command is executed. +rem Include here and not in JAVA_OPTS all options, that should +rem only be used by Tomcat itself, not by the stop process, +rem the version command etc. +rem Examples are heap size, GC logging, JMX ports etc. +rem +rem CATALINA_TMPDIR (Optional) Directory path location of temporary directory +rem the JVM should use (java.io.tmpdir). Defaults to +rem %CATALINA_BASE%\temp. +rem +rem JAVA_HOME Must point at your Java Development Kit installation. +rem Required to run the with the "debug" argument. +rem +rem JRE_HOME Must point at your Java Runtime installation. +rem Defaults to JAVA_HOME if empty. If JRE_HOME and JAVA_HOME +rem are both set, JRE_HOME is used. +rem +rem JAVA_OPTS (Optional) Java runtime options used when any command +rem is executed. +rem Include here and not in CATALINA_OPTS all options, that +rem should be used by Tomcat and also by the stop process, +rem the version command etc. +rem Most options should go into CATALINA_OPTS. +rem +rem JAVA_ENDORSED_DIRS (Optional) Lists of of semi-colon separated directories +rem containing some jars in order to allow replacement of APIs +rem created outside of the JCP (i.e. DOM and SAX from W3C). +rem It can also be used to update the XML parser implementation. +rem This is only supported for Java <= 8. +rem Defaults to $CATALINA_HOME/endorsed. +rem +rem JPDA_TRANSPORT (Optional) JPDA transport used when the "jpda start" +rem command is executed. The default is "dt_socket". +rem +rem JPDA_ADDRESS (Optional) Java runtime options used when the "jpda start" +rem command is executed. The default is localhost:8000. +rem +rem JPDA_SUSPEND (Optional) Java runtime options used when the "jpda start" +rem command is executed. Specifies whether JVM should suspend +rem execution immediately after startup. Default is "n". +rem +rem JPDA_OPTS (Optional) Java runtime options used when the "jpda start" +rem command is executed. If used, JPDA_TRANSPORT, JPDA_ADDRESS, +rem and JPDA_SUSPEND are ignored. Thus, all required jpda +rem options MUST be specified. The default is: +rem +rem -agentlib:jdwp=transport=%JPDA_TRANSPORT%, +rem address=%JPDA_ADDRESS%,server=y,suspend=%JPDA_SUSPEND% +rem +rem JSSE_OPTS (Optional) Java runtime options used to control the TLS +rem implementation when JSSE is used. Default is: +rem "-Djdk.tls.ephemeralDHKeySize=2048" +rem +rem CATALINA_LOGGING_CONFIG (Optional) Override Tomcat's logging config file +rem Example (all one line) +rem set CATALINA_LOGGING_CONFIG="-Djava.util.logging.config.file=%CATALINA_BASE%\conf\logging.properties" +rem +rem LOGGING_CONFIG Deprecated +rem Use CATALINA_LOGGING_CONFIG +rem This is only used if CATALINA_LOGGING_CONFIG is not set +rem and LOGGING_CONFIG starts with "-D..." +rem +rem LOGGING_MANAGER (Optional) Override Tomcat's logging manager +rem Example (all one line) +rem set LOGGING_MANAGER="-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager" +rem +rem TITLE (Optional) Specify the title of Tomcat window. The default +rem TITLE is Tomcat if it's not specified. +rem Example (all one line) +rem set TITLE=Tomcat.Cluster#1.Server#1 [%DATE% %TIME%] +rem --------------------------------------------------------------------------- + +setlocal + +rem Suppress Terminate batch job on CTRL+C +if not ""%1"" == ""run"" goto mainEntry +if "%TEMP%" == "" goto mainEntry +if exist "%TEMP%\%~nx0.run" goto mainEntry +echo Y>"%TEMP%\%~nx0.run" +if not exist "%TEMP%\%~nx0.run" goto mainEntry +echo Y>"%TEMP%\%~nx0.Y" +call "%~f0" %* <"%TEMP%\%~nx0.Y" +rem Use provided errorlevel +set RETVAL=%ERRORLEVEL% +del /Q "%TEMP%\%~nx0.Y" >NUL 2>&1 +exit /B %RETVAL% +:mainEntry +del /Q "%TEMP%\%~nx0.run" >NUL 2>&1 + +rem Guess CATALINA_HOME if not defined +set "CURRENT_DIR=%cd%" +if not "%CATALINA_HOME%" == "" goto gotHome +set "CATALINA_HOME=%CURRENT_DIR%" +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +cd .. +set "CATALINA_HOME=%cd%" +cd "%CURRENT_DIR%" +:gotHome + +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +echo The CATALINA_HOME environment variable is not defined correctly +echo This environment variable is needed to run this program +goto end +:okHome + +rem Copy CATALINA_BASE from CATALINA_HOME if not defined +if not "%CATALINA_BASE%" == "" goto gotBase +set "CATALINA_BASE=%CATALINA_HOME%" +:gotBase + +rem Ensure that neither CATALINA_HOME nor CATALINA_BASE contains a semi-colon +rem as this is used as the separator in the classpath and Java provides no +rem mechanism for escaping if the same character appears in the path. Check this +rem by replacing all occurrences of ';' with '' and checking that neither +rem CATALINA_HOME nor CATALINA_BASE have changed +if "%CATALINA_HOME%" == "%CATALINA_HOME:;=%" goto homeNoSemicolon +echo Using CATALINA_HOME: "%CATALINA_HOME%" +echo Unable to start as CATALINA_HOME contains a semicolon (;) character +goto end +:homeNoSemicolon + +if "%CATALINA_BASE%" == "%CATALINA_BASE:;=%" goto baseNoSemicolon +echo Using CATALINA_BASE: "%CATALINA_BASE%" +echo Unable to start as CATALINA_BASE contains a semicolon (;) character +goto end +:baseNoSemicolon + +rem Ensure that any user defined CLASSPATH variables are not used on startup, +rem but allow them to be specified in setenv.bat, in rare case when it is needed. +set CLASSPATH= + +rem Get standard environment variables +if not exist "%CATALINA_BASE%\bin\setenv.bat" goto checkSetenvHome +call "%CATALINA_BASE%\bin\setenv.bat" +goto setenvDone +:checkSetenvHome +if exist "%CATALINA_HOME%\bin\setenv.bat" call "%CATALINA_HOME%\bin\setenv.bat" +:setenvDone + +rem Get standard Java environment variables +if exist "%CATALINA_HOME%\bin\setclasspath.bat" goto okSetclasspath +echo Cannot find "%CATALINA_HOME%\bin\setclasspath.bat" +echo This file is needed to run this program +goto end +:okSetclasspath +call "%CATALINA_HOME%\bin\setclasspath.bat" %1 +if errorlevel 1 goto end + +rem Add on extra jar file to CLASSPATH +rem Note that there are no quotes as we do not want to introduce random +rem quotes into the CLASSPATH +if "%CLASSPATH%" == "" goto emptyClasspath +set "CLASSPATH=%CLASSPATH%;" +:emptyClasspath +set "CLASSPATH=%CLASSPATH%%CATALINA_HOME%\bin\bootstrap.jar" + +if not "%CATALINA_TMPDIR%" == "" goto gotTmpdir +set "CATALINA_TMPDIR=%CATALINA_BASE%\temp" +:gotTmpdir + +rem Add tomcat-juli.jar to classpath +rem tomcat-juli.jar can be over-ridden per instance +if not exist "%CATALINA_BASE%\bin\tomcat-juli.jar" goto juliClasspathHome +set "CLASSPATH=%CLASSPATH%;%CATALINA_BASE%\bin\tomcat-juli.jar" +goto juliClasspathDone +:juliClasspathHome +set "CLASSPATH=%CLASSPATH%;%CATALINA_HOME%\bin\tomcat-juli.jar" +:juliClasspathDone + +if not "%JSSE_OPTS%" == "" goto gotJsseOpts +set "JSSE_OPTS=-Djdk.tls.ephemeralDHKeySize=2048" +:gotJsseOpts +set "JAVA_OPTS=%JAVA_OPTS% %JSSE_OPTS%" + +rem Check for the deprecated LOGGING_CONFIG +rem Only use it if CATALINA_LOGGING_CONFIG is not set and LOGGING_CONFIG starts with "-D..." +if not "%LOGGING_CONFIG:~0,2%"=="-D" goto noLoggingDeprecation +if not "%CATALINA_LOGGING_CONFIG%" == "" goto noLoggingDeprecation +set "CATALINA_LOGGING_CONFIG=%LOGGING_CONFIG%" +:noLoggingDeprecation + +if not "%CATALINA_LOGGING_CONFIG%" == "" goto noJuliConfig +set CATALINA_LOGGING_CONFIG=-Dnop +if not exist "%CATALINA_BASE%\conf\logging.properties" goto noJuliConfig +set CATALINA_LOGGING_CONFIG=-Djava.util.logging.config.file="%CATALINA_BASE%\conf\logging.properties" +:noJuliConfig + +if not "%LOGGING_MANAGER%" == "" goto noJuliManager +set LOGGING_MANAGER=-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager +:noJuliManager + +rem Configure JAVA 9 specific start-up parameters +set "JDK_JAVA_OPTIONS=%JDK_JAVA_OPTIONS% --add-opens=java.base/java.lang=ALL-UNNAMED" +set "JDK_JAVA_OPTIONS=%JDK_JAVA_OPTIONS% --add-opens=java.base/java.io=ALL-UNNAMED" +set "JDK_JAVA_OPTIONS=%JDK_JAVA_OPTIONS% --add-opens=java.base/java.util=ALL-UNNAMED" +set "JDK_JAVA_OPTIONS=%JDK_JAVA_OPTIONS% --add-opens=java.base/java.util.concurrent=ALL-UNNAMED" +set "JDK_JAVA_OPTIONS=%JDK_JAVA_OPTIONS% --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED" + +rem Java 9 no longer supports the java.endorsed.dirs +rem system property. Only try to use it if +rem JAVA_ENDORSED_DIRS was explicitly set +rem or CATALINA_HOME/endorsed exists. +set ENDORSED_PROP=ignore.endorsed.dirs +if "%JAVA_ENDORSED_DIRS%" == "" goto noEndorsedVar +set ENDORSED_PROP=java.endorsed.dirs +goto doneEndorsed +:noEndorsedVar +if not exist "%CATALINA_HOME%\endorsed" goto doneEndorsed +set ENDORSED_PROP=java.endorsed.dirs +:doneEndorsed + +rem ----- Execute The Requested Command --------------------------------------- + +echo Using CATALINA_BASE: "%CATALINA_BASE%" +echo Using CATALINA_HOME: "%CATALINA_HOME%" +echo Using CATALINA_TMPDIR: "%CATALINA_TMPDIR%" +if ""%1"" == ""debug"" goto use_jdk +echo Using JRE_HOME: "%JRE_HOME%" +goto java_dir_displayed +:use_jdk +echo Using JAVA_HOME: "%JAVA_HOME%" +:java_dir_displayed +echo Using CLASSPATH: "%CLASSPATH%" +echo Using CATALINA_OPTS: "%CATALINA_OPTS%" + +set _EXECJAVA=%_RUNJAVA% +set MAINCLASS=org.apache.catalina.startup.Bootstrap +set ACTION=start +set SECURITY_POLICY_FILE= +set DEBUG_OPTS= +set JPDA= + +if not ""%1"" == ""jpda"" goto noJpda +set JPDA=jpda +if not "%JPDA_TRANSPORT%" == "" goto gotJpdaTransport +set JPDA_TRANSPORT=dt_socket +:gotJpdaTransport +if not "%JPDA_ADDRESS%" == "" goto gotJpdaAddress +set JPDA_ADDRESS=localhost:8000 +:gotJpdaAddress +if not "%JPDA_SUSPEND%" == "" goto gotJpdaSuspend +set JPDA_SUSPEND=n +:gotJpdaSuspend +if not "%JPDA_OPTS%" == "" goto gotJpdaOpts +set JPDA_OPTS=-agentlib:jdwp=transport=%JPDA_TRANSPORT%,address=%JPDA_ADDRESS%,server=y,suspend=%JPDA_SUSPEND% +:gotJpdaOpts +shift +:noJpda + +if ""%1"" == ""debug"" goto doDebug +if ""%1"" == ""run"" goto doRun +if ""%1"" == ""start"" goto doStart +if ""%1"" == ""stop"" goto doStop +if ""%1"" == ""configtest"" goto doConfigTest +if ""%1"" == ""version"" goto doVersion + +echo Usage: catalina ( commands ... ) +echo commands: +echo debug Start Catalina in a debugger +echo debug -security Debug Catalina with a security manager +echo jpda start Start Catalina under JPDA debugger +echo run Start Catalina in the current window +echo run -security Start in the current window with security manager +echo start Start Catalina in a separate window +echo start -security Start in a separate window with security manager +echo stop Stop Catalina +echo configtest Run a basic syntax check on server.xml +echo version What version of tomcat are you running? +goto end + +:doDebug +shift +set _EXECJAVA=%_RUNJDB% +set DEBUG_OPTS=-sourcepath "%CATALINA_HOME%\..\..\java" +if not ""%1"" == ""-security"" goto execCmd +shift +echo Using Security Manager +set "SECURITY_POLICY_FILE=%CATALINA_BASE%\conf\catalina.policy" +goto execCmd + +:doRun +shift +if not ""%1"" == ""-security"" goto execCmd +shift +echo Using Security Manager +set "SECURITY_POLICY_FILE=%CATALINA_BASE%\conf\catalina.policy" +goto execCmd + +:doStart +shift +if "%TITLE%" == "" set TITLE=Tomcat +set _EXECJAVA=start "%TITLE%" %_RUNJAVA% +if not ""%1"" == ""-security"" goto execCmd +shift +echo Using Security Manager +set "SECURITY_POLICY_FILE=%CATALINA_BASE%\conf\catalina.policy" +goto execCmd + +:doStop +shift +set ACTION=stop +set CATALINA_OPTS= +goto execCmd + +:doConfigTest +shift +set ACTION=configtest +set CATALINA_OPTS= +goto execCmd + +:doVersion +%_EXECJAVA% -classpath "%CATALINA_HOME%\lib\catalina.jar" org.apache.catalina.util.ServerInfo +goto end + + +:execCmd +rem Get remaining unshifted command line arguments and save them in the +set CMD_LINE_ARGS= +:setArgs +if ""%1""=="""" goto doneSetArgs +set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1 +shift +goto setArgs +:doneSetArgs + +rem Execute Java with the applicable properties +if not "%JPDA%" == "" goto doJpda +if not "%SECURITY_POLICY_FILE%" == "" goto doSecurity +%_EXECJAVA% %CATALINA_LOGGING_CONFIG% %LOGGING_MANAGER% %JAVA_OPTS% %CATALINA_OPTS% %DEBUG_OPTS% -D%ENDORSED_PROP%="%JAVA_ENDORSED_DIRS%" -classpath "%CLASSPATH%" -Dcatalina.base="%CATALINA_BASE%" -Dcatalina.home="%CATALINA_HOME%" -Djava.io.tmpdir="%CATALINA_TMPDIR%" %MAINCLASS% %CMD_LINE_ARGS% %ACTION% +goto end +:doSecurity +%_EXECJAVA% %CATALINA_LOGGING_CONFIG% %LOGGING_MANAGER% %JAVA_OPTS% %CATALINA_OPTS% %DEBUG_OPTS% -D%ENDORSED_PROP%="%JAVA_ENDORSED_DIRS%" -classpath "%CLASSPATH%" -Djava.security.manager -Djava.security.policy=="%SECURITY_POLICY_FILE%" -Dcatalina.base="%CATALINA_BASE%" -Dcatalina.home="%CATALINA_HOME%" -Djava.io.tmpdir="%CATALINA_TMPDIR%" %MAINCLASS% %CMD_LINE_ARGS% %ACTION% +goto end +:doJpda +if not "%SECURITY_POLICY_FILE%" == "" goto doSecurityJpda +%_EXECJAVA% %CATALINA_LOGGING_CONFIG% %LOGGING_MANAGER% %JAVA_OPTS% %JPDA_OPTS% %CATALINA_OPTS% %DEBUG_OPTS% -D%ENDORSED_PROP%="%JAVA_ENDORSED_DIRS%" -classpath "%CLASSPATH%" -Dcatalina.base="%CATALINA_BASE%" -Dcatalina.home="%CATALINA_HOME%" -Djava.io.tmpdir="%CATALINA_TMPDIR%" %MAINCLASS% %CMD_LINE_ARGS% %ACTION% +goto end +:doSecurityJpda +%_EXECJAVA% %CATALINA_LOGGING_CONFIG% %LOGGING_MANAGER% %JAVA_OPTS% %JPDA_OPTS% %CATALINA_OPTS% %DEBUG_OPTS% -D%ENDORSED_PROP%="%JAVA_ENDORSED_DIRS%" -classpath "%CLASSPATH%" -Djava.security.manager -Djava.security.policy=="%SECURITY_POLICY_FILE%" -Dcatalina.base="%CATALINA_BASE%" -Dcatalina.home="%CATALINA_HOME%" -Djava.io.tmpdir="%CATALINA_TMPDIR%" %MAINCLASS% %CMD_LINE_ARGS% %ACTION% +goto end + +:end diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina.sh new file mode 100755 index 0000000..34bb4f3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/catalina.sh @@ -0,0 +1,684 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ----------------------------------------------------------------------------- +# Control Script for the CATALINA Server +# +# For supported commands call "catalina.sh help" or see the usage section at +# the end of this file. +# +# Environment Variable Prerequisites +# +# Do not set the variables in this script. Instead put them into a script +# setenv.sh in CATALINA_BASE/bin to keep your customizations separate. +# +# CATALINA_HOME May point at your Catalina "build" directory. +# +# CATALINA_BASE (Optional) Base directory for resolving dynamic portions +# of a Catalina installation. If not present, resolves to +# the same directory that CATALINA_HOME points to. +# +# CATALINA_OUT (Optional) Full path to a file where stdout and stderr +# will be redirected. +# Default is $CATALINA_BASE/logs/catalina.out +# +# CATALINA_OUT_CMD (Optional) Command which will be executed and receive +# as its stdin the stdout and stderr from the Tomcat java +# process. If CATALINA_OUT_CMD is set, the value of +# CATALINA_OUT will be used as a named pipe. +# No default. +# Example (all one line) +# CATALINA_OUT_CMD="/usr/bin/rotatelogs -f $CATALINA_BASE/logs/catalina.out.%Y-%m-%d.log 86400" +# +# CATALINA_OPTS (Optional) Java runtime options used when the "start", +# "run" or "debug" command is executed. +# Include here and not in JAVA_OPTS all options, that should +# only be used by Tomcat itself, not by the stop process, +# the version command etc. +# Examples are heap size, GC logging, JMX ports etc. +# +# CATALINA_TMPDIR (Optional) Directory path location of temporary directory +# the JVM should use (java.io.tmpdir). Defaults to +# $CATALINA_BASE/temp. +# +# JAVA_HOME Must point at your Java Development Kit installation. +# Required to run the with the "debug" argument. +# +# JRE_HOME Must point at your Java Runtime installation. +# Defaults to JAVA_HOME if empty. If JRE_HOME and JAVA_HOME +# are both set, JRE_HOME is used. +# +# JAVA_OPTS (Optional) Java runtime options used when any command +# is executed. +# Include here and not in CATALINA_OPTS all options, that +# should be used by Tomcat and also by the stop process, +# the version command etc. +# Most options should go into CATALINA_OPTS. +# +# JAVA_ENDORSED_DIRS (Optional) Lists of of colon separated directories +# containing some jars in order to allow replacement of APIs +# created outside of the JCP (i.e. DOM and SAX from W3C). +# It can also be used to update the XML parser implementation. +# This is only supported for Java <= 8. +# Defaults to $CATALINA_HOME/endorsed. +# +# JPDA_TRANSPORT (Optional) JPDA transport used when the "jpda start" +# command is executed. The default is "dt_socket". +# +# JPDA_ADDRESS (Optional) Java runtime options used when the "jpda start" +# command is executed. The default is localhost:8000. +# +# JPDA_SUSPEND (Optional) Java runtime options used when the "jpda start" +# command is executed. Specifies whether JVM should suspend +# execution immediately after startup. Default is "n". +# +# JPDA_OPTS (Optional) Java runtime options used when the "jpda start" +# command is executed. If used, JPDA_TRANSPORT, JPDA_ADDRESS, +# and JPDA_SUSPEND are ignored. Thus, all required jpda +# options MUST be specified. The default is: +# +# -agentlib:jdwp=transport=$JPDA_TRANSPORT, +# address=$JPDA_ADDRESS,server=y,suspend=$JPDA_SUSPEND +# +# JSSE_OPTS (Optional) Java runtime options used to control the TLS +# implementation when JSSE is used. Default is: +# "-Djdk.tls.ephemeralDHKeySize=2048" +# +# CATALINA_PID (Optional) Path of the file which should contains the pid +# of the catalina startup java process, when start (fork) is +# used +# +# CATALINA_LOGGING_CONFIG (Optional) Override Tomcat's logging config file +# Example (all one line) +# CATALINA_LOGGING_CONFIG="-Djava.util.logging.config.file=$CATALINA_BASE/conf/logging.properties" +# +# LOGGING_CONFIG Deprecated +# Use CATALINA_LOGGING_CONFIG +# This is only used if CATALINA_LOGGING_CONFIG is not set +# and LOGGING_CONFIG starts with "-D..." +# +# LOGGING_MANAGER (Optional) Override Tomcat's logging manager +# Example (all one line) +# LOGGING_MANAGER="-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager" +# +# UMASK (Optional) Override Tomcat's default UMASK of 0027 +# +# USE_NOHUP (Optional) If set to the string true the start command will +# use nohup so that the Tomcat process will ignore any hangup +# signals. Default is "false" unless running on HP-UX in which +# case the default is "true" +# ----------------------------------------------------------------------------- + +# OS specific support. $var _must_ be set to either true or false. +cygwin=false +darwin=false +os400=false +hpux=false +case "`uname`" in +CYGWIN*) cygwin=true;; +Darwin*) darwin=true;; +OS400*) os400=true;; +HP-UX*) hpux=true;; +esac + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ]; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +# Get standard environment variables +PRGDIR=`dirname "$PRG"` + +# Only set CATALINA_HOME if not already set +[ -z "$CATALINA_HOME" ] && CATALINA_HOME=`cd "$PRGDIR/.." >/dev/null; pwd` + +# Copy CATALINA_BASE from CATALINA_HOME if not already set +[ -z "$CATALINA_BASE" ] && CATALINA_BASE="$CATALINA_HOME" + +# Ensure that any user defined CLASSPATH variables are not used on startup, +# but allow them to be specified in setenv.sh, in rare case when it is needed. +CLASSPATH= + +if [ -r "$CATALINA_BASE/bin/setenv.sh" ]; then + . "$CATALINA_BASE/bin/setenv.sh" +elif [ -r "$CATALINA_HOME/bin/setenv.sh" ]; then + . "$CATALINA_HOME/bin/setenv.sh" +fi + +# For Cygwin, ensure paths are in UNIX format before anything is touched +if $cygwin; then + [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"` + [ -n "$JRE_HOME" ] && JRE_HOME=`cygpath --unix "$JRE_HOME"` + [ -n "$CATALINA_HOME" ] && CATALINA_HOME=`cygpath --unix "$CATALINA_HOME"` + [ -n "$CATALINA_BASE" ] && CATALINA_BASE=`cygpath --unix "$CATALINA_BASE"` + [ -n "$CLASSPATH" ] && CLASSPATH=`cygpath --path --unix "$CLASSPATH"` +fi + +# Ensure that neither CATALINA_HOME nor CATALINA_BASE contains a colon +# as this is used as the separator in the classpath and Java provides no +# mechanism for escaping if the same character appears in the path. +case $CATALINA_HOME in + *:*) echo "Using CATALINA_HOME: $CATALINA_HOME"; + echo "Unable to start as CATALINA_HOME contains a colon (:) character"; + exit 1; +esac +case $CATALINA_BASE in + *:*) echo "Using CATALINA_BASE: $CATALINA_BASE"; + echo "Unable to start as CATALINA_BASE contains a colon (:) character"; + exit 1; +esac + +# For OS400 +if $os400; then + # Set job priority to standard for interactive (interactive - 6) by using + # the interactive priority - 6, the helper threads that respond to requests + # will be running at the same priority as interactive jobs. + COMMAND='chgjob job('$JOBNAME') runpty(6)' + system $COMMAND + + # Enable multi threading + export QIBM_MULTI_THREADED=Y +fi + +# Get standard Java environment variables +if $os400; then + # -r will Only work on the os400 if the files are: + # 1. owned by the user + # 2. owned by the PRIMARY group of the user + # this will not work if the user belongs in secondary groups + . "$CATALINA_HOME"/bin/setclasspath.sh +else + if [ -r "$CATALINA_HOME"/bin/setclasspath.sh ]; then + . "$CATALINA_HOME"/bin/setclasspath.sh + else + echo "Cannot find $CATALINA_HOME/bin/setclasspath.sh" + echo "This file is needed to run this program" + exit 1 + fi +fi + +# Add on extra jar files to CLASSPATH +if [ ! -z "$CLASSPATH" ] ; then + CLASSPATH="$CLASSPATH": +fi +CLASSPATH="$CLASSPATH""$CATALINA_HOME"/bin/bootstrap.jar + +if [ -z "$CATALINA_OUT" ] ; then + CATALINA_OUT="$CATALINA_BASE"/logs/catalina.out +fi + +if [ -z "$CATALINA_TMPDIR" ] ; then + # Define the java.io.tmpdir to use for Catalina + CATALINA_TMPDIR="$CATALINA_BASE"/temp +fi + +# Add tomcat-juli.jar to classpath +# tomcat-juli.jar can be over-ridden per instance +if [ -r "$CATALINA_BASE/bin/tomcat-juli.jar" ] ; then + CLASSPATH=$CLASSPATH:$CATALINA_BASE/bin/tomcat-juli.jar +else + CLASSPATH=$CLASSPATH:$CATALINA_HOME/bin/tomcat-juli.jar +fi + +# Bugzilla 37848: When no TTY is available, don't output to console +have_tty=0 +if [ -t 0 ]; then + have_tty=1 +fi + +# For Cygwin, switch paths to Windows format before running java +if $cygwin; then + JAVA_HOME=`cygpath --absolute --windows "$JAVA_HOME"` + JRE_HOME=`cygpath --absolute --windows "$JRE_HOME"` + CATALINA_HOME=`cygpath --absolute --windows "$CATALINA_HOME"` + CATALINA_BASE=`cygpath --absolute --windows "$CATALINA_BASE"` + CATALINA_TMPDIR=`cygpath --absolute --windows "$CATALINA_TMPDIR"` + CLASSPATH=`cygpath --path --windows "$CLASSPATH"` + [ -n "$JAVA_ENDORSED_DIRS" ] && JAVA_ENDORSED_DIRS=`cygpath --path --windows "$JAVA_ENDORSED_DIRS"` +fi + +if [ -z "$JSSE_OPTS" ] ; then + JSSE_OPTS="-Djdk.tls.ephemeralDHKeySize=2048" +fi +JAVA_OPTS="$JAVA_OPTS $JSSE_OPTS" + +# Check for the deprecated LOGGING_CONFIG +# Only use it if CATALINA_LOGGING_CONFIG is not set and LOGGING_CONFIG starts with "-D..." +if [ -z "$CATALINA_LOGGING_CONFIG" ]; then + case $LOGGING_CONFIG in + -D*) CATALINA_LOGGING_CONFIG="$LOGGING_CONFIG" + esac +fi + +# Set juli LogManager config file if it is present and an override has not been issued +if [ -z "$CATALINA_LOGGING_CONFIG" ]; then + if [ -r "$CATALINA_BASE"/conf/logging.properties ]; then + CATALINA_LOGGING_CONFIG="-Djava.util.logging.config.file=$CATALINA_BASE/conf/logging.properties" + else + # Bugzilla 45585 + CATALINA_LOGGING_CONFIG="-Dnop" + fi +fi + +if [ -z "$LOGGING_MANAGER" ]; then + LOGGING_MANAGER="-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager" +fi + +# Set UMASK unless it has been overridden +if [ -z "$UMASK" ]; then + UMASK="0027" +fi +umask $UMASK + +# Java 9 no longer supports the java.endorsed.dirs +# system property. Only try to use it if +# JAVA_ENDORSED_DIRS was explicitly set +# or CATALINA_HOME/endorsed exists. +ENDORSED_PROP=ignore.endorsed.dirs +if [ -n "$JAVA_ENDORSED_DIRS" ]; then + ENDORSED_PROP=java.endorsed.dirs +fi +if [ -d "$CATALINA_HOME/endorsed" ]; then + ENDORSED_PROP=java.endorsed.dirs +fi + +# Make the umask available when using the org.apache.catalina.security.SecurityListener +JAVA_OPTS="$JAVA_OPTS -Dorg.apache.catalina.security.SecurityListener.UMASK=`umask`" + +if [ -z "$USE_NOHUP" ]; then + if $hpux; then + USE_NOHUP="true" + else + USE_NOHUP="false" + fi +fi +unset _NOHUP +if [ "$USE_NOHUP" = "true" ]; then + _NOHUP="nohup" +fi + +# Add the JAVA 9 specific start-up parameters required by Tomcat +JDK_JAVA_OPTIONS="$JDK_JAVA_OPTIONS --add-opens=java.base/java.lang=ALL-UNNAMED" +JDK_JAVA_OPTIONS="$JDK_JAVA_OPTIONS --add-opens=java.base/java.io=ALL-UNNAMED" +JDK_JAVA_OPTIONS="$JDK_JAVA_OPTIONS --add-opens=java.base/java.util=ALL-UNNAMED" +JDK_JAVA_OPTIONS="$JDK_JAVA_OPTIONS --add-opens=java.base/java.util.concurrent=ALL-UNNAMED" +JDK_JAVA_OPTIONS="$JDK_JAVA_OPTIONS --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED" +export JDK_JAVA_OPTIONS + +# ----- Execute The Requested Command ----------------------------------------- + +# Bugzilla 37848: only output this if we have a TTY +if [ $have_tty -eq 1 ]; then + echo "Using CATALINA_BASE: $CATALINA_BASE" + echo "Using CATALINA_HOME: $CATALINA_HOME" + echo "Using CATALINA_TMPDIR: $CATALINA_TMPDIR" + if [ "$1" = "debug" ] ; then + echo "Using JAVA_HOME: $JAVA_HOME" + else + echo "Using JRE_HOME: $JRE_HOME" + fi + echo "Using CLASSPATH: $CLASSPATH" + echo "Using CATALINA_OPTS: $CATALINA_OPTS" + if [ ! -z "$CATALINA_PID" ]; then + echo "Using CATALINA_PID: $CATALINA_PID" + fi +fi + +if [ "$1" = "jpda" ] ; then + if [ -z "$JPDA_TRANSPORT" ]; then + JPDA_TRANSPORT="dt_socket" + fi + if [ -z "$JPDA_ADDRESS" ]; then + JPDA_ADDRESS="localhost:8000" + fi + if [ -z "$JPDA_SUSPEND" ]; then + JPDA_SUSPEND="n" + fi + if [ -z "$JPDA_OPTS" ]; then + JPDA_OPTS="-agentlib:jdwp=transport=$JPDA_TRANSPORT,address=$JPDA_ADDRESS,server=y,suspend=$JPDA_SUSPEND" + fi + CATALINA_OPTS="$JPDA_OPTS $CATALINA_OPTS" + shift +fi + +if [ "$1" = "debug" ] ; then + if $os400; then + echo "Debug command not available on OS400" + exit 1 + else + shift + if [ "$1" = "-security" ] ; then + if [ $have_tty -eq 1 ]; then + echo "Using Security Manager" + fi + shift + eval exec "\"$_RUNJDB\"" "\"$CATALINA_LOGGING_CONFIG\"" $LOGGING_MANAGER "$JAVA_OPTS" "$CATALINA_OPTS" \ + -D$ENDORSED_PROP="$JAVA_ENDORSED_DIRS" \ + -classpath "$CLASSPATH" \ + -sourcepath "$CATALINA_HOME"/../../java \ + -Djava.security.manager \ + -Djava.security.policy=="$CATALINA_BASE"/conf/catalina.policy \ + -Dcatalina.base="$CATALINA_BASE" \ + -Dcatalina.home="$CATALINA_HOME" \ + -Djava.io.tmpdir="$CATALINA_TMPDIR" \ + org.apache.catalina.startup.Bootstrap "$@" start + else + eval exec "\"$_RUNJDB\"" "\"$CATALINA_LOGGING_CONFIG\"" $LOGGING_MANAGER "$JAVA_OPTS" "$CATALINA_OPTS" \ + -D$ENDORSED_PROP="$JAVA_ENDORSED_DIRS" \ + -classpath "$CLASSPATH" \ + -sourcepath "$CATALINA_HOME"/../../java \ + -Dcatalina.base="$CATALINA_BASE" \ + -Dcatalina.home="$CATALINA_HOME" \ + -Djava.io.tmpdir="$CATALINA_TMPDIR" \ + org.apache.catalina.startup.Bootstrap "$@" start + fi + fi + +elif [ "$1" = "run" ]; then + + shift + if [ "$1" = "-security" ] ; then + if [ $have_tty -eq 1 ]; then + echo "Using Security Manager" + fi + shift + eval exec "\"$_RUNJAVA\"" "\"$CATALINA_LOGGING_CONFIG\"" $LOGGING_MANAGER "$JAVA_OPTS" "$CATALINA_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -classpath "\"$CLASSPATH\"" \ + -Djava.security.manager \ + -Djava.security.policy=="\"$CATALINA_BASE/conf/catalina.policy\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMPDIR\"" \ + org.apache.catalina.startup.Bootstrap "$@" start + else + eval exec "\"$_RUNJAVA\"" "\"$CATALINA_LOGGING_CONFIG\"" $LOGGING_MANAGER "$JAVA_OPTS" "$CATALINA_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -classpath "\"$CLASSPATH\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMPDIR\"" \ + org.apache.catalina.startup.Bootstrap "$@" start + fi + +elif [ "$1" = "start" ] ; then + + if [ ! -z "$CATALINA_PID" ]; then + if [ -f "$CATALINA_PID" ]; then + if [ -s "$CATALINA_PID" ]; then + echo "Existing PID file found during start." + if [ -r "$CATALINA_PID" ]; then + PID=`cat "$CATALINA_PID"` + ps -p $PID >/dev/null 2>&1 + if [ $? -eq 0 ] ; then + echo "Tomcat appears to still be running with PID $PID. Start aborted." + echo "If the following process is not a Tomcat process, remove the PID file and try again:" + ps -f -p $PID + exit 1 + else + echo "Removing/clearing stale PID file." + rm -f "$CATALINA_PID" >/dev/null 2>&1 + if [ $? != 0 ]; then + if [ -w "$CATALINA_PID" ]; then + cat /dev/null > "$CATALINA_PID" + else + echo "Unable to remove or clear stale PID file. Start aborted." + exit 1 + fi + fi + fi + else + echo "Unable to read PID file. Start aborted." + exit 1 + fi + else + rm -f "$CATALINA_PID" >/dev/null 2>&1 + if [ $? != 0 ]; then + if [ ! -w "$CATALINA_PID" ]; then + echo "Unable to remove or write to empty PID file. Start aborted." + exit 1 + fi + fi + fi + fi + fi + + shift + if [ -z "$CATALINA_OUT_CMD" ] ; then + touch "$CATALINA_OUT" + else + if [ ! -e "$CATALINA_OUT" ]; then + if ! mkfifo "$CATALINA_OUT"; then + echo "cannot create named pipe $CATALINA_OUT. Start aborted." + exit 1 + fi + elif [ ! -p "$CATALINA_OUT" ]; then + echo "$CATALINA_OUT exists and is not a named pipe. Start aborted." + exit 1 + fi + $CATALINA_OUT_CMD <"$CATALINA_OUT" & + fi + if [ "$1" = "-security" ] ; then + if [ $have_tty -eq 1 ]; then + echo "Using Security Manager" + fi + shift + eval $_NOHUP "\"$_RUNJAVA\"" "\"$CATALINA_LOGGING_CONFIG\"" $LOGGING_MANAGER "$JAVA_OPTS" "$CATALINA_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -classpath "\"$CLASSPATH\"" \ + -Djava.security.manager \ + -Djava.security.policy=="\"$CATALINA_BASE/conf/catalina.policy\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMPDIR\"" \ + org.apache.catalina.startup.Bootstrap "$@" start \ + >> "$CATALINA_OUT" 2>&1 "&" + + else + eval $_NOHUP "\"$_RUNJAVA\"" "\"$CATALINA_LOGGING_CONFIG\"" $LOGGING_MANAGER "$JAVA_OPTS" "$CATALINA_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -classpath "\"$CLASSPATH\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMPDIR\"" \ + org.apache.catalina.startup.Bootstrap "$@" start \ + >> "$CATALINA_OUT" 2>&1 "&" + + fi + + if [ ! -z "$CATALINA_PID" ]; then + echo $! > "$CATALINA_PID" + fi + + echo "Tomcat started." + +elif [ "$1" = "stop" ] ; then + + shift + + SLEEP=5 + if [ ! -z "$1" ]; then + echo $1 | grep "[^0-9]" >/dev/null 2>&1 + if [ $? -gt 0 ]; then + SLEEP=$1 + shift + fi + fi + + FORCE=0 + if [ "$1" = "-force" ]; then + shift + FORCE=1 + fi + + if [ ! -z "$CATALINA_PID" ]; then + if [ -f "$CATALINA_PID" ]; then + if [ -s "$CATALINA_PID" ]; then + kill -0 `cat "$CATALINA_PID"` >/dev/null 2>&1 + if [ $? -gt 0 ]; then + echo "PID file found but either no matching process was found or the current user does not have permission to stop the process. Stop aborted." + exit 1 + fi + else + echo "PID file is empty and has been ignored." + fi + else + echo "\$CATALINA_PID was set but the specified file does not exist. Is Tomcat running? Stop aborted." + exit 1 + fi + fi + + eval "\"$_RUNJAVA\"" $LOGGING_MANAGER "$JAVA_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -classpath "\"$CLASSPATH\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMPDIR\"" \ + org.apache.catalina.startup.Bootstrap "$@" stop + + # stop failed. Shutdown port disabled? Try a normal kill. + if [ $? != 0 ]; then + if [ ! -z "$CATALINA_PID" ]; then + echo "The stop command failed. Attempting to signal the process to stop through OS signal." + kill -15 `cat "$CATALINA_PID"` >/dev/null 2>&1 + fi + fi + + if [ ! -z "$CATALINA_PID" ]; then + if [ -f "$CATALINA_PID" ]; then + while [ $SLEEP -ge 0 ]; do + kill -0 `cat "$CATALINA_PID"` >/dev/null 2>&1 + if [ $? -gt 0 ]; then + rm -f "$CATALINA_PID" >/dev/null 2>&1 + if [ $? != 0 ]; then + if [ -w "$CATALINA_PID" ]; then + cat /dev/null > "$CATALINA_PID" + # If Tomcat has stopped don't try and force a stop with an empty PID file + FORCE=0 + else + echo "The PID file could not be removed or cleared." + fi + fi + echo "Tomcat stopped." + break + fi + if [ $SLEEP -gt 0 ]; then + sleep 1 + fi + if [ $SLEEP -eq 0 ]; then + echo "Tomcat did not stop in time." + if [ $FORCE -eq 0 ]; then + echo "PID file was not removed." + fi + echo "To aid diagnostics a thread dump has been written to standard out." + kill -3 `cat "$CATALINA_PID"` + fi + SLEEP=`expr $SLEEP - 1 ` + done + fi + fi + + KILL_SLEEP_INTERVAL=5 + if [ $FORCE -eq 1 ]; then + if [ -z "$CATALINA_PID" ]; then + echo "Kill failed: \$CATALINA_PID not set" + else + if [ -f "$CATALINA_PID" ]; then + PID=`cat "$CATALINA_PID"` + echo "Killing Tomcat with the PID: $PID" + kill -9 $PID + while [ $KILL_SLEEP_INTERVAL -ge 0 ]; do + kill -0 `cat "$CATALINA_PID"` >/dev/null 2>&1 + if [ $? -gt 0 ]; then + rm -f "$CATALINA_PID" >/dev/null 2>&1 + if [ $? != 0 ]; then + if [ -w "$CATALINA_PID" ]; then + cat /dev/null > "$CATALINA_PID" + else + echo "The PID file could not be removed." + fi + fi + echo "The Tomcat process has been killed." + break + fi + if [ $KILL_SLEEP_INTERVAL -gt 0 ]; then + sleep 1 + fi + KILL_SLEEP_INTERVAL=`expr $KILL_SLEEP_INTERVAL - 1 ` + done + if [ $KILL_SLEEP_INTERVAL -lt 0 ]; then + echo "Tomcat has not been killed completely yet. The process might be waiting on some system call or might be UNINTERRUPTIBLE." + fi + fi + fi + fi + +elif [ "$1" = "configtest" ] ; then + + eval "\"$_RUNJAVA\"" $LOGGING_MANAGER "$JAVA_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -classpath "\"$CLASSPATH\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMPDIR\"" \ + org.apache.catalina.startup.Bootstrap configtest + result=$? + if [ $result -ne 0 ]; then + echo "Configuration error detected!" + fi + exit $result + +elif [ "$1" = "version" ] ; then + + "$_RUNJAVA" \ + -classpath "$CATALINA_HOME/lib/catalina.jar" \ + org.apache.catalina.util.ServerInfo + +else + + echo "Usage: catalina.sh ( commands ... )" + echo "commands:" + if $os400; then + echo " debug Start Catalina in a debugger (not available on OS400)" + echo " debug -security Debug Catalina with a security manager (not available on OS400)" + else + echo " debug Start Catalina in a debugger" + echo " debug -security Debug Catalina with a security manager" + fi + echo " jpda start Start Catalina under JPDA debugger" + echo " run Start Catalina in the current window" + echo " run -security Start in the current window with security manager" + echo " start Start Catalina in a separate window" + echo " start -security Start in a separate window with security manager" + echo " stop Stop Catalina, waiting up to 5 seconds for the process to end" + echo " stop n Stop Catalina, waiting up to n seconds for the process to end" + echo " stop -force Stop Catalina, wait up to 5 seconds and then use kill -KILL if still running" + echo " stop n -force Stop Catalina, wait up to n seconds and then use kill -KILL if still running" + echo " configtest Run a basic syntax check on server.xml - check exit code for result" + echo " version What version of tomcat are you running?" + echo "Note: Waiting for the process to end and use of the -force option require that \$CATALINA_PID is defined" + exit 1 + +fi diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/commons-daemon-native.tar.gz b/centos8_tomcat/apache-tomcat-7.0.108/bin/commons-daemon-native.tar.gz new file mode 100644 index 0000000..6399975 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/bin/commons-daemon-native.tar.gz differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/commons-daemon.jar b/centos8_tomcat/apache-tomcat-7.0.108/bin/commons-daemon.jar new file mode 100644 index 0000000..8a4bbcf Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/bin/commons-daemon.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/configtest.bat b/centos8_tomcat/apache-tomcat-7.0.108/bin/configtest.bat new file mode 100644 index 0000000..02448e1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/configtest.bat @@ -0,0 +1,58 @@ +@echo off +rem Licensed to the Apache Software Foundation (ASF) under one or more +rem contributor license agreements. See the NOTICE file distributed with +rem this work for additional information regarding copyright ownership. +rem The ASF licenses this file to You under the Apache License, Version 2.0 +rem (the "License"); you may not use this file except in compliance with +rem the License. You may obtain a copy of the License at +rem +rem http://www.apache.org/licenses/LICENSE-2.0 +rem +rem Unless required by applicable law or agreed to in writing, software +rem distributed under the License is distributed on an "AS IS" BASIS, +rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +rem See the License for the specific language governing permissions and +rem limitations under the License. + +rem --------------------------------------------------------------------------- +rem Configuration test script for the CATALINA Server +rem --------------------------------------------------------------------------- + +setlocal + +rem Guess CATALINA_HOME if not defined +set "CURRENT_DIR=%cd%" +if not "%CATALINA_HOME%" == "" goto gotHome +set "CATALINA_HOME=%CURRENT_DIR%" +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +cd .. +set "CATALINA_HOME=%cd%" +cd "%CURRENT_DIR%" +:gotHome +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +echo The CATALINA_HOME environment variable is not defined correctly +echo This environment variable is needed to run this program +goto end +:okHome + +set "EXECUTABLE=%CATALINA_HOME%\bin\catalina.bat" + +rem Check that target executable exists +if exist "%EXECUTABLE%" goto okExec +echo Cannot find "%EXECUTABLE%" +echo This file is needed to run this program +goto end +:okExec + +rem Get remaining unshifted command line arguments and save them in the +set CMD_LINE_ARGS= +:setArgs +if ""%1""=="""" goto doneSetArgs +set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1 +shift +goto setArgs +:doneSetArgs + +call "%EXECUTABLE%" configtest %CMD_LINE_ARGS% + +:end diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/configtest.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/configtest.sh new file mode 100755 index 0000000..9a8ebff --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/configtest.sh @@ -0,0 +1,60 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ----------------------------------------------------------------------------- +# Configuration Test Script for the CATALINA Server +# ----------------------------------------------------------------------------- + +# Better OS/400 detection: see Bugzilla 31132 +os400=false +case "`uname`" in +OS400*) os400=true;; +esac + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ] ; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +PRGDIR=`dirname "$PRG"` +EXECUTABLE=catalina.sh + +# Check that target executable exists +if $os400; then + # -x will Only work on the os400 if the files are: + # 1. owned by the user + # 2. owned by the PRIMARY group of the user + # this will not work if the user belongs in secondary groups + eval +else + if [ ! -x "$PRGDIR"/"$EXECUTABLE" ]; then + echo "Cannot find $PRGDIR/$EXECUTABLE" + echo "The file is absent or does not have execute permission" + echo "This file is needed to run this program" + exit 1 + fi +fi + +exec "$PRGDIR"/"$EXECUTABLE" configtest "$@" diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/daemon.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/daemon.sh new file mode 100755 index 0000000..014a350 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/daemon.sh @@ -0,0 +1,293 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ----------------------------------------------------------------------------- +# Commons Daemon wrapper script. +# ----------------------------------------------------------------------------- + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ]; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +DIRNAME="`dirname "$PRG"`" +PROGRAM="`basename "$PRG"`" +while [ ".$1" != . ] +do + case "$1" in + --java-home ) + JAVA_HOME="$2" + shift; shift; + continue + ;; + --catalina-home ) + CATALINA_HOME="$2" + shift; shift; + continue + ;; + --catalina-base ) + CATALINA_BASE="$2" + shift; shift; + continue + ;; + --catalina-pid ) + CATALINA_PID="$2" + shift; shift; + continue + ;; + --tomcat-user ) + TOMCAT_USER="$2" + shift; shift; + continue + ;; + --service-start-wait-time ) + SERVICE_START_WAIT_TIME="$2" + shift; shift; + continue + ;; + * ) + break + ;; + esac +done +# OS specific support (must be 'true' or 'false'). +cygwin=false; +darwin=false; +case "`uname`" in + CYGWIN*) + cygwin=true + ;; + Darwin*) + darwin=true + ;; +esac + +# Use the maximum available, or set MAX_FD != -1 to use that +test ".$MAX_FD" = . && MAX_FD="maximum" +# Setup parameters for running the jsvc +# +test ".$TOMCAT_USER" = . && TOMCAT_USER=tomcat +# Set JAVA_HOME to working JDK or JRE +# If not set we'll try to guess the JAVA_HOME +# from java binary if on the PATH +# +if [ -z "$JAVA_HOME" ]; then + JAVA_BIN="`which java 2>/dev/null || type java 2>&1`" + while [ -h "$JAVA_BIN" ]; do + ls=`ls -ld "$JAVA_BIN"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + JAVA_BIN="$link" + else + JAVA_BIN="`dirname "$JAVA_BIN"`/$link" + fi + done + test -x "$JAVA_BIN" && JAVA_HOME="`dirname "$JAVA_BIN"`" + test ".$JAVA_HOME" != . && JAVA_HOME=`cd "$JAVA_HOME/.." >/dev/null; pwd` +else + JAVA_BIN="$JAVA_HOME/bin/java" +fi + +# Only set CATALINA_HOME if not already set +test ".$CATALINA_HOME" = . && CATALINA_HOME=`cd "$DIRNAME/.." >/dev/null; pwd` +test ".$CATALINA_BASE" = . && CATALINA_BASE="$CATALINA_HOME" +test ".$CATALINA_MAIN" = . && CATALINA_MAIN=org.apache.catalina.startup.Bootstrap +# If not explicitly set, look for jsvc in CATALINA_BASE first then CATALINA_HOME +if [ -z "$JSVC" ]; then + JSVC="$CATALINA_BASE/bin/jsvc" + if [ ! -x "$JSVC" ]; then + JSVC="$CATALINA_HOME/bin/jsvc" + fi +fi +# Set the default service-start wait time if necessary +test ".$SERVICE_START_WAIT_TIME" = . && SERVICE_START_WAIT_TIME=10 + +# Ensure that any user defined CLASSPATH variables are not used on startup, +# but allow them to be specified in setenv.sh, in rare case when it is needed. +CLASSPATH= +JAVA_OPTS= +if [ -r "$CATALINA_BASE/bin/setenv.sh" ]; then + . "$CATALINA_BASE/bin/setenv.sh" +elif [ -r "$CATALINA_HOME/bin/setenv.sh" ]; then + . "$CATALINA_HOME/bin/setenv.sh" +fi + +# Add on extra jar files to CLASSPATH +test ".$CLASSPATH" != . && CLASSPATH="$CLASSPATH:" +CLASSPATH="$CLASSPATH$CATALINA_HOME/bin/bootstrap.jar:$CATALINA_HOME/bin/commons-daemon.jar" + +test ".$CATALINA_OUT" = . && CATALINA_OUT="$CATALINA_BASE/logs/catalina-daemon.out" +test ".$CATALINA_TMP" = . && CATALINA_TMP="$CATALINA_BASE/temp" + +# Add tomcat-juli.jar to classpath +# tomcat-juli.jar can be over-ridden per instance +if [ -r "$CATALINA_BASE/bin/tomcat-juli.jar" ] ; then + CLASSPATH="$CLASSPATH:$CATALINA_BASE/bin/tomcat-juli.jar" +else + CLASSPATH="$CLASSPATH:$CATALINA_HOME/bin/tomcat-juli.jar" +fi + +# Check for the deprecated LOGGING_CONFIG +# Only use it if CATALINA_LOGGING_CONFIG is not set and LOGGING_CONFIG starts with "-D..." +if [ -z "$CATALINA_LOGGING_CONFIG" ]; then + case $LOGGING_CONFIG in + -D*) CATALINA_LOGGING_CONFIG="$LOGGING_CONFIG" + esac +fi + +# Set juli LogManager config file if it is present and an override has not been issued +if [ -z "$CATALINA_LOGGING_CONFIG" ]; then + if [ -r "$CATALINA_BASE/conf/logging.properties" ]; then + CATALINA_LOGGING_CONFIG="-Djava.util.logging.config.file=$CATALINA_BASE/conf/logging.properties" + else + # Bugzilla 45585 + CATALINA_LOGGING_CONFIG="-Dnop" + fi +fi + +test ".$LOGGING_MANAGER" = . && LOGGING_MANAGER="-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager" +JAVA_OPTS="$JAVA_OPTS $LOGGING_MANAGER" + +# Set -pidfile +test ".$CATALINA_PID" = . && CATALINA_PID="$CATALINA_BASE/logs/catalina-daemon.pid" + +# Increase the maximum file descriptors if we can +if [ "$cygwin" = "false" ]; then + MAX_FD_LIMIT=`ulimit -H -n` + if [ "$?" -eq 0 ]; then + # Darwin does not allow RLIMIT_INFINITY on file soft limit + if [ "$darwin" = "true" ] && [ "$MAX_FD_LIMIT" = "unlimited" ]; then + MAX_FD_LIMIT=`/usr/sbin/sysctl -n kern.maxfilesperproc` + fi + test ".$MAX_FD" = ".maximum" && MAX_FD="$MAX_FD_LIMIT" + ulimit -n $MAX_FD + if [ "$?" -ne 0 ]; then + echo "$PROGRAM: Could not set maximum file descriptor limit: $MAX_FD" + fi + else + echo "$PROGRAM: Could not query system maximum file descriptor limit: $MAX_FD_LIMIT" + fi +fi + +# Set UMASK unless it has been overridden +if [ -z "$UMASK" ]; then + UMASK="0027" +fi +umask $UMASK + +# Java 9 no longer supports the java.endorsed.dirs +# system property. Only try to use it if +# JAVA_ENDORSED_DIRS was explicitly set +# or CATALINA_HOME/endorsed exists. +ENDORSED_PROP=ignore.endorsed.dirs +if [ -n "$JAVA_ENDORSED_DIRS" ]; then + ENDORSED_PROP=java.endorsed.dirs +fi +if [ -d "$CATALINA_HOME/endorsed" ]; then + ENDORSED_PROP=java.endorsed.dirs +fi + +# ----- Execute The Requested Command ----------------------------------------- +case "$1" in + run ) + shift + eval exec "\"$JSVC\"" $* \ + "$JSVC_OPTS" \ + -java-home "\"$JAVA_HOME\"" \ + -pidfile "\"$CATALINA_PID\"" \ + -wait $SERVICE_START_WAIT_TIME \ + -umask $UMASK \ + -nodetach \ + -outfile "\"&1\"" \ + -errfile "\"&2\"" \ + -classpath "\"$CLASSPATH\"" \ + "\"$CATALINA_LOGGING_CONFIG\"" "$JAVA_OPTS" "$CATALINA_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMP\"" \ + $CATALINA_MAIN + exit $? + ;; + start ) + eval "\"$JSVC\"" \ + "$JSVC_OPTS" \ + -java-home "\"$JAVA_HOME\"" \ + -user $TOMCAT_USER \ + -pidfile "\"$CATALINA_PID\"" \ + -wait $SERVICE_START_WAIT_TIME \ + -umask $UMASK \ + -outfile "\"$CATALINA_OUT\"" \ + -errfile "\"&1\"" \ + -classpath "\"$CLASSPATH\"" \ + "\"$CATALINA_LOGGING_CONFIG\"" "$JAVA_OPTS" "$CATALINA_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMP\"" \ + $CATALINA_MAIN + exit $? + ;; + stop ) + eval "\"$JSVC\"" \ + "$JSVC_OPTS" \ + -stop \ + -pidfile "\"$CATALINA_PID\"" \ + -classpath "\"$CLASSPATH\"" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -Dcatalina.base="\"$CATALINA_BASE\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + -Djava.io.tmpdir="\"$CATALINA_TMP\"" \ + $CATALINA_MAIN + exit $? + ;; + version ) + "$JSVC" \ + -java-home "$JAVA_HOME" \ + -pidfile "$CATALINA_PID" \ + -classpath "$CLASSPATH" \ + -errfile "&2" \ + -version \ + -check \ + $CATALINA_MAIN + if [ "$?" = 0 ]; then + "$JAVA_BIN" \ + -classpath "$CATALINA_HOME/lib/catalina.jar" \ + org.apache.catalina.util.ServerInfo + fi + exit $? + ;; + * ) + echo "Unknown command: '$1'" + echo "Usage: $PROGRAM ( commands ... )" + echo "commands:" + echo " run Start Tomcat without detaching from console" + echo " start Start Tomcat" + echo " stop Stop Tomcat" + echo " version What version of commons daemon and Tomcat" + echo " are you running?" + exit 1 + ;; +esac diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/digest.bat b/centos8_tomcat/apache-tomcat-7.0.108/bin/digest.bat new file mode 100644 index 0000000..428b9d1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/digest.bat @@ -0,0 +1,58 @@ +@echo off +rem Licensed to the Apache Software Foundation (ASF) under one or more +rem contributor license agreements. See the NOTICE file distributed with +rem this work for additional information regarding copyright ownership. +rem The ASF licenses this file to You under the Apache License, Version 2.0 +rem (the "License"); you may not use this file except in compliance with +rem the License. You may obtain a copy of the License at +rem +rem http://www.apache.org/licenses/LICENSE-2.0 +rem +rem Unless required by applicable law or agreed to in writing, software +rem distributed under the License is distributed on an "AS IS" BASIS, +rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +rem See the License for the specific language governing permissions and +rem limitations under the License. + +rem --------------------------------------------------------------------------- +rem Script to digest password using the algorithm specified +rem --------------------------------------------------------------------------- + +setlocal + +rem Guess CATALINA_HOME if not defined +set "CURRENT_DIR=%cd%" +if not "%CATALINA_HOME%" == "" goto gotHome +set "CATALINA_HOME=%CURRENT_DIR%" +if exist "%CATALINA_HOME%\bin\tool-wrapper.bat" goto okHome +cd .. +set "CATALINA_HOME=%cd%" +cd "%CURRENT_DIR%" +:gotHome +if exist "%CATALINA_HOME%\bin\tool-wrapper.bat" goto okHome +echo The CATALINA_HOME environment variable is not defined correctly +echo This environment variable is needed to run this program +goto end +:okHome + +set "EXECUTABLE=%CATALINA_HOME%\bin\tool-wrapper.bat" + +rem Check that target executable exists +if exist "%EXECUTABLE%" goto okExec +echo Cannot find "%EXECUTABLE%" +echo This file is needed to run this program +goto end +:okExec + +rem Get remaining unshifted command line arguments and save them in the +set CMD_LINE_ARGS= +:setArgs +if ""%1""=="""" goto doneSetArgs +set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1 +shift +goto setArgs +:doneSetArgs + +call "%EXECUTABLE%" -server org.apache.catalina.realm.RealmBase %CMD_LINE_ARGS% + +:end diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/digest.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/digest.sh new file mode 100755 index 0000000..62ed5d0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/digest.sh @@ -0,0 +1,60 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ----------------------------------------------------------------------------- +# Script to digest password using the algorithm specified +# ----------------------------------------------------------------------------- + +# Better OS/400 detection: see Bugzilla 31132 +os400=false +case "`uname`" in +OS400*) os400=true;; +esac + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ] ; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +PRGDIR=`dirname "$PRG"` +EXECUTABLE=tool-wrapper.sh + +# Check that target executable exists +if $os400; then + # -x will Only work on the os400 if the files are: + # 1. owned by the user + # 2. owned by the PRIMARY group of the user + # this will not work if the user belongs in secondary groups + eval +else + if [ ! -x "$PRGDIR"/"$EXECUTABLE" ]; then + echo "Cannot find $PRGDIR/$EXECUTABLE" + echo "The file is absent or does not have execute permission" + echo "This file is needed to run this program" + exit 1 + fi +fi + +exec "$PRGDIR"/"$EXECUTABLE" -server org.apache.catalina.realm.RealmBase "$@" diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/setclasspath.bat b/centos8_tomcat/apache-tomcat-7.0.108/bin/setclasspath.bat new file mode 100644 index 0000000..5109c38 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/setclasspath.bat @@ -0,0 +1,94 @@ +@echo off +rem Licensed to the Apache Software Foundation (ASF) under one or more +rem contributor license agreements. See the NOTICE file distributed with +rem this work for additional information regarding copyright ownership. +rem The ASF licenses this file to You under the Apache License, Version 2.0 +rem (the "License"); you may not use this file except in compliance with +rem the License. You may obtain a copy of the License at +rem +rem http://www.apache.org/licenses/LICENSE-2.0 +rem +rem Unless required by applicable law or agreed to in writing, software +rem distributed under the License is distributed on an "AS IS" BASIS, +rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +rem See the License for the specific language governing permissions and +rem limitations under the License. + +rem --------------------------------------------------------------------------- +rem Set JAVA_HOME or JRE_HOME if not already set, ensure any provided settings +rem are valid and consistent with the selected start-up options and set up the +rem endorsed directory. +rem --------------------------------------------------------------------------- + +rem Make sure prerequisite environment variables are set + +rem In debug mode we need a real JDK (JAVA_HOME) +if ""%1"" == ""debug"" goto needJavaHome + +rem Otherwise either JRE or JDK are fine +if not "%JRE_HOME%" == "" goto gotJreHome +if not "%JAVA_HOME%" == "" goto gotJavaHome +echo Neither the JAVA_HOME nor the JRE_HOME environment variable is defined +echo At least one of these environment variable is needed to run this program +goto exit + +:needJavaHome +rem Check if we have a usable JDK +if "%JAVA_HOME%" == "" goto noJavaHome +if not exist "%JAVA_HOME%\bin\java.exe" goto noJavaHome +if not exist "%JAVA_HOME%\bin\jdb.exe" goto noJavaHome +if not exist "%JAVA_HOME%\bin\javac.exe" goto noJavaHome +set "JRE_HOME=%JAVA_HOME%" +goto okJava + +:noJavaHome +echo The JAVA_HOME environment variable is not defined correctly. +echo It is needed to run this program in debug mode. +echo NB: JAVA_HOME should point to a JDK not a JRE. +goto exit + +:gotJavaHome +rem No JRE given, use JAVA_HOME as JRE_HOME +set "JRE_HOME=%JAVA_HOME%" + +:gotJreHome +rem Check if we have a usable JRE +if not exist "%JRE_HOME%\bin\java.exe" goto noJreHome +goto okJava + +:noJreHome +rem Needed at least a JRE +echo The JRE_HOME environment variable is not defined correctly +echo This environment variable is needed to run this program +goto exit + +:okJava +rem Don't override the endorsed dir if the user has set it previously +if not "%JAVA_ENDORSED_DIRS%" == "" goto gotEndorseddir +rem Java 9 no longer supports the java.endorsed.dirs +rem system property. Only try to use it if +rem CATALINA_HOME/endorsed exists. +if not exist "%CATALINA_HOME%\endorsed" goto gotEndorseddir +set "JAVA_ENDORSED_DIRS=%CATALINA_HOME%\endorsed" +:gotEndorseddir + +rem Don't override _RUNJAVA if the user has set it previously +if not "%_RUNJAVA%" == "" goto gotRunJava +rem Set standard command for invoking Java. +rem Also note the quoting as JRE_HOME may contain spaces. +set _RUNJAVA="%JRE_HOME%\bin\java.exe" +:gotRunJava + +rem Don't override _RUNJDB if the user has set it previously +rem Also note the quoting as JAVA_HOME may contain spaces. +if not "%_RUNJDB%" == "" goto gotRunJdb +set _RUNJDB="%JAVA_HOME%\bin\jdb.exe" +:gotRunJdb + +goto end + +:exit +exit /b 1 + +:end +exit /b 0 diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/setclasspath.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/setclasspath.sh new file mode 100755 index 0000000..4ae4b6a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/setclasspath.sh @@ -0,0 +1,98 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ----------------------------------------------------------------------------- +# Set JAVA_HOME or JRE_HOME if not already set, ensure any provided settings +# are valid and consistent with the selected start-up options and set up the +# endorsed directory. +# ----------------------------------------------------------------------------- + +# Make sure prerequisite environment variables are set +if [ -z "$JAVA_HOME" ] && [ -z "$JRE_HOME" ]; then + if $darwin; then + # Bugzilla 54390 + if [ -x '/usr/libexec/java_home' ] ; then + export JAVA_HOME=`/usr/libexec/java_home` + # Bugzilla 37284 (reviewed). + elif [ -d "/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home" ]; then + export JAVA_HOME="/System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK/Home" + fi + else + JAVA_PATH=`which java 2>/dev/null` + if [ "x$JAVA_PATH" != "x" ]; then + JAVA_PATH=`dirname "$JAVA_PATH" 2>/dev/null` + JRE_HOME=`dirname "$JAVA_PATH" 2>/dev/null` + fi + if [ "x$JRE_HOME" = "x" ]; then + # XXX: Should we try other locations? + if [ -x /usr/bin/java ]; then + JRE_HOME=/usr + fi + fi + fi + if [ -z "$JAVA_HOME" ] && [ -z "$JRE_HOME" ]; then + echo "Neither the JAVA_HOME nor the JRE_HOME environment variable is defined" + echo "At least one of these environment variable is needed to run this program" + exit 1 + fi +fi +if [ -z "$JAVA_HOME" ] && [ "$1" = "debug" ]; then + echo "JAVA_HOME should point to a JDK in order to run in debug mode." + exit 1 +fi +if [ -z "$JRE_HOME" ]; then + JRE_HOME="$JAVA_HOME" +fi + +# If we're running under jdb, we need a full jdk. +if [ "$1" = "debug" ] ; then + if [ "$os400" = "true" ]; then + if [ ! -x "$JAVA_HOME"/bin/java ] || [ ! -x "$JAVA_HOME"/bin/javac ]; then + echo "The JAVA_HOME environment variable is not defined correctly" + echo "This environment variable is needed to run this program" + echo "NB: JAVA_HOME should point to a JDK not a JRE" + exit 1 + fi + else + if [ ! -x "$JAVA_HOME"/bin/java ] || [ ! -x "$JAVA_HOME"/bin/jdb ] || [ ! -x "$JAVA_HOME"/bin/javac ]; then + echo "The JAVA_HOME environment variable is not defined correctly" + echo "This environment variable is needed to run this program" + echo "NB: JAVA_HOME should point to a JDK not a JRE" + exit 1 + fi + fi +fi + +# Don't override the endorsed dir if the user has set it previously +if [ -z "$JAVA_ENDORSED_DIRS" ]; then + # Java 9 no longer supports the java.endorsed.dirs + # system property. Only try to use it if + # CATALINA_HOME/endorsed exists. + if [ -d "$CATALINA_HOME"/endorsed ]; then + JAVA_ENDORSED_DIRS="$CATALINA_HOME"/endorsed + fi +fi + +# Set standard commands for invoking Java, if not already set. +if [ -z "$_RUNJAVA" ]; then + _RUNJAVA="$JRE_HOME"/bin/java +fi +if [ "$os400" != "true" ]; then + if [ -z "$_RUNJDB" ]; then + _RUNJDB="$JAVA_HOME"/bin/jdb + fi +fi diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/shutdown.bat b/centos8_tomcat/apache-tomcat-7.0.108/bin/shutdown.bat new file mode 100644 index 0000000..119fb99 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/shutdown.bat @@ -0,0 +1,58 @@ +@echo off +rem Licensed to the Apache Software Foundation (ASF) under one or more +rem contributor license agreements. See the NOTICE file distributed with +rem this work for additional information regarding copyright ownership. +rem The ASF licenses this file to You under the Apache License, Version 2.0 +rem (the "License"); you may not use this file except in compliance with +rem the License. You may obtain a copy of the License at +rem +rem http://www.apache.org/licenses/LICENSE-2.0 +rem +rem Unless required by applicable law or agreed to in writing, software +rem distributed under the License is distributed on an "AS IS" BASIS, +rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +rem See the License for the specific language governing permissions and +rem limitations under the License. + +rem --------------------------------------------------------------------------- +rem Stop script for the CATALINA Server +rem --------------------------------------------------------------------------- + +setlocal + +rem Guess CATALINA_HOME if not defined +set "CURRENT_DIR=%cd%" +if not "%CATALINA_HOME%" == "" goto gotHome +set "CATALINA_HOME=%CURRENT_DIR%" +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +cd .. +set "CATALINA_HOME=%cd%" +cd "%CURRENT_DIR%" +:gotHome +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +echo The CATALINA_HOME environment variable is not defined correctly +echo This environment variable is needed to run this program +goto end +:okHome + +set "EXECUTABLE=%CATALINA_HOME%\bin\catalina.bat" + +rem Check that target executable exists +if exist "%EXECUTABLE%" goto okExec +echo Cannot find "%EXECUTABLE%" +echo This file is needed to run this program +goto end +:okExec + +rem Get remaining unshifted command line arguments and save them in the +set CMD_LINE_ARGS= +:setArgs +if ""%1""=="""" goto doneSetArgs +set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1 +shift +goto setArgs +:doneSetArgs + +call "%EXECUTABLE%" stop %CMD_LINE_ARGS% + +:end diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/shutdown.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/shutdown.sh new file mode 100755 index 0000000..cd0c97d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/shutdown.sh @@ -0,0 +1,60 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ----------------------------------------------------------------------------- +# Stop script for the CATALINA Server +# ----------------------------------------------------------------------------- + +# Better OS/400 detection: see Bugzilla 31132 +os400=false +case "`uname`" in +OS400*) os400=true;; +esac + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ] ; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +PRGDIR=`dirname "$PRG"` +EXECUTABLE=catalina.sh + +# Check that target executable exists +if $os400; then + # -x will Only work on the os400 if the files are: + # 1. owned by the user + # 2. owned by the PRIMARY group of the user + # this will not work if the user belongs in secondary groups + eval +else + if [ ! -x "$PRGDIR"/"$EXECUTABLE" ]; then + echo "Cannot find $PRGDIR/$EXECUTABLE" + echo "The file is absent or does not have execute permission" + echo "This file is needed to run this program" + exit 1 + fi +fi + +exec "$PRGDIR"/"$EXECUTABLE" stop "$@" diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/startup.bat b/centos8_tomcat/apache-tomcat-7.0.108/bin/startup.bat new file mode 100644 index 0000000..e9f46b8 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/startup.bat @@ -0,0 +1,58 @@ +@echo off +rem Licensed to the Apache Software Foundation (ASF) under one or more +rem contributor license agreements. See the NOTICE file distributed with +rem this work for additional information regarding copyright ownership. +rem The ASF licenses this file to You under the Apache License, Version 2.0 +rem (the "License"); you may not use this file except in compliance with +rem the License. You may obtain a copy of the License at +rem +rem http://www.apache.org/licenses/LICENSE-2.0 +rem +rem Unless required by applicable law or agreed to in writing, software +rem distributed under the License is distributed on an "AS IS" BASIS, +rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +rem See the License for the specific language governing permissions and +rem limitations under the License. + +rem --------------------------------------------------------------------------- +rem Start script for the CATALINA Server +rem --------------------------------------------------------------------------- + +setlocal + +rem Guess CATALINA_HOME if not defined +set "CURRENT_DIR=%cd%" +if not "%CATALINA_HOME%" == "" goto gotHome +set "CATALINA_HOME=%CURRENT_DIR%" +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +cd .. +set "CATALINA_HOME=%cd%" +cd "%CURRENT_DIR%" +:gotHome +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +echo The CATALINA_HOME environment variable is not defined correctly +echo This environment variable is needed to run this program +goto end +:okHome + +set "EXECUTABLE=%CATALINA_HOME%\bin\catalina.bat" + +rem Check that target executable exists +if exist "%EXECUTABLE%" goto okExec +echo Cannot find "%EXECUTABLE%" +echo This file is needed to run this program +goto end +:okExec + +rem Get remaining unshifted command line arguments and save them in the +set CMD_LINE_ARGS= +:setArgs +if ""%1""=="""" goto doneSetArgs +set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1 +shift +goto setArgs +:doneSetArgs + +call "%EXECUTABLE%" start %CMD_LINE_ARGS% + +:end diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/startup.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/startup.sh new file mode 100755 index 0000000..7b10287 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/startup.sh @@ -0,0 +1,60 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ----------------------------------------------------------------------------- +# Start Script for the CATALINA Server +# ----------------------------------------------------------------------------- + +# Better OS/400 detection: see Bugzilla 31132 +os400=false +case "`uname`" in +OS400*) os400=true;; +esac + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ] ; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +PRGDIR=`dirname "$PRG"` +EXECUTABLE=catalina.sh + +# Check that target executable exists +if $os400; then + # -x will Only work on the os400 if the files are: + # 1. owned by the user + # 2. owned by the PRIMARY group of the user + # this will not work if the user belongs in secondary groups + eval +else + if [ ! -x "$PRGDIR"/"$EXECUTABLE" ]; then + echo "Cannot find $PRGDIR/$EXECUTABLE" + echo "The file is absent or does not have execute permission" + echo "This file is needed to run this program" + exit 1 + fi +fi + +exec "$PRGDIR"/"$EXECUTABLE" start "$@" diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/tomcat-juli.jar b/centos8_tomcat/apache-tomcat-7.0.108/bin/tomcat-juli.jar new file mode 100644 index 0000000..5baac09 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/bin/tomcat-juli.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/tomcat-native.tar.gz b/centos8_tomcat/apache-tomcat-7.0.108/bin/tomcat-native.tar.gz new file mode 100644 index 0000000..51883ee Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/bin/tomcat-native.tar.gz differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/tool-wrapper.bat b/centos8_tomcat/apache-tomcat-7.0.108/bin/tool-wrapper.bat new file mode 100644 index 0000000..2d9b9e2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/tool-wrapper.bat @@ -0,0 +1,110 @@ +@echo off +rem Licensed to the Apache Software Foundation (ASF) under one or more +rem contributor license agreements. See the NOTICE file distributed with +rem this work for additional information regarding copyright ownership. +rem The ASF licenses this file to You under the Apache License, Version 2.0 +rem (the "License"); you may not use this file except in compliance with +rem the License. You may obtain a copy of the License at +rem +rem http://www.apache.org/licenses/LICENSE-2.0 +rem +rem Unless required by applicable law or agreed to in writing, software +rem distributed under the License is distributed on an "AS IS" BASIS, +rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +rem See the License for the specific language governing permissions and +rem limitations under the License. + +rem --------------------------------------------------------------------------- +rem Wrapper script for command line tools +rem +rem Environment Variable Prerequisites +rem +rem CATALINA_HOME May point at your Catalina "build" directory. +rem +rem TOOL_OPTS (Optional) Java runtime options. +rem +rem JAVA_HOME Must point at your Java Development Kit installation. +rem Using JRE_HOME instead works as well. +rem +rem JRE_HOME Must point at your Java Runtime installation. +rem Defaults to JAVA_HOME if empty. If JRE_HOME and JAVA_HOME +rem are both set, JRE_HOME is used. +rem +rem JAVA_OPTS (Optional) Java runtime options. +rem +rem JAVA_ENDORSED_DIRS (Optional) Lists of of semi-colon separated directories +rem containing some jars in order to allow replacement of APIs +rem created outside of the JCP (i.e. DOM and SAX from W3C). +rem It can also be used to update the XML parser implementation. +rem This is only supported for Java <= 8. +rem Defaults to $CATALINA_HOME/endorsed. +rem --------------------------------------------------------------------------- + +setlocal + +rem Guess CATALINA_HOME if not defined +set "CURRENT_DIR=%cd%" +if not "%CATALINA_HOME%" == "" goto gotHome +set "CATALINA_HOME=%CURRENT_DIR%" +if exist "%CATALINA_HOME%\bin\tool-wrapper.bat" goto okHome +cd .. +set "CATALINA_HOME=%cd%" +cd "%CURRENT_DIR%" +:gotHome +if exist "%CATALINA_HOME%\bin\tool-wrapper.bat" goto okHome +echo The CATALINA_HOME environment variable is not defined correctly +echo This environment variable is needed to run this program +goto end +:okHome + +rem Ensure that any user defined CLASSPATH variables are not used on startup, +rem but allow them to be specified in setenv.bat, in rare case when it is needed. +set CLASSPATH= + +rem Get standard environment variables +if exist "%CATALINA_HOME%\bin\setenv.bat" call "%CATALINA_HOME%\bin\setenv.bat" + +rem Get standard Java environment variables +if exist "%CATALINA_HOME%\bin\setclasspath.bat" goto okSetclasspath +echo Cannot find "%CATALINA_HOME%\bin\setclasspath.bat" +echo This file is needed to run this program +goto end +:okSetclasspath +call "%CATALINA_HOME%\bin\setclasspath.bat" %1 +if errorlevel 1 goto end + +rem Add on extra jar files to CLASSPATH +rem Note that there are no quotes as we do not want to introduce random +rem quotes into the CLASSPATH +if "%CLASSPATH%" == "" goto emptyClasspath +set "CLASSPATH=%CLASSPATH%;" +:emptyClasspath +set "CLASSPATH=%CLASSPATH%%CATALINA_HOME%\bin\bootstrap.jar;%CATALINA_HOME%\bin\tomcat-juli.jar;%CATALINA_HOME%\lib\servlet-api.jar;%CATALINA_HOME%\lib\tomcat-coyote.jar" + +set JAVA_OPTS=%JAVA_OPTS% -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager + +rem Java 9 no longer supports the java.endorsed.dirs +rem system property. Only try to use it if +rem JAVA_ENDORSED_DIRS was explicitly set +rem or CATALINA_HOME/endorsed exists. +set ENDORSED_PROP=ignore.endorsed.dirs +if "%JAVA_ENDORSED_DIRS%" == "" goto noEndorsedVar +set ENDORSED_PROP=java.endorsed.dirs +goto doneEndorsed +:noEndorsedVar +if not exist "%CATALINA_HOME%\endorsed" goto doneEndorsed +set ENDORSED_PROP=java.endorsed.dirs +:doneEndorsed + +rem Get remaining unshifted command line arguments and save them in the +set CMD_LINE_ARGS= +:setArgs +if ""%1""=="""" goto doneSetArgs +set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1 +shift +goto setArgs +:doneSetArgs + +%_RUNJAVA% %JAVA_OPTS% %TOOL_OPTS% -D%ENDORSED_PROP%="%JAVA_ENDORSED_DIRS%" -classpath "%CLASSPATH%" -Dcatalina.home="%CATALINA_HOME%" org.apache.catalina.startup.Tool %CMD_LINE_ARGS% + +:end diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/tool-wrapper.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/tool-wrapper.sh new file mode 100755 index 0000000..32f61c4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/tool-wrapper.sh @@ -0,0 +1,153 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ----------------------------------------------------------------------------- +# Wrapper script for command line tools +# +# Environment Variable Prerequisites +# +# CATALINA_HOME May point at your Catalina "build" directory. +# +# TOOL_OPTS (Optional) Java runtime options. +# +# JAVA_HOME Must point at your Java Development Kit installation. +# Using JRE_HOME instead works as well. +# +# JRE_HOME Must point at your Java Runtime installation. +# Defaults to JAVA_HOME if empty. If JRE_HOME and JAVA_HOME +# are both set, JRE_HOME is used. +# +# JAVA_OPTS (Optional) Java runtime options. +# +# JAVA_ENDORSED_DIRS (Optional) Lists of of colon separated directories +# containing some jars in order to allow replacement of APIs +# created outside of the JCP (i.e. DOM and SAX from W3C). +# It can also be used to update the XML parser implementation. +# This is only supported for Java <= 8. +# Defaults to $CATALINA_HOME/endorsed. +# ----------------------------------------------------------------------------- + +# OS specific support. $var _must_ be set to either true or false. +cygwin=false +darwin=false +os400=false +case "`uname`" in +CYGWIN*) cygwin=true;; +Darwin*) darwin=true;; +OS400*) os400=true;; +esac + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ]; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +# Get standard environment variables +PRGDIR=`dirname "$PRG"` + +# Only set CATALINA_HOME if not already set +[ -z "$CATALINA_HOME" ] && CATALINA_HOME=`cd "$PRGDIR/.." >/dev/null; pwd` + +# Ensure that any user defined CLASSPATH variables are not used on startup, +# but allow them to be specified in setenv.sh, in rare case when it is needed. +CLASSPATH= + +if [ -r "$CATALINA_HOME/bin/setenv.sh" ]; then + . "$CATALINA_HOME/bin/setenv.sh" +fi + +# For Cygwin, ensure paths are in UNIX format before anything is touched +if $cygwin; then + [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"` + [ -n "$JRE_HOME" ] && JRE_HOME=`cygpath --unix "$JRE_HOME"` + [ -n "$CATALINA_HOME" ] && CATALINA_HOME=`cygpath --unix "$CATALINA_HOME"` + [ -n "$CLASSPATH" ] && CLASSPATH=`cygpath --path --unix "$CLASSPATH"` +fi + +# For OS400 +if $os400; then + # Set job priority to standard for interactive (interactive - 6) by using + # the interactive priority - 6, the helper threads that respond to requests + # will be running at the same priority as interactive jobs. + COMMAND='chgjob job('$JOBNAME') runpty(6)' + system $COMMAND + + # Enable multi threading + export QIBM_MULTI_THREADED=Y +fi + +# Get standard Java environment variables +if $os400; then + # -r will Only work on the os400 if the files are: + # 1. owned by the user + # 2. owned by the PRIMARY group of the user + # this will not work if the user belongs in secondary groups + . "$CATALINA_HOME"/bin/setclasspath.sh +else + if [ -r "$CATALINA_HOME"/bin/setclasspath.sh ]; then + . "$CATALINA_HOME"/bin/setclasspath.sh + else + echo "Cannot find $CATALINA_HOME/bin/setclasspath.sh" + echo "This file is needed to run this program" + exit 1 + fi +fi + +# Add on extra jar files to CLASSPATH +if [ ! -z "$CLASSPATH" ] ; then + CLASSPATH="$CLASSPATH": +fi +CLASSPATH="$CLASSPATH""$CATALINA_HOME"/bin/bootstrap.jar:"$CATALINA_HOME"/bin/tomcat-juli.jar:"$CATALINA_HOME"/lib/servlet-api.jar:"$CATALINA_HOME"/lib/tomcat-coyote.jar + +# For Cygwin, switch paths to Windows format before running java +if $cygwin; then + JAVA_HOME=`cygpath --absolute --windows "$JAVA_HOME"` + JRE_HOME=`cygpath --absolute --windows "$JRE_HOME"` + CATALINA_HOME=`cygpath --absolute --windows "$CATALINA_HOME"` + CLASSPATH=`cygpath --path --windows "$CLASSPATH"` + [ -n "$JAVA_ENDORSED_DIRS" ] && JAVA_ENDORSED_DIRS=`cygpath --path --windows "$JAVA_ENDORSED_DIRS"` +fi + +# Java 9 no longer supports the java.endorsed.dirs +# system property. Only try to use it if +# JAVA_ENDORSED_DIRS was explicitly set +# or CATALINA_HOME/endorsed exists. +ENDORSED_PROP=ignore.endorsed.dirs +if [ -n "$JAVA_ENDORSED_DIRS" ]; then + ENDORSED_PROP=java.endorsed.dirs +fi +if [ -d "$CATALINA_HOME/endorsed" ]; then + ENDORSED_PROP=java.endorsed.dirs +fi + +JAVA_OPTS="$JAVA_OPTS -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager" + +# ----- Execute The Requested Command ----------------------------------------- + +eval exec "\"$_RUNJAVA\"" "$JAVA_OPTS" "$TOOL_OPTS" \ + -D$ENDORSED_PROP="\"$JAVA_ENDORSED_DIRS\"" \ + -classpath "\"$CLASSPATH\"" \ + -Dcatalina.home="\"$CATALINA_HOME\"" \ + org.apache.catalina.startup.Tool "$@" diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/version.bat b/centos8_tomcat/apache-tomcat-7.0.108/bin/version.bat new file mode 100644 index 0000000..d294f76 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/version.bat @@ -0,0 +1,58 @@ +@echo off +rem Licensed to the Apache Software Foundation (ASF) under one or more +rem contributor license agreements. See the NOTICE file distributed with +rem this work for additional information regarding copyright ownership. +rem The ASF licenses this file to You under the Apache License, Version 2.0 +rem (the "License"); you may not use this file except in compliance with +rem the License. You may obtain a copy of the License at +rem +rem http://www.apache.org/licenses/LICENSE-2.0 +rem +rem Unless required by applicable law or agreed to in writing, software +rem distributed under the License is distributed on an "AS IS" BASIS, +rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +rem See the License for the specific language governing permissions and +rem limitations under the License. + +rem --------------------------------------------------------------------------- +rem Version script for the CATALINA Server +rem --------------------------------------------------------------------------- + +setlocal + +rem Guess CATALINA_HOME if not defined +set "CURRENT_DIR=%cd%" +if not "%CATALINA_HOME%" == "" goto gotHome +set "CATALINA_HOME=%CURRENT_DIR%" +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +cd .. +set "CATALINA_HOME=%cd%" +cd "%CURRENT_DIR%" +:gotHome +if exist "%CATALINA_HOME%\bin\catalina.bat" goto okHome +echo The CATALINA_HOME environment variable is not defined correctly +echo This environment variable is needed to run this program +goto end +:okHome + +set "EXECUTABLE=%CATALINA_HOME%\bin\catalina.bat" + +rem Check that target executable exists +if exist "%EXECUTABLE%" goto okExec +echo Cannot find "%EXECUTABLE%" +echo This file is needed to run this program +goto end +:okExec + +rem Get remaining unshifted command line arguments and save them in the +set CMD_LINE_ARGS= +:setArgs +if ""%1""=="""" goto doneSetArgs +set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1 +shift +goto setArgs +:doneSetArgs + +call "%EXECUTABLE%" version %CMD_LINE_ARGS% + +:end diff --git a/centos8_tomcat/apache-tomcat-7.0.108/bin/version.sh b/centos8_tomcat/apache-tomcat-7.0.108/bin/version.sh new file mode 100755 index 0000000..1cb19bd --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/bin/version.sh @@ -0,0 +1,60 @@ +#!/bin/sh + +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# ----------------------------------------------------------------------------- +# Version Script for the CATALINA Server +# ----------------------------------------------------------------------------- + +# Better OS/400 detection: see Bugzilla 31132 +os400=false +case "`uname`" in +OS400*) os400=true;; +esac + +# resolve links - $0 may be a softlink +PRG="$0" + +while [ -h "$PRG" ] ; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`/"$link" + fi +done + +PRGDIR=`dirname "$PRG"` +EXECUTABLE=catalina.sh + +# Check that target executable exists +if $os400; then + # -x will Only work on the os400 if the files are: + # 1. owned by the user + # 2. owned by the PRIMARY group of the user + # this will not work if the user belongs in secondary groups + eval +else + if [ ! -x "$PRGDIR"/"$EXECUTABLE" ]; then + echo "Cannot find $PRGDIR/$EXECUTABLE" + echo "The file is absent or does not have execute permission" + echo "This file is needed to run this program" + exit 1 + fi +fi + +exec "$PRGDIR"/"$EXECUTABLE" version "$@" diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/catalina.policy b/centos8_tomcat/apache-tomcat-7.0.108/conf/catalina.policy new file mode 100644 index 0000000..3e16824 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/conf/catalina.policy @@ -0,0 +1,268 @@ +// Licensed to the Apache Software Foundation (ASF) under one or more +// contributor license agreements. See the NOTICE file distributed with +// this work for additional information regarding copyright ownership. +// The ASF licenses this file to You under the Apache License, Version 2.0 +// (the "License"); you may not use this file except in compliance with +// the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// ============================================================================ +// catalina.policy - Security Policy Permissions for Tomcat 7 +// +// This file contains a default set of security policies to be enforced (by the +// JVM) when Catalina is executed with the "-security" option. In addition +// to the permissions granted here, the following additional permissions are +// granted to each web application: +// +// * Read access to the web application's document root directory +// * Read, write and delete access to the web application's working directory +// ============================================================================ + + +// ========== SYSTEM CODE PERMISSIONS ========================================= + + +// These permissions apply to javac +grant codeBase "file:${java.home}/lib/-" { + permission java.security.AllPermission; +}; + +// These permissions apply to all shared system extensions +grant codeBase "file:${java.home}/jre/lib/ext/-" { + permission java.security.AllPermission; +}; + +// These permissions apply to javac when ${java.home} points at $JAVA_HOME/jre +grant codeBase "file:${java.home}/../lib/-" { + permission java.security.AllPermission; +}; + +// These permissions apply to all shared system extensions when +// ${java.home} points at $JAVA_HOME/jre +grant codeBase "file:${java.home}/lib/ext/-" { + permission java.security.AllPermission; +}; + + +// ========== CATALINA CODE PERMISSIONS ======================================= + + +// These permissions apply to the daemon code +grant codeBase "file:${catalina.home}/bin/commons-daemon.jar" { + permission java.security.AllPermission; +}; + +// These permissions apply to the logging API +// Note: If tomcat-juli.jar is in ${catalina.base} and not in ${catalina.home}, +// update this section accordingly. +// grant codeBase "file:${catalina.base}/bin/tomcat-juli.jar" {..} +grant codeBase "file:${catalina.home}/bin/tomcat-juli.jar" { + permission java.io.FilePermission + "${java.home}${file.separator}lib${file.separator}logging.properties", "read"; + + permission java.io.FilePermission + "${catalina.base}${file.separator}conf${file.separator}logging.properties", "read"; + permission java.io.FilePermission + "${catalina.base}${file.separator}logs", "read, write"; + permission java.io.FilePermission + "${catalina.base}${file.separator}logs${file.separator}*", "read, write, delete"; + + permission java.lang.RuntimePermission "shutdownHooks"; + permission java.lang.RuntimePermission "getClassLoader"; + permission java.lang.RuntimePermission "setContextClassLoader"; + + permission java.util.logging.LoggingPermission "control"; + + permission java.util.PropertyPermission "java.util.logging.config.class", "read"; + permission java.util.PropertyPermission "java.util.logging.config.file", "read"; + permission java.util.PropertyPermission "org.apache.juli.ClassLoaderLogManager.debug", "read"; + permission java.util.PropertyPermission "catalina.base", "read"; + + // Note: To enable per context logging configuration, permit read access to + // the appropriate file. Be sure that the logging configuration is + // secure before enabling such access. + // E.g. for the examples web application (uncomment and unwrap + // the following to be on a single line): + // permission java.io.FilePermission "${catalina.base}${file.separator} + // webapps${file.separator}examples${file.separator}WEB-INF + // ${file.separator}classes${file.separator}logging.properties", "read"; +}; + +// These permissions apply to the server startup code +grant codeBase "file:${catalina.home}/bin/bootstrap.jar" { + permission java.security.AllPermission; +}; + +// These permissions apply to the servlet API classes +// and those that are shared across all class loaders +// located in the "lib" directory +grant codeBase "file:${catalina.home}/lib/-" { + permission java.security.AllPermission; +}; + + +// If using a per instance lib directory, i.e. ${catalina.base}/lib, +// then the following permission will need to be uncommented +// grant codeBase "file:${catalina.base}/lib/-" { +// permission java.security.AllPermission; +// }; + + +// ========== WEB APPLICATION PERMISSIONS ===================================== + + +// These permissions are granted by default to all web applications +// In addition, a web application will be given a read FilePermission +// and JndiPermission for all files and directories in its document root. +grant { + // Required for JNDI lookup of named JDBC DataSource's and + // javamail named MimePart DataSource used to send mail + permission java.util.PropertyPermission "java.home", "read"; + permission java.util.PropertyPermission "java.naming.*", "read"; + permission java.util.PropertyPermission "javax.sql.*", "read"; + + // OS Specific properties to allow read access + permission java.util.PropertyPermission "os.name", "read"; + permission java.util.PropertyPermission "os.version", "read"; + permission java.util.PropertyPermission "os.arch", "read"; + permission java.util.PropertyPermission "file.separator", "read"; + permission java.util.PropertyPermission "path.separator", "read"; + permission java.util.PropertyPermission "line.separator", "read"; + + // JVM properties to allow read access + permission java.util.PropertyPermission "java.version", "read"; + permission java.util.PropertyPermission "java.vendor", "read"; + permission java.util.PropertyPermission "java.vendor.url", "read"; + permission java.util.PropertyPermission "java.class.version", "read"; + permission java.util.PropertyPermission "java.specification.version", "read"; + permission java.util.PropertyPermission "java.specification.vendor", "read"; + permission java.util.PropertyPermission "java.specification.name", "read"; + + permission java.util.PropertyPermission "java.vm.specification.version", "read"; + permission java.util.PropertyPermission "java.vm.specification.vendor", "read"; + permission java.util.PropertyPermission "java.vm.specification.name", "read"; + permission java.util.PropertyPermission "java.vm.version", "read"; + permission java.util.PropertyPermission "java.vm.vendor", "read"; + permission java.util.PropertyPermission "java.vm.name", "read"; + + // Required for OpenJMX + permission java.lang.RuntimePermission "getAttribute"; + + // Allow read of JAXP compliant XML parser debug + permission java.util.PropertyPermission "jaxp.debug", "read"; + + // All JSPs need to be able to read this package + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.tomcat"; + + // Precompiled JSPs need access to these packages. + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.jasper.el"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.jasper.runtime"; + permission java.lang.RuntimePermission + "accessClassInPackage.org.apache.jasper.runtime.*"; + + // Precompiled JSPs need access to these system properties. + + // The following two permissions are no longer needed since Tomcat 7.0.88 + // They are here for historic reasons. There is no harm in keeping them. + permission java.util.PropertyPermission + "org.apache.jasper.runtime.BodyContentImpl.LIMIT_BUFFER", "read"; + permission java.util.PropertyPermission + "org.apache.el.parser.COERCE_TO_ZERO", "read"; + + // The cookie code needs these. + permission java.util.PropertyPermission + "org.apache.catalina.STRICT_SERVLET_COMPLIANCE", "read"; + permission java.util.PropertyPermission + "org.apache.tomcat.util.http.ServerCookie.STRICT_NAMING", "read"; + permission java.util.PropertyPermission + "org.apache.tomcat.util.http.ServerCookie.FWD_SLASH_IS_SEPARATOR", "read"; + + // Applications using Comet need to be able to access this package + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.comet"; + + // Applications using the legacy WebSocket implementation need to be able to access this package + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.websocket"; + + // Applications using the JSR-356 WebSocket implementation need to be able to access these packages + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.tomcat.websocket"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.tomcat.websocket.server"; +}; + + +// The Manager application needs access to the following packages to support the +// session display functionality. It also requires the custom Tomcat +// DeployXmlPermission to enable the use of META-INF/context.xml +// These settings support the following configurations: +// - default CATALINA_HOME == CATALINA_BASE +// - CATALINA_HOME != CATALINA_BASE, per instance Manager in CATALINA_BASE +// - CATALINA_HOME != CATALINA_BASE, shared Manager in CATALINA_HOME +grant codeBase "file:${catalina.base}/webapps/manager/-" { + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.ha.session"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.manager"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.manager.util"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.util"; + permission org.apache.catalina.security.DeployXmlPermission "manager"; +}; +grant codeBase "file:${catalina.home}/webapps/manager/-" { + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.ha.session"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.manager"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.manager.util"; + permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.util"; + permission org.apache.catalina.security.DeployXmlPermission "manager"; +}; + +// The Host Manager application needs the custom Tomcat DeployXmlPermission to +// enable the use of META-INF/context.xml +// These settings support the following configurations: +// - default CATALINA_HOME == CATALINA_BASE +// - CATALINA_HOME != CATALINA_BASE, per instance Host Manager in CATALINA_BASE +// - CATALINA_HOME != CATALINA_BASE, shared Host Manager in CATALINA_HOME +grant codeBase "file:${catalina.base}/webapps/host-manager/-" { + permission org.apache.catalina.security.DeployXmlPermission "host-manager"; +}; +grant codeBase "file:${catalina.home}/webapps/host-manager/-" { + permission org.apache.catalina.security.DeployXmlPermission "host-manager"; +}; + + +// You can assign additional permissions to particular web applications by +// adding additional "grant" entries here, based on the code base for that +// application, /WEB-INF/classes/, or /WEB-INF/lib/ jar files. +// +// Different permissions can be granted to JSP pages, classes loaded from +// the /WEB-INF/classes/ directory, all jar files in the /WEB-INF/lib/ +// directory, or even to individual jar files in the /WEB-INF/lib/ directory. +// +// For instance, assume that the standard "examples" application +// included a JDBC driver that needed to establish a network connection to the +// corresponding database and used the scrape taglib to get the weather from +// the NOAA web server. You might create a "grant" entries like this: +// +// The permissions granted to the context root directory apply to JSP pages. +// grant codeBase "file:${catalina.base}/webapps/examples/-" { +// permission java.net.SocketPermission "dbhost.mycompany.com:5432", "connect"; +// permission java.net.SocketPermission "*.noaa.gov:80", "connect"; +// }; +// +// The permissions granted to the context WEB-INF/classes directory +// grant codeBase "file:${catalina.base}/webapps/examples/WEB-INF/classes/-" { +// }; +// +// The permission granted to your JDBC driver +// grant codeBase "jar:file:${catalina.base}/webapps/examples/WEB-INF/lib/driver.jar!/-" { +// permission java.net.SocketPermission "dbhost.mycompany.com:5432", "connect"; +// }; +// The permission granted to the scrape taglib +// grant codeBase "jar:file:${catalina.base}/webapps/examples/WEB-INF/lib/scrape.jar!/-" { +// permission java.net.SocketPermission "*.noaa.gov:80", "connect"; +// }; + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/catalina.properties b/centos8_tomcat/apache-tomcat-7.0.108/conf/catalina.properties new file mode 100644 index 0000000..926e5f6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/conf/catalina.properties @@ -0,0 +1,195 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# +# List of comma-separated packages that start with or equal this string +# will cause a security exception to be thrown when +# passed to checkPackageAccess unless the +# corresponding RuntimePermission ("accessClassInPackage."+package) has +# been granted. +package.access=sun.,org.apache.catalina.,org.apache.coyote.,org.apache.jasper.,\ +org.apache.naming.resources.,org.apache.tomcat. +# +# List of comma-separated packages that start with or equal this string +# will cause a security exception to be thrown when +# passed to checkPackageDefinition unless the +# corresponding RuntimePermission ("defineClassInPackage."+package) has +# been granted. +# +# by default, no packages are restricted for definition, and none of +# the class loaders supplied with the JDK call checkPackageDefinition. +# +package.definition=sun.,java.,org.apache.catalina.,org.apache.coyote.,\ +org.apache.jasper.,org.apache.naming.,org.apache.tomcat. + +# +# +# List of comma-separated paths defining the contents of the "common" +# classloader. Prefixes should be used to define what is the repository type. +# Path may be relative to the CATALINA_HOME or CATALINA_BASE path or absolute. +# If left as blank,the JVM system loader will be used as Catalina's "common" +# loader. +# Examples: +# "foo": Add this folder as a class repository +# "foo/*.jar": Add all the JARs of the specified folder as class +# repositories +# "foo/bar.jar": Add bar.jar as a class repository +common.loader=${catalina.base}/lib,${catalina.base}/lib/*.jar,${catalina.home}/lib,${catalina.home}/lib/*.jar + +# +# List of comma-separated paths defining the contents of the "server" +# classloader. Prefixes should be used to define what is the repository type. +# Path may be relative to the CATALINA_HOME or CATALINA_BASE path or absolute. +# If left as blank, the "common" loader will be used as Catalina's "server" +# loader. +# Examples: +# "foo": Add this folder as a class repository +# "foo/*.jar": Add all the JARs of the specified folder as class +# repositories +# "foo/bar.jar": Add bar.jar as a class repository +server.loader= + +# +# List of comma-separated paths defining the contents of the "shared" +# classloader. Prefixes should be used to define what is the repository type. +# Path may be relative to the CATALINA_BASE path or absolute. If left as blank, +# the "common" loader will be used as Catalina's "shared" loader. +# Examples: +# "foo": Add this folder as a class repository +# "foo/*.jar": Add all the JARs of the specified folder as class +# repositories +# "foo/bar.jar": Add bar.jar as a class repository +# Please note that for single jars, e.g. bar.jar, you need the URL form +# starting with file:. +shared.loader= + +# List of JAR files that should not be scanned using the JarScanner +# functionality. This is typically used to scan JARs for configuration +# information. JARs that do not contain such information may be excluded from +# the scan to speed up the scanning process. This is the default list. JARs on +# this list are excluded from all scans. Scan specific lists (to exclude JARs +# from individual scans) follow this. The list must be a comma separated list of +# JAR file names. +# The JARs listed below include: +# - Tomcat Bootstrap JARs +# - Tomcat API JARs +# - Catalina JARs +# - Jasper JARs +# - Tomcat JARs +# - Common non-Tomcat JARs +# - Test JARs (JUnit, Cobertura and dependencies) +tomcat.util.scan.DefaultJarScanner.jarsToSkip=\ +annotations-api.jar,\ +ant-junit*.jar,\ +ant-launcher.jar,\ +ant.jar,\ +asm-*.jar,\ +aspectj*.jar,\ +bootstrap.jar,\ +catalina-ant.jar,\ +catalina-ha.jar,\ +catalina-jmx-remote.jar,\ +catalina-tribes.jar,\ +catalina-ws.jar,\ +catalina.jar,\ +cobertura-*.jar,\ +commons-beanutils*.jar,\ +commons-codec*.jar,\ +commons-collections*.jar,\ +commons-daemon.jar,\ +commons-dbcp*.jar,\ +commons-digester*.jar,\ +commons-fileupload*.jar,\ +commons-httpclient*.jar,\ +commons-io*.jar,\ +commons-lang*.jar,\ +commons-logging*.jar,\ +commons-math*.jar,\ +commons-pool*.jar,\ +dom4j-*.jar,\ +ecj-*.jar,\ +el-api.jar,\ +geronimo-spec-jaxrpc*.jar,\ +h2*.jar,\ +hamcrest-*.jar,\ +hibernate*.jar,\ +httpclient*.jar,\ +icu4j-*.jar,\ +jasper-el.jar,\ +jasper.jar,\ +jaxb-*.jar,\ +jaxen-*.jar,\ +jdom-*.jar,\ +jetty-*.jar,\ +jmx-tools.jar,\ +jmx.jar,\ +jsp-api.jar,\ +jstl.jar,\ +jta*.jar,\ +junit-*.jar,\ +junit.jar,\ +log4j-1*.jar,\ +log4j*.jar,\ +mail*.jar,\ +org.hamcrest.*.jar,\ +oraclepki.jar,\ +oro-*.jar,\ +servlet-api-*.jar,\ +servlet-api.jar,\ +slf4j*.jar,\ +taglibs-standard-spec-*.jar,\ +tagsoup-*.jar,\ +tomcat-api.jar,\ +tomcat-coyote.jar,\ +tomcat-dbcp.jar,\ +tomcat-i18n-*.jar,\ +tomcat-jdbc.jar,\ +tomcat-jni.jar,\ +tomcat-juli-adapters.jar,\ +tomcat-juli.jar,\ +tomcat-spdy.jar,\ +tomcat-util.jar,\ +tools.jar,\ +websocket-api.jar,\ +wsdl4j*.jar,\ +xercesImpl.jar,\ +xml-apis.jar,\ +xmlParserAPIs-*.jar,\ +xmlParserAPIs.jar,\ +xom-*.jar + +# Additional JARs (over and above the default JARs listed above) to skip when +# scanning for Servlet 3.0 pluggability features. These features include web +# fragments, annotations, SCIs and classes that match @HandlesTypes. The list +# must be a comma separated list of JAR file names. +org.apache.catalina.startup.ContextConfig.jarsToSkip= + +# Additional JARs (over and above the default JARs listed above) to skip when +# scanning for TLDs. The list must be a comma separated list of JAR file names. +org.apache.catalina.startup.TldConfig.jarsToSkip=tomcat7-websocket.jar + +# +# String cache configuration. +tomcat.util.buf.StringCache.byte.enabled=true +#tomcat.util.buf.StringCache.char.enabled=true +#tomcat.util.buf.StringCache.trainThreshold=500000 +#tomcat.util.buf.StringCache.cacheSize=5000 + +# This system property is deprecated. Use the relaxedPathChars relaxedQueryChars +# attributes of the Connector instead. These attributes permit a wider range of +# characters to be configured as valid. +# Allow for changes to HTTP request validation +# WARNING: Using this option may expose the server to CVE-2016-6816 +#tomcat.util.http.parser.HttpParser.requestTargetAllow=| diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/context.xml b/centos8_tomcat/apache-tomcat-7.0.108/conf/context.xml new file mode 100644 index 0000000..7583804 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/conf/context.xml @@ -0,0 +1,46 @@ + + + + + + + WEB-INF/web.xml + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/logging.properties b/centos8_tomcat/apache-tomcat-7.0.108/conf/logging.properties new file mode 100644 index 0000000..96156de --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/conf/logging.properties @@ -0,0 +1,69 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +handlers = 1catalina.org.apache.juli.FileHandler, 2localhost.org.apache.juli.FileHandler, 3manager.org.apache.juli.FileHandler, 4host-manager.org.apache.juli.FileHandler, java.util.logging.ConsoleHandler + +.handlers = 1catalina.org.apache.juli.FileHandler, java.util.logging.ConsoleHandler + +############################################################ +# Handler specific properties. +# Describes specific configuration info for Handlers. +############################################################ + +1catalina.org.apache.juli.FileHandler.level = FINE +1catalina.org.apache.juli.FileHandler.directory = ${catalina.base}/logs +1catalina.org.apache.juli.FileHandler.prefix = catalina. +1catalina.org.apache.juli.FileHandler.encoding = UTF-8 + +2localhost.org.apache.juli.FileHandler.level = FINE +2localhost.org.apache.juli.FileHandler.directory = ${catalina.base}/logs +2localhost.org.apache.juli.FileHandler.prefix = localhost. +2localhost.org.apache.juli.FileHandler.encoding = UTF-8 + +3manager.org.apache.juli.FileHandler.level = FINE +3manager.org.apache.juli.FileHandler.directory = ${catalina.base}/logs +3manager.org.apache.juli.FileHandler.prefix = manager. +3manager.org.apache.juli.FileHandler.encoding = UTF-8 + +4host-manager.org.apache.juli.FileHandler.level = FINE +4host-manager.org.apache.juli.FileHandler.directory = ${catalina.base}/logs +4host-manager.org.apache.juli.FileHandler.prefix = host-manager. +4host-manager.org.apache.juli.FileHandler.encoding = UTF-8 + +java.util.logging.ConsoleHandler.level = FINE +java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter +java.util.logging.ConsoleHandler.encoding = UTF-8 + + +############################################################ +# Facility specific properties. +# Provides extra control for each logger. +############################################################ + +org.apache.catalina.core.ContainerBase.[Catalina].[localhost].level = INFO +org.apache.catalina.core.ContainerBase.[Catalina].[localhost].handlers = 2localhost.org.apache.juli.FileHandler + +org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].level = INFO +org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].handlers = 3manager.org.apache.juli.FileHandler + +org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager].level = INFO +org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager].handlers = 4host-manager.org.apache.juli.FileHandler + +# For example, set the org.apache.catalina.util.LifecycleBase logger to log +# each component that extends LifecycleBase changing state: +#org.apache.catalina.util.LifecycleBase.level = FINE + +# To see debug messages in TldLocationsCache, uncomment the following line: +#org.apache.jasper.compiler.TldLocationsCache.level = FINE diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/server.xml b/centos8_tomcat/apache-tomcat-7.0.108/conf/server.xml new file mode 100644 index 0000000..8faa3a0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/conf/server.xml @@ -0,0 +1,149 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat-users.xml b/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat-users.xml new file mode 100644 index 0000000..a41ece3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat-users.xml @@ -0,0 +1,46 @@ + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat-users.xsd b/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat-users.xsd new file mode 100644 index 0000000..948bd01 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat-users.xsd @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat_ssl.pfx b/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat_ssl.pfx new file mode 100644 index 0000000..1799cb7 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/conf/tomcat_ssl.pfx differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/conf/web.xml b/centos8_tomcat/apache-tomcat-7.0.108/conf/web.xml new file mode 100644 index 0000000..cf5bdd2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/conf/web.xml @@ -0,0 +1,4712 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + default + org.apache.catalina.servlets.DefaultServlet + + debug + 0 + + + listings + false + + 1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + jsp + org.apache.jasper.servlet.JspServlet + + fork + false + + + xpoweredBy + false + + 3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + default + / + + + + + jsp + *.jsp + *.jspx + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + setCharacterEncodingFilter + org.apache.catalina.filters.SetCharacterEncodingFilter + + encoding + UTF-8 + + true + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + setCharacterEncodingFilter + /* + + + + + + + + + + + + + + + 540 + + + + + + + + + + + + + 123 + application/vnd.lotus-1-2-3 + + + 3dml + text/vnd.in3d.3dml + + + 3ds + image/x-3ds + + + 3g2 + video/3gpp2 + + + 3gp + video/3gpp + + + 7z + application/x-7z-compressed + + + aab + application/x-authorware-bin + + + aac + audio/x-aac + + + aam + application/x-authorware-map + + + aas + application/x-authorware-seg + + + abs + audio/x-mpeg + + + abw + application/x-abiword + + + ac + application/pkix-attr-cert + + + acc + application/vnd.americandynamics.acc + + + ace + application/x-ace-compressed + + + acu + application/vnd.acucobol + + + acutc + application/vnd.acucorp + + + adp + audio/adpcm + + + aep + application/vnd.audiograph + + + afm + application/x-font-type1 + + + afp + application/vnd.ibm.modcap + + + ahead + application/vnd.ahead.space + + + ai + application/postscript + + + aif + audio/x-aiff + + + aifc + audio/x-aiff + + + aiff + audio/x-aiff + + + aim + application/x-aim + + + air + application/vnd.adobe.air-application-installer-package+zip + + + ait + application/vnd.dvb.ait + + + ami + application/vnd.amiga.ami + + + anx + application/annodex + + + apk + application/vnd.android.package-archive + + + appcache + text/cache-manifest + + + application + application/x-ms-application + + + apr + application/vnd.lotus-approach + + + arc + application/x-freearc + + + art + image/x-jg + + + asc + application/pgp-signature + + + asf + video/x-ms-asf + + + asm + text/x-asm + + + aso + application/vnd.accpac.simply.aso + + + asx + video/x-ms-asf + + + atc + application/vnd.acucorp + + + atom + application/atom+xml + + + atomcat + application/atomcat+xml + + + atomsvc + application/atomsvc+xml + + + atx + application/vnd.antix.game-component + + + au + audio/basic + + + avi + video/x-msvideo + + + avx + video/x-rad-screenplay + + + aw + application/applixware + + + axa + audio/annodex + + + axv + video/annodex + + + azf + application/vnd.airzip.filesecure.azf + + + azs + application/vnd.airzip.filesecure.azs + + + azw + application/vnd.amazon.ebook + + + bat + application/x-msdownload + + + bcpio + application/x-bcpio + + + bdf + application/x-font-bdf + + + bdm + application/vnd.syncml.dm+wbxml + + + bed + application/vnd.realvnc.bed + + + bh2 + application/vnd.fujitsu.oasysprs + + + bin + application/octet-stream + + + blb + application/x-blorb + + + blorb + application/x-blorb + + + bmi + application/vnd.bmi + + + bmp + image/bmp + + + body + text/html + + + book + application/vnd.framemaker + + + box + application/vnd.previewsystems.box + + + boz + application/x-bzip2 + + + bpk + application/octet-stream + + + btif + image/prs.btif + + + bz + application/x-bzip + + + bz2 + application/x-bzip2 + + + c + text/x-c + + + c11amc + application/vnd.cluetrust.cartomobile-config + + + c11amz + application/vnd.cluetrust.cartomobile-config-pkg + + + c4d + application/vnd.clonk.c4group + + + c4f + application/vnd.clonk.c4group + + + c4g + application/vnd.clonk.c4group + + + c4p + application/vnd.clonk.c4group + + + c4u + application/vnd.clonk.c4group + + + cab + application/vnd.ms-cab-compressed + + + caf + audio/x-caf + + + cap + application/vnd.tcpdump.pcap + + + car + application/vnd.curl.car + + + cat + application/vnd.ms-pki.seccat + + + cb7 + application/x-cbr + + + cba + application/x-cbr + + + cbr + application/x-cbr + + + cbt + application/x-cbr + + + cbz + application/x-cbr + + + cc + text/x-c + + + cct + application/x-director + + + ccxml + application/ccxml+xml + + + cdbcmsg + application/vnd.contact.cmsg + + + cdf + application/x-cdf + + + cdkey + application/vnd.mediastation.cdkey + + + cdmia + application/cdmi-capability + + + cdmic + application/cdmi-container + + + cdmid + application/cdmi-domain + + + cdmio + application/cdmi-object + + + cdmiq + application/cdmi-queue + + + cdx + chemical/x-cdx + + + cdxml + application/vnd.chemdraw+xml + + + cdy + application/vnd.cinderella + + + cer + application/pkix-cert + + + cfs + application/x-cfs-compressed + + + cgm + image/cgm + + + chat + application/x-chat + + + chm + application/vnd.ms-htmlhelp + + + chrt + application/vnd.kde.kchart + + + cif + chemical/x-cif + + + cii + application/vnd.anser-web-certificate-issue-initiation + + + cil + application/vnd.ms-artgalry + + + cla + application/vnd.claymore + + + class + application/java + + + clkk + application/vnd.crick.clicker.keyboard + + + clkp + application/vnd.crick.clicker.palette + + + clkt + application/vnd.crick.clicker.template + + + clkw + application/vnd.crick.clicker.wordbank + + + clkx + application/vnd.crick.clicker + + + clp + application/x-msclip + + + cmc + application/vnd.cosmocaller + + + cmdf + chemical/x-cmdf + + + cml + chemical/x-cml + + + cmp + application/vnd.yellowriver-custom-menu + + + cmx + image/x-cmx + + + cod + application/vnd.rim.cod + + + com + application/x-msdownload + + + conf + text/plain + + + cpio + application/x-cpio + + + cpp + text/x-c + + + cpt + application/mac-compactpro + + + crd + application/x-mscardfile + + + crl + application/pkix-crl + + + crt + application/x-x509-ca-cert + + + cryptonote + application/vnd.rig.cryptonote + + + csh + application/x-csh + + + csml + chemical/x-csml + + + csp + application/vnd.commonspace + + + css + text/css + + + cst + application/x-director + + + csv + text/csv + + + cu + application/cu-seeme + + + curl + text/vnd.curl + + + cww + application/prs.cww + + + cxt + application/x-director + + + cxx + text/x-c + + + dae + model/vnd.collada+xml + + + daf + application/vnd.mobius.daf + + + dart + application/vnd.dart + + + dataless + application/vnd.fdsn.seed + + + davmount + application/davmount+xml + + + dbk + application/docbook+xml + + + dcr + application/x-director + + + dcurl + text/vnd.curl.dcurl + + + dd2 + application/vnd.oma.dd2+xml + + + ddd + application/vnd.fujixerox.ddd + + + deb + application/x-debian-package + + + def + text/plain + + + deploy + application/octet-stream + + + der + application/x-x509-ca-cert + + + dfac + application/vnd.dreamfactory + + + dgc + application/x-dgc-compressed + + + dib + image/bmp + + + dic + text/x-c + + + dir + application/x-director + + + dis + application/vnd.mobius.dis + + + dist + application/octet-stream + + + distz + application/octet-stream + + + djv + image/vnd.djvu + + + djvu + image/vnd.djvu + + + dll + application/x-msdownload + + + dmg + application/x-apple-diskimage + + + dmp + application/vnd.tcpdump.pcap + + + dms + application/octet-stream + + + dna + application/vnd.dna + + + doc + application/msword + + + docm + application/vnd.ms-word.document.macroenabled.12 + + + docx + application/vnd.openxmlformats-officedocument.wordprocessingml.document + + + dot + application/msword + + + dotm + application/vnd.ms-word.template.macroenabled.12 + + + dotx + application/vnd.openxmlformats-officedocument.wordprocessingml.template + + + dp + application/vnd.osgi.dp + + + dpg + application/vnd.dpgraph + + + dra + audio/vnd.dra + + + dsc + text/prs.lines.tag + + + dssc + application/dssc+der + + + dtb + application/x-dtbook+xml + + + dtd + application/xml-dtd + + + dts + audio/vnd.dts + + + dtshd + audio/vnd.dts.hd + + + dump + application/octet-stream + + + dv + video/x-dv + + + dvb + video/vnd.dvb.file + + + dvi + application/x-dvi + + + dwf + model/vnd.dwf + + + dwg + image/vnd.dwg + + + dxf + image/vnd.dxf + + + dxp + application/vnd.spotfire.dxp + + + dxr + application/x-director + + + ecelp4800 + audio/vnd.nuera.ecelp4800 + + + ecelp7470 + audio/vnd.nuera.ecelp7470 + + + ecelp9600 + audio/vnd.nuera.ecelp9600 + + + ecma + application/ecmascript + + + edm + application/vnd.novadigm.edm + + + edx + application/vnd.novadigm.edx + + + efif + application/vnd.picsel + + + ei6 + application/vnd.pg.osasli + + + elc + application/octet-stream + + + emf + application/x-msmetafile + + + eml + message/rfc822 + + + emma + application/emma+xml + + + emz + application/x-msmetafile + + + eol + audio/vnd.digital-winds + + + eot + application/vnd.ms-fontobject + + + eps + application/postscript + + + epub + application/epub+zip + + + es3 + application/vnd.eszigno3+xml + + + esa + application/vnd.osgi.subsystem + + + esf + application/vnd.epson.esf + + + et3 + application/vnd.eszigno3+xml + + + etx + text/x-setext + + + eva + application/x-eva + + + evy + application/x-envoy + + + exe + application/octet-stream + + + exi + application/exi + + + ext + application/vnd.novadigm.ext + + + ez + application/andrew-inset + + + ez2 + application/vnd.ezpix-album + + + ez3 + application/vnd.ezpix-package + + + f + text/x-fortran + + + f4v + video/x-f4v + + + f77 + text/x-fortran + + + f90 + text/x-fortran + + + fbs + image/vnd.fastbidsheet + + + fcdt + application/vnd.adobe.formscentral.fcdt + + + fcs + application/vnd.isac.fcs + + + fdf + application/vnd.fdf + + + fe_launch + application/vnd.denovo.fcselayout-link + + + fg5 + application/vnd.fujitsu.oasysgp + + + fgd + application/x-director + + + fh + image/x-freehand + + + fh4 + image/x-freehand + + + fh5 + image/x-freehand + + + fh7 + image/x-freehand + + + fhc + image/x-freehand + + + fig + application/x-xfig + + + flac + audio/flac + + + fli + video/x-fli + + + flo + application/vnd.micrografx.flo + + + flv + video/x-flv + + + flw + application/vnd.kde.kivio + + + flx + text/vnd.fmi.flexstor + + + fly + text/vnd.fly + + + fm + application/vnd.framemaker + + + fnc + application/vnd.frogans.fnc + + + for + text/x-fortran + + + fpx + image/vnd.fpx + + + frame + application/vnd.framemaker + + + fsc + application/vnd.fsc.weblaunch + + + fst + image/vnd.fst + + + ftc + application/vnd.fluxtime.clip + + + fti + application/vnd.anser-web-funds-transfer-initiation + + + fvt + video/vnd.fvt + + + fxp + application/vnd.adobe.fxp + + + fxpl + application/vnd.adobe.fxp + + + fzs + application/vnd.fuzzysheet + + + g2w + application/vnd.geoplan + + + g3 + image/g3fax + + + g3w + application/vnd.geospace + + + gac + application/vnd.groove-account + + + gam + application/x-tads + + + gbr + application/rpki-ghostbusters + + + gca + application/x-gca-compressed + + + gdl + model/vnd.gdl + + + geo + application/vnd.dynageo + + + gex + application/vnd.geometry-explorer + + + ggb + application/vnd.geogebra.file + + + ggt + application/vnd.geogebra.tool + + + ghf + application/vnd.groove-help + + + gif + image/gif + + + gim + application/vnd.groove-identity-message + + + gml + application/gml+xml + + + gmx + application/vnd.gmx + + + gnumeric + application/x-gnumeric + + + gph + application/vnd.flographit + + + gpx + application/gpx+xml + + + gqf + application/vnd.grafeq + + + gqs + application/vnd.grafeq + + + gram + application/srgs + + + gramps + application/x-gramps-xml + + + gre + application/vnd.geometry-explorer + + + grv + application/vnd.groove-injector + + + grxml + application/srgs+xml + + + gsf + application/x-font-ghostscript + + + gtar + application/x-gtar + + + gtm + application/vnd.groove-tool-message + + + gtw + model/vnd.gtw + + + gv + text/vnd.graphviz + + + gxf + application/gxf + + + gxt + application/vnd.geonext + + + gz + application/x-gzip + + + h + text/x-c + + + h261 + video/h261 + + + h263 + video/h263 + + + h264 + video/h264 + + + hal + application/vnd.hal+xml + + + hbci + application/vnd.hbci + + + hdf + application/x-hdf + + + hh + text/x-c + + + hlp + application/winhlp + + + hpgl + application/vnd.hp-hpgl + + + hpid + application/vnd.hp-hpid + + + hps + application/vnd.hp-hps + + + hqx + application/mac-binhex40 + + + htc + text/x-component + + + htke + application/vnd.kenameaapp + + + htm + text/html + + + html + text/html + + + hvd + application/vnd.yamaha.hv-dic + + + hvp + application/vnd.yamaha.hv-voice + + + hvs + application/vnd.yamaha.hv-script + + + i2g + application/vnd.intergeo + + + icc + application/vnd.iccprofile + + + ice + x-conference/x-cooltalk + + + icm + application/vnd.iccprofile + + + ico + image/x-icon + + + ics + text/calendar + + + ief + image/ief + + + ifb + text/calendar + + + ifm + application/vnd.shana.informed.formdata + + + iges + model/iges + + + igl + application/vnd.igloader + + + igm + application/vnd.insors.igm + + + igs + model/iges + + + igx + application/vnd.micrografx.igx + + + iif + application/vnd.shana.informed.interchange + + + imp + application/vnd.accpac.simply.imp + + + ims + application/vnd.ms-ims + + + in + text/plain + + + ink + application/inkml+xml + + + inkml + application/inkml+xml + + + install + application/x-install-instructions + + + iota + application/vnd.astraea-software.iota + + + ipfix + application/ipfix + + + ipk + application/vnd.shana.informed.package + + + irm + application/vnd.ibm.rights-management + + + irp + application/vnd.irepository.package+xml + + + iso + application/x-iso9660-image + + + itp + application/vnd.shana.informed.formtemplate + + + ivp + application/vnd.immervision-ivp + + + ivu + application/vnd.immervision-ivu + + + jad + text/vnd.sun.j2me.app-descriptor + + + jam + application/vnd.jam + + + jar + application/java-archive + + + java + text/x-java-source + + + jisp + application/vnd.jisp + + + jlt + application/vnd.hp-jlyt + + + jnlp + application/x-java-jnlp-file + + + joda + application/vnd.joost.joda-archive + + + jpe + image/jpeg + + + jpeg + image/jpeg + + + jpg + image/jpeg + + + jpgm + video/jpm + + + jpgv + video/jpeg + + + jpm + video/jpm + + + js + application/javascript + + + jsf + text/plain + + + json + application/json + + + jsonml + application/jsonml+json + + + jspf + text/plain + + + kar + audio/midi + + + karbon + application/vnd.kde.karbon + + + kfo + application/vnd.kde.kformula + + + kia + application/vnd.kidspiration + + + kml + application/vnd.google-earth.kml+xml + + + kmz + application/vnd.google-earth.kmz + + + kne + application/vnd.kinar + + + knp + application/vnd.kinar + + + kon + application/vnd.kde.kontour + + + kpr + application/vnd.kde.kpresenter + + + kpt + application/vnd.kde.kpresenter + + + kpxx + application/vnd.ds-keypoint + + + ksp + application/vnd.kde.kspread + + + ktr + application/vnd.kahootz + + + ktx + image/ktx + + + ktz + application/vnd.kahootz + + + kwd + application/vnd.kde.kword + + + kwt + application/vnd.kde.kword + + + lasxml + application/vnd.las.las+xml + + + latex + application/x-latex + + + lbd + application/vnd.llamagraphics.life-balance.desktop + + + lbe + application/vnd.llamagraphics.life-balance.exchange+xml + + + les + application/vnd.hhe.lesson-player + + + lha + application/x-lzh-compressed + + + link66 + application/vnd.route66.link66+xml + + + list + text/plain + + + list3820 + application/vnd.ibm.modcap + + + listafp + application/vnd.ibm.modcap + + + lnk + application/x-ms-shortcut + + + log + text/plain + + + lostxml + application/lost+xml + + + lrf + application/octet-stream + + + lrm + application/vnd.ms-lrm + + + ltf + application/vnd.frogans.ltf + + + lvp + audio/vnd.lucent.voice + + + lwp + application/vnd.lotus-wordpro + + + lzh + application/x-lzh-compressed + + + m13 + application/x-msmediaview + + + m14 + application/x-msmediaview + + + m1v + video/mpeg + + + m21 + application/mp21 + + + m2a + audio/mpeg + + + m2v + video/mpeg + + + m3a + audio/mpeg + + + m3u + audio/x-mpegurl + + + m3u8 + application/vnd.apple.mpegurl + + + m4a + audio/mp4 + + + m4b + audio/mp4 + + + m4r + audio/mp4 + + + m4u + video/vnd.mpegurl + + + m4v + video/mp4 + + + ma + application/mathematica + + + mac + image/x-macpaint + + + mads + application/mads+xml + + + mag + application/vnd.ecowin.chart + + + maker + application/vnd.framemaker + + + man + text/troff + + + mar + application/octet-stream + + + mathml + application/mathml+xml + + + mb + application/mathematica + + + mbk + application/vnd.mobius.mbk + + + mbox + application/mbox + + + mc1 + application/vnd.medcalcdata + + + mcd + application/vnd.mcd + + + mcurl + text/vnd.curl.mcurl + + + mdb + application/x-msaccess + + + mdi + image/vnd.ms-modi + + + me + text/troff + + + mesh + model/mesh + + + meta4 + application/metalink4+xml + + + metalink + application/metalink+xml + + + mets + application/mets+xml + + + mfm + application/vnd.mfmp + + + mft + application/rpki-manifest + + + mgp + application/vnd.osgeo.mapguide.package + + + mgz + application/vnd.proteus.magazine + + + mid + audio/midi + + + midi + audio/midi + + + mie + application/x-mie + + + mif + application/x-mif + + + mime + message/rfc822 + + + mj2 + video/mj2 + + + mjp2 + video/mj2 + + + mk3d + video/x-matroska + + + mka + audio/x-matroska + + + mks + video/x-matroska + + + mkv + video/x-matroska + + + mlp + application/vnd.dolby.mlp + + + mmd + application/vnd.chipnuts.karaoke-mmd + + + mmf + application/vnd.smaf + + + mmr + image/vnd.fujixerox.edmics-mmr + + + mng + video/x-mng + + + mny + application/x-msmoney + + + mobi + application/x-mobipocket-ebook + + + mods + application/mods+xml + + + mov + video/quicktime + + + movie + video/x-sgi-movie + + + mp1 + audio/mpeg + + + mp2 + audio/mpeg + + + mp21 + application/mp21 + + + mp2a + audio/mpeg + + + mp3 + audio/mpeg + + + mp4 + video/mp4 + + + mp4a + audio/mp4 + + + mp4s + application/mp4 + + + mp4v + video/mp4 + + + mpa + audio/mpeg + + + mpc + application/vnd.mophun.certificate + + + mpe + video/mpeg + + + mpeg + video/mpeg + + + mpega + audio/x-mpeg + + + mpg + video/mpeg + + + mpg4 + video/mp4 + + + mpga + audio/mpeg + + + mpkg + application/vnd.apple.installer+xml + + + mpm + application/vnd.blueice.multipass + + + mpn + application/vnd.mophun.application + + + mpp + application/vnd.ms-project + + + mpt + application/vnd.ms-project + + + mpv2 + video/mpeg2 + + + mpy + application/vnd.ibm.minipay + + + mqy + application/vnd.mobius.mqy + + + mrc + application/marc + + + mrcx + application/marcxml+xml + + + ms + text/troff + + + mscml + application/mediaservercontrol+xml + + + mseed + application/vnd.fdsn.mseed + + + mseq + application/vnd.mseq + + + msf + application/vnd.epson.msf + + + msh + model/mesh + + + msi + application/x-msdownload + + + msl + application/vnd.mobius.msl + + + msty + application/vnd.muvee.style + + + mts + model/vnd.mts + + + mus + application/vnd.musician + + + musicxml + application/vnd.recordare.musicxml+xml + + + mvb + application/x-msmediaview + + + mwf + application/vnd.mfer + + + mxf + application/mxf + + + mxl + application/vnd.recordare.musicxml + + + mxml + application/xv+xml + + + mxs + application/vnd.triscape.mxs + + + mxu + video/vnd.mpegurl + + + n-gage + application/vnd.nokia.n-gage.symbian.install + + + n3 + text/n3 + + + nb + application/mathematica + + + nbp + application/vnd.wolfram.player + + + nc + application/x-netcdf + + + ncx + application/x-dtbncx+xml + + + nfo + text/x-nfo + + + ngdat + application/vnd.nokia.n-gage.data + + + nitf + application/vnd.nitf + + + nlu + application/vnd.neurolanguage.nlu + + + nml + application/vnd.enliven + + + nnd + application/vnd.noblenet-directory + + + nns + application/vnd.noblenet-sealer + + + nnw + application/vnd.noblenet-web + + + npx + image/vnd.net-fpx + + + nsc + application/x-conference + + + nsf + application/vnd.lotus-notes + + + ntf + application/vnd.nitf + + + nzb + application/x-nzb + + + oa2 + application/vnd.fujitsu.oasys2 + + + oa3 + application/vnd.fujitsu.oasys3 + + + oas + application/vnd.fujitsu.oasys + + + obd + application/x-msbinder + + + obj + application/x-tgif + + + oda + application/oda + + + + odb + application/vnd.oasis.opendocument.database + + + + odc + application/vnd.oasis.opendocument.chart + + + + odf + application/vnd.oasis.opendocument.formula + + + odft + application/vnd.oasis.opendocument.formula-template + + + + odg + application/vnd.oasis.opendocument.graphics + + + + odi + application/vnd.oasis.opendocument.image + + + + odm + application/vnd.oasis.opendocument.text-master + + + + odp + application/vnd.oasis.opendocument.presentation + + + + ods + application/vnd.oasis.opendocument.spreadsheet + + + + odt + application/vnd.oasis.opendocument.text + + + oga + audio/ogg + + + ogg + audio/ogg + + + ogv + video/ogg + + + + ogx + application/ogg + + + omdoc + application/omdoc+xml + + + onepkg + application/onenote + + + onetmp + application/onenote + + + onetoc + application/onenote + + + onetoc2 + application/onenote + + + opf + application/oebps-package+xml + + + opml + text/x-opml + + + oprc + application/vnd.palm + + + org + application/vnd.lotus-organizer + + + osf + application/vnd.yamaha.openscoreformat + + + osfpvg + application/vnd.yamaha.openscoreformat.osfpvg+xml + + + otc + application/vnd.oasis.opendocument.chart-template + + + otf + font/otf + + + + otg + application/vnd.oasis.opendocument.graphics-template + + + + oth + application/vnd.oasis.opendocument.text-web + + + oti + application/vnd.oasis.opendocument.image-template + + + + otp + application/vnd.oasis.opendocument.presentation-template + + + + ots + application/vnd.oasis.opendocument.spreadsheet-template + + + + ott + application/vnd.oasis.opendocument.text-template + + + oxps + application/oxps + + + oxt + application/vnd.openofficeorg.extension + + + p + text/x-pascal + + + p10 + application/pkcs10 + + + p12 + application/x-pkcs12 + + + p7b + application/x-pkcs7-certificates + + + p7c + application/pkcs7-mime + + + p7m + application/pkcs7-mime + + + p7r + application/x-pkcs7-certreqresp + + + p7s + application/pkcs7-signature + + + p8 + application/pkcs8 + + + pas + text/x-pascal + + + paw + application/vnd.pawaafile + + + pbd + application/vnd.powerbuilder6 + + + pbm + image/x-portable-bitmap + + + pcap + application/vnd.tcpdump.pcap + + + pcf + application/x-font-pcf + + + pcl + application/vnd.hp-pcl + + + pclxl + application/vnd.hp-pclxl + + + pct + image/pict + + + pcurl + application/vnd.curl.pcurl + + + pcx + image/x-pcx + + + pdb + application/vnd.palm + + + pdf + application/pdf + + + pfa + application/x-font-type1 + + + pfb + application/x-font-type1 + + + pfm + application/x-font-type1 + + + pfr + application/font-tdpfr + + + pfx + application/x-pkcs12 + + + pgm + image/x-portable-graymap + + + pgn + application/x-chess-pgn + + + pgp + application/pgp-encrypted + + + pic + image/pict + + + pict + image/pict + + + pkg + application/octet-stream + + + pki + application/pkixcmp + + + pkipath + application/pkix-pkipath + + + plb + application/vnd.3gpp.pic-bw-large + + + plc + application/vnd.mobius.plc + + + plf + application/vnd.pocketlearn + + + pls + audio/x-scpls + + + pml + application/vnd.ctc-posml + + + png + image/png + + + pnm + image/x-portable-anymap + + + pnt + image/x-macpaint + + + portpkg + application/vnd.macports.portpkg + + + pot + application/vnd.ms-powerpoint + + + potm + application/vnd.ms-powerpoint.template.macroenabled.12 + + + potx + application/vnd.openxmlformats-officedocument.presentationml.template + + + ppam + application/vnd.ms-powerpoint.addin.macroenabled.12 + + + ppd + application/vnd.cups-ppd + + + ppm + image/x-portable-pixmap + + + pps + application/vnd.ms-powerpoint + + + ppsm + application/vnd.ms-powerpoint.slideshow.macroenabled.12 + + + ppsx + application/vnd.openxmlformats-officedocument.presentationml.slideshow + + + ppt + application/vnd.ms-powerpoint + + + pptm + application/vnd.ms-powerpoint.presentation.macroenabled.12 + + + pptx + application/vnd.openxmlformats-officedocument.presentationml.presentation + + + pqa + application/vnd.palm + + + prc + application/x-mobipocket-ebook + + + pre + application/vnd.lotus-freelance + + + prf + application/pics-rules + + + ps + application/postscript + + + psb + application/vnd.3gpp.pic-bw-small + + + psd + image/vnd.adobe.photoshop + + + psf + application/x-font-linux-psf + + + pskcxml + application/pskc+xml + + + ptid + application/vnd.pvi.ptid1 + + + pub + application/x-mspublisher + + + pvb + application/vnd.3gpp.pic-bw-var + + + pwn + application/vnd.3m.post-it-notes + + + pya + audio/vnd.ms-playready.media.pya + + + pyv + video/vnd.ms-playready.media.pyv + + + qam + application/vnd.epson.quickanime + + + qbo + application/vnd.intu.qbo + + + qfx + application/vnd.intu.qfx + + + qps + application/vnd.publishare-delta-tree + + + qt + video/quicktime + + + qti + image/x-quicktime + + + qtif + image/x-quicktime + + + qwd + application/vnd.quark.quarkxpress + + + qwt + application/vnd.quark.quarkxpress + + + qxb + application/vnd.quark.quarkxpress + + + qxd + application/vnd.quark.quarkxpress + + + qxl + application/vnd.quark.quarkxpress + + + qxt + application/vnd.quark.quarkxpress + + + ra + audio/x-pn-realaudio + + + ram + audio/x-pn-realaudio + + + rar + application/x-rar-compressed + + + ras + image/x-cmu-raster + + + rcprofile + application/vnd.ipunplugged.rcprofile + + + rdf + application/rdf+xml + + + rdz + application/vnd.data-vision.rdz + + + rep + application/vnd.businessobjects + + + res + application/x-dtbresource+xml + + + rgb + image/x-rgb + + + rif + application/reginfo+xml + + + rip + audio/vnd.rip + + + ris + application/x-research-info-systems + + + rl + application/resource-lists+xml + + + rlc + image/vnd.fujixerox.edmics-rlc + + + rld + application/resource-lists-diff+xml + + + rm + application/vnd.rn-realmedia + + + rmi + audio/midi + + + rmp + audio/x-pn-realaudio-plugin + + + rms + application/vnd.jcp.javame.midlet-rms + + + rmvb + application/vnd.rn-realmedia-vbr + + + rnc + application/relax-ng-compact-syntax + + + roa + application/rpki-roa + + + roff + text/troff + + + rp9 + application/vnd.cloanto.rp9 + + + rpss + application/vnd.nokia.radio-presets + + + rpst + application/vnd.nokia.radio-preset + + + rq + application/sparql-query + + + rs + application/rls-services+xml + + + rsd + application/rsd+xml + + + rss + application/rss+xml + + + rtf + application/rtf + + + rtx + text/richtext + + + s + text/x-asm + + + s3m + audio/s3m + + + saf + application/vnd.yamaha.smaf-audio + + + sbml + application/sbml+xml + + + sc + application/vnd.ibm.secure-container + + + scd + application/x-msschedule + + + scm + application/vnd.lotus-screencam + + + scq + application/scvp-cv-request + + + scs + application/scvp-cv-response + + + scurl + text/vnd.curl.scurl + + + sda + application/vnd.stardivision.draw + + + sdc + application/vnd.stardivision.calc + + + sdd + application/vnd.stardivision.impress + + + sdkd + application/vnd.solent.sdkm+xml + + + sdkm + application/vnd.solent.sdkm+xml + + + sdp + application/sdp + + + sdw + application/vnd.stardivision.writer + + + see + application/vnd.seemail + + + seed + application/vnd.fdsn.seed + + + sema + application/vnd.sema + + + semd + application/vnd.semd + + + semf + application/vnd.semf + + + ser + application/java-serialized-object + + + setpay + application/set-payment-initiation + + + setreg + application/set-registration-initiation + + + sfd-hdstx + application/vnd.hydrostatix.sof-data + + + sfs + application/vnd.spotfire.sfs + + + sfv + text/x-sfv + + + sgi + image/sgi + + + sgl + application/vnd.stardivision.writer-global + + + sgm + text/sgml + + + sgml + text/sgml + + + sh + application/x-sh + + + shar + application/x-shar + + + shf + application/shf+xml + + + + sid + image/x-mrsid-image + + + sig + application/pgp-signature + + + sil + audio/silk + + + silo + model/mesh + + + sis + application/vnd.symbian.install + + + sisx + application/vnd.symbian.install + + + sit + application/x-stuffit + + + sitx + application/x-stuffitx + + + skd + application/vnd.koan + + + skm + application/vnd.koan + + + skp + application/vnd.koan + + + skt + application/vnd.koan + + + sldm + application/vnd.ms-powerpoint.slide.macroenabled.12 + + + sldx + application/vnd.openxmlformats-officedocument.presentationml.slide + + + slt + application/vnd.epson.salt + + + sm + application/vnd.stepmania.stepchart + + + smf + application/vnd.stardivision.math + + + smi + application/smil+xml + + + smil + application/smil+xml + + + smv + video/x-smv + + + smzip + application/vnd.stepmania.package + + + snd + audio/basic + + + snf + application/x-font-snf + + + so + application/octet-stream + + + spc + application/x-pkcs7-certificates + + + spf + application/vnd.yamaha.smaf-phrase + + + spl + application/x-futuresplash + + + spot + text/vnd.in3d.spot + + + spp + application/scvp-vp-response + + + spq + application/scvp-vp-request + + + spx + audio/ogg + + + sql + application/x-sql + + + src + application/x-wais-source + + + srt + application/x-subrip + + + sru + application/sru+xml + + + srx + application/sparql-results+xml + + + ssdl + application/ssdl+xml + + + sse + application/vnd.kodak-descriptor + + + ssf + application/vnd.epson.ssf + + + ssml + application/ssml+xml + + + st + application/vnd.sailingtracker.track + + + stc + application/vnd.sun.xml.calc.template + + + std + application/vnd.sun.xml.draw.template + + + stf + application/vnd.wt.stf + + + sti + application/vnd.sun.xml.impress.template + + + stk + application/hyperstudio + + + stl + application/vnd.ms-pki.stl + + + str + application/vnd.pg.format + + + stw + application/vnd.sun.xml.writer.template + + + sub + text/vnd.dvb.subtitle + + + sus + application/vnd.sus-calendar + + + susp + application/vnd.sus-calendar + + + sv4cpio + application/x-sv4cpio + + + sv4crc + application/x-sv4crc + + + svc + application/vnd.dvb.service + + + svd + application/vnd.svd + + + svg + image/svg+xml + + + svgz + image/svg+xml + + + swa + application/x-director + + + swf + application/x-shockwave-flash + + + swi + application/vnd.aristanetworks.swi + + + sxc + application/vnd.sun.xml.calc + + + sxd + application/vnd.sun.xml.draw + + + sxg + application/vnd.sun.xml.writer.global + + + sxi + application/vnd.sun.xml.impress + + + sxm + application/vnd.sun.xml.math + + + sxw + application/vnd.sun.xml.writer + + + t + text/troff + + + t3 + application/x-t3vm-image + + + taglet + application/vnd.mynfc + + + tao + application/vnd.tao.intent-module-archive + + + tar + application/x-tar + + + tcap + application/vnd.3gpp2.tcap + + + tcl + application/x-tcl + + + teacher + application/vnd.smart.teacher + + + tei + application/tei+xml + + + teicorpus + application/tei+xml + + + tex + application/x-tex + + + texi + application/x-texinfo + + + texinfo + application/x-texinfo + + + text + text/plain + + + tfi + application/thraud+xml + + + tfm + application/x-tex-tfm + + + tga + image/x-tga + + + thmx + application/vnd.ms-officetheme + + + tif + image/tiff + + + tiff + image/tiff + + + tmo + application/vnd.tmobile-livetv + + + torrent + application/x-bittorrent + + + tpl + application/vnd.groove-tool-template + + + tpt + application/vnd.trid.tpt + + + tr + text/troff + + + tra + application/vnd.trueapp + + + trm + application/x-msterminal + + + tsd + application/timestamped-data + + + tsv + text/tab-separated-values + + + ttc + font/collection + + + ttf + font/ttf + + + ttl + text/turtle + + + twd + application/vnd.simtech-mindmapper + + + twds + application/vnd.simtech-mindmapper + + + txd + application/vnd.genomatix.tuxedo + + + txf + application/vnd.mobius.txf + + + txt + text/plain + + + u32 + application/x-authorware-bin + + + udeb + application/x-debian-package + + + ufd + application/vnd.ufdl + + + ufdl + application/vnd.ufdl + + + ulw + audio/basic + + + ulx + application/x-glulx + + + umj + application/vnd.umajin + + + unityweb + application/vnd.unity + + + uoml + application/vnd.uoml+xml + + + uri + text/uri-list + + + uris + text/uri-list + + + urls + text/uri-list + + + ustar + application/x-ustar + + + utz + application/vnd.uiq.theme + + + uu + text/x-uuencode + + + uva + audio/vnd.dece.audio + + + uvd + application/vnd.dece.data + + + uvf + application/vnd.dece.data + + + uvg + image/vnd.dece.graphic + + + uvh + video/vnd.dece.hd + + + uvi + image/vnd.dece.graphic + + + uvm + video/vnd.dece.mobile + + + uvp + video/vnd.dece.pd + + + uvs + video/vnd.dece.sd + + + uvt + application/vnd.dece.ttml+xml + + + uvu + video/vnd.uvvu.mp4 + + + uvv + video/vnd.dece.video + + + uvva + audio/vnd.dece.audio + + + uvvd + application/vnd.dece.data + + + uvvf + application/vnd.dece.data + + + uvvg + image/vnd.dece.graphic + + + uvvh + video/vnd.dece.hd + + + uvvi + image/vnd.dece.graphic + + + uvvm + video/vnd.dece.mobile + + + uvvp + video/vnd.dece.pd + + + uvvs + video/vnd.dece.sd + + + uvvt + application/vnd.dece.ttml+xml + + + uvvu + video/vnd.uvvu.mp4 + + + uvvv + video/vnd.dece.video + + + uvvx + application/vnd.dece.unspecified + + + uvvz + application/vnd.dece.zip + + + uvx + application/vnd.dece.unspecified + + + uvz + application/vnd.dece.zip + + + vcard + text/vcard + + + vcd + application/x-cdlink + + + vcf + text/x-vcard + + + vcg + application/vnd.groove-vcard + + + vcs + text/x-vcalendar + + + vcx + application/vnd.vcx + + + vis + application/vnd.visionary + + + viv + video/vnd.vivo + + + vob + video/x-ms-vob + + + vor + application/vnd.stardivision.writer + + + vox + application/x-authorware-bin + + + vrml + model/vrml + + + vsd + application/vnd.visio + + + vsf + application/vnd.vsf + + + vss + application/vnd.visio + + + vst + application/vnd.visio + + + vsw + application/vnd.visio + + + vtu + model/vnd.vtu + + + vxml + application/voicexml+xml + + + w3d + application/x-director + + + wad + application/x-doom + + + wasm + application/wasm + + + wav + audio/x-wav + + + wax + audio/x-ms-wax + + + + wbmp + image/vnd.wap.wbmp + + + wbs + application/vnd.criticaltools.wbs+xml + + + wbxml + application/vnd.wap.wbxml + + + wcm + application/vnd.ms-works + + + wdb + application/vnd.ms-works + + + wdp + image/vnd.ms-photo + + + weba + audio/webm + + + webm + video/webm + + + webp + image/webp + + + wg + application/vnd.pmi.widget + + + wgt + application/widget + + + wks + application/vnd.ms-works + + + wm + video/x-ms-wm + + + wma + audio/x-ms-wma + + + wmd + application/x-ms-wmd + + + wmf + application/x-msmetafile + + + + wml + text/vnd.wap.wml + + + + wmlc + application/vnd.wap.wmlc + + + + wmls + text/vnd.wap.wmlscript + + + + wmlsc + application/vnd.wap.wmlscriptc + + + wmv + video/x-ms-wmv + + + wmx + video/x-ms-wmx + + + wmz + application/x-msmetafile + + + woff + font/woff + + + woff2 + font/woff2 + + + wpd + application/vnd.wordperfect + + + wpl + application/vnd.ms-wpl + + + wps + application/vnd.ms-works + + + wqd + application/vnd.wqd + + + wri + application/x-mswrite + + + wrl + model/vrml + + + wsdl + application/wsdl+xml + + + wspolicy + application/wspolicy+xml + + + wtb + application/vnd.webturbo + + + wvx + video/x-ms-wvx + + + x32 + application/x-authorware-bin + + + x3d + model/x3d+xml + + + x3db + model/x3d+binary + + + x3dbz + model/x3d+binary + + + x3dv + model/x3d+vrml + + + x3dvz + model/x3d+vrml + + + x3dz + model/x3d+xml + + + xaml + application/xaml+xml + + + xap + application/x-silverlight-app + + + xar + application/vnd.xara + + + xbap + application/x-ms-xbap + + + xbd + application/vnd.fujixerox.docuworks.binder + + + xbm + image/x-xbitmap + + + xdf + application/xcap-diff+xml + + + xdm + application/vnd.syncml.dm+xml + + + xdp + application/vnd.adobe.xdp+xml + + + xdssc + application/dssc+xml + + + xdw + application/vnd.fujixerox.docuworks + + + xenc + application/xenc+xml + + + xer + application/patch-ops-error+xml + + + xfdf + application/vnd.adobe.xfdf + + + xfdl + application/vnd.xfdl + + + xht + application/xhtml+xml + + + xhtml + application/xhtml+xml + + + xhvml + application/xv+xml + + + xif + image/vnd.xiff + + + xla + application/vnd.ms-excel + + + xlam + application/vnd.ms-excel.addin.macroenabled.12 + + + xlc + application/vnd.ms-excel + + + xlf + application/x-xliff+xml + + + xlm + application/vnd.ms-excel + + + xls + application/vnd.ms-excel + + + xlsb + application/vnd.ms-excel.sheet.binary.macroenabled.12 + + + xlsm + application/vnd.ms-excel.sheet.macroenabled.12 + + + xlsx + application/vnd.openxmlformats-officedocument.spreadsheetml.sheet + + + xlt + application/vnd.ms-excel + + + xltm + application/vnd.ms-excel.template.macroenabled.12 + + + xltx + application/vnd.openxmlformats-officedocument.spreadsheetml.template + + + xlw + application/vnd.ms-excel + + + xm + audio/xm + + + xml + application/xml + + + xo + application/vnd.olpc-sugar + + + xop + application/xop+xml + + + xpi + application/x-xpinstall + + + xpl + application/xproc+xml + + + xpm + image/x-xpixmap + + + xpr + application/vnd.is-xpr + + + xps + application/vnd.ms-xpsdocument + + + xpw + application/vnd.intercon.formnet + + + xpx + application/vnd.intercon.formnet + + + xsl + application/xml + + + xslt + application/xslt+xml + + + xsm + application/vnd.syncml+xml + + + xspf + application/xspf+xml + + + xul + application/vnd.mozilla.xul+xml + + + xvm + application/xv+xml + + + xvml + application/xv+xml + + + xwd + image/x-xwindowdump + + + xyz + chemical/x-xyz + + + xz + application/x-xz + + + yang + application/yang + + + yin + application/yin+xml + + + z + application/x-compress + + + z1 + application/x-zmachine + + + z2 + application/x-zmachine + + + z3 + application/x-zmachine + + + z4 + application/x-zmachine + + + z5 + application/x-zmachine + + + z6 + application/x-zmachine + + + z7 + application/x-zmachine + + + z8 + application/x-zmachine + + + zaz + application/vnd.zzazz.deck+xml + + + zip + application/zip + + + zir + application/vnd.zul + + + zirz + application/vnd.zul + + + zmm + application/vnd.handheld-entertainment+xml + + + + + + + + + + + + + + + + + + index.html + index.htm + index.jsp + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/annotations-api.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/annotations-api.jar new file mode 100644 index 0000000..b19596a Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/annotations-api.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-ant.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-ant.jar new file mode 100644 index 0000000..c6aaa0d Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-ant.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-ha.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-ha.jar new file mode 100644 index 0000000..9a1fc7d Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-ha.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-tribes.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-tribes.jar new file mode 100644 index 0000000..51a3937 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina-tribes.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina.jar new file mode 100644 index 0000000..9206422 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/catalina.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-dbcp2-2.8.0.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-dbcp2-2.8.0.jar new file mode 100644 index 0000000..58653c9 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-dbcp2-2.8.0.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-logging-1.2.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-logging-1.2.jar new file mode 100644 index 0000000..93a3b9f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-logging-1.2.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-pool2-2.9.0.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-pool2-2.9.0.jar new file mode 100644 index 0000000..a038b36 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/commons-pool2-2.9.0.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/ecj-4.4.2.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/ecj-4.4.2.jar new file mode 100644 index 0000000..d9411b3 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/ecj-4.4.2.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/el-api.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/el-api.jar new file mode 100644 index 0000000..3d13459 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/el-api.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/jasper-el.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/jasper-el.jar new file mode 100644 index 0000000..a24b42b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/jasper-el.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/jasper.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/jasper.jar new file mode 100644 index 0000000..d351bb7 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/jasper.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/jsp-api.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/jsp-api.jar new file mode 100644 index 0000000..aab2798 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/jsp-api.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/servlet-api.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/servlet-api.jar new file mode 100644 index 0000000..26118e6 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/servlet-api.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-api.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-api.jar new file mode 100644 index 0000000..2b70d79 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-api.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-coyote.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-coyote.jar new file mode 100644 index 0000000..70cdac5 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-coyote.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-dbcp.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-dbcp.jar new file mode 100644 index 0000000..b5fd416 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-dbcp.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-de.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-de.jar new file mode 100644 index 0000000..d3f3dfa Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-de.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-es.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-es.jar new file mode 100644 index 0000000..34c1445 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-es.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-fr.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-fr.jar new file mode 100644 index 0000000..a41796e Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-fr.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ja.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ja.jar new file mode 100644 index 0000000..c1da578 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ja.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ko.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ko.jar new file mode 100644 index 0000000..70344ca Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ko.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ru.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ru.jar new file mode 100644 index 0000000..89d391a Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-ru.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-zh-CN.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-zh-CN.jar new file mode 100644 index 0000000..4b75005 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-i18n-zh-CN.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-jdbc.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-jdbc.jar new file mode 100644 index 0000000..c7674cd Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-jdbc.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-util.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-util.jar new file mode 100644 index 0000000..90d87cb Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat-util.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat7-websocket.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat7-websocket.jar new file mode 100644 index 0000000..8681d6b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/tomcat7-websocket.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/lib/websocket-api.jar b/centos8_tomcat/apache-tomcat-7.0.108/lib/websocket-api.jar new file mode 100644 index 0000000..4f7d16e Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/lib/websocket-api.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/BUILDING.txt b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/BUILDING.txt new file mode 100644 index 0000000..a5b96f5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/BUILDING.txt @@ -0,0 +1,522 @@ +================================================================================ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +================================================================================ + + ==================================================== + Building The Apache Tomcat 7.0 Servlet/JSP Container + ==================================================== + +This subproject contains the source code for Tomcat 7.0, a container that +implements the Servlet 3.0, JSP 2.2, EL 2.2 and WebSocket 1.1 specifications +from the Java Community Process . + +Note: If you just need to run Apache Tomcat, it is not necessary to build +it. You may simply download a binary distribution. It is cross-platform. +Read RUNNING.txt for the instruction on how to run it. + +In order to build a binary distribution version of Apache Tomcat from a +source distribution, do the following: + + +(1) Download and Install a Java 6 and Java 7 Development Kit + + 1. If the JDKs are already installed, skip to (2). + + 2. Download a version 6 of the Java Development Kit (JDK) release (use the + latest update available for your chosen version) from + + http://www.oracle.com/technetwork/java/javase/downloads/index.html + or from another JDK vendor. + + Note regarding later versions of Java: + + As documented elsewhere, one of the components in Apache Tomcat includes + a private copy of the Apache Commons DBCP 1.x library. The source code + for this library is downloaded, processed by the build script + (renaming the packages) and compiled. + + Due to changes in JDBC interfaces implemented by the library between + versions of Java SE specification, the library has to target specific + version of Java and can be compiled only with the JDK version + implementing this version of specification. Therefore, the build Tomcat + build process must be executed with a Java 6 JDK. + + See Apache Commons DBCP 1.x project web site for more details on + available versions of the library and its requirements, + + https://commons.apache.org/dbcp/ + + If you really want to use a later version of JDK to build Tomcat, + several workarounds are possible. One of them is to skip building + the component (tomcat-dbcp.jar). + + 3. Install the Java 6 JDK according to the instructions included with the + release. + + 4. Set an environment variable JAVA_HOME to the pathname of the directory + into which you installed the JDK release. + + 5. Download a version 7 of the Java Development Kit (JDK) release (use the + latest update available for your chosen version) from + + http://www.oracle.com/technetwork/java/javase/downloads/index.html + or from another JDK vendor. + + 6. Install the Java 7 JDK according to the instructions included with the + release. + +* NOTE: The Java 7 JDK is only required if you wish to build Tomcat with + JSR-356 (Java WebSocket 1.1) support. + + +(2) Install Apache Ant version 1.9.1 or later on your computer + + 1. If Apache Ant version 1.9.1 or later is already installed on your computer, skip to (3). + + 2. Download a binary distribution of Ant from: + + https://ant.apache.org/bindownload.cgi + + 3. Unpack the binary distribution into a convenient location so that the + Ant release resides in its own directory (conventionally named + "apache-ant-[version]"). + + For the purposes of the remainder of this document, the symbolic name + "${ant.home}" is used to refer to the full pathname of the release + directory. + + 4. Create an ANT_HOME environment variable to point the directory + ${ant.home}. + + 5. Modify the PATH environment variable to include the directory + ${ant.home}/bin in its list. This makes the "ant" command line script + available, which will be used to actually perform the build. + + +(3) Building Tomcat 7.0 + +(3.1) Checkout or obtain the source code for Tomcat 7.0 + +Clone the source using git, then checkout a specific major branch or +master for the latest code development, or download and unpack a source +package. + + * Tomcat GitHub repository URL: + + https://github.com/apache/tomcat + + * Source packages can be downloaded from: + + https://tomcat.apache.org/download-70.cgi + +The location where the source has been placed will be further referred as +${tomcat.source}. + +The Tomcat local build process does not modify line-endings. The svn repository +is configured so that all files will be checked out with the line-ending +appropriate for the current platform. When using a source package you should +ensure that you use the source package that has the appropriate line-ending +for your platform: + + zip -> CRLF + tar.gz -> LF + +Note that the release build process does modify line-endings to ensure that +each release package has the appropriate line-endings. + +(3.2) Building + + 1. The build is controlled by creating a ${tomcat.source}/build.properties + file. + + It is recommended to always create the file, because of unfortunate + default value of base.path property. You may start with the following + content for the file: + + # ----- Default Base Path for Dependent Packages ----- + # Replace this path with the directory path where dependencies binaries + # should be downloaded + base.path=/home/me/some-place-to-download-to + + 2. Configure base.path property by adding it to the + ${tomcat.source}/build.properties file. + + The base.path property specifies the place where Tomcat dependencies + required by the build are downloaded. It is recommended to place this + directory outside of the source tree, so that you do not waste your + time re-downloading the libraries. + +* NOTE: The default value of the base.path property configures the build script + to download the libraries required to build Tomcat to the + ${user.home}/tomcat-build-libs directory. + +* NOTE: Users accessing the Internet through a proxy must use the properties + file to indicate to Ant the proxy configuration. + + The following properties should be added to the ${tomcat.source}/build.properties + file. + + proxy.use=on + proxy.host=proxy.domain + proxy.port=8080 + proxy.user=username + proxy.password=password + + See Apache Ant documentation for the task for details. + +* NOTE: Users wishing to build Tomcat with JSR-356 (Java WebSocket 1.1) support + must also set the java.7.home build property to the location of the Java 7 JDK + installation. + + 3. Go to the sources directory and run Ant: + + cd ${tomcat.source} + ant + + This will execute the "deploy" target in build.xml. + + Once the build has completed successfully, a usable Tomcat installation + will have been produced in the ${tomcat.source}/output/build directory, + and can be started and stopped with the usual scripts. + + Note that the build includes Tomcat documentation, which can be found + in the output/build/webapps/docs directory. + + The path of the output directory can be controlled by specifying the + "tomcat.output" property in the build.properties file. + +* NOTE: Do not run the build as the root user. Building and running Tomcat + does not require root privileges. + + +(4) Updating sources and rebuilding + +It is recommended that you regularly update the downloaded Tomcat 7.0 +sources using your SVN client. + +For a quick rebuild of only modified code you can use: + + cd ${tomcat.source} + ant + + +(5) Special builds + +There are several targets in Tomcat build files that are useful to be +called separately. They build components that you may want to build +quickly, or ones that are included in the full release and are not built +during the default "deploy" build. + +(5.1) Building documentation + +The documentation web application is built during the default "deploy" +build. + +It can be built quickly by using the following commands: + + cd ${tomcat.source} + ant build-docs + +The output of this command will be found in the following directory: + + output/build/webapps/docs + + +The API documentation (Javadoc) is built during a "release" build. It is +easy to build it separately by using the following commands: + + cd ${tomcat.source} + ant javadoc + +The output of this command will be found in the following directories: + + output/dist/webapps/docs/api + output/dist/webapps/docs/elapi + output/dist/webapps/docs/jspapi + output/dist/webapps/docs/servletapi + + +(5.2) Building the extras (commons-logging, webservices etc.) + +These components are documented on the "Additional Components" +(extras.html) page of documentation. They are built during a "release" +build. + +You can build them by using the following commands: + + cd ${tomcat.source} + ant extras + +(5.3) Building the embedded packages + +These are built during a "release" build. + +You can build them by using the following commands: + + cd ${tomcat.source} + ant embed + + +(6) Building a full release (as provided via the ASF download pages) + + A full release includes the Windows installer which requires a Windows + environment to be available to create it. If not building in a Windows + environment, the build scripts assume that Wine is available. If this is not + the case, the skip.installer property may be set to skip the creation of the + Windows installer. + + 1. Configure GPG, if needed + + If the released artifacts have to be cryptographically signed with a + PGP signature, like the official ASF releases are, the following + property can be added to the build.properties file: + + # Location of GPG executable (used only for releases) + gpg.exec=/path/to/gpg + + You do not need it if you do not plan to sign the release. + + If "gpg.exec" property does not point to an existing file, it will be + ignored and this feature will be disabled. + + You will be prompted for the GPG passphrase when the release build + starts, unless "gpg.passphrase" property is set. + + 2. Build the release: + + cd ${tomcat.source} + ant release + + +(7) Tests + +(7.1) Running Tomcat tests + +Tomcat includes a number of junit tests. The tests are not run when a +release is built. There is separate command to run them. + +To run the testsuite use the following command: + + cd ${tomcat.source} + ant test + +It is advisable to redirect output of the above command to a file for later +inspection. + +The JUnit reports generated by the tests will be written to the following +directory: + + output/build/logs + +By default the testsuite is run three times to test 3 different +implementations of Tomcat connectors: BIO, NIO and APR. (If you are not +familiar with Tomcat connectors, see config/http.html in documentation for +details). + +The 3 runs are enabled and disabled individually by the following +properties, which all are "true" by default: + + execute.test.bio=true + execute.test.nio=true + execute.test.apr=true + +The APR connector can be tested only if Tomcat-Native library binaries are +found by the testsuite. The "test.apr.loc" property specifies the directory +where the library binaries are located. + +By default the "test.apr.loc" property specifies the following location: + + output/build/bin/native/ + +If you are on Windows and want to test the APR connector you can put the +tcnative-1.dll file into ${tomcat.source}/bin/native/ and it will be copied +into the above directory when the build runs. + +* NOTE: If you configured the build to use a Java 7 JDK (if the +"java.7.home" property has been defined) the tests will be run with Java 7. + +The version of Java that was actually used to run the tests is reported by +"org.apache.catalina.util.TestServerInfo" test class. + + +(7.2) Running a single test + +It is possible to run a single JUnit test class by adding the "test.entry" +property to the build.properties file. The property specifies the name of +the test class. + +For example: + + test.entry=org.apache.catalina.util.TestServerInfo + +It is possible to further limit such run to a number of selected test +methods by adding "test.entry.methods" property. The property specifies a +comma-separated list of test case methods. + +For example: + + test.entry=org.apache.el.lang.TestELArithmetic + test.entry.methods=testMultiply01,testMultiply02 + + +(7.3) Running a set of tests + +It is possible to run a set of JUnit test classes by adding the "test.name" +property to the build.properties file. The property specifies an Ant +includes pattern for the fileset of test class files to run. + +The default value is "**/Test*.java", so all test classes are being +executed (with few exceptions - see build.xml for several exclude patterns). + +You can include multiple patterns by concatenating them with a comma (",") +as the separator. + +For example: + + test.name=**/TestSsl.java,**/TestWebSocketFrameClientSSL.java + +You can exclude specific JUnit test classes by adding the "test.exclude" +property to the build.properties file. The property specifies an Ant +excludes pattern for the fileset of test class files to exclude form the run. +The default value is empty, so no classes are excluded. The syntax is the same +as for the property "test.name". + + +(7.4) Other configuration options + + 1. It is possible to configure the directory where JUnit reports are + written to. It is configured by "test.reports" property. The default + value is + + output/build/logs + + 2. It is possible to enable generation of access log file when the tests + are run. This is off by default and can be enabled by the following + property: + + test.accesslog=true + + The "access_log." file will be written to the same directory as + JUnit reports, + + output/build/logs + + 3. The testsuite respects logging configuration as configured by + ${tomcat.source}/conf/logging.properties + + The log files will be written to the temporary directory used by the + tests, + + output/test-tmp/logs + + 4. It is possible to configure formatter used by JUnit reports. + Configuration properties are "junit.formatter.type", + "junit.formatter.extension" and "junit.formatter.usefile". + + For example the following property disables generation of separate report + files: + + junit.formatter.usefile=false + + 5. Optional support is provided for the Cobertura code coverage tool. + +* NOTE: Cobertura is licensed under GPL v2 with parts of it being under + Apache License v1.1. See http://cobertura.sf.net for details. Using it + during Tomcat build is optional and is off by default. + + Cobertura can be enabled using the following property: + + test.cobertura=true + + The report files by default are written to + + output/coverage + + 6. The performance tests are written to run reasonably powerful machines (such + as a developer may use day to day) assuming no other resource hungry + processes are running. + + These assumptions are not always true (e.g. on CI systems running in a + virtual machine) so the performance tests may be disabled by using the + following property: + + test.excludePerformance=true + + 7. Some tests include checks that the access log valve entries are as expected. + These checks include timings. On slower / loaded systems these checks will + often fail. The checks may be relaxed by using the following property: + + test.relaxTiming=true + + 8. It is known that some platforms (e.g. OSX El Capitan) require IPv4 to + be the default for the multicast tests to work. This is configured by + the following property: + + java.net.preferIPv4Stack=true + + 9. It is possible to control whether the output of the tests is displayed + on the console or not. By default it is displayed and can be disabled + by the following property: + + test.verbose=true + +(8) Source code checks + +(8.1) Checkstyle + +* NOTE: Checkstyle is licensed under LGPL. Using Checkstyle during Tomcat + build is optional and is off by default. + + See http://checkstyle.sourceforge.net/ for more information. + +Tomcat comes with a Checkstyle configuration that tests its source code +for certain conventions, like presence of the license header. + +To enable Checkstyle, add the following property to build.properties file: + + execute.validate=true + +Once Checkstyle is enabled, the check will be performed automatically +during the build. The check is run before compilation of the source code. + +To speed-up repeated runs of this check, a cache is configured. The cache +is located in the following directory: + + output/res/checkstyle + +It is possible to run the check separately by calling the "validate" +target. The command is: + + cd ${tomcat.source} + ant -Dexecute.validate=true validate + + +(8.2) End-of-line conventions check + +You usually would not need to run this check. You can skip this section. + +Apache Tomcat project has convention that all of its textual source files, +stored in the Git repository, use Unix style LF line endings. + +This test is used by developers to check that the source code adheres to +this convention. It verifies that the ends of lines in textual files are +appropriate. The idea is to run this check regularly and notify developers +when an inconsistency is detected. + +The command to run this test is: + + cd ${tomcat.source} + ant validate-eoln diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/RELEASE-NOTES.txt b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/RELEASE-NOTES.txt new file mode 100644 index 0000000..c4582d1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/RELEASE-NOTES.txt @@ -0,0 +1,237 @@ +================================================================================ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +================================================================================ + + + Apache Tomcat Version 7.0.108 + Release Notes + + +========= +CONTENTS: +========= + +* Dependency Changes +* API Stability +* JNI Based Applications +* Bundled APIs +* Web application reloading and static fields in shared libraries +* Tomcat on Linux +* Enabling SSI and CGI Support +* Security manager URLs +* Symlinking static resources +* Viewing the Tomcat Change Log +* Cryptographic software notice +* When all else fails + + +=================== +Dependency Changes: +=================== +Tomcat 7.0 is designed to run on Java 6 and later. + +In addition, Tomcat 7.0 uses the Eclipse JDT Java compiler for +compiling JSP pages. This means you no longer need to have the complete +Java Development Kit (JDK) to run Tomcat, but a Java Runtime Environment +(JRE) is sufficient. The Eclipse JDT Java compiler is bundled with the +binary Tomcat distributions. Tomcat can also be configured to use the +compiler from the JDK to compile JSPs, or any other Java compiler supported +by Apache Ant. + + +============== +API Stability: +============== +The public interfaces for the following classes are fixed and will not be +changed at all during the remaining lifetime of the 7.x series: +- javax/**/* + +The public interfaces for the following classes may be added to in order to +resolve bugs and/or add new features. No existing interface will be removed or +changed although it may be deprecated. +- org/apache/catalina/* +- org/apache/catalina/comet/* + +Note: As Tomcat 7 matures, the above list will be added to. The list is not + considered complete at this time. + +The remaining classes are considered part of the Tomcat internals and may change +without notice between point releases. + + +======================= +JNI Based Applications: +======================= +Applications that require native libraries must ensure that the libraries have +been loaded prior to use. Typically, this is done with a call like: + + static { + System.loadLibrary("path-to-library-file"); + } + +in some class. However, the application must also ensure that the library is +not loaded more than once. If the above code were placed in a class inside +the web application (i.e. under /WEB-INF/classes or /WEB-INF/lib), and the +application were reloaded, the loadLibrary() call would be attempted a second +time. + +To avoid this problem, place classes that load native libraries outside of the +web application, and ensure that the loadLibrary() call is executed only once +during the lifetime of a particular JVM. + + +============= +Bundled APIs: +============= +A standard installation of Tomcat 7.0 makes all of the following APIs available +for use by web applications (by placing them in "lib"): +* annotations-api.jar (Common Annotations 1.1 package) +* catalina.jar (Tomcat Catalina implementation) +* catalina-ant.jar (Tomcat Catalina Ant tasks) +* catalina-ha.jar (High availability package) +* catalina-tribes.jar (Group communication) +* ecj-4.4.2.jar (Eclipse JDT Java compiler) +* el-api.jar (EL 2.2 API) +* jasper.jar (Jasper 2 Compiler and Runtime) +* jasper-el.jar (Jasper 2 EL implementation) +* jsp-api.jar (JSP 2.2 API) +* servlet-api.jar (Servlet 3.0 API) +* tomcat7-websocket.jar (WebSocket 1.1 implementation) +* tomcat-api.jar (Interfaces shared by Catalina and Jasper) +* tomcat-coyote.jar (Tomcat connectors and utility classes) +* tomcat-dbcp.jar (package renamed database connection pool based on Commons DBCP 1.x) +* tomcat-jdbc.jar (Tomcat's database connection pooling solution) +* tomcat-util.jar (Various utilities) +* websocket-api.jar (WebSocket 1.1 API) + +You can make additional APIs available to all of your web applications by +putting unpacked classes into a "classes" directory (not created by default), +or by placing them in JAR files in the "lib" directory. + +To override the XML parser implementation or interfaces, use the Endorsed +Standards Override mechanism of the JVM. The default configuration defines +JARs located in "$CATALINA_HOME/endorsed" as endorsed. This mechanism is +no longer supported with Java 9. + +When running on Java 6, the Common Annotations 1.0 implementation provided +by the JRE will be used. To use the Common Annotations 1.1 provided by +Tomcat, use the Endorsed Standards Override mechanism of the JVM. The +default configuration defines JARs located in "$CATALINA_HOME/endorsed" as +endorsed. + + +================================================================ +Web application reloading and static fields in shared libraries: +================================================================ +Some shared libraries (many are part of the JDK) keep references to objects +instantiated by the web application. To avoid class loading related problems +(ClassCastExceptions, messages indicating that the classloader +is stopped, etc.), the shared libraries state should be reinitialized. + +Something which might help is to avoid putting classes which would be +referenced by a shared static field in the web application classloader, +and putting them in the shared classloader instead (JARs should be put in the +"lib" folder, and classes should be put in the "classes" folder). + + +================ +Tomcat on Linux: +================ +GLIBC 2.2 / Linux 2.4 users should define an environment variable: +export LD_ASSUME_KERNEL=2.2.5 + +Redhat Linux 9.0 users should use the following setting to avoid +stability problems: +export LD_ASSUME_KERNEL=2.4.1 + +There are some Linux bugs reported against the NIO sendfile behavior, make sure you +have a JDK that is up to date, or disable sendfile behavior in the Connector.
+6427312: (fc) FileChannel.transferTo() throws IOException "system call interrupted"
+5103988: (fc) FileChannel.transferTo should return -1 for EAGAIN instead throws IOException
+6253145: (fc) FileChannel.transferTo on Linux fails when going beyond 2GB boundary
+6470086: (fc) FileChannel.transferTo(2147483647, 1, channel) cause "Value too large" exception
+ + +============================= +Enabling SSI and CGI Support: +============================= +Because of the security risks associated with CGI and SSI available +to web applications, these features are disabled by default. + +To enable and configure CGI support, please see the cgi-howto.html page. + +To enable and configure SSI support, please see the ssi-howto.html page. + + +====================== +Security manager URLs: +====================== +In order to grant security permissions to JARs located inside the +web application repository, use URLs of the following format +in your policy file: + +file:${catalina.base}/webapps/examples/WEB-INF/lib/driver.jar + + +============================ +Symlinking static resources: +============================ +By default, Unix symlinks will not work when used in a web application to link +resources located outside the web application root directory. + +This behavior is optional, and the "allowLinking" flag may be used to disable +the check. + + +============================== +Viewing the Tomcat Change Log: +============================== +See changelog.html in this directory. + + +============================= +Cryptographic software notice +============================= +This distribution includes cryptographic software. The country in +which you currently reside may have restrictions on the import, +possession, use, and/or re-export to another country, of +encryption software. BEFORE using any encryption software, please +check your country's laws, regulations and policies concerning the +import, possession, or use, and re-export of encryption software, to +see if this is permitted. See for more +information. + +The U.S. Government Department of Commerce, Bureau of Industry and +Security (BIS), has classified this software as Export Commodity +Control Number (ECCN) 5D002.C.1, which includes information security +software using or performing cryptographic functions with asymmetric +algorithms. The form and manner of this Apache Software Foundation +distribution makes it eligible for export under the License Exception +ENC Technology Software Unrestricted (TSU) exception (see the BIS +Export Administration Regulations, Section 740.13) for both object +code and source code. + +The following provides more details on the included cryptographic +software: + - Tomcat includes code designed to work with JSSE + - Tomcat includes code designed to work with OpenSSL + + +==================== +When all else fails: +==================== +See the FAQ +https://tomcat.apache.org/faq/ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/RUNNING.txt b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/RUNNING.txt new file mode 100644 index 0000000..f66f9ae --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/RUNNING.txt @@ -0,0 +1,493 @@ +================================================================================ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +================================================================================ + + =================================================== + Running The Apache Tomcat 7.0 Servlet/JSP Container + =================================================== + +Apache Tomcat 7.0 requires a Java Standard Edition Runtime +Environment (JRE) version 6 or later. + +============================= +Running With JRE 6 Or Later +============================= + +(1) Download and Install a Java SE Runtime Environment (JRE) + +(1.1) Download a Java SE Runtime Environment (JRE), + release version 6 or later, from + http://www.oracle.com/technetwork/java/javase/downloads/index.html + + NOTE: Java WebSocket API (JSR-356) is supported only when running + with Java 7 or later. + +(1.2) Install the JRE according to the instructions included with the + release. + + You may also use a full Java Development Kit (JDK) rather than just + a JRE. + +(1.3) When running on Java 6, the Common Annotations 1.0 implementation + provided by the JRE will be used. To use the Common Annotations 1.1 + provided by Tomcat, use the Endorsed Standards Override mechanism + of the JVM. The default configuration defines JARs located in + "$CATALINA_HOME/endorsed" as endorsed. + + NOTE: Java 6 includes a subset of Common Annotations 1.0 classes. + + The only known difference between versions 1.0 and 1.1 of those + classes is introduction of "lookup" element on Resource annotation. + + Majority of web applications will not notice the difference. + +(2) Download and Install Apache Tomcat + +(2.1) Download a binary distribution of Tomcat from: + + https://tomcat.apache.org/ + +(2.2) Unpack the binary distribution so that it resides in its own + directory (conventionally named "apache-tomcat-[version]"). + + For the purposes of the remainder of this document, the name + "CATALINA_HOME" is used to refer to the full pathname of that + directory. + +NOTE: As an alternative to downloading a binary distribution, you can +create your own from the Tomcat source code, as described in +"BUILDING.txt". You can either + + a) Do the full "release" build and find the created distribution in the + "output/release" directory and then proceed with unpacking as above, or + + b) Do a simple build and use the "output/build" directory as + "CATALINA_HOME". Be warned that there are some differences between the + contents of the "output/build" directory and a full "release" + distribution. + + +(3) Configure Environment Variables + +Tomcat is a Java application and does not use environment variables directly. +Environment variables are used by the Tomcat startup scripts. The scripts use +the environment variables to prepare the command that starts Tomcat. + +(3.1) Set CATALINA_HOME (required) and CATALINA_BASE (optional) + +The CATALINA_HOME environment variable should be set to the location of the +root directory of the "binary" distribution of Tomcat. + +The Tomcat startup scripts have some logic to set this variable +automatically if it is absent, based on the location of the startup script +in *nix and on the current directory in Windows. That logic might not work +in all circumstances, so setting the variable explicitly is recommended. + +The CATALINA_BASE environment variable specifies location of the root +directory of the "active configuration" of Tomcat. It is optional. It +defaults to be equal to CATALINA_HOME. + +Using distinct values for the CATALINA_HOME and CATALINA_BASE variables is +recommended to simplify further upgrades and maintenance. It is documented +in the "Multiple Tomcat Instances" section below. + + +(3.2) Set JRE_HOME or JAVA_HOME (required) + +These variables are used to specify location of a Java Runtime +Environment or of a Java Development Kit that is used to start Tomcat. + +The JRE_HOME variable is used to specify location of a JRE. The JAVA_HOME +variable is used to specify location of a JDK. + +Using JAVA_HOME provides access to certain additional startup options that +are not allowed when JRE_HOME is used. + +If both JRE_HOME and JAVA_HOME are specified, JRE_HOME is used. + +The recommended place to specify these variables is a "setenv" script. See +below. + + +(3.3) Other variables (optional) + +Other environment variables exist, besides the four described above. +See the comments at the top of catalina.bat or catalina.sh scripts for +the list and a description of each of them. + +One frequently used variable is CATALINA_OPTS. It allows specification of +additional options for the java command that starts Tomcat. + +See the Java documentation for the options that affect the Java Runtime +Environment. + +See the "System Properties" page in the Tomcat Configuration Reference for +the system properties that are specific to Tomcat. + +A similar variable is JAVA_OPTS. It is used less frequently. It allows +specification of options that are used both to start and to stop Tomcat as well +as for other commands. + +Note: Do not use JAVA_OPTS to specify memory limits. You do not need much +memory for a small process that is used to stop Tomcat. Those settings +belong to CATALINA_OPTS. + +Another frequently used variable is CATALINA_PID (on *nix only). It +specifies the location of the file where process id of the forked Tomcat +java process will be written. This setting is optional. It will enable the +following features: + + * better protection against duplicate start attempts and + * allows forceful termination of Tomcat process when it does not react to + the standard shutdown command. + + +(3.4) Using the "setenv" script (optional, recommended) + +Apart from CATALINA_HOME and CATALINA_BASE, all environment variables can +be specified in the "setenv" script. The script is placed either into +CATALINA_BASE/bin or into CATALINA_HOME/bin directory and is named +setenv.bat (on Windows) or setenv.sh (on *nix). The file has to be +readable. + +By default the setenv script file is absent. If the script file is present +both in CATALINA_BASE and in CATALINA_HOME, the one in CATALINA_BASE is +preferred. + +For example, to configure the JRE_HOME and CATALINA_PID variables you can +create the following script file: + +On Windows, %CATALINA_BASE%\bin\setenv.bat: + + set "JRE_HOME=%ProgramFiles%\Java\jre6" + exit /b 0 + +On *nix, $CATALINA_BASE/bin/setenv.sh: + + JRE_HOME=/usr/java/latest + CATALINA_PID="$CATALINA_BASE/tomcat.pid" + + +The CATALINA_HOME and CATALINA_BASE variables cannot be configured in the +setenv script, because they are used to locate that file. + +All the environment variables described here and the "setenv" script are +used only if you use the standard scripts to launch Tomcat. For example, if +you have installed Tomcat as a service on Windows, the service wrapper +launches Java directly and does not use the script files. + + +(4) Start Up Tomcat + +(4.1) Tomcat can be started by executing one of the following commands: + + On Windows: + + %CATALINA_HOME%\bin\startup.bat + + or + + %CATALINA_HOME%\bin\catalina.bat start + + On *nix: + + $CATALINA_HOME/bin/startup.sh + + or + + $CATALINA_HOME/bin/catalina.sh start + +(4.2) After startup, the default web applications included with Tomcat will be + available by visiting: + + http://localhost:8080/ + +(4.3) Further information about configuring and running Tomcat can be found in + the documentation included here, as well as on the Tomcat web site: + + https://tomcat.apache.org/ + + +(5) Shut Down Tomcat + +(5.1) Tomcat can be shut down by executing one of the following commands: + + On Windows: + + %CATALINA_HOME%\bin\shutdown.bat + + or + + %CATALINA_HOME%\bin\catalina.bat stop + + On *nix: + + $CATALINA_HOME/bin/shutdown.sh + + or + + $CATALINA_HOME/bin/catalina.sh stop + +================================================== +Advanced Configuration - Multiple Tomcat Instances +================================================== + +In many circumstances, it is desirable to have a single copy of a Tomcat +binary distribution shared among multiple users on the same server. To make +this possible, you can set the CATALINA_BASE environment variable to the +directory that contains the files for your 'personal' Tomcat instance. + +When running with a separate CATALINA_HOME and CATALINA_BASE, the files +and directories are split as following: + +In CATALINA_BASE: + + * bin - Only the following files: + + * setenv.sh (*nix) or setenv.bat (Windows), + * tomcat-juli.jar + + The setenv scripts were described above. The tomcat-juli library + is documented in the Logging chapter in the User Guide. + + * conf - Server configuration files (including server.xml) + + * lib - Libraries and classes, as explained below + + * logs - Log and output files + + * webapps - Automatically loaded web applications + + * work - Temporary working directories for web applications + + * temp - Directory used by the JVM for temporary files (java.io.tmpdir) + + +In CATALINA_HOME: + + * bin - Startup and shutdown scripts + + The following files will be used only if they are absent in + CATALINA_BASE/bin: + + setenv.sh (*nix), setenv.bat (Windows), tomcat-juli.jar + + * lib - Libraries and classes, as explained below + + * endorsed - Libraries that override standard "Endorsed Standards" + libraries provided by JRE. See Classloading documentation + in the User Guide for details. + No longer supported with Java 9. + + By default this "endorsed" directory is absent. + +In the default configuration the JAR libraries and classes both in +CATALINA_BASE/lib and in CATALINA_HOME/lib will be added to the common +classpath, but the ones in CATALINA_BASE will be added first and thus will +be searched first. + +The idea is that you may leave the standard Tomcat libraries in +CATALINA_HOME/lib and add other ones such as database drivers into +CATALINA_BASE/lib. + +In general it is advised to never share libraries between web applications, +but put them into WEB-INF/lib directories inside the applications. See +Classloading documentation in the User Guide for details. + + +It might be useful to note that the values of CATALINA_HOME and +CATALINA_BASE can be referenced in the XML configuration files processed +by Tomcat as ${catalina.home} and ${catalina.base} respectively. + +For example, the standard manager web application can be kept in +CATALINA_HOME/webapps/manager and loaded into CATALINA_BASE by copying +its deployment descriptor into the desired virtual host: + + * Copy the CATALINA_HOME/webapps/manager/META-INF/context.xml + file as CATALINA_BASE/conf/Catalina/localhost/manager.xml + + * Add docBase attribute as shown below. + +The file will look like the following: + + + + + + + +See Deployer chapter in User Guide and Context and Host chapters in the +Configuration Reference for more information on contexts and web +application deployment. + + +================ +Troubleshooting +================ + +There are only really 2 things likely to go wrong during the stand-alone +Tomcat install: + +(1) The most common hiccup is when another web server (or any process for that + matter) has laid claim to port 8080. This is the default HTTP port that + Tomcat attempts to bind to at startup. To change this, open the file: + + $CATALINA_HOME/conf/server.xml + + and search for '8080'. Change it to a port that isn't in use, and is + greater than 1024, as ports less than or equal to 1024 require superuser + access to bind under UNIX. + + Restart Tomcat and you're in business. Be sure that you replace the "8080" + in the URL you're using to access Tomcat. For example, if you change the + port to 1977, you would request the URL http://localhost:1977/ in your + browser. + +(2) The 'localhost' machine isn't found. This could happen if you're behind a + proxy. If that's the case, make sure the proxy configuration for your + browser knows that you shouldn't be going through the proxy to access the + "localhost". + + In Firefox, this is under Tools/Preferences -> Advanced/Network -> + Connection -> Settings..., and in Internet Explorer it is Tools -> + Internet Options -> Connections -> LAN Settings. + + +==================== +Optional Components +==================== + +The following optional components may be included with the Apache Tomcat binary +distribution. If they are not included, you can install them separately. + + 1. Apache Tomcat Native library + + 2. Apache Commons Daemon service launcher + +Both of them are implemented in C language and as such have to be compiled +into binary code. The binary code will be specific for a platform and CPU +architecture and it must match the Java Runtime Environment executables +that will be used to launch Tomcat. + +The Windows-specific binary distributions of Apache Tomcat include binary +files for these components. On other platforms you would have to look for +binary versions elsewhere or compile them yourself. + +If you are new to Tomcat, do not bother with these components to start with. +If you do use them, do not forget to read their documentation. + + +Apache Tomcat Native library +----------------------------- + +It is a library that allows to use the "Apr" variant of HTTP and AJP +protocol connectors in Apache Tomcat. It is built around OpenSSL and Apache +Portable Runtime (APR) libraries. Those are the same libraries as used by +Apache HTTPD Server project. + +This feature was especially important in the old days when Java performance +was poor. It is less important nowadays, but it is still used and respected +by many. See Tomcat documentation for more details. + +For further reading: + + - Apache Tomcat documentation + + * Documentation for APR/Native library in the Tomcat User's Guide + + https://tomcat.apache.org/tomcat-7.0-doc/apr.html + + * Documentation for the HTTP and AJP protocol connectors in the Tomcat + Configuration Reference + + https://tomcat.apache.org/tomcat-7.0-doc/config/http.html + + https://tomcat.apache.org/tomcat-7.0-doc/config/ajp.html + + - Apache Tomcat Native project home + + https://tomcat.apache.org/native-doc/ + + - Other projects + + * OpenSSL + + https://www.openssl.org/ + + * Apache Portable Runtime + + https://apr.apache.org/ + + * Apache HTTP Server + + https://httpd.apache.org/ + +To disable Apache Tomcat Native library: + + - To disable Apache Tomcat Native library when it is installed, or + - To remove the warning that is logged during Tomcat startup when the + library is not installed: + + Edit the "conf/server.xml" file and remove "AprLifecycleListener" from + it. + +The binary file of Apache Tomcat Native library is usually named + + - "tcnative-1.dll" on Windows + - "libtcnative-1.so" on *nix systems + + +Apache Commons Daemon +---------------------- + +Apache Commons Daemon project provides wrappers that can be used to +install Apache Tomcat as a service on Windows or as a daemon on *nix +systems. + +The Windows-specific implementation of Apache Commons Daemon is called +"procrun". The *nix-specific one is called "jsvc". + +For further reading: + + - Apache Commons Daemon project + + https://commons.apache.org/daemon/ + + - Apache Tomcat documentation + + * Installing Apache Tomcat + + https://tomcat.apache.org/tomcat-7.0-doc/setup.html + + * Windows service HOW-TO + + https://tomcat.apache.org/tomcat-7.0-doc/windows-service-howto.html + +The binary files of Apache Commons Daemon in Apache Tomcat distributions +for Windows are named: + + - "tomcat7.exe" + - "tomcat7w.exe" + +These files are renamed copies of "prunsrv.exe" and "prunmgr.exe" from +Apache Commons Daemon distribution. The file names have a meaning: they are +used as the service name to register the service in Windows, as well as the +key name to store distinct configuration for this installation of +"procrun". If you would like to install several instances of Tomcat 7.0 +in parallel, you have to further rename those files, using the same naming +scheme. diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/WEB-INF/web.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/WEB-INF/web.xml new file mode 100644 index 0000000..46babd4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/WEB-INF/web.xml @@ -0,0 +1,29 @@ + + + + + Tomcat Documentation + + Tomcat Documentation. + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/aio.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/aio.html new file mode 100644 index 0000000..754c8b0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/aio.html @@ -0,0 +1,392 @@ +Apache Tomcat 7 (7.0.108) - Advanced IO and Tomcat

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Advanced IO and Tomcat

Table of Contents
+ +
Introduction
+ +

+ With usage of APR or NIO APIs as the basis of its connectors, Tomcat is + able to provide a number of extensions over the regular blocking IO + as provided with support for the Servlet API. +

+ +

+ IMPORTANT NOTE: Usage of these features requires using the APR or NIO + HTTP connectors. The classic java.io HTTP connector and the AJP connectors + do not support them. +

+ +
Comet support
+ +

+ Comet support allows a servlet to process IO asynchronously, receiving + events when data is available for reading on the connection (rather than + always using a blocking read), and writing data back on connections + asynchronously (most likely responding to some event raised from some + other source). +

+ +
CometEvent
+ +

+ Servlets which implement the org.apache.catalina.comet.CometProcessor + interface will have their event method invoked rather than the usual service + method, according to the event which occurred. The event object gives + access to the usual request and response objects, which may be used in the + usual way. The main difference is that those objects remain valid and fully + functional at any time between processing of the BEGIN event until processing + an END or ERROR event. + The following event types exist: +

+ +
    +
  • EventType.BEGIN: will be called at the beginning + of the processing of the connection. It can be used to initialize any relevant + fields using the request and response objects. Between the end of the processing + of this event, and the beginning of the processing of the end or error events, + it is possible to use the response object to write data on the open connection. + Note that the response object and dependent OutputStream and Writer are still + not synchronized, so when they are accessed by multiple threads, + synchronization is mandatory. After processing the initial event, the request + is considered to be committed.
  • +
  • EventType.READ: This indicates that input data is available, and that one read can be made + without blocking. The available and ready methods of the InputStream or + Reader may be used to determine if there is a risk of blocking: the servlet + should read while data is reported available. When encountering a read error, + the servlet should report it by propagating the exception properly. Throwing + an exception will cause the error event to be invoked, and the connection + will be closed. + Alternately, it is also possible to catch any exception, perform clean up + on any data structure the servlet may be using, and using the close method + of the event. It is not allowed to attempt reading data from the request + object outside of the execution of this method.
    + On some platforms, like Windows, a client disconnect is indicated by a READ event. + Reading from the stream may result in -1, an IOException or an EOFException. + Make sure you properly handle all these three cases. + If you don't catch the IOException, Tomcat will instantly invoke your event chain with an ERROR as + it catches the error for you, and you will be notified of the error at that time. +
  • +
  • EventType.END: End may be called to end the processing of the request. Fields that have + been initialized in the begin method should be reset. After this event has + been processed, the request and response objects, as well as all their dependent + objects will be recycled and used to process other requests. End will also be + called when data is available and the end of file is reached on the request input + (this usually indicates the client has pipelined a request).
  • +
  • EventType.ERROR: Error will be called by the container in the case where an IO exception + or a similar unrecoverable error occurs on the connection. Fields that have + been initialized in the begin method should be reset. After this event has + been processed, the request and response objects, as well as all their dependent + objects will be recycled and used to process other requests.
  • +
+ +

+ There are some event subtypes which allow finer processing of events (note: some of these + events require usage of the org.apache.catalina.valves.CometConnectionManagerValve valve): +

+ +
    +
  • EventSubType.TIMEOUT: The connection timed out (sub type of ERROR); note that this ERROR + type is not fatal, and the connection will not be closed unless the servlet uses the close + method of the event. +
  • +
  • EventSubType.CLIENT_DISCONNECT: The client connection was closed (sub type of ERROR). +
  • +
  • EventSubType.IOEXCEPTION: An IO exception occurred, such as invalid content, for example, + an invalid chunk block (sub type of ERROR). +
  • +
  • EventSubType.WEBAPP_RELOAD: The web application is being reloaded (sub type of END). +
  • +
  • EventSubType.SESSION_END: The servlet ended the session (sub type of END). +
  • +
+ +

+ As described above, the typical lifecycle of a Comet request will consist in a series of + events such as: BEGIN -> READ -> READ -> READ -> ERROR/TIMEOUT. At any time, the servlet + may end processing of the request by using the close method of the event object. +

+ +
+ +
CometFilter
+ +

+ Similar to regular filters, a filter chain is invoked when comet events are processed. + These filters should implement the CometFilter interface (which works in the same way as + the regular Filter interface), and should be declared and mapped in the deployment + descriptor in the same way as a regular filter. The filter chain when processing an event + will only include filters which match all the usual mapping rules, and also implement + the CometFiler interface. +

+ +
+ +
Example code
+ +

+ The following pseudo code servlet implements asynchronous chat functionality using the API + described above: +

+ +
public class ChatServlet
+    extends HttpServlet implements CometProcessor {
+
+    protected ArrayList<HttpServletResponse> connections =
+        new ArrayList<HttpServletResponse>();
+    protected MessageSender messageSender = null;
+
+    public void init() throws ServletException {
+        messageSender = new MessageSender();
+        Thread messageSenderThread =
+            new Thread(messageSender, "MessageSender[" + getServletContext().getContextPath() + "]");
+        messageSenderThread.setDaemon(true);
+        messageSenderThread.start();
+    }
+
+    public void destroy() {
+        connections.clear();
+        messageSender.stop();
+        messageSender = null;
+    }
+
+    /**
+     * Process the given Comet event.
+     *
+     * @param event The Comet event that will be processed
+     * @throws IOException
+     * @throws ServletException
+     */
+    public void event(CometEvent event)
+        throws IOException, ServletException {
+        HttpServletRequest request = event.getHttpServletRequest();
+        HttpServletResponse response = event.getHttpServletResponse();
+        if (event.getEventType() == CometEvent.EventType.BEGIN) {
+            log("Begin for session: " + request.getSession(true).getId());
+            PrintWriter writer = response.getWriter();
+            writer.println("<!DOCTYPE html>");
+            writer.println("<head><title>JSP Chat</title></head><body>");
+            writer.flush();
+            synchronized(connections) {
+                connections.add(response);
+            }
+        } else if (event.getEventType() == CometEvent.EventType.ERROR) {
+            log("Error for session: " + request.getSession(true).getId());
+            synchronized(connections) {
+                connections.remove(response);
+            }
+            event.close();
+        } else if (event.getEventType() == CometEvent.EventType.END) {
+            log("End for session: " + request.getSession(true).getId());
+            synchronized(connections) {
+                connections.remove(response);
+            }
+            PrintWriter writer = response.getWriter();
+            writer.println("</body></html>");
+            event.close();
+        } else if (event.getEventType() == CometEvent.EventType.READ) {
+            InputStream is = request.getInputStream();
+            byte[] buf = new byte[512];
+            do {
+                int n = is.read(buf); //can throw an IOException
+                if (n > 0) {
+                    log("Read " + n + " bytes: " + new String(buf, 0, n)
+                            + " for session: " + request.getSession(true).getId());
+                } else if (n < 0) {
+                    error(event, request, response);
+                    return;
+                }
+            } while (is.available() > 0);
+        }
+    }
+
+    public class MessageSender implements Runnable {
+
+        protected boolean running = true;
+        protected ArrayList<String> messages = new ArrayList<String>();
+
+        public MessageSender() {
+        }
+
+        public void stop() {
+            running = false;
+        }
+
+        /**
+         * Add message for sending.
+         */
+        public void send(String user, String message) {
+            synchronized (messages) {
+                messages.add("[" + user + "]: " + message);
+                messages.notify();
+            }
+        }
+
+        public void run() {
+
+            while (running) {
+
+                if (messages.size() == 0) {
+                    try {
+                        synchronized (messages) {
+                            messages.wait();
+                        }
+                    } catch (InterruptedException e) {
+                        // Ignore
+                    }
+                }
+
+                synchronized (connections) {
+                    String[] pendingMessages = null;
+                    synchronized (messages) {
+                        pendingMessages = messages.toArray(new String[0]);
+                        messages.clear();
+                    }
+                    // Send any pending message on all the open connections
+                    for (int i = 0; i < connections.size(); i++) {
+                        try {
+                            PrintWriter writer = connections.get(i).getWriter();
+                            for (int j = 0; j < pendingMessages.length; j++) {
+                                writer.println(pendingMessages[j] + "<br>");
+                            }
+                            writer.flush();
+                        } catch (IOException e) {
+                            log("IOExeption sending message", e);
+                        }
+                    }
+                }
+
+            }
+
+        }
+
+    }
+
+}
+ +
+
Comet timeouts
+

If you are using the NIO connector, you can set individual timeouts for your different comet connections. + To set a timeout, simply set a request attribute like the following code shows:

+
CometEvent event.... event.setTimeout(30*1000);
+

or

+
event.getHttpServletRequest().setAttribute("org.apache.tomcat.comet.timeout", new Integer(30 * 1000));
+

+ This sets the timeout to 30 seconds. + Important note: in order to set this timeout, it has to be done on the BEGIN event. + The default value is soTimeout +

+

If you are using the APR connector, all Comet connections will have the same timeout value. It is soTimeout*50 +

+
+ +
Asynchronous writes
+ +

+ When APR or NIO is enabled, Tomcat supports using sendfile to send large static files. + These writes, as soon as the system load increases, will be performed + asynchronously in the most efficient way. Instead of sending a large response using + blocking writes, it is possible to write content to a static file, and write it + using a sendfile code. A caching valve could take advantage of this to cache the + response data in a file rather than store it in memory. Sendfile support is + available if the request attribute org.apache.tomcat.sendfile.support + is set to Boolean.TRUE. +

+ +

+ Any servlet can instruct Tomcat to perform a sendfile call by setting the appropriate + request attributes. It is also necessary to correctly set the content length + for the response. When using sendfile, it is best to ensure that neither the + request or response have been wrapped, since as the response body will be sent later + by the connector itself, it cannot be filtered. Other than setting the 3 needed + request attributes, the servlet should not send any response data, but it may use + any method which will result in modifying the response header (like setting cookies). +

+ +
    +
  • org.apache.tomcat.sendfile.filename: Canonical filename of the file which will be sent as + a String
  • +
  • org.apache.tomcat.sendfile.start: Start offset as a Long
  • +
  • org.apache.tomcat.sendfile.end: End offset as a Long
  • +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/annotationapi/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/annotationapi/index.html new file mode 100644 index 0000000..3e9cb01 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/annotationapi/index.html @@ -0,0 +1,34 @@ + + + + + + API docs + + + + +The Annotation API Javadoc is not installed by default. Download and install +the "fulldocs" package to get it. + +You can also access the javadoc online in the Tomcat + + documentation bundle. + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/api/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/api/index.html new file mode 100644 index 0000000..a98cef0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/api/index.html @@ -0,0 +1,34 @@ + + + + + + API docs + + + + +Tomcat's internal javadoc is not installed by default. Download and install +the "fulldocs" package to get it. + +You can also access the javadoc online in the Tomcat + +documentation bundle. + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/build.xml.txt b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/build.xml.txt new file mode 100644 index 0000000..555bc24 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/build.xml.txt @@ -0,0 +1,512 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/deployment.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/deployment.html new file mode 100644 index 0000000..845e3ba --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/deployment.html @@ -0,0 +1,279 @@ +Application Developer's Guide (7.0.108) - Deployment

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Deployment

Table of Contents
+ +
Background
+ +

Before describing how to organize your source code directories, +it is useful to examine the runtime organization of a web application. +Prior to the Servlet API Specification, version 2.2, there was little +consistency between server platforms. However, servers that conform +to the 2.2 (or later) specification are required to accept a +Web Application Archive in a standard format, which is discussed +further below.

+ +

A web application is defined as a hierarchy of directories and files +in a standard layout. Such a hierarchy can be accessed in its "unpacked" +form, where each directory and file exists in the filesystem separately, +or in a "packed" form known as a Web ARchive, or WAR file. The former format +is more useful during development, while the latter is used when you +distribute your application to be installed.

+ +

The top-level directory of your web application hierarchy is also the +document root of your application. Here, you will place the HTML +files and JSP pages that comprise your application's user interface. When the +system administrator deploys your application into a particular server, he +or she assigns a context path to your application (a later section +of this manual describes deployment on Tomcat). Thus, if the +system administrator assigns your application to the context path +/catalog, then a request URI referring to +/catalog/index.html will retrieve the index.html +file from your document root.

+ +
Standard Directory Layout
+ +

To facilitate creation of a Web Application Archive file in the required +format, it is convenient to arrange the "executable" files of your web +application (that is, the files that Tomcat actually uses when executing +your app) in the same organization as required by the WAR format itself. +To do this, you will end up with the following contents in your +application's "document root" directory:

+
    +
  • *.html, *.jsp, etc. - The HTML and JSP pages, along + with other files that must be visible to the client browser (such as + JavaScript, stylesheet files, and images) for your application. + In larger applications you may choose to divide these files into + a subdirectory hierarchy, but for smaller apps, it is generally + much simpler to maintain only a single directory for these files. +

  • +
  • /WEB-INF/web.xml - The Web Application Deployment + Descriptor for your application. This is an XML file describing + the servlets and other components that make up your application, + along with any initialization parameters and container-managed + security constraints that you want the server to enforce for you. + This file is discussed in more detail in the following subsection. +

  • +
  • /WEB-INF/classes/ - This directory contains any Java + class files (and associated resources) required for your application, + including both servlet and non-servlet classes, that are not combined + into JAR files. If your classes are organized into Java packages, + you must reflect this in the directory hierarchy under + /WEB-INF/classes/. For example, a Java class named + com.mycompany.mypackage.MyServlet + would need to be stored in a file named + /WEB-INF/classes/com/mycompany/mypackage/MyServlet.class. +

  • +
  • /WEB-INF/lib/ - This directory contains JAR files that + contain Java class files (and associated resources) required for your + application, such as third party class libraries or JDBC drivers.
  • +
+ +

When you install an application into Tomcat (or any other 2.2 or later +Servlet container), the classes in the WEB-INF/classes/ +directory, as well as all classes in JAR files found in the +WEB-INF/lib/ directory, are made visible to other classes +within your particular web application. Thus, if +you include all of the required library classes in one of these places (be +sure to check licenses for redistribution rights for any third party libraries +you utilize), you will simplify the installation of your web application -- +no adjustment to the system class path (or installation of global library +files in your server) will be necessary.

+ +

Much of this information was extracted from Chapter 9 of the Servlet +API Specification, version 2.3, which you should consult for more details.

+ +
Shared Library Files
+ +

Like most servlet containers, Tomcat also supports mechanisms to install +library JAR files (or unpacked classes) once, and make them visible to all +installed web applications (without having to be included inside the web +application itself). The details of how Tomcat locates and shares such +classes are described in the +Class Loader HOW-TO documentation. +The location commonly used within a Tomcat installation for shared code is +$CATALINA_HOME/lib. JAR files placed here are visible both to +web applications and internal Tomcat code. This is a good place to put JDBC +drivers that are required for both your application or internal Tomcat use +(such as for a DataSourceRealm).

+ +

Out of the box, a standard Tomcat installation includes a variety +of pre-installed shared library files, including:

+
    +
  • The Servlet 3.0 and JSP 2.2 APIs that are fundamental + to writing servlets and JavaServer Pages.

  • +
+ +
Web Application Deployment Descriptor
+ +

As mentioned above, the /WEB-INF/web.xml file contains the +Web Application Deployment Descriptor for your application. As the filename +extension implies, this file is an XML document, and defines everything about +your application that a server needs to know (except the context path, +which is assigned by the system administrator when the application is +deployed).

+ +

The complete syntax and semantics for the deployment descriptor is defined +in Chapter 13 of the Servlet API Specification, version 2.3. Over time, it +is expected that development tools will be provided that create and edit the +deployment descriptor for you. In the meantime, to provide a starting point, +a basic web.xml file +is provided. This file includes comments that describe the purpose of each +included element.

+ +

NOTE - The Servlet Specification includes a Document +Type Descriptor (DTD) for the web application deployment descriptor, and +Tomcat enforces the rules defined here when processing your application's +/WEB-INF/web.xml file. In particular, you must +enter your descriptor elements (such as <filter>, +<servlet>, and <servlet-mapping> in +the order defined by the DTD (see Section 13.3).

+ +
Tomcat Context Descriptor
+ +

A /META-INF/context.xml file can be used to define Tomcat specific +configuration options, such as an access log, data sources, session manager +configuration and more. This XML file must contain one Context element, which +will be considered as if it was the child of the Host element corresponding +to the Host to which the web application is being deployed. The +Tomcat configuration documentation contains +information on the Context element.

+ +
Deployment With Tomcat
+ +

The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+ +

In order to be executed, a web application must be deployed on +a servlet container. This is true even during development. +We will describe using Tomcat to provide the execution environment. +A web application can be deployed in Tomcat by one of the following +approaches:

+
    +
  • Copy unpacked directory hierarchy into a subdirectory in directory + $CATALINA_BASE/webapps/. Tomcat will assign a + context path to your application based on the subdirectory name you + choose. We will use this technique in the build.xml + file that we construct, because it is the quickest and easiest approach + during development. Be sure to restart Tomcat after installing or + updating your application. +

  • +
  • Copy the web application archive file into directory + $CATALINA_BASE/webapps/. When Tomcat is started, it will + automatically expand the web application archive file into its unpacked + form, and execute the application that way. This approach would typically + be used to install an additional application, provided by a third party + vendor or by your internal development staff, into an existing + Tomcat installation. NOTE - If you use this approach, + and wish to update your application later, you must both replace the + web application archive file AND delete the expanded + directory that Tomcat created, and then restart Tomcat, in order to reflect + your changes. +

  • +
  • Use the Tomcat "Manager" web application to deploy and undeploy + web applications. Tomcat includes a web application, deployed + by default on context path /manager, that allows you to + deploy and undeploy applications on a running Tomcat server without + restarting it. See Manager App HOW-TO + for more information on using the Manager web application.

  • +
  • Use "Manager" Ant Tasks In Your Build Script. Tomcat + includes a set of custom task definitions for the Ant + build tool that allow you to automate the execution of commands to the + "Manager" web application. These tasks are used in the Tomcat deployer. +

  • +
  • Use the Tomcat Deployer. Tomcat includes a packaged tool + bundling the Ant tasks, and can be used to automatically precompile JSPs + which are part of the web application before deployment to the server. +

  • +
+ +

Deploying your app on other servlet containers will be specific to each +container, but all containers compatible with the Servlet API Specification +(version 2.2 or later) are required to accept a web application archive file. +Note that other containers are NOT required to accept an +unpacked directory structure (as Tomcat does), or to provide mechanisms for +shared library files, but these features are commonly available.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/index.html new file mode 100644 index 0000000..37bf160 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/index.html @@ -0,0 +1,122 @@ +Application Developer's Guide (7.0.108) - Table of Contents

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Table of Contents

Preface
+ +

This manual includes contributions from many members of the Tomcat Project +developer community. The following authors have provided significant content: +

+ + +
Table of Contents
+ +

The information presented is divided into the following sections:

+
    +
  • Introduction - + Briefly describes the information covered here, with + links and references to other sources of information.
  • +
  • Installation - + Covers acquiring and installing the required software + components to use Tomcat for web application development.
  • +
  • Deployment Organization - + Discusses the standard directory layout for a web application + (defined in the Servlet API Specification), the Web Application + Deployment Descriptor, and options for integration with Tomcat + in your development environment.
  • +
  • Source Organization - + Describes a useful approach to organizing the source code + directories for your project, and introduces the + build.xml used by Ant to manage compilation.
  • +
  • Development Processes - + Provides brief descriptions of typical development processes + utilizing the recommended deployment and source organizations.
  • +
  • Example Application - + This directory contains a very simple, but functionally complete, + "Hello, World" application built according to the principles + described in this manual. You can use this application to + practice using the described techniques.
  • +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/installation.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/installation.html new file mode 100644 index 0000000..fdd4b53 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/installation.html @@ -0,0 +1,150 @@ +Application Developer's Guide (7.0.108) - Installation

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Installation

Installation
+ +

In order to use Tomcat for developing web applications, you must first +install it (and the software it depends on). The required steps are outlined +in the following subsections.

+ +
JDK
+ +

Tomcat 7.0 was designed to run on Java 6 or later. +

+ +

Compatible JDKs for many platforms (or links to where they can be found) +are available at +http://www.oracle.com/technetwork/java/javase/downloads/index.html.

+ +
+ +
Tomcat
+ +

Binary downloads of the Tomcat server are available from +https://tomcat.apache.org/. +This manual assumes you are using the most recent release +of Tomcat 7. Detailed instructions for downloading and installing +Tomcat are available here.

+ +

In the remainder of this manual, example shell scripts assume that you have +set an environment variable CATALINA_HOME that contains the +pathname to the directory in which Tomcat has been installed. Optionally, if +Tomcat has been configured for multiple instances, each instance will have its +own CATALINA_BASE configured.

+ +
+ + +
Ant
+ +

Binary downloads of the Ant build tool are available from +https://ant.apache.org/. +This manual assumes you are using Ant 1.8 or later. The instructions may +also be compatible with other versions, but this has not been tested.

+ +

Download and install Ant. +Then, add the bin directory of the Ant distribution to your +PATH environment variable, following the standard practices for +your operating system platform. Once you have done this, you will be able to +execute the ant shell command directly.

+ +
+ + +
CVS
+ +

Besides the required tools described above, you are strongly encouraged +to download and install a source code control system, such as the +Concurrent Version System (CVS), to maintain historical +versions of the source files that make up your web application. Besides +the server, you will also need appropriate client +tools to check out source code files, and check in modified versions.

+ +

Detailed instructions for installing and using source code control +applications is beyond the scope of this manual. However, CVS server and +client tools for many platforms (along with documentation) can be downloaded +from http://www.cvshome.org/.

+ +
+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/introduction.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/introduction.html new file mode 100644 index 0000000..1254598 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/introduction.html @@ -0,0 +1,135 @@ +Application Developer's Guide (7.0.108) - Introduction

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Introduction

Overview
+ +

Congratulations! You've decided to (or been told to) learn how to +build web applications using servlets and JSP pages, and picked the +Tomcat server to use for your learning and development. But now what +do you do?

+ +

This manual is a primer covering the basic steps of using Tomcat to +set up a development environment, organize your source code, and then +build and test your application. It does not discuss architectures or +recommended coding practices for web application development, +or provide in depth instructions on operating the development +tools that are discussed. References to sources of additional information +are included in the following subsections.

+ +

The discussion in this manual is aimed at developers who will be using +a text editor along with command line tools to develop and debug their +applications. As such, the recommendations are fairly generic – but you +should easily be able to apply them in either a Windows-based or Unix-based +development environment. If you are utilizing an Integrated Development +Environment (IDE) tool, you will need to adapt the advice given here to +the details of your particular environment.

+ +
Links
+ +

The following links provide access to selected sources of online +information, documentation, and software that is useful in developing +web applications with Tomcat.

+
    +
  • https://jcp.org/aboutJava/communityprocess/mrel/jsr245/ - + JavaServer Pages (JSP) Specification, Version 2.2. Describes + the programming environment provided by standard implementations + of the JavaServer Pages (JSP) technology. In conjunction with + the Servlet API Specification (see below), this document describes + what a portable API page is allowed to contain. Specific + information on scripting (Chapter 9), tag extensions (Chapter 7), + and packaging JSP pages (Appendix A) is useful. The Javadoc + API Documentation is included in the specification, and with the + Tomcat download.

  • +
  • https://jcp.org/aboutJava/communityprocess/mrel/jsr315/ - + Servlet API Specification, Version 3.0. Describes the + programming environment that must be provided by all servlet + containers conforming to this specification. In particular, you + will need this document to understand the web application + directory structure and deployment file (Chapter 10), methods of + mapping request URIs to servlets (Chapter 12), container managed + security (Chapter 13), and the syntax of the web.xml + Web Application Deployment Descriptor (Chapter 14). The Javadoc + API Documentation is included in the specification, and with the + Tomcat download.

  • +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/processes.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/processes.html new file mode 100644 index 0000000..c5724e0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/processes.html @@ -0,0 +1,350 @@ +Application Developer's Guide (7.0.108) - Development Processes

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Development Processes

Table of Contents
+ +
Development Processes
+ +

Although application development can take many forms, this manual proposes +a fairly generic process for creating web applications using Tomcat. The +following sections highlight the commands and tasks that you, as the developer +of the code, will perform. The same basic approach works when you have +multiple programmers involved, as long as you have an appropriate source code +control system and internal team rules about who is working on what parts +of the application at any given time.

+ +

The task descriptions below assume that you will be using CVS for source +code control, and that you have already configured access to the appropriate +CVS repository. Instructions for doing this are beyond the scope of this +manual. If you are using a different source code control environment, you +will need to figure out the corresponding commands for your system.

+ + +
One-Time Setup of Ant and Tomcat for Development
+ +

In order to take advantage of the special Ant tasks that interact with the +Manager web application, you need to perform the following tasks +once (no matter how many web applications you plan to develop).

+
    +
  • Configure the Ant custom tasks. The implementation code for the + Ant custom tasks is in a JAR file named + $CATALINA_HOME/lib/catalina-ant.jar, which must be + copied in to the lib directory of your Ant installation. +

  • +
  • Define one or more Tomcat users. The Manager web + application runs under a security constraint that requires a user to be + logged in, and have the security role manager-script assigned + to him or her. How such users are defined depends on which Realm you have + configured in Tomcat's conf/server.xml file -- see the + Realm Configuration HOW-TO for more + information. You may define any number of users (with any username + and password that you like) with the manager-script role. +

  • +
+ +
+ + +
Create Project Source Code Directory
+ +

The first step is to create a new project source directory, and customize +the build.xml and build.properties files you will +be using. The directory structure is described in the +previous section, or you can use the +sample application as a starting point.

+ +

Create your project source directory, and define it within your CVS +repository. This might be done by a series of commands like this, where +{project} is the name under which your project should be +stored in the CVS repository, and {username} is your login username:

+
cd {my home directory}
+mkdir myapp <-- Assumed "project source directory"
+cd myapp
+mkdir docs
+mkdir src
+mkdir web
+mkdir web/WEB-INF
+cvs import -m "Initial Project Creation" {project} \
+    {username} start
+ +

Now, to verify that it was created correctly in CVS, we will perform a +checkout of the new project:

+
cd ..
+mv myapp myapp.bu
+cvs checkout {project}
+ +

Next, you will need to create and check in an initial version of the +build.xml script to be used for development. For getting +started quickly and easily, base your build.xml on the +basic build.xml file, included with this manual, +or code it from scratch.

+
cd {my home directory}
+cd myapp
+emacs build.xml     <-- if you want a real editor :-)
+cvs add build.xml
+cvs commit
+ +

Until you perform the CVS commit, your changes are local to your own +development directory. Committing makes those changes visible to other +developers on your team that are sharing the same CVS repository.

+ +

The next step is to customize the Ant properties that are +named in the build.xml script. This is done by creating a +file named build.properties in your project's top-level +directory. The supported properties are listed in the comments inside +the sample build.xml script. At a minimum, you will generally +need to define the catalina.home property defining where +Tomcat is installed, and the manager application username and password. +You might end up with something like this:

+
# Context path to install this application on
+app.path=/hello
+
+# Tomcat 7 installation directory
+catalina.home=/usr/local/apache-tomcat-7.0
+
+# Manager webapp username and password
+manager.username=myusername
+manager.password=mypassword
+ +

In general, you will not want to check the +build.properties file in to the CVS repository, because it +is unique to each developer's environment.

+ +

Now, create the initial version of the web application deployment +descriptor. You can base web.xml on the +basic web.xml file, or code it from scratch.

+
cd {my home directory}
+cd myapp/web/WEB-INF
+emacs web.xml
+cvs add web.xml
+cvs commit
+ +Note that this is only an example web.xml file. The full definition +of the deployment descriptor file is in the +Servlet Specification. + +
+ + +
Edit Source Code and Pages
+ +

The edit/build/test tasks will generally be your most common activities +during development and maintenance. The following general principles apply. +As described in Source Organization, newly created +source files should be located in the appropriate subdirectory, under your +project source directory.

+ +

Whenever you wish to refresh your development directory to reflect the +work performed by other developers, you will ask CVS to do it for you:

+
cd {my home directory}
+cd myapp
+cvs update -dP
+ +

To create a new file, go to the appropriate directory, create the file, +and register it with CVS. When you are satisfied with it's contents (after +building and testing is successful), commit the new file to the repository. +For example, to create a new JSP page:

+
cd {my home directory}
+cd myapp/web        <-- Ultimate destination is document root
+emacs mypage.jsp
+cvs add mypage.jsp
+... build and test the application ...
+cvs commit
+ +

Java source code that is defined in packages must be organized in a +directory hierarchy (under the src/ subdirectory) that +matches the package names. For example, a Java class named +com.mycompany.mypackage.MyClass.java should be stored in file +src/com/mycompany/mypackage/MyClass.java. +Whenever you create a new subdirectory, don't forget to +register it with CVS.

+ +

To edit an existing source file, you will generally just start editing +and testing, then commit the changed file when everything works. Although +CVS can be configured to required you to "check out" or "lock" a file you +are going to be modifying, this is generally not used.

+ +
+ + +
Build the Web Application
+ +

When you are ready to compile the application, issue the following +commands (generally, you will want a shell window open that is set to +the project source directory, so that only the last command is needed):

+
cd {my home directory}
+cd myapp        <-- Normally leave a window open here
+ant
+ +

The Ant tool will be execute the default "compile" target in your +build.xml file, which will compile any new or updated Java +code. If this is the first time you compile after a "build clean", +it will cause everything to be recompiled.

+ +

To force the recompilation of your entire application, do this instead:

+
cd {my home directory}
+cd myapp
+ant all
+ +

This is a very good habit immediately before checking in changes, to +make sure that you have not introduced any subtle problems that Javac's +conditional checking did not catch.

+ +
+ + +
Test Your Web Application
+ +

To test your application, you will want to install it under Tomcat. The +quickest way to do that is to use the custom Ant tasks that are included in +the sample build.xml script. Using these commands might follow +a pattern like this:

+
    +
  • Start Tomcat if needed. If Tomcat is not already running, + you will need to start it in the usual way. +

  • +
  • Compile your application. Use the ant compile + command (or just ant, since this is the default). Make + sure that there are no compilation errors. +

  • +
  • Install the application. Use the ant install + command. This tells Tomcat to immediately start running your app on + the context path defined in the app.path build property. + Tomcat does NOT have to be restarted for this to + take effect. +

  • +
  • Test the application. Using your browser or other testing + tools, test the functionality of your application. +

  • +
  • Modify and rebuild as needed. As you discover that changes + are required, make those changes in the original source + files, not in the output build directory, and re-issue the + ant compile command. This ensures that your changes will + be available to be saved (via cvs commit) later on -- + the output build directory is deleted and recreated as necessary. +

  • +
  • Reload the application. Tomcat will recognize changes in + JSP pages automatically, but it will continue to use the old versions + of any servlet or JavaBean classes until the application is reloaded. + You can trigger this by executing the ant reload command. +

  • +
  • Remove the application when you are done. When you are through + working on this application, you can remove it from live execution by + running the ant remove command. +

  • +
+ +

Do not forget to commit your changes to the source code repository when +you have completed your testing!

+ +
+ + +
Creating a Release
+ +

When you are through adding new functionality, and you've tested everything +(you DO test, don't you :-), it is time to create the distributable version +of your web application that can be deployed on the production server. The +following general steps are required:

+
    +
  • Issue the command ant all from the project source + directory, to rebuild everything from scratch one last time. +

  • +
  • Use the cvs tag command to create an identifier for + all of the source files utilized to create this release. This allows + you to reliably reconstruct a release (from sources) at a later + time. +

  • +
  • Issue the command ant dist to create a distributable + web application archive (WAR) file, as well as a JAR file containing + the corresponding source code. +

  • +
  • Package the contents of the dist directory using the + tar or zip utility, according to + the standard release procedures used by your organization. +

  • +
+ +
+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/build.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/build.xml new file mode 100644 index 0000000..555bc24 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/build.xml @@ -0,0 +1,512 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/docs/README.txt b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/docs/README.txt new file mode 100644 index 0000000..f146b0e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/docs/README.txt @@ -0,0 +1,17 @@ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +This is a dummy README file for the sample +web application. diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/index.html new file mode 100644 index 0000000..a316a23 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/index.html @@ -0,0 +1,46 @@ + + + + +Sample Application + + +

Sample Application

+

+ The example app has been packaged as a war file and can be downloaded + here (Note: make sure your browser doesn't + change file extension or append a new one). +

+

+ The easiest way to run this application is simply to move the war file + to your CATALINA_HOME/webapps directory. Tomcat will automatically + expand and deploy the application for you. You can view it with the + following URL (assuming that you're running tomcat on port 8080 + as is the default): +
+ http://localhost:8080/sample +

+

+ If you just want to browse the contents, you can unpack the war file + with the jar command. +

+
+        jar -xvf sample.war
+      
+ + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/sample.war b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/sample.war new file mode 100644 index 0000000..0a127e6 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/sample.war differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/src/mypackage/Hello.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/src/mypackage/Hello.java new file mode 100644 index 0000000..0098cbc --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/src/mypackage/Hello.java @@ -0,0 +1,84 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package mypackage; + +import java.io.IOException; +import java.io.PrintWriter; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + + +/** + * Simple servlet to validate that the Hello, World example can + * execute servlets. In the web application deployment descriptor, + * this servlet must be mapped to correspond to the link in the + * "index.html" file. + * + * @author Craig R. McClanahan + */ + +public final class Hello extends HttpServlet { + + private static final long serialVersionUID = 1L; + + /** + * Respond to a GET request for the content produced by + * this servlet. + * + * @param request The servlet request we are processing + * @param response The servlet response we are producing + * + * @exception IOException if an input/output error occurs + * @exception ServletException if a servlet error occurs + */ + @Override + public void doGet(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException { + + response.setContentType("text/html"); + PrintWriter writer = response.getWriter(); + + writer.println(""); + writer.println(""); + writer.println("Sample Application Servlet Page"); + writer.println(""); + writer.println(""); + + writer.println(""); + writer.println(""); + writer.println(""); + writer.println(""); + writer.println(""); + writer.println("
"); + writer.println(""); + writer.println(""); + writer.println("

Sample Application Servlet

"); + writer.println("This is the output of a servlet that is part of"); + writer.println("the Hello, World application."); + writer.println("
"); + + writer.println(""); + writer.println(""); + + } + + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/WEB-INF/web.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/WEB-INF/web.xml new file mode 100644 index 0000000..08b7053 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/WEB-INF/web.xml @@ -0,0 +1,39 @@ + + + + + Hello, World Application + + This is a simple web application with a source code organization + based on the recommendations of the Application Developer's Guide. + + + + HelloServlet + mypackage.Hello + + + + HelloServlet + /hello + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/hello.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/hello.jsp new file mode 100644 index 0000000..0f23637 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/hello.jsp @@ -0,0 +1,39 @@ + + + +Sample Application JSP Page + + + + + + + + +
+ + +

Sample Application JSP Page

+This is the output of a JSP page that is part of the Hello, World +application. +
+ +<%= new String("Hello!") %> + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/images/tomcat.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/images/tomcat.gif new file mode 100644 index 0000000..f2aa6f8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/images/tomcat.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/index.html new file mode 100644 index 0000000..bbb9997 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/sample/web/index.html @@ -0,0 +1,44 @@ + + + +Sample "Hello, World" Application + + + + + + + + +
+ + +

Sample "Hello, World" Application

+

This is the home page for a sample application used to illustrate the +source directory organization of a web application utilizing the principles +outlined in the Application Developer's Guide. +

+ +

To prove that they work, you can execute either of the following links:

+ + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/source.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/source.html new file mode 100644 index 0000000..833bec4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/source.html @@ -0,0 +1,356 @@ +Application Developer's Guide (7.0.108) - Source Organization

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Source Organization

Table of Contents
+ +
Directory Structure
+ +

The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+ +

A key recommendation of this manual is to separate the directory +hierarchy containing your source code (described in this section) from +the directory hierarchy containing your deployable application +(described in the preceding section). Maintaining this separation has +the following advantages:

+
    +
  • The contents of the source directories can be more easily administered, + moved, and backed up if the "executable" version of the application + is not intermixed. +

  • +
  • Source code control is easier to manage on directories that contain + only source files. +

  • +
  • The files that make up an installable distribution of your + application are much easier to select when the deployment + hierarchy is separate.

  • +
+ +

As we will see, the ant development tool makes the creation +and processing of such directory hierarchies nearly painless.

+ +

The actual directory and file hierarchy used to contain the source code +of an application can be pretty much anything you like. However, the +following organization has proven to be quite generally applicable, and is +expected by the example build.xml configuration file that +is discussed below. All of these components exist under a top level +project source directory for your application:

+
    +
  • docs/ - Documentation for your application, in whatever + format your development team is using.

  • +
  • src/ - Java source files that generate the servlets, + beans, and other Java classes that are unique to your application. + If your source code is organized in packages (highly + recommended), the package hierarchy should be reflected as a directory + structure underneath this directory.

  • +
  • web/ - The static content of your web site (HTML pages, + JSP pages, JavaScript files, CSS stylesheet files, and images) that will + be accessible to application clients. This directory will be the + document root of your web application, and any subdirectory + structure found here will be reflected in the request URIs required to + access those files.

  • +
  • web/WEB-INF/ - The special configuration files required + for your application, including the web application deployment descriptor + (web.xml, defined in the + Servlet Specification), + tag library descriptors for custom tag libraries + you have created, and other resource files you wish to include within + your web application. Even though this directory appears to be a + subdirectory of your document root, the Servlet Specification + prohibits serving the contents of this directory (or any file it contains) + directly to a client request. Therefore, this is a good place to store + configuration information that is sensitive (such as database connection + usernames and passwords), but is required for your application to + operate successfully.
  • +
+ +

During the development process, two additional directories will be +created on a temporary basis:

+
    +
  • build/ - When you execute a default build + (ant), this directory will contain an exact image + of the files in the web application archive for this application. + Tomcat allows you to deploy an application in an unpacked + directory like this, either by copying it to the + $CATALINA_BASE/webapps directory, or by installing + it via the "Manager" web application. The latter approach is very + useful during development, and will be illustrated below. +

  • +
  • dist/ - When you execute the ant dist + target, this directory will be created. It will create an exact image + of the binary distribution for your web application, including an license + information, documentation, and README files that you have prepared.
  • +
+ +

Note that these two directories should NOT be archived in +your source code control system, because they are deleted and recreated (from +scratch) as needed during development. For that reason, you should not edit +any source files in these directories if you want to maintain a permanent +record of the changes, because the changes will be lost the next time that a +build is performed.

+ +
External Dependencies
+ +

What do you do if your application requires JAR files (or other + resources) from external projects or packages? A common example is that + you need to include a JDBC driver in your web application, in order to + operate.

+ +

Different developers take different approaches to this problem. + Some will encourage checking a copy of the JAR files you depend on into + the source code control archives for every application that requires those + JAR files. However, this can cause significant management issues when you + use the same JAR in many applications - particular when faced with a need + to upgrade to a different version of that JAR file.

+ +

Therefore, this manual recommends that you NOT store + a copy of the packages you depend on inside the source control archives + of your applications. Instead, the external dependencies should be + integrated as part of the process of building your + application. In that way, you can always pick up the appropriate version + of the JAR files from wherever your development system administrator has + installed them, without having to worry about updating your application + every time the version of the dependent JAR file is changed.

+ +

In the example Ant build.xml file, we will demonstrate + how to define build properties that let you configure the locations + of the files to be copied, without having to modify build.xml + when these files change. The build properties used by a particular + developer can be customized on a per-application basis, or defaulted to + "standard" build properties stored in the developer's home directory.

+ +

In many cases, your development system administrator will have already + installed the required JAR files into the lib directory of Tomcat. + If this has been done, you need + to take no actions at all - the example build.xml file + automatically constructs a compile classpath that includes these files.

+ +
+ +
Source Code Control
+ +

As mentioned earlier, it is highly recommended that you place all of the +source files that comprise your application under the management of a +source code control system like the Concurrent Version System (CVS). If you +elect to do this, every directory and file in the source hierarchy should be +registered and saved -- but none of the generated files. If you register +binary format files (such as images or JAR libraries), be sure to indicate +this to your source code control system.

+ +

We recommended (in the previous section) that you should not store the +contents of the build/ and dist/ directories +created by your development process in the source code control system. An +easy way to tell CVS to ignore these directories is to create a file named +.cvsignore (note the leading period) in your top-level source +directory, with the following contents:

+
build
+dist
+build.properties
+ +

The reason for mentioning build.properties here will be +explained in the Processes section.

+ +

Detailed instructions for your source code control environment are beyond +the scope of this manual. However, the following steps are followed when +using a command-line CVS client:

+
    +
  • To refresh the state of your source code to that stored in the + the source repository, go to your project source directory, and + execute cvs update -dP. +

  • +
  • When you create a new subdirectory in the source code hierarchy, register + it in CVS with a command like cvs add {subdirname}. +

  • +
  • When you first create a new source code file, navigate to the directory + that contains it, and register the new file with a command like + cvs add {filename}. +

  • +
  • If you no longer need a particular source code file, navigate to the + containing directory and remove the file. Then, deregister it in CVS + with a command like cvs remove {filename}. +

  • +
  • While you are creating, modifying, and deleting source files, changes + are not yet reflected in the server repository. To save your changes in + their current state, go to the project source directory + and execute cvs commit. You will be asked to write a brief + description of the changes you have just completed, which will be stored + with the new version of any updated source file.
  • +
+ +

CVS, like other source code control systems, has many additional features +(such as the ability to tag the files that made up a particular release, and +support for multiple development branches that can later be merged). See the +links and references in the Introduction for +more information.

+ +
BUILD.XML Configuration File
+ +

We will be using the ant tool to manage the compilation of +our Java source code files, and creation of the deployment hierarchy. Ant +operates under the control of a build file, normally called +build.xml, that defines the processing steps required. This +file is stored in the top-level directory of your source code hierarchy, and +should be checked in to your source code control system.

+ +

Like a Makefile, the build.xml file provides several +"targets" that support optional development activities (such as creating +the associated Javadoc documentation, erasing the deployment home directory +so you can build your project from scratch, or creating the web application +archive file so you can distribute your application. A well-constructed +build.xml file will contain internal documentation describing +the targets that are designed for use by the developer, versus those targets +used internally. To ask Ant to display the project documentation, change to +the directory containing the build.xml file and type:

+
ant -projecthelp
+ +

To give you a head start, a basic build.xml file +is provided that you can customize and install in the project source directory +for your application. This file includes comments that describe the various +targets that can be executed. Briefly, the following targets are generally +provided:

+
    +
  • clean - This target deletes any existing + build and dist directories, so that they + can be reconstructed from scratch. This allows you to guarantee that + you have not made source code modifications that will result in + problems at runtime due to not recompiling all affected classes. +

  • +
  • compile - This target is used to compile any source code + that has been changed since the last time compilation took place. The + resulting class files are created in the WEB-INF/classes + subdirectory of your build directory, exactly where the + structure of a web application requires them to be. Because + this command is executed so often during development, it is normally + made the "default" target so that a simple ant command will + execute it. +

  • +
  • all - This target is a short cut for running the + clean target, followed by the compile target. + Thus, it guarantees that you will recompile the entire application, to + ensure that you have not unknowingly introduced any incompatible changes. +

  • +
  • javadoc - This target creates Javadoc API documentation + for the Java classes in this web application. The example + build.xml file assumes you want to include the API + documentation with your app distribution, so it generates the docs + in a subdirectory of the dist directory. Because you normally + do not need to generate the Javadocs on every compilation, this target is + usually a dependency of the dist target, but not of the + compile target. +

  • +
  • dist - This target creates a distribution directory for + your application, including any required documentation, the Javadocs for + your Java classes, and a web application archive (WAR) file that will be + delivered to system administrators who wish to install your application. + Because this target also depends on the deploy target, the + web application archive will have also picked up any external dependencies + that were included at deployment time.
  • +
+ +

For interactive development and testing of your web application using +Tomcat, the following additional targets are defined:

+
    +
  • install - Tell the currently running Tomcat to make + the application you are developing immediately available for execution + and testing. This action does not require Tomcat to be restarted, but + it is also not remembered after Tomcat is restarted the next time. +

  • +
  • reload - Once the application is installed, you can + continue to make changes and recompile using the compile + target. Tomcat will automatically recognize changes made to JSP pages, + but not to servlet or JavaBean classes - this command will tell Tomcat + to restart the currently installed application so that such changes are + recognized. +

  • +
  • remove - When you have completed your development and + testing activities, you can optionally tell Tomcat to remove this + application from service. +
  • +
+ +

Using the development and testing targets requires some additional +one-time setup that is described on the next page.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/web.xml.txt b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/web.xml.txt new file mode 100644 index 0000000..593b800 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/appdev/web.xml.txt @@ -0,0 +1,166 @@ + + + + + + + + + + + My Web Application + + This is version X.X of an application to perform + a wild and wonderful task, based on servlets and + JSP pages. It was written by Dave Developer + (dave@mycompany.com), who should be contacted for + more information. + + + + + + + webmaster + myaddress@mycompany.com + + The EMAIL address of the administrator to whom questions + and comments about this application should be addressed. + + + + + + + + controller + + This servlet plays the "controller" role in the MVC architecture + used in this application. It is generally mapped to the ".do" + filename extension with a servlet-mapping element, and all form + submits in the app will be submitted to a request URI like + "saveCustomer.do", which will therefore be mapped to this servlet. + + The initialization parameter names for this servlet are the + "servlet path" that will be received by this servlet (after the + filename extension is removed). The corresponding value is the + name of the action class that will be used to process this request. + + com.mycompany.mypackage.ControllerServlet + + listOrders + com.mycompany.myactions.ListOrdersAction + + + saveCustomer + com.mycompany.myactions.SaveCustomerAction + + + 5 + + + + graph + + This servlet produces GIF images that are dynamically generated + graphs, based on the input parameters included on the request. + It is generally mapped to a specific request URI like "/graph". + + + + + + + + controller + *.do + + + + graph + /graph + + + + + + + 30 + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/apr.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/apr.html new file mode 100644 index 0000000..8704055 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/apr.html @@ -0,0 +1,221 @@ +Apache Tomcat 7 (7.0.108) - Apache Portable Runtime (APR) based Native library for Tomcat

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Apache Portable Runtime (APR) based Native library for Tomcat

Table of Contents
+ +
Introduction
+ +

+ Tomcat can use the Apache Portable Runtime to + provide superior scalability, performance, and better integration with native server + technologies. The Apache Portable Runtime is a highly portable library that is at + the heart of Apache HTTP Server 2.x. APR has many uses, including access to advanced IO + functionality (such as sendfile, epoll and OpenSSL), OS level functionality (random number + generation, system status, etc), and native process handling (shared memory, NT + pipes and Unix sockets). +

+ +

+ These features allows making Tomcat a general purpose webserver, will enable much better + integration with other native web technologies, and overall make Java much more viable as + a full fledged webserver platform rather than simply a backend focused technology. +

+ +
Installation
+ +

+ APR support requires three main native components to be installed: +

+
    +
  • APR library
  • +
  • JNI wrappers for APR used by Tomcat (libtcnative)
  • +
  • OpenSSL libraries
  • +
+ +
Windows
+ +

+ Windows binaries are provided for tcnative-1, which is a statically compiled .dll which includes + OpenSSL and APR. It can be downloaded from here + as 32bit or AMD x86-64 binaries. + In security conscious production environments, it is recommended to use separate shared dlls + for OpenSSL, APR, and libtcnative-1, and update them as needed according to security bulletins. + Windows OpenSSL binaries are linked from the Official OpenSSL + website (see related/binaries). +

+ +
+ +
Linux
+ +

+ Most Linux distributions will ship packages for APR and OpenSSL. The JNI wrapper (libtcnative) will + then have to be compiled. It depends on APR, OpenSSL, and the Java headers. +

+ +

+ Requirements: +

+
    +
  • APR 1.2+ development headers (libapr1-dev package)
  • +
  • OpenSSL 0.9.7+ development headers (libssl-dev package)
  • +
  • JNI headers from Java compatible JDK 1.4+
  • +
  • GNU development environment (gcc, make)
  • +
+ +

+ The wrapper library sources are located in the Tomcat binary bundle, in the + bin/tomcat-native.tar.gz archive. + Once the build environment is installed and the source archive is extracted, the wrapper library + can be compiled using (from the folder containing the configure script): +

+
./configure && make && make install
+ +
+ +
APR Components
+ +

+ Once the libraries are properly installed and available to Java (if loading fails, the library path + will be displayed), the Tomcat connectors will automatically use APR. Configuration of the connectors + is similar to the regular connectors, but have a few extra attributes which are used to configure + APR components. Note that the defaults should be well tuned for most use cases, and additional + tweaking shouldn't be required. +

+ +

+ When APR is enabled, the following features are also enabled in Tomcat: +

+
    +
  • Secure session ID generation by default on all platforms (platforms other than Linux required + random number generation using a configured entropy)
  • +
  • OS level statistics on memory usage and CPU usage by the Tomcat process are displayed by + the status servlet
  • +
+ +
APR Lifecycle Listener Configuration
+
AprLifecycleListener
+
AttributeDescription
SSLEngine +

+ Name of the SSLEngine to use. off: Do not use SSL, on: Use SSL but no specific ENGINE. + The default value is on. + This initializes the native SSL engine, then enable the use of this engine in the connector + using the SSLEnabled attribute. Example: +

+
<Listener className="org.apache.catalina.core.AprLifecycleListener" SSLEngine="on" />
+ +

See the Official OpenSSL + website for more details on SSL hardware engines and manufacturers. +

+
+
+
APR Connectors Configuration
+ +
HTTP/HTTPS
+ +

For HTTP configuration, see the HTTP + connector configuration documentation.

+ +

For HTTPS configuration, see the + HTTPS connector configuration + documentation.

+ +

An example SSL Connector declaration is:

+
<Connector port="443" maxHttpHeaderSize="8192"
+                 maxThreads="150"
+                 enableLookups="false" disableUploadTimeout="true"
+                 acceptCount="100" scheme="https" secure="true"
+                 SSLEnabled="true"
+                 SSLCertificateFile="${catalina.base}/conf/localhost.crt"
+                 SSLCertificateKeyFile="${catalina.base}/conf/localhost.key" />
+ + +
+ +
AJP
+ +

For AJP configuration, see the AJP + connector configuration documentation.

+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/index.html new file mode 100644 index 0000000..958748c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/index.html @@ -0,0 +1,112 @@ +Apache Tomcat 7 Architecture (7.0.108) - Table of Contents

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Table of Contents

Preface
+ +

This section of the Tomcat documentation attempts to explain +the architecture and design of the Tomcat server. It includes significant +contributions from several tomcat developers: +

+ + +
Table of Contents
+ +

The information presented is divided into the following sections:

+
    +
  • Overview - + An overview of the Tomcat server architecture with key terms + and concepts.
  • +
  • Server Startup - + A detailed description, with sequence diagrams, of how the Tomcat + server starts up.
  • +
  • Request Process Flow - + A detailed description of how Tomcat handles a request.
  • +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/overview.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/overview.html new file mode 100644 index 0000000..84ebaa4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/overview.html @@ -0,0 +1,181 @@ +Apache Tomcat 7 Architecture (7.0.108) - Architecture Overview

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Architecture Overview

Overview
+

+This page provides an overview of the Tomcat server architecture. +

+
Terms
+ +
Server
+

+In the Tomcat world, a +Server represents the whole container. +Tomcat provides a default implementation of the +Server interface +which is rarely customized by users. +

+
+ +
Service
+

+A Service is an intermediate component +which lives inside a Server and ties one or more Connectors to exactly one +Engine. The Service element is rarely customized by users, as the default +implementation is simple and sufficient: +Service interface. +

+
+ +
Engine
+

+An +Engine represents request processing +pipeline for a specific Service. As a Service may have multiple Connectors, +the Engine receives and processes all requests from these connectors, handing +the response back to the appropriate connector for transmission to the client. +The Engine interface +may be implemented to supply custom Engines, though this is uncommon. +

+

+Note that the Engine may be used for Tomcat server clustering via the +jvmRoute parameter. Read the Clustering documentation for more information. +

+
+ +
Host
+

+A Host is an association of a network name, +e.g. www.yourcompany.com, to the Tomcat server. An Engine may contain +multiple hosts, and the Host element also supports network aliases such as +yourcompany.com and abc.yourcompany.com. Users rarely create custom +Hosts +because the +StandardHost +implementation provides significant additional functionality. +

+
+ +
Connector
+

+A Connector handles communications with the client. There are multiple +connectors available with Tomcat. These include the +HTTP connector which is used for +most HTTP traffic, especially when running Tomcat as a standalone server, +and the AJP connector which implements +the AJP protocol used when connecting Tomcat to a web server such as +Apache HTTPD server. Creating a customized connector is a significant +effort. +

+
+ +
Context
+

+A +Context +represents a web application. A Host may contain multiple +contexts, each with a unique path. The +Context +interface may be implemented to create custom Contexts, but +this is rarely the case because the + +StandardContext provides significant additional functionality. +

+
+
Comments
+

+Tomcat is designed to be a fast and efficient implementation of the +Servlet Specification. Tomcat came about as the reference implementation +of this specification, and has remained rigorous in adhering to the +specification. At the same time, significant attention has been paid +to Tomcat's performance and it is now on par with other servlet containers, +including commercial ones. +

+

+In recent releases of Tomcat, mostly starting with Tomcat 5, +we have begun efforts to make more aspects of Tomcat manageable via +JMX. In addition, the Manager and Admin webapps have been greatly +enhanced and improved. Manageability is a primary area of concern +for us as the product matures and the specification becomes more +stable. +

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess.html new file mode 100644 index 0000000..e3b2e3f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess.html @@ -0,0 +1,120 @@ +Apache Tomcat 7 Architecture (7.0.108) - Request Process Flow

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Request Process Flow

Request Process Flow
+ +

+This page describes the process used by Tomcat to handle +an incoming request. This process is largely defined by +the Servlet Specification, which outlines the order +of events that must take place. +

+ +
description
+

+TODO +

+
+ +
diagrams
+

+A UML sequence diagram of the request process is available +here. +

+

+A UML sequence diagram of the authentication process is available +here. +

+ +
+ +
comments
+

+The Servlet Specification provides many opportunities for +listening in (using Listeners) or modifying (using Filters) +the request handling process even before the request arrives +at the servlet that will handle it. +

+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess/authentication-process.png b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess/authentication-process.png new file mode 100644 index 0000000..e23c333 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess/authentication-process.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess/request-process.png b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess/request-process.png new file mode 100644 index 0000000..33ae3c3 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/requestProcess/request-process.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup.html new file mode 100644 index 0000000..7639547 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup.html @@ -0,0 +1,119 @@ +Apache Tomcat 7 Architecture (7.0.108) - Startup

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Contents

Startup

Server Startup
+ +

+This page describes how the Tomcat server starts up. There are several +different ways to start tomcat, including: +

+
    +
  • From the command line.
  • +
  • From a Java program as an embedded server.
  • +
  • Automatically as a Windows service.
  • +
+ +
description
+

+A text description of the startup procedure is available +here. +

+
+ +
diagram
+

+A UML sequence diagram of the startup procedure is available +here. +

+
+ +
comments
+

+The startup process can be customized in many ways, both +by modifying Tomcat code and by implementing your own +LifecycleListeners which are then registered in the server.xml +configuration file. +

+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup/serverStartup.pdf b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup/serverStartup.pdf new file mode 100644 index 0000000..34aa598 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup/serverStartup.pdf differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup/serverStartup.txt b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup/serverStartup.txt new file mode 100644 index 0000000..1904e82 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/architecture/startup/serverStartup.txt @@ -0,0 +1,139 @@ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +Tomcat Startup Sequence + +Sequence 1. Start from Command Line +Class: org.apache.catalina.startup.Bootstrap +What it does: + a) Set up classloaders + commonLoader (common)-> System Loader + sharedLoader (shared)-> commonLoader -> System Loader + catalinaLoader(server) -> commonLoader -> System Loader + (by default the commonLoader is used for the + sharedLoader and the serverLoader) + b) Load startup class (reflection) + org.apache.catalina.startup.Catalina + setParentClassloader -> sharedLoader + Thread.contextClassloader -> catalinaLoader + c) Bootstrap.daemon.init() complete + +Sequence 2. Process command line argument (start, stop) +Class: org.apache.catalina.startup.Bootstrap (assume command->start) +What it does: + a) Catalina.setAwait(true); + b) Catalina.load() + b1) initDirs() -> set properties like + catalina.home + catalina.base == catalina.home (most cases) + b2) initNaming + setProperty(javax.naming.Context.INITIAL_CONTEXT_FACTORY, + org.apache.naming.java.javaURLContextFactory ->default) + b3) createStartDigester() + Configures a digester for the main server.xml elements like + org.apache.catalina.core.StandardServer (can change of course :) + org.apache.catalina.deploy.NamingResources + Stores naming resources in the J2EE JNDI tree + org.apache.catalina.LifecycleListener + implements events for start/stop of major components + org.apache.catalina.core.StandardService + The single entry for a set of connectors, + so that a container can listen to multiple connectors + ie, single entry + org.apache.catalina.Connector + Connectors to listen for incoming requests only + It also adds the following rulesets to the digester + NamingRuleSet + EngineRuleSet + HostRuleSet + ContextRuleSet + b4) Load the server.xml and parse it using the digester + Parsing the server.xml using the digester is an automatic + XML-object mapping tool, that will create the objects defined in server.xml + Startup of the actual container has not started yet. + b5) Assigns System.out and System.err to the SystemLogHandler class + b6) Calls initialize on all components, this makes each object register itself with the + JMX agent. + During the process call the Connectors also initialize the adapters. + The adapters are the components that do the request pre-processing. + Typical adapters are HTTP1.1 (default if no protocol is specified, + org.apache.coyote.http11.Http11Protocol) + AJP1.3 for mod_jk etc. + + c) Catalina.start() + c1) Starts the NamingContext and binds all JNDI references into it + c2) Starts the services under which are: + StandardService -> starts Engine (ContainerBase -> Realm,Cluster etc) + c3) StandardHost (started by the service) + Configures an ErrorReportValve to do proper HTML output for different HTTP + errors codes + Starts the Valves in the pipeline (at least the ErrorReportValve) + Configures the StandardHostValve, + this valves ties the Webapp Class loader to the thread context + it also finds the session for the request + and invokes the context pipeline + Starts the HostConfig component + This component deploys all the webapps + (webapps & conf/Catalina/localhost/*.xml) + HostConfig will create a Digester for your context, this digester + will then invoke ContextConfig.start() + The ContextConfig.start() will process the default web.xml (conf/web.xml) + and then process the applications web.xml (WEB-INF/web.xml) + + c4) During the lifetime of the container (StandardEngine) there is a background thread that + keeps checking if the context has changed. If a context changes (timestamp of war file, + context xml file, web.xml) then a reload is issued (stop/remove/deploy/start) + + d) Tomcat receives a request on an HTTP port + d1) The request is received by a separate thread which is waiting in the ThreadPoolExecutor + class. It is waiting for a request in a regular ServerSocket.accept() method. + When a request is received, this thread wakes up. + d2) The ThreadPoolExecutor assigns the a TaskThread to handle the request. + It also supplies a JMX object name to the catalina container (not used I believe) + d3) The processor to handle the request in this case is Coyote Http11Processor, + and the process method is invoked. + This same processor is also continuing to check the input stream of the socket + until the keep alive point is reached or the connection is disconnected. + d4) The HTTP request is parsed using an internal buffer class (Http11InputBuffer) + The buffer class parses the request line, the headers, etc and store the result in a + Coyote request (not an HTTP request) This request contains all the HTTP info, such + as servername, port, scheme, etc. + d5) The processor contains a reference to an Adapter, in this case it is the + CoyoteAdapter. Once the request has been parsed, the Http11Processor + invokes service() on the adapter. In the service method, the Request contains a + CoyoteRequest and CoyoteResponse (null for the first time) + The CoyoteRequest(Response) implements HttpRequest(Response) and HttpServletRequest(Response) + The adapter parses and associates everything with the request, cookies, the context through a + Mapper, etc + d6) When the parsing is finished, the CoyoteAdapter invokes its container (StandardEngine) + and invokes the invoke(request,response) method. + This initiates the HTTP request into the Catalina container starting at the engine level + d7) The StandardEngine.invoke() simply invokes the container pipeline.invoke() + d8) By default the engine only has one valve the StandardEngineValve, this valve simply + invokes the invoke() method on the Host pipeline (StandardHost.getPipeLine()) + d9) the StandardHost has two valves by default, the StandardHostValve and the ErrorReportValve + d10) The standard host valve associates the correct class loader with the current thread + It also retrieves the Manager and the session associated with the request (if there is one) + If there is a session access() is called to keep the session alive + d11) After that the StandardHostValve invokes the pipeline on the context associated + with the request. + d12) The first valve that gets invoked by the Context pipeline is the FormAuthenticator + valve. Then the StandardContextValve gets invoke. + The StandardContextValve invokes any context listeners associated with the context. + Next it invokes the pipeline on the Wrapper component (StandardWrapperValve) + d13) During the invocation of the StandardWrapperValve, the JSP wrapper (Jasper) gets invoked + This results in the actual compilation of the JSP. + And then invokes the actual servlet. + e) Invocation of the servlet class diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/balancer-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/balancer-howto.html new file mode 100644 index 0000000..1c00f74 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/balancer-howto.html @@ -0,0 +1,96 @@ +Apache Tomcat 7 (7.0.108) - Load Balancer HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Load Balancer HOW-TO

Table of Contents
+ +
Using the JK 1.2.x native connector
+ +Please refer to the JK 1.2.x documentation. + +
Using Apache HTTP Server 2.x with mod_proxy
+ +Please refer to the mod_proxy documentation for Apache HTTP Server 2.2. This supports either +HTTP or AJP load balancing. This new version of mod_proxy is also usable with +Apache HTTP Server 2.0, but mod_proxy will have to be compiled separately using the code +from Apache HTTP Server 2.2. + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/building.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/building.html new file mode 100644 index 0000000..585d5b5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/building.html @@ -0,0 +1,351 @@ +Apache Tomcat 7 (7.0.108) - Building Tomcat

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Building Tomcat

Table of Contents
+ +
Introduction
+ +

+Building Apache Tomcat from source is very easy, and is the first step to +contributing to Tomcat. The complete and comprehensive instructions are +provided in the file BUILDING.txt. +The following is a quick step by step guide. +

+ +
Download Java Development Kit (JDK) versions 6 and 7
+ +

+ Building Apache Tomcat requires a Java 6 JDK to be installed and optionally + a Java 7 JDK installed in parallel with Java 6 one. The Java 7 JDK is only + required if you wish to build Tomcat with JSR-356 (Java WebSocket 1.1) + support. +

+ +

+ You can download JDKs from Oracle
+ http://www.oracle.com/technetwork/java/javase/downloads/index.html
+ or from another JDK vendor. +

+ +

+ IMPORTANT: Set an environment variable JAVA_HOME to the pathname of + the directory into which you installed the Java 6 JDK. The path to Java 7 + JDK is configured in build.properties file (see below). +

+ +
Install Apache Ant 1.9.1 or later
+ +

+Download a binary distribution of Ant 1.9.1 or later from +here. +

+ +

+Unpack the binary distribution into a convenient location so that the +Ant release resides in its own directory (conventionally named +apache-ant-1.8.x). For the remainder of this guide, +the symbolic name ${ant.home} is used to refer to the full pathname of + the Ant installation directory. +

+ +

+IMPORTANT: Create an ANT_HOME environment variable to point the directory ${ant.home}, +and modify the PATH environment variable to include directory +${ant.home}/bin in its list. This makes the ant command line script +available, which will be used to actually perform the build. +

+ +
Checkout or obtain the source code for Tomcat 7.0
+ +

+ Tomcat 7.0 SVN repository URL: + https://svn.apache.org/repos/asf/tomcat/tc7.0.x/trunk/ +

+

+ Tomcat source packages: + https://tomcat.apache.org/download-70.cgi. +

+ +

+ Checkout the source using SVN, selecting a tag for released version or + trunk for the current development code, or download and unpack a + source package. For the remainder of this guide, the symbolic name + ${tomcat.source} is used to refer to the + location where the source has been placed. +

+ +
Configure download area
+ +

+ Building Tomcat involves downloading a number of libraries that it depends on. + It is strongly recommended to configure download area for those libraries. +

+ +

+ By default the build is configured to download the dependencies into the + ${user.home}/tomcat-build-libs directory. You can change this + (see below) but it must be an absolute path. +

+ +

+ The build is controlled by creating a + ${tomcat.source}/build.properties file. It can be used to + redefine any property that is present in build.properties.default + and build.xml files. The build.properties file + does not exist by default. You have to create it. +

+ +

+ The download area is defined by property base.path. For example: +

+ +
# ----- Default Base Path for Dependent Packages -----
+# Replace this path with the directory path where
+# dependencies binaries should be downloaded.
+base.path=/home/me/some-place-to-download-to
+ +

+ Different versions of Tomcat are allowed to share the same download area. +

+ +

+ Another example: +

+ +
base.path=${user.dir}/../libraries-tomcat7.0
+ +

+ Users who access the Internet through a proxy must use the properties + file to indicate to Ant the proxy configuration: +

+ +
# ----- Proxy setup -----
+proxy.host=proxy.domain
+proxy.port=8080
+proxy.use=on
+ +
Building Tomcat
+ +

+ If you have installed a Java 7 JDK and wish to build Tomcat with JSR-356 + (Java WebSocket 1.1) support, set java.7.home property in + file ${tomcat.source}/build.properties to the location of + the Java 7 JDK installation. +

+ +

+ An example, using 32-bit JDK on a 64-bit Windows system: +

+ +
# Location of Java 7 JDK
+java.7.home=C:/Program Files (x86)/Java/jdk1.7.0_72
+ +

+Use the following commands to build Tomcat: +

+ +

+cd ${tomcat.source}
+ant +

+ +

+Once the build has completed successfully, a usable Tomcat installation will have been +produced in the ${tomcat.source}/output/build directory, and can be started +and stopped with the usual scripts. +

+
Building with Eclipse
+ +

+IMPORTANT: This is not a supported means of building Tomcat; this information is +provided without warranty :-). +The only supported means of building Tomcat is with the Ant build described above. +However, some developers like to work on Java code with a Java IDE, +and the following steps have been used by some developers. +

+ +

+NOTE: This will not let you build everything under Eclipse; +the build process requires use of Ant for the many stages that aren't +simple Java compilations. +However, it will allow you to view and edit the Java code, +get warnings, reformat code, perform refactorings, run Tomcat +under the IDE, and so on. +

+ +

+WARNING: Do not forget to create and configure + ${tomcat.source}/build.properties file as described above + before running any Ant targets. +

+ +

+Sample Eclipse project files and launch targets are provided in the +res/ide-support/eclipse directory of the source tree. +The instructions below will automatically copy these into the required locations. +

+

+Two Ant targets are provided as a convenience. The first one, named +ide-eclipse, downloads all binary dependencies and configures +Eclipse project in the root of the source tree. The created Eclipse project +targets a Java 6 JDK and skips WebSocket classes that cannot be compiled with +Java 6. +

+ +

+The second target, named ide-eclipse-websocket, creates directory +../tomcat-7.0.x-java7 and configures the second Eclipse project +there. This project targets a Java 7 JDK. This project does not have its own +source tree, but accesses a subset of the source tree of the first project, +compiling all WebSocket classes that were skipped. +

+ +

+cd ${tomcat.source}
+ant ide-eclipse
+ant ide-eclipse-websocket +

+ +

+Start Eclipse and create a new Workspace. +

+ +

+Open the Preferences dialog and then select Java->Build Path->Classpath +Variables to add two new Classpath Variables: +

+ + + + + +
TOMCAT_LIBS_BASEThe same location as the base.path + setting in build.properties, where the binary dependencies have been downloaded
ANT_HOMEthe base path of Ant 1.9.1 or later
+ +

+In the Preferences dialog go to Java->Installed JREs +and add JDK 6 and JDK 7 there. Close the dialog. +

+ +

+Use File->Import command from menu and choose Existing Projects into Workspace. +From there choose the root directory of the Tomcat source tree (${tomcat.source}) +and import the project located there. Import the second project as well, +if you have created it (../tomcat-7.0.x-java7). +

+ +

+start-tomcat and stop-tomcat launch configurations are provided in +res/ide-support/eclipse and will be available in the Run->Run Configurations +dialog. Use these to start and stop Tomcat from Eclipse. +If you want to configure these yourself (or are using a different IDE) +then use org.apache.catalina.startup.Bootstrap as the main class, +start/stop etc. as program arguments, and specify -Dcatalina.home=... +(with the name of your build directory) as VM arguments. +

+ +

+Tweaking a few formatting preferences will make it much easier to keep consistent with Tomcat +coding conventions (and have your contributions accepted): +

+ + + + + + + + +
Java -> Code Style -> Formatter -> Edit...Tab policy: Spaces only
Tab and Indentation size: 4
General -> Editors -> Text EditorsDisplayed tab width: 2
Insert spaces for tabs
Show whitespace characters (optional)
XML -> XML Files -> EditorIndent using spaces
Indentation size: 2
Ant -> Editor -> FormatterTab size: 2
Use tab character instead of spaces: unchecked
+ +

+The recommended configuration of Compiler Warnings is documented in +res/ide-support/eclipse/java-compiler-errors-warnings.txt file. +

+ +
Building with other IDEs
+

+The same general approach should work for most IDEs; it has been reported +to work in IntelliJ IDEA, for example. +

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/cgi-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/cgi-howto.html new file mode 100644 index 0000000..96e1d01 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/cgi-howto.html @@ -0,0 +1,210 @@ +Apache Tomcat 7 (7.0.108) - CGI How To

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

CGI How To

Table of Contents
+ +
Introduction
+ +

The CGI (Common Gateway Interface) defines a way for a web server to +interact with external content-generating programs, which are often +referred to as CGI programs or CGI scripts. +

+ +

Within Tomcat, CGI support can be added when you are using Tomcat as your +HTTP server and require CGI support. Typically this is done +during development when you don't want to run a web server like +Apache httpd. +Tomcat's CGI support is largely compatible with Apache httpd's, +but there are some limitations (e.g., only one cgi-bin directory). +

+ +

CGI support is implemented using the servlet class +org.apache.catalina.servlets.CGIServlet. Traditionally, +this servlet is mapped to the URL pattern "/cgi-bin/*".

+ +

By default CGI support is disabled in Tomcat.

+
Installation
+ +

CAUTION - CGI scripts are used to execute programs +external to the Tomcat JVM. If you are using the Java SecurityManager this +will bypass your security policy configuration in catalina.policy.

+ +

To enable CGI support:

+ +
    +
  1. There are commented-out sample servlet and servlet-mapping elements for +CGI servlet in the default $CATALINA_BASE/conf/web.xml file. +To enable CGI support in your web application, copy that servlet and +servlet-mapping declarations into WEB-INF/web.xml file of your +web application.

    + +

    Uncommenting the servlet and servlet-mapping in +$CATALINA_BASE/conf/web.xml file enables CGI for all installed +web applications at once.

    +
  2. + +
  3. Set privileged="true" on the Context element for your +web application.

    + +

    Only Contexts which are marked as privileged are allowed to use the +CGI servlet. Note that modifying the global $CATALINA_BASE/conf/context.xml +file affects all web applications. See +Context documentation for details.

    +
  4. +
+ +
Configuration
+ +

There are several servlet init parameters which can be used to +configure the behaviour of the CGI servlet.

+
    +
  • cgiMethods - Comma separated list of HTTP methods. Requests +using one of these methods will be passed to the CGI script for the script to +generate the response. The default value is GET,POST. Use +* for the script to handle all requests regardless of method. +Unless over-ridden by the configuration of this parameter, requests using HEAD, +OPTIONS or TRACE will have handled by the superclass.
  • +
  • cgiPathPrefix - The CGI search path will start at +the web application root directory + File.separator + this prefix. +By default there is no value, which results in the web application root +directory being used as the search path. The recommended value is +WEB-INF/cgi
  • +
  • cmdLineArgumentsDecoded - If command line arguments +are enabled (via enableCmdLineArguments) and Tomcat is running +on Windows then each individual decoded command line argument must match this +pattern else the request will be rejected. This is to protect against known +issues passing command line arguments from Java to Windows. These issues can +lead to remote code execution. For more information on these issues see +Markus +Wulftange's blog and this archived +blog +by Daniel Colascione.
  • +
  • cmdLineArgumentsEncoded - If command line arguments +are enabled (via enableCmdLineArguments) individual encoded +command line argument must match this pattern else the request will be rejected. +The default matches the allowed values defined by RFC3875 and is +[a-zA-Z0-9\Q%;/?:@&,$-_.!~*'()\E]+
  • +
  • enableCmdLineArguments - Are command line arguments +generated from the query string as per section 4.4 of 3875 RFC? The default is +false.
  • +
  • environment-variable- - An environment to be set for the +execution environment of the CGI script. The name of variable is taken from the +parameter name. To configure an environment variable named FOO, configure a +parameter named environment-variable-FOO. The parameter value is used as the +environment variable value. The default is no environment variables.
  • +
  • executable - The name of the executable to be used to +run the script. You may explicitly set this parameter to be an empty string +if your script is itself executable (e.g. an exe file). Default is +perl.
  • +
  • executable-arg-1, executable-arg-2, +and so on - additional arguments for the executable. These precede the +CGI script name. By default there are no additional arguments.
  • +
  • envHttpHeaders - A regular expression used to select the +HTTP headers passed to the CGI process as environment variables. Note that +headers are converted to upper case before matching and that the entire header +name must match the pattern. Default is +ACCEPT[-0-9A-Z]*|CACHE-CONTROL|COOKIE|HOST|IF-[-0-9A-Z]*|REFERER|USER-AGENT +
  • +
  • parameterEncoding - Name of the parameter encoding +to be used with the CGI servlet. Default is +System.getProperty("file.encoding","UTF-8"). That is the system +default encoding, or UTF-8 if that system property is not available.
  • +
  • passShellEnvironment - Should the shell environment +variables from Tomcat process (if any) be passed to the CGI script? Default is +false.
  • +
  • stderrTimeout - The time (in milliseconds) to wait for +the reading of stderr to complete before terminating the CGI process. Default +is 2000.
  • +
+ +

The CGI script executed depends on the configuration of the CGI Servlet and +how the request is mapped to the CGI Servlet. The CGI search path starts at the +web application root directory + File.separator + cgiPathPrefix. The +pathInfo is then searched unless it is null - in +which case the servletPath is searched.

+ +

The search starts with the first path segment and expands one path segment +at a time until no path segments are left (resulting in a 404) or a script is +found. Any remaining path segments are passed to the script in the +PATH_INFO environment variable.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/changelog.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/changelog.html new file mode 100644 index 0000000..9f900b0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/changelog.html @@ -0,0 +1,17161 @@ +Apache Tomcat 7 (7.0.108) - Changelog

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Changelog

Tomcat 7.0.108 (violetagg)
+
Catalina
+ + + + + +
fix + 56181: Update the RemoteIpValve and RemoteIpFilter so that + calls to ServletRequest.getRemoteHost() are consistent with + the return value of ServletRequest.getRemoteAddr() rather + than always returning a value for the proxy. (markt) +
fix + Ensure that values are not duplicated when manipulating the vary header. + Based on a pull request by Fredrik Fall. (markt) +
fix + Avoid uncaught InaccessibleObjectException on Java 16 trying to clear + references threads. (remm) +
fix + 65047: If the AccessLogValve is unable to open + the access log file, include information on the current user in the + associated log message (markt) +
+
+
Jasper
+ + +
fix + 64965: JspContextWrapper.findAttribute should + ignore expired sessions rather than throw an + IllegalStateException. (remm) +
+
+
WebSocket
+ + +
fix + 64951: Fix a potential file descriptor leak when WebSocket + connections are attempted and fail. Patch provided by Maurizio Adami. + (markt) +
+
+
Web applications
+ + + + +
fix + Correct a regression in the addition of the HTTP header security filter + to the examples web application that prevented the Servlet examples that + depend on the asynchronous API from functioning correctly. + (kkolinko/markt) +
fix + 65007: Clarify that the commands shown in the TLS + documentation for importing a signed TLS certificate from a certificate + authority are typical examples that may need to be adjusted in some + cases. (markt) +
code + Test for one directory being a sub-directory of another in a consistent + way. (markt) +
+
+
Other
+ + + + + + + + + + + + +
add + 64931: Implement validation of changelog.xml + file at build time. (kkolinko) +
update + Update to Maven Ant Resolver Tasks 1.3.0. (markt) +
fix + 62695: Provide SHA-256 and SHA-512 checksums for files + published via Maven. (markt) +
add + Improvements to Chinese translations. Provided by leeyazhou. (markt) +
add + Improvements to French translations. (remm) +
add + Improvements to Korean translations. (woonsan) +
update + Update the packaged version of the Tomcat Native Library to 1.2.26. + (markt) +
update + Migrate to new code signing service. (markt) +
update + Update to Commons Daemon 1.2.4. (markt) +
add + Improvements to Russian translations. Provided by Polina and Azat. + (markt) +
update + Update the NSIS Installer used to build the Windows installer to version + 3.06.1. (kkolinko) +
+
+
Tomcat 7.0.107 (violetagg)released 2020-11-23
+
Catalina
+ + + + + + + +
fix + Correct numerous spellings throughout the code base. Based on a pull + request from John Bampton. (markt) +
fix + 64735: Ensure that none of the methods on a + ServletContext instance always fail when running under a + SecurityManager. Pull request provided by Kyle Stiemann. (markt) +
fix + 64765: Ensure that the number of currently processing threads + is tracked correctly when a web application is undeployed, long running + requests are being processed and + renewThreadsWhenStoppingContext is enabled for the web + application. (markt) +
add + Improve the error messages when running under JPMS without the necessary + options to enable reflection required by the memory leak prevention / + detection code. (markt) +
fix + 64805: Correct imports used by JMXProxyServlet. + (markt) +
add + 64871: Log a warning if Tomcat blocks access to a file + because it uses symlinks. (markt) +
+
+
Coyote
+ + + + +
fix + Fix processing of URIs with %nn encoded solidus characters when + encodedSolidusHandling was set to passthrough + and the encoded solidus was preceded by other %nn encoded characters. + Based on a pull request by willmeck. (markt) +
fix + 55160: Re-fix this bug after the original fix was reverted by + a separate fix to timeouts in 7.0.81. (markt) +
add + Add additional debug logging for I/O issues when communicating with the + user agent. (markt) +
+
+
Web applications
+ + + + +
fix + Update the Manager How-To in the documentation web application to + clarify when a user may wish to deploy additional instances of the + Manager web application. (markt) +
fix + 64797: Align manager.xml template file in Host-Manager with + context.xml of real Manager web application. (isapir) +
add + Configure the examples, Manager and Host Manager to use the HTTP header + security filter with default settings apart from no HSTS header. Based + on a suggestion by Debangshu Kundu. (markt) +
+
+
Other
+ + + + + + + + + + + + +
add + When building, only rebuild JAR files if the contents has changed. + (markt) +
add + Improvements to Chinese translations. Pull request provided by Yang + Yang. (markt) +
add + Expand coverage of Russian translations. Pull request provided by + Nikolay Gribanov. (markt) +
update + Updated to Ant 1.9.1. The build now requires a minimum of Ant 1.9.1. + (markt) +
fix + Fix running service.bat when called from $CATALINA_HOME. + (markt) +
fix + Complete the fix for 63815. Users wishing to use system + properties that require quoting with catalina.sh and the + debug option must use a JRE that includes the fix for JDK-8234808. + (markt) +
add + Improvements to Chinese translations. Provided by leeyazhou. (markt) +
add + Improvements to French translations. (remm) +
add + Improvements to Korean translations. (woonsan) +
add + Improvements to Spanish translations. Provided by Andrewlanecarr. + (markt) +
add + Improvements to Russian translations. Provided by Azat. (markt) +
+
+
Tomcat 7.0.106 (violetagg)released 2020-09-20
+
Catalina
+ + + + + +
fix + 64582: Pre-load the CoyoteOutputStream class to + prevent a potential exception when running under a security manager. + Patch provided by Johnathan Gilday. (markt) +
add + Refactor the Default servlet to provide a single method that can be + overridden (generateETag()) should a custom entity tag + format be required. (markt) +
fix + Improve the validation of entity tags provided with conditional + requests. Requests with headers that contain invalid entity tags will be + rejected with a 400 response code. Improve the matching algorithm used + to compare entity tags in conditional requests with the entity tag for + the requested resource. Based on a pull request by Sergey Ponomarev. + (markt) +
update + Deprecate the JDBCRealm. (markt) +
+
+
Coyote
+ + + +
fix + Refactor the implementation of + ServletInputStream.available() to provide a more accurate + return value, particularly when end of stream has been reached. (markt) +
fix + Fix a rare potential race condition when checking for timeouts with the + APR connector. (markt) +
+
+
WebSocket
+ + + +
fix + Requests received via proxies may be marked as using the ws + or wss protocol rather than http or + https. Ensure that such requests are not rejected. PR + provided by Ronny Perinke. (markt) +
add + 64644: Add support for a read idle timeout and a write idle + timeout to the WebSocket session via custom properties in the user + properties instance associated with the session. Based on a pull request + by sakshamverma. (markt) +
+
+
Web applications
+ + + +
fix + Remove the localization of the text output of the Manager application + list of contexts and the Host Manager application list of hosts so that + the output is more consistent. PR provided by Holomark. (markt) +
fix + Remove the out of date functional specification section from the + documentation web application. (markt) +
+
+
Other
+ + + + + + + + +
add + Improve the quality of the Japanese translations provided with Apache + Tomcat. Includes contributions from Yuki Shira. (markt) +
fix + 64645: Use a non-zero exit code if the + service.bat does not complete normally. (markt) +
add + Update the internal fork of Apache Commons BCEL to 6.5.0. Code clean-up + only. (markt) +
add + Update the internal fork of Apache Commons Codec to 53c93d0 (2020-08-18, + 1.15-SNAPSHOT). Code clean-up. (markt) +
add + Update the internal fork of Apache Commons FileUpload to c25a4e3 + (2020-08-26, 2.0-SNAPSHOT). Code clean-up and RFC 2231 support. (markt) +
update + Update to Commons Daemon 1.2.3. This adds support to jsvc for + --enable-preview and native memory tracking (Procrun + already supported these features), adds some addition debug logging and + adds a new feature to Procrun that outputs the command to (re-)configure + the service with the current settings. (markt) +
update + Update the packaged version of the Tomcat Native Library to 1.2.25. + (markt) +
+
+
Tomcat 7.0.105 (violetagg)released 2020-07-07
+
Catalina
+ + + + +
fix + 64470: The default value of the solidus handling should + reflect the associated system property. (remm) +
add + Add application/wasm to the media types recognised by + Tomcat. Based on a PR by Thiago Henrique Hüpner. (markt) +
fix + 64541: Refactor the DTD used to validate + mbeans-descriptors.xml files to avoid issues when XML + entity expansion is limited or disabled. (markt) +
+
+
Coyote
+ + +
add + 64483: Log a warning if an AJP request is rejected because it + contains an unexpected request attribute. (markt) +
+
+
Cluster
+ + +
fix + 64560: Refactor the replication of a changed session ID for a + replicated session so that the list of changes associated with the + session is not reset when the session ID changes. (markt) +
+
+
WebSocket
+ + + + + +
fix + Consistently throw a DeploymentException when an invalid + endpoint path is specified and catch invalid endpoint paths earlier. + (markt) +
add + Include the target URL in the log message when a WebSocket connection + fails. (markt) +
fix + 64563: Add additional validation of payload length for + WebSocket messages. (markt) +
fix + Correct the calculation of payload length when four or more bytes are + required to represent the payload length. (markt) +
+
+
Other
+ + + + + + + + + +
fix + Use Apache archives when downloading commons-logging dependency. (violetagg) +
update + Update the list of known Charsets in the + CharsetCache to include ISO-8859-16, added in + OpenJDK 15. (markt) +
add + Improve the quality and expand the coverage of the French translations + provided with Apache Tomcat. (remm) +
add + 64430: Add support for the CATALINA_OUT_CMD + environment variable that defines a command to which captured stdout and + stderr will be redirected. Patch provided by Harald Dunkel. (markt) +
update + Switch from the unsupported Maven Ant Tasks to the supported Maven + Resolver Ant Tasks to upload artifacts to the ASF Maven repository (and + from there to Maven Central). (markt) +
fix + 64501: Refactor the handling of the deprecated + LOGGING_CONFIG environment variable to avoid using a POSIX + shell feature that is not available by default on Solaris 10. (markt) +
fix + 64521: Avoid moving i18n translations into classes dir since + they are packaged into separate jars. Pull request provided by Raymond + Augé. (markt) +
add + Improve the quality and expand the coverage of the French translations + provided with Apache Tomcat. (remm) +
+
+
Tomcat 7.0.104 (violetagg)released 2020-05-16
+
Catalina
+ + + + + + + + + + + + +
add + 45995, 64237: Align Tomcat with Apache httpd and + perform MIME type mapping based on file extension in a case insensitive + manner. (markt) +
add + 59203: Before calling Thread.stop() (if + configured to do so) on a web application created thread that is not + stopped by the web application when the web application is stopped, try + interrupting the thread first. Based on a pull request by Govinda + Sakhare. (markt) +
fix + 64226: Reset timezone after parsing a date since the date + format is reused. Test case submitted by Gary Thomas. (remm) +
fix + 64265: Fix ETag comparison performed by the default servlet. + The default servlet always uses weak comparison. (markt) +
fix + Add support for default values when using ${...} property + replacement in configuration files. Based on a pull request provided by + Bernd Bohmann. (markt) +
fix + Rework the fix for 64021 to better support web applications + that use a custom class loader that loads resources from non-standard + locations. (markt) +
update + Remove redundant sole path/URI from error page message on SC_NOT_FOUND. + (michaelo) +
add + Add more descriptive error message in DefaultServlet for SC_NOT_FOUND. + (michaelo) +
add + 64386: WebdavServlet does not send "getlastmodified" + property for resource collections. (michaelo) +
fix + 64398: Change default value separator for property + replacement to :- due to possible conflicts. The + syntax is now ${name:-default}. (remm) +
add + Improve validation of storage location when using FileStore. (markt) +
+
+
Coyote
+ + + + + +
add + When configuring an HTTP Connector, warn if the encoding specified for + URIEncoding is not a superset of US-ASCII as required by + RFC7230. (markt) +
fix + 64240: Ensure that HTTP/0.9 requests that contain additional + data on the request line after the URI are treated consistently. Such + requests will now always be treated as HTTP/1.1. (markt) +
add + Replace the system property + org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH + with the Connector attribute encodedSolidusHandling that + adds an additional option to pass the %2f sequence through + to the application without decoding it in addition to rejecting such + sequences and decoding such sequences. (markt) +
fix + Include the problematic data in the error message when reporting that + the provided request line contains an invalid component. (markt) +
+
+
Jasper
+ + + + + +
add + Add support for specifying Java 14 (with the value 14) and + Java 15 (with the value 15) as the compiler source and/or + compiler target for JSP compilation. If used with an ECJ version that + does not support these values, a warning will be logged and the latest + supported version will used. (markt) +
update + Remove redundant sole path/URI from error page message on SC_NOT_FOUND. + (michaelo) +
add + Add more descriptive error message in DefaultServlet for SC_NOT_FOUND. + (michaelo) +
fix + Ensure that the Jasper code that interfaces with the Eclipse Compiler + for Java (ECJ) enables Jasper to compile JSPs using ECJ 4.14 onwards + when the JSPs have inner classes. (markt) +
+
+
Cluster
+ + +
code + Refactor the creation of DeltaRequest objects to make it + simpler to use custom implementations. Based on a pull request provided + by Thomas Stock. (markt) +
+
+
Web applications
+ + + +
fix + Correct the documentation web application to remove references to the + org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH + system property changing how the sequence %5c is + interpreted in a URI. (markt) +
add + Add a section to the TLS Connector documentation on different key store + types and how to configure them. (markt) +
+
+
Other
+ + + + + + + + + + + + + +
add + Improve the quality and expand the coverage of the French translations + provided with Apache Tomcat. Contribution provided by Tom Bens. (remm) +
add + Expand the coverage of the Chinese translations provided with Apache + Tomcat. Contribution provided by Lee Yazhou. (markt) +
fix + 64270: Set the documented default umask of 0027 + when using jsvc via daemon.sh and allow the umask used to + be configured via the UMASK environment variable as it is + when using catalina.sh. (markt) +
fix + Deprecated the LOGGING_CONFIG environment variable and + replace it with the CATALINA_LOGGING_CONFIG environment + variable to avoid clashes with other components that use + LOGGING_CONFIG. (markt) +
update + Update JUnit to version 4.13. (markt) +
code + Refactor to use parameterized Collection constructors where + possible. Pull request provided by Lars Grefer. (markt) +
code + Refactor to use empty arrays with Collections.toArray(). + Pull request provided by Lars Grefer. (markt) +
code + Refactor loops with a condition to exit as soon as the condition is met. + Pull request provided by Lars Grefer. (markt) +
code + Refactor bulk addition to collections to use addAll() + rather than a loop. Pull request provided by Lars Grefer. (markt) +
update + Update the packaged version of the Tomcat Native Library to 1.2.24. + (markt) +
code + Refactor to use enhanced for loops where possible. Pull request by Lars + Grefer. (markt) +
add + Improve IDE support for IntelliJ IDEA. Patch provided by Lars Grefer. + (markt) +
+
+
Tomcat 7.0.103 (violetagg)released 2020-03-19
+
Catalina
+ + +
fix + 64191: Make an additional fix for the SCI regression + introduced by the fix for 64021 for the case, such as when + embedding, when the class loader performing the SCI service lookup is not + the Tomcat web application class loader. (markt) +
+
+
Tomcat 7.0.102 (violetagg)not released
+
Coyote
+ + +
fix + 64210: Correct a regression in the improvements to HTTP + header validation that caused requests to be incorrectly treated as + invalid if a CRLF sequence was split between TCP packets. + Improve validation of request lines, including for HTTP/0.9 requests. + (markt) +
+
+
Tomcat 7.0.101 (violetagg)not released
+
Catalina
+ + + + + + + + + +
fix + Switch Tomcat embedded to loading MIME type mappings from a property + file generated from the default web.xml so the MIME type + mappings are consistent regardless of how Tomcat is started. (markt) +
fix + Ensure that the HEAD response is consistent with the GET response when + HttpServlet is relied upon to generate the HEAD response + and the GET response uses chunking. (markt) +
fix + 64153: Ensure that the parent for the web application class + loader is set consistently. (markt) +
fix + 64166: Ensure that the names returned by + HttpServletResponse.getHeaderNames() are unique. (markt) +
add + 64189: Expose the web application version String as a + ServletContext attribute named + org.apache.catalina.webappVersion. (markt) +
fix + 64191: Fix an SCI support regression that was caused by a JAR + path lookup error in the classloader findResources. (remm) +
code + Rename org.apache.tomcat.util.digester.Digester$EnvironmentPropertySource + to + org.apache.tomcat.util.digester.EnvironmentPropertySource. + The old class is still available but deprecated. Patch provided by Bernd + Bohmann. (markt) +
add + Add new attribute persistAuthentication to both + StandardManager and PersistentManager to + support authentication persistence. Patch provided by Carsten Klein. + (markt) +
+
+
Coyote
+ + + + +
fix + Add the TLS request attributes used by IIS to the attributes that an AJP + Connector will always accept. (markt) +
fix + A zero length AJP secret will now behave as if it has not been + specified. (remm) +
fix + Allow async requests to complete cleanly when the Connector is paused + before complete() is called on a container thread. (markt) +
+
+
Web applications
+ + +
add + Expand the documentation for the address attribute of the + AJP Connector. (markt) +
+
+
Other
+ + + + + +
add + Expand the coverage of the French translations provided with Apache + Tomcat. (remm) +
add + Expand the coverage of the Korean translations provided with Apache + Tomcat. Contributions provided by B. Cansmile Cha. (markt) +
add + 64190: Add support for specifying milliseconds (using + S, SS or SSS) in the timestamp + used by JULI's OneLineFormatter. (markt) +
fix + 64206: Correct a regression introduced in 7.0.100 that meant + that the HTTP port specified when using the Windows Installer was + ignored and 8080 was always used. (markt) +
+
+
Tomcat 7.0.100 (violetagg)released 2020-02-14
+
Catalina
+ + + + + + + + + + + + + + +
fix + Avoid useless environment restore when not using GSSCredential + in JNDIRealm. (remm) +
fix + 58577: Respect the argument-count when searching for MBean + operations to invoke via the JMXProxyServlet. (schultz) +
add + 62755: Add ability to opt out of adding the default web.xml + config when embedding Tomcat and adding a context via + addWebapp(). Call + setAddDefaultWebXmlToWebapp(false) to prevent the automatic + config. (isapir/markt) +
fix + 64008: Clarify/expand the Javadoc for the + Tomcat#addWebapp() and related methods. (markt) +
code + Deprecate the JmxRemoteLifecycleListener as the features it + provides are now available in the remote JMX capability included with + the JRE. This listener will be removed in Tomcat 10 and may be removed + from Tomcat 7.0.x some time after 2020-12-31. (markt) +
fix + 64011: JNDIRealm no longer authenticates to LDAP. + (michaelo) +
fix + 64021: Ensure that container provided SCIs are always loaded + before application provided SCIs. Note that where both the container and + the application provide the same SCI, it is the application provided SCI + that will be used. (markt) +
fix + SCI definitions from JARs unpacked into WEB-INF/classes are + now handled consistently and will always be found irrespective of + whether the web application defines a JAR ordering or not. (markt) +
fix + 64023: Skip null-valued session attributes when deserializing + sessions. (schultz) +
fix + Do not throw a NullPointerException when an MBean or operation cannot + be found by the JMXProxyServlet. (schultz) +
update + Refactor recycle facade system property into a new connector attribute + named discardFacades. (remm) +
fix + 64089: Add ${...} property replacement support + to XML external entity definitions. (markt) +
code + Deprecate MappingData.contextPath as it is unused. (markt) +
+
+
Coyote
+ + + + + + + + +
add + When reporting / logging invalid HTTP headers encode any non-printing + characters using the 0xNN form. (markt) +
fix + Correct a regression introduced in 7.0.98 that meant invalid tokens in + the Transfer-Encoding header were ignored rather than + treated as an error. (markt) +
fix + Rename the HTTP Connector attribute rejectIllegalHeaderName + to rejectIllegalHeader and expand the underlying + implementation to include header values as well as names. (markt) +
update + Disable (comment out in server.xml) the AJP/1.3 connector by default. + (markt) +
update + Change the default bind address for the AJP/1.3 connector to be the + loopback address. (markt) +
add + Rename the requiredSecret attribute of the AJP/1.3 + Connector to secret and add a new attribute + secretRequired that defaults to true. When + secretRequired is true the AJP/1.3 Connector + will not start unless the secret attribute is configured to + a non-null, non-zero length String. (markt) +
add + Add a new attribute, allowedRequestAttributesPattern to + the AJP/1.3 Connector. Requests with unrecognised attributes will be + blocked with a 403. (markt) +
+
+
Jasper
+ + + + +
fix + 64097: Replace the faulty custom services lookup used for + ExpressionFactory implementations with + ServiceLoader. (markt) +
add + Add a META-INF/services entry to jasper-el.jar so that the + Expression Language implementation can be discovered via the services + API. (markt) +
code + Parameterize JSP version and API class names in localization messages to + allow simpler re-use between major versions. (markt) +
+
+
Cluster
+ + +
fix + 64043: Ensure that session ID changes are replicated during + form-authentication. (kfujino) +
+
+
Web applications
+ + +
fix + 64000: In the examples web application, where a Servlet + example includes i18n support, the Locale used should be based on the + request locale and not the server locale. (markt) +
+
+
Tribes
+ + +
add + Add EncryptInterceptor to the portfolio of available clustering + interceptors. This adds symmetric encryption of session data + to Tomcat clustering regardless of the type of cluster manager + or membership being used. (schultz/markt) +
+
+
Other
+ + + +
add + Expand the coverage of the French translations provided with Apache + Tomcat. (remm) +
add + Expand the coverage of the Chinese translations provided with Apache + Tomcat. Contribution provided by BoltzmannWxd. (markt) +
+
+
Tomcat 7.0.99 (violetagg)released 2019-12-17
+
Catalina
+ + + + + + + + + +
add + 63681: Introduce RealmBase#authenticate(GSSName, GSSCredential) + and friends. (michaelo) +
add + 63937: Add a new attribute to the standard + Authenticator implementations, + allowCorsPreflight, that allows the + Authenticators to be configured to allow CORS preflight + requests to bypass authentication as required by the CORS specification. + (markt) +
fix + 63939: Correct the same origin check in the CORS filter. An + origin with an explicit default port is now considered to be the same as + an origin without a default port and origins are now compared in a + case-sensitive manner as required by the CORS specification. (markt) +
fix + 63950: Fix timing issue in + TestAsyncContextStateChanges test that caused it + to hang indefinitely. (markt) +
fix + 63982: CombinedRealm makes assumptions about principal implementation + (michaelo) +
code + Add a unit test for the session FileStore implementation + and refactor loops in FileStore to use the ForEach style. + Pull request provided by Govinda Sakhare. (markt) +
fix + Refactor FORM authentication to reduce duplicate code and to ensure that + the authenticated Principal is not cached in the session when caching is + disabled. This is the fix for CVE-2019-17563. (markt/kkolinko) +
update + Do not store username and password as session notes during + authentication if they are not needed. (kkolinko) +
+
+
Coyote
+ + +
fix + 63932: By default, do not compress content that has a strong + ETag. This behaviour is configuration for the HTTP/1.1 connectors via + the new Connector attribute noCompressionStrongETag. + (markt) +
+
+
WebSocket
+ + +
fix + Ensure a very unlikely concurrency issue is avoided when writing + WebSocket messages. (markt) +
+
+
Web applications
+ + +
add + Add the ability to set and display session attributes in the JSP FORM + authentication example to demonstrate session persistence across + restarts for authenticated sessions. (markt) +
+
+
Other
+ + + + + + + + + + + +
fix + Correct the fix for 63815 (quoting the use of + CATALINA_OPTS and JAVA_OPTS when used in shell + scripts to avoid the expansion of *) as it caused various + regressions, particularly with daemon.sh. (markt) +
add + Expand the search made by the Windows installer for a suitable Java + installation to include the 64-bit JDK registry entries and the + JAVA_HOME environment variable. Pull request provided by + Alexander Norz. (markt) +
add + Expand the coverage of the German translations provided with Apache + Tomcat. Contribution provided by Jens. (markt) +
add + Expand the coverage of the French translations provided with Apache + Tomcat. (remm) +
add + Expand the coverage of the Japanese translations provided with Apache + Tomcat. (markt) +
add + Expand the coverage of the Korean translations provided with Apache + Tomcat. (woonsan) +
add + Expand the coverage of the Chinese translations provided with Apache + Tomcat. Contributions provided by lins and 磊. (markt) +
add + Update the internal fork of Apache Commons BCEL to ff6941e (2019-12-06, + 6.4.2-dev). Code clean-up only. (markt) +
add + Update the internal fork of Apache Commons Codec to 9637dd4 (2019-12-06, + 1.14-SNAPSHOT). Code clean-up and a fix for CODEC-265. (markt) +
add + Update the internal fork of Apache Commons FileUpload to 2317552 + (2019-12-06, 2.0-SNAPSHOT). Refactoring. (markt) +
+
+
Tomcat 7.0.98 (violetagg)not released
+
Catalina
+ + + + + +
fix + 63832: Properly mark container as FAILED when a JVM error + occurs on stop. (remm) +
fix + Make a best efforts attempt to clean-up if a request fails during + processing due to an OutOfMemoryException. (markt) +
update + 63905 Clean up Tomcat CSS. (michaelo) +
fix + Refactor JMX remote RMI registry creation. This is the fix for + CVE-2019-12418. (remm) +
+
+
Coyote
+ + + + + + + + + +
fix + 63814: Do not set server socket timeout with negative + values in NIO. (remm) +
fix + Ensure that ServletRequest.isAsyncStarted() returns + false once AsyncContext.complete() or + AsyncContext.dispatch() has been called during + AsyncListener.onTimeout() or + AsyncListener.onError(). (markt) +
fix + 63816 and 63817: Correctly handle I/O errors after + asynchronous processing has been started but before the container thread + that started asynchronous processing has completed processing the + current request/response. (markt) +
fix + 63825: When processing the Expect and + Connection HTTP headers looking for a specific token, be + stricter in ensuring that the exact token is present. (markt) +
fix + 63829: Improve the check of the Content-Encoding + header when looking to see if Tomcat is serving pre-compressed content. + Ensure that only a full token is matched and that the match is case + insensitive. (markt) +
fix + 63836: Ensure that the memory reserved for the OOME parachute + is released when the NIO endpoint is stopped. (markt) +
fix + 63864: Refactor parsing of the transfer-encoding + request header to use the shared parsing code and reduce duplication. + (markt) +
code + Refactor the APR poller to always use a single pollset now that the + Windows operating systems that required multiple smaller pollsets to be + used are no longer supported. (markt) +
+
+
Jasper
+ + + +
fix + 63897: Capture the timestamp of a JSP for the purposes of + modification tracking before the JSP is compiled to prevent a race + condition if the JSP is modified during compilation. Patch provided by + Karl von Randow. (markt) +
fix + Fix a race condition that could mean changes to a modified JSP were not + visible to end users. (markt) +
+
+
WebSocket
+ + +
fix + 63913: Wrap any NullPointerExceptions throw by + the Inflater or Deflater used by the + PerMessageDeflate extension in an IOException + so that the error can be caught and handled by the WebSocket error + handling mechanism. (markt) +
+
+
Web applications
+ + + +
fix + Correct the description of the default value for the server attribute in + the security How-To. (markt) +
fix + Correct the documentation for the maxConnections attribute + of the Connector in the documentation web application. + (markt) +
+
+
Other
+ + + + + + + + + +
fix + 63815: Quote the use of CATALINA_OPTS and + JAVA_OPTS when used in shell scripts to avoid the expansion + of *. Note that any newlines present in + CATALINA_OPTS and/or JAVA_OPTS will no longer + removed. (markt) +
fix + 63826: Remove commons-daemon-native.tar.gz and + tomcat-native.tar.gz from the binary zip distributions for + Windows since compiled versions of those components are already + included within the zip distributions. (markt) +
fix + 63833: Fix an error in the generification of the copied + Commons DBCP 1.x code that caused a NullPointerException if + a DataSource was configured with a database that did not exist. Patch + provided by Guoxiong Li. (markt) +
fix + 63838: Suppress reflexive access warnings when running the + unit tests on the command line. (markt) +
fix + Add missing charsets from the HPE JVM on HP-UX to pass unit tests in + org.apache.tomcat.util.buf.TestCharsetCache. (michaelo) +
add + Expand the coverage and quality of the French translations provided + with Apache Tomcat. (remm) +
add + Expand the coverage and quality of the Korean translations provided + with Apache Tomcat. (woonsan) +
add + Expand the coverage and quality of the Simplified Chinese translations + provided with Apache Tomcat. Contributions provided by rpo130, Mason + Shen, leeyazhou, winsonzhao, qingshi huang, Lay, Shucheng Hou and + Yanming Zhou. (markt) +
+
+
Tomcat 7.0.97 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + +
add + 57665: Add support for the X-Forwarded-Host + header to the RemoteIpFilter and RemoteIpValve. + (markt) +
add + 62496: Add option to write auth information (remote user/auth type) + to response headers. (michaelo) +
fix + 63550: Only try the alternateURL in the + JNDIRealm if one has been specified. (markt) +
update + 63627: Implement more fine-grained handling in + RealmBase.authenticate(GSSContext, boolean). (michaelo) +
fix + Avoid a NullPointerException in the + CrawlerSessionManagerValve if no ROOT Context is deployed + and a request does not map to any of the other deployed Contexts. Patch + provided by Jop Zinkweg. (markt) +
fix + 63636: Context.findRoleMapping() never called + in StandardWrapper.findSecurityReference(). (michaelo) +
fix + Fix a crash on shutdown with the APR/native connector when a blocking + I/O operation was still in progress when the connector stopped. (markt) +
fix + 63684: Wrapper never passed to + RealmBase.hasRole() for given security constraints. + (michaelo) +
fix + Avoid a potential NullPointerException on Service stop if a + Service is embedded directly (i.e. with no Server) in an application + and JNDI is enabled. Patch provided by S. Ali Tokmen. (markt) +
add + Add a new PropertySource implementation, + EnvironmentPropertySource, that can be used to do property + replacement in configuration files with environment variables. Based on + a pull request provided by Thomas Meyer. (markt) +
fix + 63758: Include the XML schema for the tomcat-users.xml file + in the binary distributions. (markt) +
fix + 63778: When running on Java 7, use the correct signature to + look up the DatabaseMetaData.getPseudoColumns() method and + avoid the NullPointerExceptions caused by using the wrong + method. Add error logging to detect similar bugs. Based on a pull + request by liguoxiong. (markt) +
+
+
Coyote
+ + + + + + +
fix + 63571: Use the implementation default for JSSE TLS session + cache size. (markt) +
fix + 63578: Improve handling of invalid requests so that 400 + responses are returned to the client rather than 500 responses. (markt) +
code + Remove the code in the sendfile poller that ensured smaller pollsets + were used with older, no longer supported versions of Windows that + could not support larger pollsets. (markt) +
fix + 63737: Correct various issues when parsing the + accept-encoding header to determine if gzip encoding is + supported including only parsing the first header found. (markt) +
fix + 63766: Ensure Processor objects are recycled when processing + an HTTP upgrade connection that terminates before processing switches to + the Processor for the upgraded protocol. (markt) +
+
+
Jasper
+ + +
fix + 63781: When performing various checks related to the + visibility of classes, fields an methods in the EL implementation, also + check that the containing module has been exported. (markt) +
+
+
Web Socket
+ + + +
fix + 63753: Ensure that the Host header in a Web + Socket HTTP upgrade request only contains a port if a non-default port + is being used. (markt) +
fix + When running on Java 9 and above, don't attempt to instantiate WebSocket + Endpoints found in modules that are not exported. (markt) +
+
+
Web applications
+ + + + + + +
fix + Correct the source code links on the index page for the ROOT web + application to point to Git rather than Subversion. (markt) +
fix + Fix various issues with the Javadoc generated for the documentation web + application to enable release builds to be built with Java 10 onwards. + (markt) +
fix + Fix a large number of Javadoc and documentation typos. Patch provided by + KangZhiDong. (markt) +
fix + Spelling and formatting corrections for the cluster how-to. Pull request + provided by Bill Mitchell. (markt) +
docs + Add Javadoc for the Common Annotations API implementation. (markt) +
+
+
jdbc-pool
+ + +
fix + When connections are validated without an explicit validation query, + ensure that any transactions opened by the validation process are + committed. Patch provided by Pascal Davoust. (markt) +
+
+
Other
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 55620: Partial fix. Prevent Tomcat from starting when + $CATALINA_HOME and/or $CATALINA_BASE contains + a semi-colon on Windows or a colon on Linux/FreeBSD/etc. (markt) +
fix + 62140: Additional usage documentation in comments for + catalina.[bat|sh]. (markt) +
add + 63285: Add an option to service.bat so that when + installing a Windows service, the name of the executables used by the + Windows service may be changed to match the service name. This makes the + installation behaviour consistent with the Windows installer. The + original executable names will be restored when the Windows service is + removed. The renaming can be enabled by using the new + --rename option after the service name. (markt) +
update + 63625: Update to Commons Daemon 1.2.1. This corrects several + regressions in Commons Daemon 1.2.0, most notably the Windows Service + crashing on start when using 32-bit JVMs. (markt) +
update + 63634: Align setproxy target in build.xml with + 8.5/9.0. (michaelo) +
add + Limit the default JPDA (remote debugging interface) listen address to + localhost:8000. (markt) +
update + Tighten up the default file permissions for the .tar.gz + distribution so no files or directories are world readable by default. + Configure Tomcat to run with a default umask of 0027 which + may be overridden by setting UMASK in + setenv.sh. (markt) +
fix + Allow customization of service.bat, such as heap memory size, service + startup mode and JVM args. (isapir) +
update + Update the internal fork of Commons Codec to 3ebef4a (2018-08-01) to + pick up the fix for CODEC-134. (markt) +
update + 63648: Update the test TLS keys and certificates used in the + test suite to replace the keys and certificates that are about to + expire. (markt) +
fix + Back-port various corrections and improvements to the English versions + of the i18n messages. (markt) +
fix + Back-port various corrections and improvements to the Spanish i18n + messages. (markt) +
fix + Back-port various corrections and improvements to the French i18n + messages. (markt) +
fix + Back-port various corrections and improvements to the Japanese i18n + messages. (markt) +
fix + Back-port various corrections and improvements to the Russian i18n + messages. (markt) +
add + Include the available German translations in the standard Tomcat + distribution. Back-port additions and updates to the German i18n + messages. (markt) +
add + Add Korean translations to the standard Tomcat distribution. (markt) +
add + Add simplified Chinese translations to the standard Tomcat distribution. + (markt) +
fix + Fix JSSE_OPTS quoting in catalina.bat. + Contributed by Peter Uhnak. (fschumacher) +
fix + Remove unused i18n messages and associated translations. Patch provided + by KangZhiDong. (markt) +
code + Deprecate org.apache.tomcat.util.compat.TLS. + Its functionality was only used for unit tests in + org.apache.tomcat.util.net.TesterSupport + and has been moved there. (rjung) +
fix + When performing a silent install with the Windows Installer, ensure that + the registry entries are added to the 64-bit registry when using a + 64-bit JVM. (markt) +
fix + 63759: When installing Tomcat with the Windows installer, + grant sufficient privileges to enable the uninstaller to execute when + user account control is active. (markt) +
add + Use a build property to define the minimum supported Java version and + use that build property to reduce the number of edits required to update + the minimum supported Java version. (markt) +
update + 63767: Update to Commons Daemon 1.2.2. This corrects a + regression in Commons Daemon 1.2.0 and 1.2.1 that caused the Windows + Service to crash on start when running on an operating system that had + not been fully updated. (markt) +
+
+
Tomcat 7.0.96 (violetagg)released 2019-07-29
+
Catalina
+ + +
fix + 63579: Correct parsing of malformed OPTIONS requests and + reject them with a 400 response rather than triggering an internal error + that results in a 500 response. (markt) +
+
+
Coyote
+ + +
fix + Correct parsing of invalid host names that contain bytes in the range + 128 to 255 and reject them with a 400 response rather than triggering an + internal error that results in a 500 response. (markt) +
+
+
WebSocket
+ + +
fix + Correct a regression that prevented a default Tomcat 7 install from + starting on Java 6. (markt) +
+
+
Other
+ + +
add + Enable the unit tests to execute in parallel. (markt) +
+
+
Tomcat 7.0.95 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + +
add + 43548: Add an XML schema for the tomcat-users.xml file. + (markt) +
fix + 63324: Refactor the CrawlerSessionManagerValve + so that the object placed in the session is compatible with session + serialization with mem-cached. Patch provided by Martin Lemanski. + (markt) +
fix + 63531: Refactor authenticators so that the session last + accessed time is not updated if the cache attribute is set to + false and FORM authentication is not being + used. (markt) +
add + 63556: Mark request as forwarded in RemoteIpValve and + RemoteIpFilter (michaelo) +
fix + Fix a potential resource leak when executing CGI scripts from a WAR + file. Identified by Coverity scan. (markt) +
fix + Fix a potential concurrency issue in the StringCache identified by + Coverity scan. (markt) +
fix + Fix a potential concurrency issue in the main Sendfile thread of the APR + connector. Identified by Coverity scan. (markt) +
fix + Fix a potential resource leak on some exception paths in the + DataSourceRealm. Identified by Coverity scan. (markt) +
fix + Fix a potential resource leak on an exception path when parsing JSP + files. Identified by Coverity scan. (markt) +
fix + Fix a potential resource leak when a JNDI lookup returns an object of an + in compatible class. Identified by Coverity scan. (markt) +
code + Refactor ManagerServlet to avoid loading classes when + filtering JNDI resources for resources of a specified type. (markt) +
fix + Avoid a NullPointerException when a Context is + defined in server.xml with a docBase but not + the optional path. (markt) +
fix + Ensure that the default servlet reads the entire global XSLT file if + one is defined. Identified by Coverity Scan. (markt) +
fix + Avoid potential NullPointerException when generating an + HTTP Allow header. Identified by Coverity Scan. (markt) +
add + Remove any fragment included in the target path used to obtain a + RequestDispatcher. The requested target path is logged as a + warning since this is an application error. (markt) +
update + Modify the Default and WebDAV Servlets so that a 405 status code is + returned for PUT and DELETE requests when + disabled via the readonly initialisation parameter. +
fix + Align the contents of the Allow header with the response + code for the Default and WebDAV Servlets. For any given resource a + method that returns a 405 status code will not be listed in the + Allow header and a method listed in the Allow + header will not return a 405 status code. (markt) +
fix + Correct two failing tests from the Litmus test suite for WebDAV when + copying/moving a file over a collection. (markt) +
update + Update the recommended minimum Tomcat Native version to 1.2.23. (markt) +
fix + If an unhandled exception occurs on a asynchronous thread started via + AsyncContext.start(Runnable), process it using the standard + error page mechanism. (markt) +
+
+
Coyote
+ + + + +
code + Refactor Hostname validation to improve performance. Patch provided by + Uwe Hees. (markt) +
fix + Fix to avoid the possibility of long poll times for individual pollers + when using multiple pollers with APR. (markt) +
fix + Refactor the fix for 63205 so it only applies when using + PKCS12 keystores as regressions have been reported with some other + keystore types. (markt) +
+
+
Jasper
+ + + +
add + Include file names in error messages if SMAP processor is unable to + delete or rename a class file during SMAP generation. (markt) +
fix + Improvements to varargs handling in the Java UEL implementation. (markt) +
+
+
Cluster
+ + + +
fix + 62841: Refactor the DeltaRequest serialization + to reduce the window during which the DeltaSession is + locked and to remove a potential cause of deadlocks during + serialization. (markt) +
fix + 63441: Further streamline the processing of session creation + messages in the DeltaManager to reduce the possibility of a + session update message being processed before the session has been + created. (markt) +
+
+
WebSocket
+ + +
fix + 63521: As required by the WebSocket specification, if a POJO + that is deployed as a result of the SCI scan for annotated POJOs is + subsequently deployed via the programmatic API ignore the programmatic + deployment. (markt) +
+
+
Tribes
+ + +
fix + Treat NoRouteToHostException the same way as + SocketTimeoutException when checking the health of group + members. This avoids a SEVERE log message every time the check is + performed when the host associated with a group member is not powered + on. (markt) +
+
+
Other
+ + + + + + + + + + +
fix + 55969: Tighten up the security of the Apache Tomcat + installation created by the Windows installer. Change the default + shutdown port used by the Windows installer from 8005 to + -1 (disabled). Limit access to the chosen installation + directory to local administrators, Local System and Local Service. + (markt) +
add + 59871: Add a property (timeFormat) to + JULI's OneLineFormatter to enable the format of the + time stamp used in log messages to be configured. (markt) +
update + 63310: Update to Commons Daemon 1.2.0. This provides improved + support for Java 11. This also changes the user configured by the + Windows installer for the Windows service from Local System + to the lower privileged Local Service. (markt) +
fix + 63335: Ensure that stack traces written by the + OneLineFormatter are fully indented. The entire stack trace + is now indented by an additional TAB character. (markt) +
fix + When using the OneLineFormatter, don't print a blank line + in the log after printing a stack trace. (markt) +
fix + Use the test command to check for terminal availability + rather than the tty command since the tty + based test fails on non-English locales. Patch provided by Radosław + Józwik. (markt) +
update + Update JUnit to version 4.12. (markt) +
update + Update optional WSDL dependency to 1.6.3. (markt) +
update + Update Checkstyle to version 8.22. (markt) +
+
+
Tomcat 7.0.94 (markt)released 2019-04-12
+
Catalina
+ + + + + + + + + + + + + + + + + + + + +
fix + 63196: Provide a default (X-Forwarded-Proto) for + the protocolHeader attribute of the + RemoteIpFilter and RemoteIpValve. (markt) +
add + 63206: Add a new attribute to Context - + createUploadTargets which, if true enables + Tomcat to create the temporary upload location used by a Servlet if the + location specified by the Servlet does not already exist. The default + value is false. (markt) +
fix + 63213: Ensure the correct escaping of group names when + searching for nested groups when the JNDIRealm is configured with + roleNested set to true. (markt) +
fix + 63235: Refactor Charset cache to reduce start time. (markt) +
fix + 63236: Use String.intern() as suggested by + Phillip Webb to reduce memory wasted due to String duplication. This + changes saves ~245k when starting a clean installation. With additional + thanks to YourKit Java profiler for helping to track down the wasted + memory and the root causes. (markt) +
fix + 63246: Fix a potential NullPointerException when + calling AsyncContext.dispatch(). (markt) +
fix + 63249: Use a consistent log level (WARN) when + logging the failure to register or deregister a JMX Bean. (markt) +
fix + 63249: Use a consistent log level (ERROR) when + logging the LifecycleException associated with the failure + to start or stop a component. (markt) +
fix + When the SSI directive fsize is used with an invalid + target, return a file size of - rather than + 1k. (markt) +
fix + 63251: Implement a work-around for a known JRE bug (JDK-8194653) + that may cause a dead-lock when Tomcat starts. (markt) +
fix + Ensure that the JarScanner correctly tests whether JARs found on the + class path should be skipped when running on Java 9 or later. (markt) +
fix + 63275: When using a RequestDispatcher ensure + that HttpServletRequest.getContextPath() returns an encoded + path in the dispatched request. (markt) +
fix + 63286: Document the differences in behaviour between the + LogFormat directive in httpd and the pattern + attribute in the AccessLogValve for %D and + %T. (markt) +
fix + 63311: Add support for https URLs to the local resolver within + Tomcat used to resolve standard XML DTDs and schemas when Tomcat is + configured to validate XML configuration files such as web.xml. (markt) +
fix + Encode the output of the SSI printenv command. This is the + fix for CVE-2019-0221. (markt) +
code + Use constants for SSI encoding values. (markt) +
add + When the CGI Servlet is configured with + enableCmdLineArguments set to true, limit the encoded form + of the individual command line arguments to those values allowed by RFC + 3875. This restriction may be relaxed by the use of the new + initialisation parameter cmdLineArgumentsEncoded. (markt) +
add + When the CGI Servlet is configured with + enableCmdLineArguments set to true, limit the decoded form + of the individual command line arguments to known safe values when + running on Windows. This restriction may be relaxed by the use of the + new initialisation parameter cmdLineArgumentsDecoded. This + is the fix for CVE-2019-0232. (markt) +
update + Change the default for the enableCmdLineArguments parameter + of the CGI servlet from true to false as + additional hardening against CVE-2019-0232. (markt) +
+
+
Coyote
+ + + +
fix + 63194: Fix failing unit test so TLS1.3 client authentication + tests work correctly when using Java 11 onwards and the APR/Native + connector. (markt) +
add + 63205: Add a work-around for a known + JRE KeyStore + loading bug. (markt) +
+
+
Jasper
+ + + +
add + Add support for specifying Java 11 (with the value 11) as + the compiler source and/or compiler target for JSP compilation. (markt) +
add + Add support for specifying Java 12 (with the value 12) and + Java 13 (with the value 13) as the compiler source and/or + compiler target for JSP compilation. If used with an ECJ version that + does not support these values, a warning will be logged and the latest + supported version will used. Based on a patch by Thomas Collignon. + (markt) +
+
+
Web applications
+ + +
fix + 63184: Expand the SSI documentation to provide more + information on the supported directives and their attributes. Patch + provided by nightwatchcyber. (markt) +
+
+
jdbc-pool
+ + +
fix + 63320: Ensure that StatementCache caches + statements that include arrays in arguments. (kfujino) +
+
+
Other
+ + + + + + +
code + Copy Apache Commons DBCP 1.4 and Apache Commons Pool 1.5.7 source code + into the Tomcat 7.0.x tree to enable additional fixes to be pulled in. + (markt) +
fix + Update the copy of Apache Commons DBCP 1.4.x and Apache Commons pool + 1.5.x to the latest source code as of 2019-03-15 to pick up multiple bug + fixes including 58338. (markt) +
code + Update the copy of Apache Commons Pool to 1.6.x to pick up the generics + changes. (markt) +
add + Add JDBC 4.1 support to the default database connection pool provided by + Tomcat. (markt) +
update + Switch from Checkstyle to the JRE6 backport and update to version 8.17. + This allows Tomcat 7 to use the newer configuration format (required by + Gump that uses the latest Checkstyle snapshot) while still building with + Java 6. (markt) +
+
+
Tomcat 7.0.93 (violetagg)released 2019-02-21
+
Catalina
+ + + + + + + + + + + + + + + +
fix + 54741: Add a new method, + Tomcat.addWebapp(String,URL), that allows a web application + to be deployed from a URL when using Tomcat in embedded mode. (markt) +
add + 62897: Provide a property + (clearReferencesThreadLocals) on the standard + Context implementation that enables the check for memory + leaks via ThreadLocals to be disabled because this check + depends on the use of an API that has been deprecated in later versions + of Java. (markt) +
fix + 62978: Update the RemoteIpValve to handle multiple values in + the x-forwarded-proto header. Patch provided by Tom Groot. + (markt) +
fix + Update the RemoteIpFilter to handle multiple values in the + x-forwarded-proto header. Based on a patch provided by Tom + Groot. (markt) +
code + 62986: Refactor the code that performs class scanning during + web application start to make integration simpler for downstream users. + Based on a patch provided by rmannibucau. (markt) +
fix + Implement the requirements of section 8.2.2 2c of the Servlet + specification and prevent a web application from deploying if it has + fragments with duplicate names and is configured to use relative + ordering of fragments. (markt) +
update + Update the recommended minimum Tomcat Native version to 1.2.19. (markt) +
fix + Ensure that the ServletOutputStream implementation is + consistent with the requirements of asynchronous I/O and that all of the + write methods use a single write rather than multiple writes. (markt) +
fix + Correct the Javadoc for Context.getDocBase() and + Context.setDocBase() and remove text that indicates that a + URL may be used for the docBase as this has not been the + case for quite some time. (markt) +
add + Ensure that Tomcat is fully terminated when running as a service. + (markt) +
fix + 63003: Extend the unloadDelay attribute on a + Context to include in-flight asynchronous requests. (markt) +
add + 63026: Add a new attribute, forceDnHexEscape, to + the JNDIRealm that forces escaping in the String + representation of a distinguished name to use the \nn form. + This may avoid issues with realms using Active Directory which appears + to be more tolerant of optional escaping when the \nn form + is used. (markt) +
update + Update the recommended minimum Tomcat Native version to 1.2.21. (markt) +
update + Simplify the value of jarsToSkip property in + catalina.properties file for tomcat-i18n jar files. + Use prefix pattern instead of listing each language. (kkolinko) +
+
+
WebSocket
+ + + + + + + + + + + +
fix + 57974: Ensure implementation of + Session.getOpenSessions() returns correct value for both + client-side and server-side calls. (markt) +
fix + 63019: Use payload remaining bytes rather than limit when + writing. Submitted by Benoit Courtilly. (remm) +
fix + When running under a SecurityManager, ensure that the + ServiceLoader look-up for the default + javax.websocket.server.ServerEndpointConfig.Configurator + implementation completes correctly rather than silently using the + hard-coded fall-back. (markt) +
fix + Ensure that the network connection is closed if the client receives an + I/O error trying to communicate with the server. (markt) +
fix + Ignore synthetic methods when scanning POJO methods. (markt) +
fix + Implement the requirements of section 5.2.1 of the WebSocket 1.1 + specification and ensure that if the deployment of one Endpoint fails, + no Endpoints are deployed for that web application. (markt) +
fix + Implement the requirements of section 4.3 of the WebSocket 1.1 + specification and ensure that the deployment of an Endpoint fails if + @PathParam is used with an invalid parameter type. (markt) +
fix + Ensure a DeploymentException rather than an + IllegalArgumentException is thrown if a method annotated + with @OnMessage does not conform to the requirements set + out in the Javadoc. (markt) +
fix + Improve algorithm that determines if two @OnMessage + annotations have been added for the same message type. Prior to this + change some matches were missed. (markt) +
code + Remove the STREAMS_DROP_EMPTY_MESSAGES system property that + was introduced to work-around four failing TCK tests. An alternative + solution has been implemented. Sending messages via + getSendStream() and getSendWriter() will now + only result in messages on the wire if data is written to the + OutputStream or Writer. Writing zero length + data will result in an empty message. Note that sending a message via an + Encoder may result in the message being send via + getSendStream() or getSendWriter(). (markt) +
+
+
Web applications
+ + + + + + +
fix + 63103: Remove the unused source.jsp file and associated tag + from the examples web application as it is no longer used. (markt) +
fix + 63143: Ensure that the Manager web application respects the + language preferences of the user as configured in the browser when the + language of the default system locale is not English. (markt) +
fix + Use client's preferred language for the Server Status page of the + Manager web application. Review and fix several cases when the + client's language preference was not respected in Manager and + Host Manager web applications. (kkolinko) +
fix + Fix messages used by Manager and Host Manager web applications. + Disambiguate message keys used when adding or removing a host. + Improve display of summary values on the status page: separate + terms and values with a whitespace. Improve wording of messages + for expire sessions command. (kkolinko) +
fix + Do not add CSRF nonce parameter and suppress Referer header for external + links in Manager and Host Manager web applications. (kkolinko) +
+
+
Other
+ + + + + + + + +
fix + Prevent an error when running in a Cygwin shell and the + JAVA_ENDORSED_DIRS system property is empty. Patch provided + by Zemian Deng. (markt) +
update + Update the packaged version of the Tomcat Native Library to 1.2.19 to + pick up the latest Windows binaries built with APR 1.6.5 and OpenSSL + 1.1.1a. (markt) +
fix + Correct AsyncFileHandler to FileHandler in logging.properties. (huxing) +
update + Update the packaged version of the Tomcat Native Library to 1.2.21 to + pick up the memory leak fixes when using NIO/NIO2 with OpenSSL. (markt) +
fix + Enable compilation and test execution with Java 11. Note that the + deprecated class org.apache.catalina.util.Base64 will be + excluded from the build in this case as it depends on JRE classes that + have been removed in Java 11 onwards. (markt) +
update + Update the NSIS Installer used to build the Windows installer to version + 3.04. (markt) +
add + Expand the coverage and quality of the Russian translations provided + with Apache Tomcat. (kkolinko) +
+
+
Tomcat 7.0.92 (violetagg)released 2018-11-15
+
Catalina
+ + + + + + + + + + + +
fix + Add documentation about the files context.xml.default and + web.xml.default that can be used to customize conf/context.xml + and conf/web.xml on a per host basis. (fschumacher) +
fix + Ensure that a canonical path is always used for the docBase of a Context + to ensure consistent behaviour. (markt) +
fix + 62788: Add explicit logging configuration to write log files + using UTF-8 to align with Tomcat's use of UTF-8 by default + elsewhere. (markt) +
fix + 62797: Pass throwable to keep client aborts with status 200 + rather than 500. Patch submitted by zikfat. (remm) +
fix + 62809: Correct a regression in the implementation of DIGEST + authentication support for the Deployer Ant tasks (bug 45832) + that prevented the DeployTask from working when + authentication was required. (markt) +
update + Update the recommended minimum Tomcat Native version to 1.2.18. (markt) +
add + Ignore an attribute named source on Context + elements provided by StandardContext. This is to suppress + warnings generated by the Eclipse / Tomcat integration provided by + Eclipse. Based on a patch by mdfst13. (markt) +
add + 62830: Added JniLifeCycleListener and static + methods Library.loadLibrary(libraryName) and + Library.load(filename) to load a native library by a + shared class loader so that more than one Webapp can use it. (isapir) +
fix + Correct a typo in the Spanish resource files. Patch provided by Diego + Agulló. (markt) +
fix + 62868: Order the Enumeration<URL> provided + by WebappClassLoaderBase.getResources(String) according to + the setting of the delegate flag. (markt) +
+
+
Coyote
+ + + + + +
add + Add TLSv1.3 to the default protocols and to the all + alias for JSSE based TLS connectors when running on a JVM that + supports TLS version 1.3. One such JVM is OpenJDK version 11. (rjung) +
fix + 62739: Do not reject requests with an empty HTTP Host header. + Such requests are unusual but not invalid. Patch provided by Michael + Orr. (markt) +
add + 62748: Add TLS 1.3 support for the APR/Native connector. + (schultz/markt) +
fix + 62791: Remove an unnecessary check in the NIO TLS + implementation that prevented from secure WebSocket connections from + being established. (markt) +
+
+
Jasper
+ + + + + + +
fix + 62674: Correct a regression in the stand-alone JSP compiler + utility, JspC, caused by the fix for 53492, that + caused the JSP compiler to hang. (markt) +
fix + 62721: Correct generation of web.xml header when using JspC. + (markt) +
fix + Fix a regression in the TLD whitespace parsing fix that broke parsing + when whitespace was present between the method name and the parameters. + (markt) +
fix + 62757: Correct a regression in the fix for 62603 + that caused NullPointerExceptions when compiling tag files + on first access when development mode was disabled and background + compilation was enabled. Based on a patch by Jordi Llach. (markt) +
fix + 62808: Fix a regression in the TLD whitespace parsing fix + that broke parsing when new lines were present in the method signature. + (markt) +
+
+
WebSocket
+ + +
fix + 62731: Make the URI returned by + HandshakeRequest.getRequestURI() and + Session.getRequestURI() absolute so that the scheme, host + and port are accessible. (markt) +
+
+
Web applications
+ + + + +
fix + 62761: Correct the advanced CORS example in the Filter + documentation to use a valid configuration. (markt) +
fix + 62786: Add a note to the Context documentation to explain + that, by default, settings for a Context element defined in server.xml + will be overwritten by settings specified in a default context file such + as conf/context.xml. (markt) +
fix + Create a little visual separation between the Undeploy button and the + other buttons in the Manager application. Patch provided by Łukasz + Jąder. (markt) +
+
+
Other
+ + +
update + Update the packaged version of the Tomcat Native Library to 1.2.18 to + pick up the latest Windows binaries built with APR 1.6.5 and OpenSSL + 1.1.1. (markt) +
+
+
Tomcat 7.0.91 (violetagg)released 2018-09-19
+
Catalina
+ + + + + + + + + + + + + + + + +
add + 61692: Add the ability to control which HTTP methods are + handled by the CGI Servlet via a new initialization parameter + cgiMethods. (markt) +
fix + Ensure that the HTTP Vary header is set correctly when using the CORS + filter and improve the cacheability of requests that pass through the + COPRS filter. (markt) +
fix + 62527: Revert restriction of JNDI to the java: + namespace. (remm) +
add + Introduce a new class - MultiThrowable - to report + exceptions when multiple actions are taken where each action may throw + an exception but all actions are taken before any errors are reported. + Use this new class when reporting multiple container (e.g. web + application) failures during start. (markt) +
fix + Correctly decode URL paths (+ should not be decoded to a + space in the path) in the RequestDispatcher and the web + application class loader. (markt) +
add + 62559: Add jaxb-*.jar to the list of JARs + ignored by StandardJarScanner. (markt) +
add + 62560: Add oraclepki.jar to the list of JARs + ignored by StandardJarScanner. (markt) +
add + 62607: Return a non-zero exit code from + catalina.[bat|sh] run if Tomcat fails to start. (markt) +
code + Remove ServletException from declaration of + Tomcat.addWebapp(String,String) since it is never thrown. + Patch provided by Tzafrir. (markt) +
fix + Use short circuit logic to prevent potential NPE in CorsFilter. (fschumacher) +
code + Simplify construction of appName from container name in JAASRealm. (fschumacher) +
fix + Improve the handling of path parameters when working with + RequestDispatcher objects. (markt) +
fix + 62664: Process requests with content type + multipart/form-data to servlets with a + @MultipartConfig annotation regardless of HTTP method. + (markt) +
fix + 62669: When using the SSIFilter and a resource does not + specify a content type, do not force the content type to + application/x-octet-stream. (markt) +
fix + When generating a redirect to a directory in the Default Servlet, avoid + generating a protocol relative redirect. (markt) +
+
+
Coyote
+ + + + + +
fix + Refactor code that adds an additional header name to the + Vary HTTP response header to use a common utility method + that addresses several additional edge cases. (markt) +
fix + 62526: Correctly handle PKCS12 format key stores when the key + store password is configured to be the empty string. Note that Java 6 + does not support PKCS12 key stores configured to use a store password of + the empty string. (markt) +
fix + 62670: Adjust the memory leak protection for the + DriverManager so that JDBC drivers located in + $CATALINA_HOME/lib and $CATALINA_BASE/lib are + loaded via the service loader mechanism when the protection is enabled. + (markt) +
fix + 62685: Correct an error in host name validation parsing that + did not allow a fully qualified domain name to terminate with a period. + Patch provided by AG. (markt) +
+
+
Jasper
+ + + + + + + +
fix + 53011: When pre-compiling with JspC, report all compilation + errors rather than stopping after the first error. A new option + -failFast can be used to restore the previous behaviour of + stopping after the first error. Based on a patch provided by Marc Pompl. + (markt) +
add + 53492: Make the Java file generation process multi-threaded. + By default, one thread will be used per core. Based on a patch by Dan + Fabulich. (markt) +
fix + 62603: Fix a potential race condition when development mode + is disabled and background compilation checks are enabled. It was + possible that some updates would not take effect and/or + ClassNotFoundExceptions would occur. (markt) +
fix + Correct the JSP version in the X-PoweredBy HTTP header generated when + the xpoweredBy option is enabled. (markt) +
fix + 62662: Fix the corruption of web.xml output during JSP + compilation caused by the fix for 53492. Patch provided by + Bernhard Frauendienst. (markt) +
fix + Correct parsing of XML whitespace in TLD function signatures that + incorrectly only looked for the space character. (markt) +
+
+
WebSocket
+ + +
fix + 62596: Remove the limit on the size of the initial HTTP + upgrade request used to establish the web socket connection. (markt) +
+
+
Web applications
+ + + + + + + +
add + 62558: Add Russian translations for the Manager and Host + Manager web applications. Based on a patch by Ivan Krasnov. (markt) +
add + 62561: Add advanced class loader configuration information + regarding the use of the Server and Shared class loaders to the + documentation web application. (markt) +
add + Expand the information in the documentation web application regarding + the use of CATALINA_HOME and CATALINA_BASE. + Patch provided by Marek Czernek. (markt) +
fix + 62652: Make it clearer that the version of DBCP that is + packaged in Tomcat 7.0.x is DBCP 1. (markt) +
add + 62666: Expand internationalisation support in the Manager + application to include the server status page and provide Russian + translations in addition to English. Patch provided by Artem Chebykin. + (markt) +
fix + 62676: Expand the CORS filter documentation to make it clear + that explicit configuration is required to enable support for + cross-origin requests. (markt) +
+
+
Tribes
+ + +
fix + Ensures that the specified rxBufSize is correctly set to + receiver buffer size. (kfujino) +
+
+
Other
+ + + +
fix + Fixed spelling. Patch provided by Jimmy Casey via GitHub. (violetagg) +
fix + Correct various spelling errors throughout the source code and + documentation. Patch provided by Kazuhiro Sera. (markt) +
+
+
Tomcat 7.0.90 (violetagg)released 2018-07-06
+
Catalina
+ + + +
fix + 62498: Correct a regression in the fix for CVE-2017-12617 + that caused request failures for some requests when using the + VirtualDirContext. (markt) +
fix + Delete reference to removed class that prevented Tomcat from starting + when running under a security manager. (markt) +
+
+
Tomcat 7.0.89 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + +
fix + JNDI resources that are defined with injection targets but no value are + now treated as if the resource is not defined. (markt) +
fix + Ensure that JNDI names used for <lookup-name> entries + in web.xml and for lookup elements of + @Resource annotations specify a name with an explicit + java: namespace. (markt) +
add + 51953: Add the RemoteCIDRFilter and + RemoteCIDRValve that can be used to allow/deny requests + based on IPv4 and/or IPv6 client address where the IP ranges are defined + using CIDR notation. Based on a patch by Francis Galiegue. (markt) +
fix + 62343: Make CORS filter defaults more secure. This is the fix + for CVE-2018-8014. (markt) +
fix + Make all loggers associated with Tomcat provided Filters non-static to + ensure that log messages are not lost when a web application is + reloaded. (markt) +
fix + Correct the manifest for the annotations-api.jar. The JAR implements the + Common Annotations API 1.1 and the manifest should reflect that. (markt) +
fix + Switch to non-static loggers where there is a possibility of a logger + becoming associated with a web application class loader causing log + messages to be lost if the web application is stopped. (markt) +
add + 62389: Add the IPv6 loopback address to the default + internalProxies regular expression. Patch by Craig Andrews. + (markt) +
fix + In the RemoteIpValve and RemoteIpFilter, + correctly handle the case when the request passes through one or more + trustedProxies but no internalProxies. Based + on a patch by zhanhb. (markt) +
fix + Correct the logic in MBeanFactory.removeConnector() to + ensure that the correct Connector is removed when there are multiple + Connectors using different addresses but the same port. (markt) +
fix + Make JAASRealm mis-configuration more obvious by requiring + the authenticated Subject to include at least one Principal of a type + specified by userClassNames. (markt) +
fix + 62476: Use GMT timezone for the value of + Expires header as required by HTTP specification + (RFC 7231, 7234). (kkolinko) +
+
+
Coyote
+ + + + + +
fix + Log an error message if the AJP connector detects that the reverse proxy + is sending AJP messages that are too large for the configured + packetSize. (markt) +
fix + 62371: Improve logging of Host validation failures. (markt) +
fix + Correctly handle a digest authorization header when the user name + contains an escaped character. (markt) +
fix + Correctly handle a digest authorization header when one of the hex + field values ends the header with in an invalid character. (markt) +
+
+
Jasper
+ + + + +
fix + Update web.xml, web-fragment.xml and web.xml extracts generated by JspC + to use the Servlet 3.0 version of the relevant schemas. (markt) +
fix + Improve IPv6 validation by ensuring that IPv4-Mapped IPv6 addresses do + not contain leading zeros in the IPv4 part. Based on a patch by Katya + Stoycheva. (markt) +
fix + 62080: Ensure that all reads of the current thread's context + class loader made by the UEL API and implementation are performed via a + PrivilegedAction to ensure that a + SecurityException is not triggered when running under a + SecurityManager. (mark) +
+
+
WebSocket
+ + + +
fix + When decoding of path parameter failed, make sure to throw + DecodeException instead of throwing + ArrayIndexOutOfBoundsException. (kfujino) +
fix + Enable host name verification when using TLS with the WebSocket client. + (markt) +
+
+
Web applications
+ + +
fix + 62395: Clarify the meaning of the connector attribute + minSpareThreads in the documentation web application. + (markt) +
+
+
jdbc-pool
+ + +
fix + When logValidationErrors is set to true, the connection + validation error is logged as SEVERE instead of + WARNING. (kfujino) +
+
+
Other
+ + + + +
fix + 62391: Remove references to javaw.exe as this + file is not required by Tomcat and the references prevent the use of the + Server JRE. (markt) +
update + Update the packaged version of the Tomcat Native Library to 1.2.17 to + pick up the latest Windows binaries built with APR 1.6.3 and OpenSSL + 1.0.2o. (markt) +
add + Implement checksum checks when downloading dependencies that are used + to build Tomcat. (kkolinko) +
+
+
Tomcat 7.0.88 (violetagg)released 2018-05-11
+
Catalina
+ + + + + + + + + + +
fix + Treat the <mapped-name> element of a + <env-entry> in web.xml in the same way as the + mappedName element of the equivalent @Resource + annotation. Both now attempt to set the mappedName property + of the resource. (markt) +
fix + Correct the processing of resources with + <injection-target>s defined in web.xml. First look + for a match using JavaBean property names and then, only if a match is + not found, look for a match using fields. (markt) +
fix + When restoring a saved request with a request body after FORM + authentication, ensure that calls to the HttpServletRequest + methods getRequestURI(), getQueryString() and + getProtocol() are not corrupted by the processing of the + saved request body. (markt) +
fix + Fix startup failure when running under SecurityManager, a regression + from the fix for bug 62273. (kkolinko) +
fix + 62353: Correct a regression introduced in Tomcat 7.0.86. + Restore the ability for Tomcat 7 to run on Java 6 where Common + Annotations 1.0 is available. Document the requirement to use the Java + endorsed mechanism to use Common Annotations 1.1. (markt) +
code + Refactor the org.apache.naming package to reduce duplicate + code. Duplicate code identified by the Simian tool. (markt) +
fix + 50019: Add support for <lookup-name>. + Based on a patch by Gurkan Erdogdu. (markt) +
fix + 60490: Various formatting and layout improvements for the + ErrorReportValve. Patch provided by Michael Osipov. (markt) +
fix + Relax Host validation by removing the requirement that the final + component of a FQDN must be alphabetic. (markt) +
+
+
Jasper
+ + + +
add + 50234: Add the capability to generate a web-fragment.xml file + to JspC. (markt) +
fix + 62350: Refactor + org.apache.jasper.runtime.BodyContentImpl so a + SecurityException is not thrown when running under a + SecurityManger and additional permissions are not required in the + catalina.policy file. This is a follow-up to the fix for + 43925. (kkolinko/markt) +
+
+
Cluster
+ + +
fix + Remove duplicate calls when creating a replicated session to reduce the + time taken to create the session and thereby reduce the chances of a + subsequent session update message being ignored because the session does + not yet exist. (markt) +
+
+
Tribes
+ + +
fix + Ensure that the correct default value is returned when retrieve unset + properties in McastService. (kfujino) +
+
+
Other
+ + +
fix + Add a .gitattributes file to make sure that Git + handles test data files for bug 52121 as binary. (kkolinko) +
+
+
Tomcat 7.0.87 (violetagg)not released
+
Catalina
+ + + + + + + + +
fix + 62316: Correct a regression in some refactoring that + broke the default factory for JDBC datasources. (markt) +
fix + Fix a rare edge case that is unlikely to occur in real usage. This edge + case meant that writing long streams of UTF-8 characters to the HTTP + response that consisted almost entirely of surrogate pairs could result + in one surrogate pair being dropped. (markt) +
fix + Register MBean when DataSource Resource + type="javax.sql.XADataSource". + Patch provided by Masafumi Miura. (csutherl) +
add + Update the internal fork of Apache Commons BCEL to r1829827 to add early + access Java 11 support to the annotation scanning code. (markt) +
fix + 62297: Enable the CrawlerSessionManagerValve to + correctly handle bots that crawl multiple hosts and/or web applications + when the Valve is configured on a Host or an Engine. (fschumacher) +
add + Collapse multiple leading / characters to a single + / in the return value of + HttpServletRequest#getContextPath() to avoid issues if the + value is used with HttpServletResponse#sendRedirect(). This + behaviour is enabled by default and configurable via the new Context + attribute allowMultipleLeadingForwardSlashInPath. (markt) +
fix + Improve handing of overflow in the UTF-8 decoder with supplementary + characters. (markt) +
+
+
Coyote
+ + + + + + +
add + Enable strict validation of the provided host name and port for all + connectors. Requests with invalid host names and/or ports will be + rejected with a 400 response. (markt) +
fix + Implement the requirements of RFC 7230 (and RFC 2616) that HTTP/1.1 + requests must include a Host header and any request that + does not must be rejected with a 400 response. (markt) +
fix + Implement the requirements of RFC 7230 that any HTTP/1.1 request that + specifies a host in the request line, must specify the same host in the + Host header and that any such request that does not, must + be rejected with a 400 response. This check is optional and disabled by + default. It may be enabled with the + allowHostHeaderMismatch attribute of the Connector. (markt) +
fix + Implement the requirements of RFC 7230 that any HTTP/1.1 request that + contains multiple Host headers is rejected with a 400 + response. (markt) +
add + 62273: Implement configuration options to work-around + specification non-compliant user agents (including all the major + browsers) that do not correctly %nn encode URI paths and query strings + as required by RFC 7230 and RFC 3986. (markt) +
+
+
Jasper
+ + + + +
fix + Enable ECJ version 4.7 and later to be used as a drop in replacement for + the ECJ version that ships with Apache Tomcat. (markt) +
fix + Enable Java 10 to be specified as a JSP source and/or target if a newer + ECJ version is used. (markt) +
fix + 62287: Do not rely on hash codes to test instances of + ValueExpressionImpl for equality. Patch provided by Mark + Struberg. (markt) +
+
+
WebSocket
+ + +
fix + 62301: Correct a regression in the fix for 61491 + that didn't correctly handle a final empty message part in all + circumstances when using PerMessageDeflate. (markt) +
+
+
Other
+ + +
fix + Avoid warning when running under Cygwin when the + JAVA_ENDORSED_DIRS environment variable is not set. Patch + provided by Zemian Deng. (markt) +
+
+
Tomcat 7.0.86 (violetagg)released 2018-04-13
+
Catalina
+ + + + + + + + + + + + + + + + +
fix + 51195: Avoid a false positive report of a web application + memory leak by clearing ObjectStreamClass$Caches of classes + loaded by the web application when the web application is stopped. + (markt) +
fix + 52688: Add support for the maxDays attribute to + the AccessLogValve and ExtendedAccessLogValve. + This allows the maximum number of days for which rotated access logs + should be retained before deletion to be defined. (markt) +
fix + Prevent Tomcat from applying gzip compression to content that is already + compressed with brotli compression. Based on a patch provided by burka. + (markt) +
fix + 62090: Null container names are not allowed. (remm) +
fix + 62104: Fix programmatic login regression as the + NonLoginAuthenticator has to be set for it to work (if no login method + is specified). (remm) +
fix + 62117: Improve error message in catalina.sh when + calling kill -0 <pid> fails. Based on a suggestion + from Mark Morschhaeuser. (markt) +
fix + 62118: Correctly create a JNDI ServiceRef using + the specified interface rather than the concrete type. Based on a + suggestion by Ángel Álvarez Páscua. (markt) +
fix + Fix for RequestDumperFilter log attribute. Patch provided + by Kirill Romanov via Github. (violetagg) +
fix + 62123: Avoid ConcurrentModificationException + when attempting to clean up application triggered RMI memory leaks on + web application stop. (markt) +
fix + 62168: When using the PersistentManager honor a + value of -1 for minIdleSwap and do not swap + out sessions to keep the number of active sessions under + maxActive. Patch provided by Holger Sunke. (markt) +
fix + 62172: Improve Javadoc for + org.apache.catalina.startup.Constants and ensure that the + constants are correctly used. (markt) +
fix + 62175: Avoid infinite recursion, when trying to validate + a session while loading it with PersistentManager. + (fschumacher) +
fix + Ensure that NamingContextListener instances are only + notified once of property changes on the associated naming resources. + (markt) +
add + 62224: Disable the forkJoinCommonPoolProtection + of the JreMemoryLeakPreventionListener when running on Java + 9 and above since the underlying JRE bug has been fixed. (markt) +
fix + 62263: Avoid a NullPointerException when the + RemoteIpValve processes a request for which no Context can + be found. (markt) +
+
+
Coyote
+ + +
fix + Correct off-by-one error in thread pool that allowed thread pools to + increase in size to one more than the configured limit. Patch provided + by usc. (markt) +
+
+
Web applications
+ + + + +
add + Work-around a known, non-specification compliant behaviour in some + versions of IE that can allow XSS when the Manager application generates + a plain text response. Based on a suggestion from Muthukumar Marikani. + (markt) +
add + Add document for FragmentationInterceptor. (kfujino) +
add + Document how the roles for an authenticated user are determined when the + CombinedRealm is used. (markt) +
+
+
jdbc-pool
+ + + + +
fix + Ensure that SQLWarning has been cleared when connection + returns to the pool. (kfujino) +
fix + Ensure that parameters have been cleared when + PreparedStatement and/or CallableStatement are + cached. (kfujino) +
fix + Enable PoolCleaner to be started even if validationQuery + is not set. (kfujino) +
+
+
Other
+ + + +
update + Update the build script so MD5 hashes are no longer generated for + releases as per the change in the ASF distribution policy. (markt) +
fix + 62164: Switch the build script to use TLS for downloads from + SourceForge and Maven Central to avoid failures due to HTTP to HTTPS + redirects. (markt) +
+
+
Tomcat 7.0.85 (violetagg)released 2018-02-13
+
Catalina
+ + + + + + + + + + + +
fix + Prevent a stack trace being written to standard out when running on Java + 10 due to changes in the LogManager implementation. (markt) +
fix + Avoid duplicate load attempts if one has been made already. (remm) +
fix + Avoid NPE in ThreadLocalLeakPreventionListener if there is no Engine. + (remm) +
fix + 58143: Fix calling classloading transformers broken in 7.0.70 + by the fix for 59619. This was observed when using Spring + weaving. (rjung) +
fix + 62000: When a JNDI reference cannot be resolved, ensure that + the root cause exception is reported rather than swallowed. (markt) +
fix + 62036: When caching an authenticated user Principal in the + session when the web application is configured with the + NonLoginAuthenticator, cache the internal Principal object + rather than the user facing Principal object as Tomcat requires the + internal object to correctly process later authorization checks. (markt) +
fix + 62067: Correctly apply security constraints mapped to the + context root using a URL pattern of "". (markt) +
fix + When using Tomcat embedded, only perform Authenticator configuration + once during web application start. (markt) +
fix + Process all ServletSecurity annotations at web application + start rather than at servlet load time to ensure constraints are applied + consistently. (markt) +
fix + Minor optimization when calling class transformers. (rjung) +
+
+
Web applications
+ + +
add + 48672: Add documentation for the Host Manager web + application. Patch provided by Marek Czernek. (markt) +
+
+
Other
+ + +
update + Update the NSIS Installer used to build the Windows installer to version + 3.03. (kkolinko) +
+
+
Tomcat 7.0.84 (violetagg)released 2018-01-24
+
Catalina
+ + + + + + + +
fix + 47214: Use a loop to preload anonymous inner classes + when running under a SecurityManager, to be safe for + future changes in the code or using a different compiler. (kkolinko) +
add + 57619: Implement a small optimisation to how JAR URLs are + processed to reduce the storage of duplicate String objects in memory. + Patch provided by Dmitri Blinov. (markt) +
add + 61810: Support configure the interval to keep all jars open + if no jar is accessed, a non-positive interval indicates + keeping jars always open. (huxing) +
fix + 61886: Pre-load additional classes to prevent + SecurityExceptions if the first request received when + running under a SecurityManager is an asynchronous Servlet. + (markt) +
fix + 61916: Extend the AddDefaultCharsetFilter to add + a character set when the content type is set via + setHeader() or addHeader() as well as when it + is set via setContentType(). (markt) +
fix + 61999: maxSavePostSize set to 0 should disable saving POST + data during authentication. (remm) +
+
+
Coyote
+ + + +
fix + 61886: Log errors on non-container threads at + DEBUG rather than INFO. The exception will be + made available to the application via the asynchronous error handling + mechanism. (markt) +
fix + 61993: Improve handling for ByteChunk and + CharChunk instances that grow close to the maximum size + allowed by the JRE. (markt) +
+
+
Jasper
+ + +
add + 43925: Add a new system property + (org.apache.jasper.runtime.BodyContentImpl.BUFFER_SIZE) to + control the size of the buffer used by Jasper when buffering tag bodies. + (markt) +
+
+
Web applications
+ + + + + + + + +
add + 61223: Add the mbeans-descriptors.dtd file to the custom + MBean documentation so users have a reference to use when constructing + mbeans-descriptors.xml files for custom components. (markt) +
fix + Partial fix for 61886. Ensure that multiple threads do not + attempt to complete the AsyncContext if an I/O error occurs + in the stock ticker example Servlet. (markt) +
fix + 61886: Prevent ConcurrentModificationException + when running the asynchronous stock ticker in the examples web + application. (markt) +
fix + 61886: Prevent NullPointerException and other + errors if the stock ticker example is running when the examples web + application is stopped. (markt) +
fix + 61910: Clarify the meaning of the allowLinking + option in the documentation web application. (markt) +
add + Add OCSP configuration information to the SSL How-To. Patch provided by + Marek Czernek. (markt) +
fix + 62006: Document the new JvmOptions9 command line + parameter for tomcat7.exe. (markt) +
+
+
jdbc-pool
+ + +
fix + 61312: Prevent NullPointerException when using + the statement cache of connection that has been closed. (kfujino) +
+
+
Other
+ + + + +
update + Update the internal fork of Commons FileUpload to 6c00d57 (2017-11-23) + to pick up some code clean-up. (markt) +
update + Update the internal fork of Commons Codec to r1817136 to pick up some + code clean-up. (markt) +
fix + The native source bundles (for Commons Daemon and Tomcat Native) are no + longer copied to the bin directory for the deploy target. They are now + only copied to the bin directory for the release target. (markt) +
+
+
Tomcat 7.0.83 (violetagg)not released
+
Catalina
+ + + + + + + + + +
add + When running under Java 9 or later, and the + urlCacheProtection option of the + JreMemoryLeakPreventionListener is enabled, use the API + added in Java 9 to only disable the caching for JAR URL connections. + (markt) +
fix + 61581: Fix possible SecurityException when using + the APR/native connector with a SecurityManager. (markt) +
fix + 61597: Extend the StandardJarScanner to scan + JARs on the module path when running on Java 9 and class path scanning + is enabled. (markt) +
fix + Fix the JMX descriptor for Wrapper.findInitParameter(). + (rjung) +
fix + 61601: Add support for multi-release JARs in JAR scanning and + web application class loading. (markt) +
fix + Revert the change from 7.0.80 that called + ServletResponse.setLocale() if the + Content-Language HTTP header was set directly. (markt) +
add + Provide the SessionInitializerFilter that can be used to + ensure that an HTTP session exists when initiating a WebSocket + connection. Patch provided by isapir. (markt) +
fix + Avoid a possible NullPointerException when timing out + AsyncContext instances during shut down. (markt) +
+
+
Coyote
+ + + +
fix + 57870: When running on Java 7 or later, take advantage of the + new syncFlush parameter when constructing a + GZIPOutputStream rather than using the custom + FlushableGZIPOutputStream implementation as a work-around. + (markt) +
fix + 61736: Improve performance of NIO connector when clients + leave large time gaps between network packets. Patch provided by Zilong + Song. (markt) +
+
+
Jasper
+ + + +
add + Enable Jasper to compile JSPs for Java 9. In addition to configuring the + JSP servlet with for Java 9 via the compilerSourceVM and + compilerTargetVM, it is necessary to replace + ecj-4.4.2.jar with a more recent version that supports Java + 9. (markt) +
fix + 61816: Invalid expressions in attribute values or template + text should trigger a translation (compile time) error, not a run time + error. (markt) +
+
+
WebSocket
+ + +
fix + 61604: Add support for authentication in the websocket + client. Patch submitted by J Fernandez. (remm) +
+
+
Web applications
+ + + +
fix + 61603: Add XML filtering for the status servlet output where + needed. (remm) +
fix + Correct the description of how the CGI servlet maps a request to a + script in the CGI How-To. (markt) +
+
+
Tribes
+ + + + +
fix + Fix incorrect behavior that attempts to resend channel messages more + than the actual setting value of maxRetryAttempts. + (kfujino) +
fix + Ensure that the remaining Sender can send channel messages by avoiding + unintended ChannelException caused by comparing the number + of failed members and the number of remaining Senders. (kfujino) +
fix + Ensure that remaining SelectionKeys that were not handled by throwing a + ChannelException during SelectionKey processing are + handled. (kfujino) +
+
+
Other
+ + + + + + + + + + + + + + +
fix + Improve the fix for 61439 and exclude the JPA, JAX-WS and EJB + annotations completely from the Tomcat distributions. (markt) +
fix + Improve handling of endorsed directories. The endorsed directory + mechanism will only be used if the JAVA_ENDORSED_DIRS + system property is explicitly set or if + $CATALINA_HOME/endorsed exists. When running on Java 9, any + such attempted use of the endorsed directory mechanism will trigger an + error and Tomcat will fail to start. (rjung) +
code + Refactoring in preparation for Java 9. Refactor to avoid using some + methods that will be deprecated in Java 9 onwards. (markt) +
add + 51496: When using the Windows installer, check if the + requested service name already exists and, if it does, prompt the user + to select an alternative service name. Patch provided by Ralph + Plawetzki. (markt) +
fix + Add necessary Java 9 configuration options to the startup scripts to + prevent warnings being generated on web application stop. (markt) +
fix + 61590: Enable service.bat to recognise when + JAVA_HOME is configured for a Java 9 JDK. (markt) +
fix + 61598: Update the Windows installer to search the new (as of + Java 9) registry locations when looking for a JRE. (markt) +
add + Add generation of a SHA-512 hash for release artifacts to the build + script. (markt) +
fix + 61658: Update MIME mappings for fonts to use + font/* as per RFC8081. (markt) +
update + Update the packaged version of the Tomcat Native Library to 1.2.16 to + pick up the latest Windows binaries built with APR 1.6.3 and OpenSSL + 1.0.2m. (markt) +
update + Update the NSIS Installer used to build the Windows installer to version + 3.02.1. (kkolinko) +
update + Update the Windows installer to use "The Apache Software Foundation" as + the Publisher when Tomcat is displayed in the list of installed + applications in Microsoft Windows. (kkolinko) +
fix + 61803: Remove outdated SSL information from the Security + documentation. (remm) +
+
+
Tomcat 7.0.82 (violetagg)released 2017-10-03
+
Catalina
+ + + + + + + + + + +
fix + 61210: When running under a SecurityManager, do not print a + warning about not being able to read a logging configuration file when + that file does not exist. (markt) +
add + 61280: Add RFC 7617 support to the + BasicAuthenticator. Note that the default configuration + does not change the existing behaviour. (markt) +
fix + 61452: Fix a copy paste error that caused an + UnsupportedEncodingException when using WebDAV. (markt) +
fix + Correct regression in 7.0.80 that broke the use of relative paths with + the extraResourcePaths attribute of a + VirtualDirContext. (markt) +
add + 61489: When using the CGI servlet, make the generation of + command line arguments from the query string (as per section 4.4 of RFC + 3875) optional. The feature is enabled by default for consistency with + previous releases. Based on a patch by jm009. (markt) +
fix + Correct a regression in 7.0.80 and 7.0.81 that wrapped the + DirContext that represented the web application in a + ProxyDirContext twice rather than just once. (markt) +
fix + 61542: Fix CVE-2017-12617 and prevent JSPs from being + uploaded via a specially crafted request when HTTP PUT was enabled. + (markt) +
fix + Use the correct path when loading the JVM logging.properties + file for Java 9. (rjung) +
fix + 61554: Exclude test files in unusual encodings and markdown + files intended for display in GitHub from RAT analysis. Patch provided + by Chris Thistlethwaite. (markt) +
+
+
Coyote
+ + + + + + +
fix + 48655: Enable Tomcat to shutdown cleanly when using sendfile, + the APR/native connector and a multi-part download is in progress. + (markt) +
fix + 58244: Handle the case when OpenSSL resumes a TLS session + using a ticket and the full client certificate chain is not available. + In this case the client certificate without the chain will be presented + to the application. (markt) +
fix + Fix random SocketTimeoutExceptions when reading the request + InputStream. Based on a patch by Peter Major. (markt) +
fix + 60900: Avoid a NullPointerException in the APR + Poller if a connection is closed at the same time as new data arrives on + that connection. (markt) +
add + Add an option to reject requests that contain HTTP headers with invalid + (non-token) header names with a 400 response. (markt) +
+
+
WebSocket
+ + +
fix + 61491: When using the permessage-deflate + extension, correctly handle the sending of empty messages after + non-empty messages to avoid the IllegalArgumentException. + (markt) +
+
+
Tribes
+ + + + + + + +
fix + To avoid unexpected session timeout notification from backup session, + update the access time when receiving the map member notification + message. (kfujino) +
fix + Add member info to the log message when the failure detection check + fails in TcpFailureDetector. (kfujino) +
fix + Avoid Ping timeout until the added map member by receiving + MSG_START message is completely started. (kfujino) +
fix + When sending a channel message, make sure that the Sender has connected. + (kfujino) +
fix + Correct the backup node selection logic that node 0 is returned twice + consecutively. (kfujino) +
fix + Fix race condition of responseMap in + RpcChannel. (kfujino) +
+
+
jdbc-pool
+ + + + +
fix + 61391: Ensure that failed queries are logged if the + SlowQueryReport interceptor is configured to do so and the + connection has been abandoned. Patch provided by Craig Webb. (markt) +
fix + 61425: Ensure that transaction of idle connection has + terminated when the testWhileIdle is set to + true and defaultAutoCommit is set to + false. Patch provided by WangZheng. (kfujino) +
fix + 61545: Correctly handle invocations of methods defined in the + PooledConnection interface when using pooled XA + connections. Patch provided by Nils Winkler. (markt) +
+
+
Other
+ + + + + + +
fix + 61439: Remove the Java Annotation API classes from + tomcat-embed-core.jar and package them in a separate JAR in the + embedded distribution to provide end users with greater flexibility to + handle potential conflicts with the JRE and/or other JARs. (markt) +
fix + 61441: Improve the detection of JAVA_HOME by the + daemon.sh script when running on a platform where Java has + been installed from an RPM. (rjung) +
update + Update the packaged version of the Tomcat Native Library to 1.2.14 to + pick up the latest Windows binaries built with APR 1.6.2 and OpenSSL + 1.0.2l. (markt) +
fix + Update fix for 59904 so that values less than zero are accepted + instead of throwing a NegativeArraySizeException. (remm) +
fix + 61563: Correct typos in Spanish translation. Patch provided by + Gonzalo Vásquez. (csutherl) +
+
+
Tomcat 7.0.81 (violetagg)released 2017-08-16
+
Catalina
+ + +
fix + Correct regression in 7.0.80 that broke WebDAV. (markt) +
+
+
Tomcat 7.0.80 (violetagg)not released
+
Catalina
+ + + + + + + + +
fix + 56785: Avoid NullPointerException if directory + exists on the class path that is not readable by the Tomcat user. + (markt) +
fix + Additional permission for deleting files is granted to JULI as it is + required by FileHandler when running under a Security Manager. The + thread that cleans the log files is marked as daemon thread. + (violetagg) +
fix + 61229: Correct a regression in 7.0.78 that broke WebDAV + handling for resources with names that included a & + character. (markt) +
add + If the Content-Language HTTP header is set directly, + attempt to determine the Locale from the header value and call + ServletResponse.setLocale() with the derived Locale. + (markt) +
fix + 61232: When log rotation is disabled only one separator will + be used when generating the log file name. For example if the prefix is + catalina. and the suffix is .log then the log + file name will be catalina.log instead of + catalina..log. Patch provided by Katya Stoycheva. + (violetagg) +
fix + 61253: Add warn message when Digester.updateAttributes + throws an exception instead of ignoring it. (csutherl) +
fix + 61313: Make the read timeout configurable in the + JNDIRealm and ensure that a read timeout will result in an + attempt to fail over to the alternateURL. Based on patches by Peter + Maloney and Felix Schumacher. (markt) +
+
+
Coyote
+ + + + + +
fix + 61086: Ensure to explicitly signal an empty request body for + HTTP 205 responses. Additional fix to r1795278. Based on a patch + provided by Alexandr Saperov. (violetagg) +
fix + 61322: Correct two regressions caused by the fix for + 60319 when using BIO with an external Executor. Firstly, use + the maxThreads setting from the Executor as the default for + maxConnections if none is specified. Secondly, use + maxThreads from the Executor when calculating the point at + which to disable keep-alive. (markt) +
add + Add additional logging to record problems that occur while waiting for + the NIO pollers to stop during the Connector stop process. (markt) +
fix + Prevent exceptions being thrown during normal shutdown of NIO + connections. This enables TLS connections to close cleanly. (markt) +
+
+
Jasper
+ + +
add + 53031: Add support for the fork option when + compiling JSPs with the Jasper Ant task and javac. (markt) +
+
+
WebSocket
+ + +
add + 57767: Add support to the WebSocket client for following + redirects when attempting to establish a WebSocket connection. Patch + provided by J Fernandez. (markt) +
+
+
Other
+ + +
add + 52791: Add the ability to set the defaults used by the + Windows installer from a configuration file. Patch provided by Sandra + Madden. (markt) +
+
+
Tomcat 7.0.79 (violetagg)released 2017-07-01
+
Catalina
+ + + + + + + + + + + +
fix + 61101: CORS filter should set Vary header in response. + Submitted by Rick Riemer. (remm) +
add + 61105: Add a new JULI FileHandler configuration for + specifying the maximum number of days to keep the log files. + (violetagg) +
fix + Improve the SSLValve so it is able to handle client + certificate headers from Nginx. Based on a patch by Lucas Ventura Carro. + (markt) +
fix + 61154: Allow the Manager and Host Manager web applications to + start by default when running under a security manager. This was + accomplished by adding a custom permission, + org.apache.catalina.security.DeployXmlPermission, that + permits an application to use a META-INF/context.xml file + and then granting that permission to the Manager and Host Manager. + (markt) +
fix + 61173: Polish the javadoc for + o.a.catalina.startup.Tomcat. Patch provided by + peterhansson_se. (violetagg) +
add + A new configuration property crawlerIps is added to the + o.a.catalina.valves.CrawlerSessionManagerValve. Using this + property one can specify a regular expression that will be used to + identify crawlers based on their IP address. Based on a patch provided + by Tetradeus. (violetagg) +
fix + 61180: Log a warning message rather than an information + message if it takes more than 100ms to initialised a + SecureRandom instance for a web application to use to + generate session identifiers. Patch provided by Piotr Chlebda. (markt) +
fix + 61185: When an asynchronous request is dispatched via + AsyncContext.dispatch() ensure that + getRequestURI() for the dispatched request matches that of + the original request. (markt) +
fix + 61201: Ensure that the SCRIPT_NAME environment + variable for CGI executables is populated in a consistent way regardless + of how the CGI servlet is mapped to a request. (markt) +
fix + 61215: Correctly define addConnectorPort and + invalidAuthenticationWhenDeny in the + mbean-descriptors.xml file for the + org.apache.catalina.valves package so that the attributes + are accessible via JMX. (markt) +
+
+
Coyote
+ + + + +
fix + 61086: Explicitly signal an empty request body for HTTP 205 + responses. (markt) +
fix + Revert a change introduced in the fix for bug 60718 that + changed the status code recorded in the access log when the client + dropped the connection from 200 to 500. (markt) +
fix + Make asynchronous error handling more robust. In particular ensure that + onError() is called for any registered + AsyncListeners after an I/O error on a non-container + thread. (markt) +
+
+
Jasper
+ + +
fix + 44787: Improve error message when JSP compiler configuration + options are not valid. (markt) +
+
+
WebSocket
+ + + + +
fix + Correct the log message when a MessageHandler for + PongMessage does not implement + MessageHandler.Whole. (rjung) +
fix + Improve thread-safety of Futures used to report the result + of sending WebSocket messages. (markt) +
fix + 61183: Correct a regression in the previous fix for + 58624 that could trigger a deadlock depending on the locking + strategy employed by the client code. (markt) +
+
+
Web applications
+ + + +
fix + Better document the meaning of the trimSpaces option for Jasper. (markt) +
fix + 61150: Configure the Manager and Host-Manager web + applications to permit serialization and deserialization of + CRSFPreventionFilter related session objects to avoid warning messages + and/or stack traces on web application stop and/or start when running + under a security manager. (markt) +
+
+
Tribes
+ + +
add + Add JMX support for Tribes components. (kfujino) +
+
+
Other
+ + + + + + + +
add + 45832: Add HTTP DIGEST authentication support to the Catalina + Ant tasks used to communicate with the Manager application. (markt) +
fix + 45879: Add the RELEASE-NOTES file to the root of + the installation created by the Tomcat installer for Windows to make it + easier for users to identify the installed Tomcat version. (markt) +
fix + 61076: Document the altDDName attribute for the + Context element. (markt) +
fix + 61145: Add missing @Documented annotation to + annotations in the annotations API. Patch provided by Katya Todorova. + (markt) +
fix + 61146: Add missing lookup() method to + @EJB annotation in the annotations API. Patch provided by + Katya Todorova. (markt) +
fix + Correct typo in Context Container Configuration Reference. + Patch provided by Katya Todorova. (violetagg) +
+
+
Tomcat 7.0.78 (violetagg)released 2017-05-16
+
General
+ + +
add + Allow to exclude JUnit test classes using the build property + test.exclude and document the property in + BUILDING.txt. (rjung) +
+
+
Catalina
+ + + + + + + + + + +
fix + Review those places where Tomcat re-encodes a URI or URI component and + ensure that the correct encoding (path differs from query string) is + applied and that the encoding is applied consistently. (markt) +
fix + Use a more reliable mechanism for the DefaultServlet when + determining if the current request is for custom error page or not. + (markt) +
fix + Ensure that when the Default or WebDAV servlets process an error + dispatch that the error resource is processed via the + doGet() method irrespective of the method used for the + original request that triggered the error. (markt) +
fix + If a static custom error page is specified that does not exist or cannot + be read, ensure that the intended error status is returned rather than a + 404. (markt) +
fix + When the WebDAV servlet is configured and an error dispatch is made to a + custom error page located below WEB-INF, ensure that the + target error page is displayed rather than a 404 response. (markt) +
add + 61047: Add MIME mapping for woff2 fonts in the default + web.xml. Patch provided by Justin Williamson. (violetagg) +
fix + Correct the logic that selects the encoding to use to decode the query + string in the SSIServletExternalResolver so that the + useBodyEncodingForURI attribute of the + Connector is correctly taken into account. (markt) +
fix + 61072: Respect the documentation statements that allow + using the platform default secure random for session id generation. + (remm) +
fix + Correct the javadoc for + o.a.c.connector.CoyoteAdapter#parseSessionCookiesId. + Patch provided by John Andrew (XUZHOUWANG) via Github. (violetagg) +
+
+
Jasper
+ + +
fix + 60925: Improve the handling of access to properties defined + by interfaces when a BeanELResolver is used under a + SecurityManager. (markt) +
+
+
WebSocket
+ + +
fix + 61003: Ensure the flags for reading/writing in + o.a.t.websocket.AsyncChannelWrapperSecure are correctly + reset even if some exceptions occurred during processing. (markt/violetagg) +
+
+
Web applications
+ + + +
add + Document the property test.excludePerformance + in BUILDING.txt. (rjung) +
add + Add documents for maxIdleTime attribute to Channel Receiver + docs. (kfujino) +
+
+
jdbc-pool
+ + + +
code + Refactor the creating a constructor for a proxy class to reduce + duplicate code. (kfujino) +
fix + In StatementFacade, the method call on the statements that + have been closed throw SQLException rather than + NullPointerException. (kfujino) +
+
+
Other
+ + + +
fix + Correct comments about Java 8 in Jre8Compat. + Patch provided by fibbers via Github. (violetagg) +
fix + 60932: Correctly escape single quotes when used in i18n + messages. Based on a patch by Michael Osipov. (markt) +
+
+
Tomcat 7.0.77 (violetagg)released 2017-04-02
+
Catalina
+ + + +
add + 54618: Add support to the + HttpHeaderSecurityFilter for the HSTS preload parameter. + (markt) +
fix + 60911: Ensure NPE will not be thrown when looking for SSL + session ID. Based on a patch by Didier Gutacker. (violetagg) +
+
+
Coyote
+ + + + +
fix + When using the NIO2 connector, ensure a WebSocket close frame is + processed before the end of stream is processed to ensure that the end + of stream is processed correctly. (markt) +
fix + 60852: Correctly spell compressible when used in + configuration attributes and internal code. Based on a patch by Michael + Osipov. (markt) +
fix + Improve sendfile handling when requests are pipelined. (markt) +
+
+
Jasper
+ + + +
fix + Improve the error handling for simple tags to ensure that the tag is + released and destroyed once used. (remm, violetagg) +
fix + 60844: Correctly handle the error when fewer parameter values + than required by the method are used to invoke an EL method expression. + Patch provided by Daniel Gray. (markt) +
+
+
jdbc-pool
+ + +
fix + 60764: Implement equals() and + hashCode() in the StatementFacade in order to + enable these methods to be called on the closed statements if any + statement proxy is set. This behavior can be changed with + useStatementFacade attribute. (kfujino) +
+
+
Tomcat 7.0.76 (markt)released 2017-03-16
+
Catalina
+ + + + + + + + + + + +
code + Make it easier for sub-classes of Tomcat to modify the + default web.xml settings by over-riding + getDefaultWebXmlListener(). Patch provided by Aaron + Anderson. (markt) +
fix + Reduce the contention in the default InstanceManager + implementation when multiple threads are managing objects and need to + reference the annotation cache. (markt) +
code + 60674: Remove final marker from + CorsFilter to enable sub-classing. (markt) +
fix + 60683: Security manager failure causing NPEs when doing IO + on some JVMs. (csutherl) +
fix + 60688: Update the internal fork of Apache Commons BCEL to + r1782855 to add early access Java 9 support to the annotation scanning + code. (markt) +
fix + 60718: Improve error handling for asynchronous processing and + correct a number of cases where the requestDestroyed() + event was not being fired and an entry wasn't being made in the access + logs. (markt) +
fix + 60808: Ensure that the Map returned by + ServletRequest.getParameterMap() is fully immutable. Based + on a patch provided by woosan. (markt) +
fix + 60824: Correctly cache the Subject in the + session - if there is a session - when running under a + SecurityManager. Patch provided by Jan Engehausen. (markt) +
fix + Ensure request and response facades are used when firing application + listeners. (markt/remm) +
fix + When HTTP TRACE requests are disabled on the Connector, ensure that the + HTTP OPTIONS response from the WebDAV servlet does not include + TRACE in the returned Allow header. (markt) +
+
+
Coyote
+ + + +
fix + Ensure that executor thread pools used with connectors pre-start the + configured minimum number of idle threads. (markt) +
add + 60594: Allow some invalid characters that were recently + restricted to be processed in requests by using the system property + tomcat.util.http.parser.HttpParser.requestTargetAllow. + (csutherl) +
+
+
Jasper
+ + +
fix + Refactor code generated for JSPs to reduce the size of the code required + for tags. (markt) +
+
+
Cluster
+ + + +
add + Make the accessTimeout configurable in + ClusterSingleSignOn. The accessTimeout is used + as a timeout period for PING in replication map. (kfujino) +
fix + 60806: To avoid ClassNotFoundException, make + sure that the web application class loader is passed to + ReplicatedContext. (kfujino) +
+
+
WebSocket
+ + +
fix + 60617: Correctly create a CONNECT request when + establishing a WebSocket connection via a proxy. Patch provided by + Svetlin Zarev. (markt) +
+
+
Tribes
+ + + +
fix + Ensure that NoRpcChannelReply messages are not received on + RpcCallback. (kfujino) +
fix + 60722: Take account of the + dispatchersUseEncodedPaths setting on the current + Context when generating paths for dispatches triggered + by AsyncContext.dispatch(). (markt) +
+
+
Other
+ + + + + + +
fix + 60620: Fix configuration of Eclipse projects, broken by + introduction of SafeForkJoinWorkerThreadFactory helper + class. This class cannot be built with Java 6. (kkolinko) +
update + Update the packaged version of the Tomcat Native Library to 1.2.12 to + pick up the latest Windows binaries built with OpenSSL 1.0.2k. (violetagg) +
add + 60784: Update all unit tests that test the HTTP status line + to check for the required space after the status code. Patch provided by + Michael Osipov. (markt) +
update + Update the NSIS Installer used to build the Windows installer to version + 3.01. (markt) +
fix + Refactor the build script and the NSIS installer script so that either + NSIS 2.x or NSIS 3.x can be used to build the installer. This is + primarily to re-enable building the installer on the Linux based CI + system where the combination of NSIS 3.x and wine leads to failed + installer builds. (markt) +
+
+
Tomcat 7.0.75 (violetagg)released 2017-01-24
+
Cluster
+ + +
add + Make the accessTimeout configurable in + BackupManager. The accessTimeout is used as a + timeout period for PING in replication map. (kfujino) +
+
+
Web applications
+ + +
fix + Ensure the ASF logo image is correctly displayed in docs and + host-manager applications. (violetagg) +
+
+
Tomcat 7.0.74 (violetagg)not released
+
Catalina
+ + + + + + + + + + + +
add + 53602: Add HTTP status code 451 (RFC 7725) to the list of + HTTP status codes recognised by Tomcat. (markt) +
fix + Correctly handle the configClass attribute of a Host when + embedding Tomcat. (markt) +
fix + 60379: Dispose of the GSS credential once it is no longer + required. Patch provided by Michael Osipov. (markt) +
fix + 60380: Ensure that a call to + HttpServletRequest#logout() triggers a call to + TomcatPrincipal#logout(). Based on a patch by Michael + Osipov. (markt) +
fix + 60387: Correct the javadoc for + o.a.catalina.AccessLog.setRequestAttributesEnabled. + The default value is different for the different implementations. + (violetagg) +
code + 60393: Use consistent parameter naming in implementations of + Realm#authenticate(GSSContext, boolean). (markt) +
fix + 60395: Log when an Authenticator passes an + incomplete GSSContext to a Realm since it indicates a bug + in the Authenticator. Patch provided by Michael Osipov. + (markt) +
update + Update the warnings that reference required options for running on Java + 9 to use the latest syntax for those options. (markt) +
fix + 60513: Fix thread safety issue with RMI cleanup code. (remm) +
add + 60620: + Extend the JreMemoryLeakPreventionListener to provide + protection against ForkJoinPool.commonPool() related memory + leaks. (markt) +
+
+
Coyote
+ + + + + + +
fix + Ensure that the endpoint is able to unlock the acceptor thread during + shutdown if the endpoint is configured to listen to any local address + of a specific type such as 0.0.0.0 or ::. + (markt) +
fix + Ensure sendfile is enabled by default for APR. (markt) +
fix + Prevent read time out when the file is deleted while serving the + response. The issue was observed only with APR Connector and + sendfile enabled. (violetagg) +
fix + Improve the logic that selects an address to use to unlock the Acceptor + to take account of platforms what do not listen on all local addresses + when configured with an address of 0.0.0.0 or + ::. (markt) +
fix + 60409: When unable to complete sendfile request, ensure the + Processor will be added to the cache only once. (markt/violetagg) +
+
+
Jasper
+ + + + + + + + +
add + 44294: Add support for varargs in UEL expressions. (markt) +
fix + 60356: Fix pre-compilation of JSPs that depend on nested tag + files packaged in a JAR. (markt) +
fix + 60431: Improve handling of varargs in UEL expressions. Based + on a patch by Ben Wolfe. (markt) +
fix + 60497: Restore previous tag reuse behavior following the use + of try/finally. (remm) +
fix + Improve the error handling for simple tags to ensure that the tag is + released and destroyed once used. (remm) +
fix + 60497: Follow up fix using a better variable name for the + tag reuse flag. (remm) +
fix + Revert use of try/finally for simple tags. (remm) +
+
+
Web applications
+ + + + +
fix + Correct a typo in Host Configuration Reference. + Issue reported via comments.apache.org. (violetagg) +
add + In the documentation web application, be explicit that clustering + requires a secure network for all of the cluster network traffic. + (markt) +
update + Update the ASF logos to the new versions. +
+
+
Tribes
+ + + + +
fix + Reduce the warning logs for a message received from a different domain + in order to avoid excessive log outputs. (kfujino) +
add + Add log message that PING message has received beyond the timeout + period. (kfujino) +
fix + When a PING message that beyond the time-out period has been received, + make sure that valid member is added to the map membership. (kfujino) +
+
+
WebSocket
+ + +
fix + 60437: Avoid possible handshake overflows in the websocket + client. (remm) +
+
+
jdbc-pool
+ + + + + +
add + 58816: Implement the statistics of jdbc-pool. The stats infos + are borrowedCount, returnedCount, + createdCount, releasedCount, + reconnectedCount, releasedIdleCount and + removeAbandonedCount. (kfujino) +
fix + 60194: If validationQuery is not specified, + connection validation is done by calling the isValid() + method. (kfujino) +
fix + 60398: Fix testcase of TestSlowQueryReport. + (kfujino) +
add + Enable reset the statistics without restarting the pool. (kfujino) +
+
+
Other
+ + + + + +
fix + 60366: Change catalina.bat to use directly + LOGGING_MANAGER and LOGGING_CONFIG variables + in order to configure logging, instead of modifying + JAVA_OPTS. Patch provided by Petter Isberg. (violetagg) +
add + New property is added test.verbose in order to control + whether the output of the tests is displayed on the console or not. + Patch provided by Emmanuel Bourg. (violetagg) +
update + Update the ASF logos used in the Apache Tomcat installer for Windows to + use the new versions. +
fix + Spelling corrections provided by Josh Soref. (violetagg) +
+
+
Tomcat 7.0.73 (violetagg)released 2016-11-14
+
Catalina
+ + + + + + + + +
fix + 60117: Ensure that the name of LogLevel is + localized when using OneLineFormatter. Patch provided by + Tatsuya Bessho. (kfujino) +
add + 60151: Improve the exception error messages when a + ResourceLink fails to specify the type, specifies an + unknown type or specifies the wrong type. (markt) +
fix + 60167: Ignore empty lines in /etc/passwd files + when using the PasswdUserDatabase. (markt) +
fix + Improve the access checks for linked global resources to handle the case + where the current class loader is a child of the web application class + loader. (markt) +
fix + 60199: Log a warning if deserialization issues prevent a + session attribute from being loaded. (markt) +
fix + Correctly test for control characters when reading the provided shutdown + password. (markt) +
fix + When configuring the JMX remote listener, specify the allowed types for + the credentials. (markt) +
+
+
Coyote
+ + + + + + + + +
fix + 60123: Avoid potential threading issues that could cause + excessively large vales to be returned for the processing time of + a current request. (markt) +
fix + 60174: Log instances of HeadersTooLargeException + during request processing. (markt) +
fix + Correct the HTTP header parser so that DEL is not treated as a valid + token character. (markt) +
fix + 60319: When using an Executor, disconnect it from the + Connector attributes maxThreads, + minSpareThreads and threadPriority to enable + the configuration settings to be consistently reported. These Connector + attributes will be reported as -1 when an Executor is in + use. The values used by the executor may be set and obtained via the + Executor. (markt) +
fix + If an I/O error occurs during async processing on a non-container + thread, ensure that the onError() event is triggered. + (markt) +
fix + Improve detection of I/O errors during async processing on non-container + threads and trigger async error handling when they are detected. (markt) +
add + Add additional checks for valid characters to the HTTP request line + parsing so invalid request lines are rejected sooner. (markt) +
+
+
Web applications
+ + + + + + + +
add + Add an example of using the classesToInitialize attribute + of the JreMemoryLeakPreventionListener to the documentation + web application. Based on a patch by Cris Berneburg. (markt) +
fix + 60192: Correct a typo in the status output of the Manager + application. Patch provided by Radhakrishna Pemmasani. (markt) +
fix + Correct a typo in HTTP Connector How-To. + Issue reported via comments.apache.org. (violetagg) +
fix + Fix default value of validationInterval attribute in + jdbc-pool. (kfujino) +
fix + Correct a typo in CGI How-To. + Issue reported via comments.apache.org. (violetagg) +
fix + 60344: Add a note to BUILDING.txt regarding using the source + bundle with the correct line endings. (markt) +
+
+
Tribes
+ + +
fix + When the proxy node sends a backup retrieve message, ensure that using + the channelSendOptions that has been set rather than the + default channelSendOptions. (kfujino) +
+
+
jdbc-pool
+ + + +
fix + 60099: Ensure that use all method arguments as a cache key + when using StatementCache. (kfujino) +
fix + 60139: Correct Javadocs for + PoolConfiguration.getValidationInterval and + setValidationInterval. Reported by Phillip Webb. (kfujino) +
+
+
Other
+ + +
add + Add documentation to the bin/catalina.bat script to remind users that + environment variables don't affect the configuration of Tomcat when + run as a Windows Service. Based upon a documentation patch by + James H.H. Lampert. (schultz) +
+
+
Tomcat 7.0.72 (violetagg)released 2016-09-19
+
Catalina
+ + +
fix + Ensure Digester.useContextClassLoader is considered in + case the class loader is used. (violetagg) +
+
+
Jasper
+ + +
fix + 60101: Remove preloading of the class that was deleted. + (violetagg) +
+
+
jdbc-pool
+ + + +
fix + Notify jmx when returning the connection that has been marked suspect. + (kfujino) +
fix + Ensure that the POOL_EMPTY notification has been added to + the jmx notification types. (kfujino) +
+
+
Other
+ + + +
update + Update the packaged version of the Tomcat Native Library to 1.2.10 to + pick up the latest Windows binaries built with OpenSSL 1.0.2j. (markt) +
update + 61599: Update to Commons Daemon 1.1.0 for improved Java 9 + support. (markt) +
+
+
Tomcat 7.0.71 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + +
fix + 57705: Add debug logging for requests denied by the remote + host and remote address valves and filters. Based on a patch by Graham + Leggett. (markt) +
update + Change the default of the + sessionCookiePathUsesTrailingSlash attribute of the + Context element to false since the problems + caused when a Servlet is mapped to /* are more significant + than the security risk of not enabling this option by default. (markt) +
fix + 59708: Modify the LockOutRealm logic. Valid authentication + attempts during the lock out period will no longer reset the lock out + timer to zero. (markt) +
fix + Improve error handling around user code prior to calling + InstanceManager.destroy() to ensure that the method is + executed. (markt) +
fix + Ensure that reading the singleThreadModel attribute of a + StandardWrapper via JMX does not trigger initialisation of + the associated servlet. With some frameworks this can trigger an + unexpected initialisation thread and if initilisation is not thread-safe + the initialisation can then fail. (markt) +
fix + By default, treat paths used to obtain a request dispatcher as encoded. + This behaviour can be changed per web application via the + dispatchersUseEncodedPaths attribute of the Context. + (markt) +
fix + 59839: Apply roleSearchAsUser to all nested searches + in JNDIRealm. (fschumacher) +
add + Provide a mechanism that enables the container to check if a component + (typically a web application) has been granted a given permission when + running under a SecurityManager without the current execution stack + having to have passed through the component. Use this new mechanism to + extend SecurityManager protection to the system property replacement + feature of the digester. (markt) +
add + When retrieving an object via a ResourceLink, ensure that + the object obtained is of the expected type. (markt) +
fix + 59866: When scanning WEB-INF/classes for + annotations, don't scan the contents of + WEB-INF/classes/META-INF (if present) since classes will + never be loaded from that location. (markt) +
fix + 59912: Fix an edge case in input stream handling where an + IOException could be thrown when reading a POST body. + (markt) +
fix + 59966: Do not start the web application if the error page + configuration in web.xml is invalid. (markt) +
fix + Switch the CGI servlet to the standard logging mechanism and remove + support for the debug attribute. (markt) +
add + Add a new initialisation parameter, envHttpHeaders, to + the CGI Servlet to mitigate httpoxy + (CVE-2016-5388) by default and to provide a mechanism that can be + used to mitigate any future, similar issues. (markt) +
add + When adding and removing ResourceLinks dynamically, ensure + that the global resource is only visible via the + ResourceLinkFactory when it is meant to be. (markt) +
fix + 60008: When processing CORs requests, treat any origin with a + URI scheme of file as a valid origin. (markt) +
fix + Improve handling of exceptions during a Lifecycle events triggered by a + state transition. The exception is now caught and the component is now + placed into the FAILED state. (markt) +
fix + Fix a file descriptor leak when reading the global web.xml. (markt) +
fix + 60041: Better error message if a JAR is deleted while a web + application is running. Note: Deleting a JAR while the application is + running is not supported and errors are expected. Based on a patch by + gehui. (markt) +
+
+
Coyote
+ + + + + +
fix + Improve error handling around user code prior to calling + InstanceManager.destroy() to ensure that the method is + executed. (markt) +
fix + 59904: Add a limit (default 200) for the number of cookies + allowed per request. Based on a patch by gehui. (markt) +
fix + Make timing attacks against the Realm implementations harder. (schultz) +
add + Refactor the code that implements the requirement that a call to + complete() or dispatch() made from a + non-container thread before the container initiated thread that called + startAsync() completes must be delayed until the container + initiated thread has completed. Rather than implementing this by + blocking the non-container thread, extend the internal state machine to + track this. This removes the possibility that blocking the non-container + thread could trigger a deadlock. (markt) +
+
+
Jasper
+ + + + +
fix + Improve error handling around user code prior to calling + InstanceManager.destroy() to ensure that the method is + executed. (markt) +
fix + Improve the error handling for custom tags to ensure that the tag is + returned to the pool or released and destroyed once used. (markt) +
fix + Fixed StringIndexOutOfBoundsException. Based on a patch provided by + wuwen via Github. (violetagg) +
+
+
WebSocket
+ + + + +
fix + Improve error handling around user code prior to calling + InstanceManager.destroy() to ensure that the method is + executed. (markt) +
fix + 59868: Clarify the documentation for the Manager web + application to make clearer that the host name and IP address in the + server section are the primary host name and IP address. (markt) +
fix + 59908: Ensure that a reason phrase is included in the close + message if a session is closed due to a timeout. (markt) +
+
+
Web Applications
+ + + + + + +
fix + Do not log an additional case of IOExceptions in the + error handler for the Drawboard WebSocket example when the root cause is + the client disconnecting since the logs add no value. (markt) +
fix + 59642: Mention the localDataSource in the + DataSourceRealm section of the Realm How-To. (markt) +
fix + Follow-up to the fix for 59399. Ensure that the new attribute + transportGuaranteeRedirectStatus is documented for all + Realms. Also document the NullRealm and + when it is automatically created for an Engine. (markt) +
fix + MBeans Descriptors How-To is moved to + mbeans-descriptors-howto.html. Patch provided by Radoslav + Husar. (violetagg) +
fix + 60034: Correct a typo in the Manager How-To page of the + documentation web application. (markt) +
+
+
Tribes
+ + + +
add + Add log message when the ping has timed-out. (kfujino) +
fix + If the ping message has been received at the + AbstractReplicatedMap#leftOver method, ensure that notify + the member is alive than ignore it. (kfujino) +
+
+
jdbc-pool
+ + + + + + + + + + + +
fix + Fix the duplicated connection release when connection verification + failed. (kfujino) +
fix + Ensure that do not remove the abandoned connection that has been already + released. (kfujino) +
fix + In order to avoid the unintended skip of PoolCleaner, + remove the check code of the execution interval in the task that has + been scheduled. (kfujino) +
fix + 59849: Ensure that the connection verification is executed by + initSQL (if required) if the borrowing + PooledConnection has not been initialized. (kfujino) +
fix + 59850: Ensure that the ResultSet is closed when + enabling the StatementCache interceptor. (kfujino) +
fix + 59923: Reduce the default value of + validationInterval in order to avoid the potential issue + that continues to return an invalid connection after database restart. + (kfujino) +
fix + Ensure that the ResultSet is returned as Proxy object when + enabling the StatementDecoratorInterceptor. (kfujino) +
fix + 60043: Ensure that the suspectTimeout works + without removing connection when the removeAbandoned is + disabled. (kfujino) +
fix + Add log message of when returning the connection that has been marked + suspect. (kfujino) +
fix + Correct Javadoc for ConnectionPool.suspect(). Based on a + patch by Yahya Cahyadi. (markt) +
+
+
Other
+ + + + + + + + +
add + Use the mirror network rather than the ASF master site to download the + current ASF dependencies. (markt) +
update + Update the packaged version of the Tomcat Native Library to 1.2.8 to + pick up the latest fixes and make 1.2.8 the minimum recommended version. + (markt) +
fix + Fixed typos in mbeans-descriptors.xml files. (violetagg) +
update + Update the internal fork of Commons BCEL to r1757132 to align with the + BCEL 6 release. (markt) +
update + Update the internal fork of Commons Codec to r1757174. Code formatting + changes only. (markt) +
update + Update the internal fork of Commons FileUpload to afdedc9. This pulls in + a fix to improve the performance with large multipart boundaries. + (markt) +
fix + Update the download location for Objenesis. (violetagg) +
+
+
Tomcat 7.0.70 (violetagg)released 2016-06-20
+
Catalina
+ + + + + + + + + + + + + + +
fix + 59219: Ensure AsyncListener.onError() is called + if an Exception is thrown during async processing. (markt) +
fix + 59220: Ensure that AsyncListener.onComplete() is + called if the async request times out and the response is already + committed. (markt) +
fix + 59261: ServletRequest.getAsyncContext() now + throws an IllegalStateException as required by the Servlet + specification if the request is not in asynchronous mode when called. + (markt) +
fix + 59310: Do not add a Content-Length: 0 header for + custom responses to HEAD requests that do not set a + Content-Length value. (markt) +
fix + When normalizing paths, improve the handling when paths end with + /. or /.. and ensure that input and output are + consistent with respect to whether or not they end with /. + (markt) +
fix + 59317: Ensure that + HttpServletRequest.getRequestURI() returns an encoded URI + rather than a decoded URI after a dispatch. (markt) +
fix + Ensure that the value for the header X-Frame-Options is + constructed correctly according to the specification when + ALLOW-FROM option is used. (violetagg) +
add + 59399: Add a new option to the Realm implementations that + ship with Tomcat that allows the HTTP status code used for HTTP -> HTTPS + redirects to be controlled per Realm. (markt) +
fix + 59449: In ContainerBase, ensure that the process + to remove a child container is the reverse of the process to add one. + Patch provided by Huxing Zhang. (markt) +
fix + RMI Target related memory leaks are avoidable which makes them an + application bug that needs to be fixed rather than a JRE bug to work + around. Therefore, start logging RMI Target related memory leaks on web + application stop. Add an option that controls if the check for these + leaks is made. Log a warning if running on Java 9 with this check + enabled but without the command line option it requires. (markt) +
fix + Fix a potential concurrency issue with the web application class loader + and concurrent reads and writes of the resource cache. (markt) +
fix + 59619: Within the web application class loader, always use + path as the key for the resource cache to improve the hit ratio. This + also fixes a problem exposed by the fix for 56777 that + enabled file based configuration resources to be loaded from the class + path. (markt) +
fix + Fix error message when failed to register MBean. (kfujino) +
+
+
Coyote
+ + + + + + +
fix + 58970: Fix a connection counting bug in the NIO connector + that meant some dropped connections were not removed from the current + connection count. (markt) +
fix + 59289: Do not recycle upgrade processors in unexpected close + situations. (remm) +
fix + Ensure that requests with HTTP method names that are not tokens (as + required by RFC 7231) are rejected with a 400 response. (markt) +
fix + When an asynchronous request is processed by the AJP connector, ensure + that request processing has fully completed before starting the next + request. (markt) +
fix + If an async dispatch results in the completion of request processing, + ensure that any remaining request body is swallowed before starting the + processing of the next request else the remaining body may be read as the + start of the next request leading to a 400 response. (markt) +
+
+
Jasper
+ + + +
fix + Fix a memory leak in the expression language implementation that caused + the class loader of the first web application to use expressions to be + pinned in memory. (markt) +
fix + 59654: Enforce the requirements of section 7.3.1 of the JSP + specification regarding the permitted locations for TLD files. Patch + provided by Huxing Zhang. (markt) +
+
+
WebSocket
+ + +
fix + Ensure that a client disconnection triggers the error handling for the + associated WebSocket end point. (markt) +
+
+
Web Applications
+ + + +
fix + Correct a typo in SSL/TLS Configuration How-To. + Issue reported via comments.apache.org. (violetagg) +
fix + 58891: Update the SSL how-to. Based on a suggestion by + Alexander Kjäll. (markt) +
+
+
Tribes
+ + + + + + + + + + + +
fix + Fix potential NPE that depends on the setting order of attributes of + static member when using the static cluster. (kfujino) +
add + Add get/set method for the channel that is related to + ChannelInterceptorBase. (kfujino) +
fix + As with the multicast cluster environment, in the static cluster + environment, the local member inherits properties from the cluster + receiver. (kfujino) +
add + Add get/set method for the channel that is related to each Channel + services. (kfujino) +
add + Add name to channel in order to identify channels. In tomcat cluster + environment, it is set the cluster name + "-Channel" as default value. + (kfujino) +
add + Add the channel name to the thread which is invoked by channel services + in order to identify the associated channel. (kfujino) +
fix + Ensure that clear the channel instance from channel services when + stopping channel. (kfujino) +
add + Implement map state in the replication map. (kfujino) +
fix + Ensure that the ping is not executed during the start/stop of the + replication map. (kfujino) +
fix + In ping processing in the replication map, send not the + INIT message but the newly introduced PING + message. (kfujino) +
+
+
jdbc-pool
+ + +
fix + Fix a memory leak with the pool cleaner thread that retained a reference + to the web application class loader for the first web application to use + a connection pool. (markt) +
+
+
Other
+ + + + + +
update + Update the packaged version of the Tomcat Native Library to 1.2.7 to + pick up the Windows binaries that are based on OpenSSL 1.0.2h and APR + 1.5.2. (violetagg/markt) +
update + Remove native code (Windows Service Wrapper, APR/native connector) + support for Windows Itanium. (markt) +
update + Update the internal fork of Commons File Upload to r1743698 (1.3.1 plus + additional fixes). (markt) +
fix + 58626: Add support for a new environment variable + (USE_NOHUP) that causes nohup to be used when + starting Tomcat. It is disabled by default except on HP-UX where it is + enabled by default since it is required when starting Tomcat at boot on + HP-UX. (markt) +
+
+
Tomcat 7.0.69 (violetagg)released 2016-04-15
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + +
fix + Fix the type of InstanceManager attribute of mbean + definition of StandardContext. (kfujino) +
add + 58351: Make the server build date and server version number + accessible via JMX. Patch provided by Huxing Zhang. (markt) +
fix + 59001: Correctly handle the case when Tomcat is installed on + a path where one of the segments ends in an exclamation mark. (markt) +
fix + Expand the fix for 59001 to cover the special sequences used + in Tomcat's custom jar:war: URLs. (markt) +
fix + 59043: Avoid warning while expiring sessions associated with + a single sign on if HttpServletRequest.logout() is used. + (markt) +
fix + 59054: Ensure that using the + CrawlerSessionManagerValve in a distributed environment + does not trigger an error when the Valve registers itself in the + session. (markt) +
add + Log a warning message if a user tries to configure the default session + timeout via the deprecated (and ignored) + Manager.setMaxInactiveInterval() method. (markt) +
fix + Correct a regression introduced in 7.0.68 where the deprecated + Manager.getMaxInactiveInterval() method returned the + current default session timeout in minutes rather than seconds. (markt) +
fix + When a Host is configured with an appBase that does not exist, create + the appBase before trying to expand an external WAR file into it. + (markt) +
fix + 59115: When using the Servlet 3.0 file upload, the submitted + file name may be provided as a token or a quoted-string. If a + quoted-string, unquote the string before returning it to the user. + (markt) +
fix + 59123: Close NamingEnumeration objects used by + the JNDIRealm once they are no longer required. + (fschumacher/markt) +
fix + 59138: Correct a false positive warning for ThreadLocal + related memory leaks when the key class but not the value class has been + loaded by the web application class loader. (markt) +
fix + 59145: Don't log an invalid warning when a user logs out of + a session associated with SSO. (markt) +
fix + 59151: Fix a regression in the fix for 56917 that + added additional (and arguably unnecessary) validation to the provided + redirect location. (markt) +
fix + 59206: Ensure NPE will not be thrown by + o.a.tomcat.util.file.ConfigFileLoader when + catalina.base is not specified. (violetagg) +
fix + 59213: Async dispatches should be based off a wrapped request. + (remm) +
fix + 59217: Remove duplication in the recycling of the path in + o.a.tomcat.util.http.ServerCookie. Patch is provided by + Kyohei Nakamura. (violetagg) +
fix + Ensure that javax.servlet.ServletRequest and + javax.servlet.ServletResponse provided during + javax.servlet.AsyncListener registration are made + available via javax.servlet.AsyncEvent.getSuppliedRequest + and javax.servlet.AsyncEvent.getSuppliedResponse + (violetagg) +
fix + Clarify the log message that specifying both urlPatterns and value + attributes in WebServlet and WebFilter annotations is not allowed. + (violetagg) +
fix + Ensure the exceptions caused by Valves will be available in the log + files so that they can be evaluated when + o.a.catalina.valves.ErrorReportValve.showReport is + disabled. Patch is provided by Svetlin Zarev. (violetagg) +
fix + 59247: Preload ResourceEntry as a workaround for security + manager issues on some JVMs. (kkolinko/remm) +
fix + 59269: Correct the implementation of + PersistentManagerBase so that minIdleSwap + functions as designed and sessions are swapped out to keep the active + session count below maxActiveSessions. (markt) +
+
+
Coyote
+ + + + + +
fix + 58646: Correct a problem with sendfile that resulted in a + Processor being added to the cache twice leading to broken responses. + (markt) +
fix + 59015: Fix potential cause of endless APR Poller loop during + shutdown if the Poller experiences an error during the shutdown process. + (markt) +
fix + Limit the default TLS ciphers for JSSE (BIO, NIO) and OpenSSL (APR) to + those currently considered secure. (markt) +
add + Add a new environment variable JSSE_OPTS that is intended + to be used to pass JVM wide configuration to the JSSE implementation. + The default value is -Djdk.tls.ephemeralDHKeySize=2048 + which protects against weak Diffie-Hellman keys. (markt) +
+
+
WebSocket
+ + + + + + + +
fix + 59014: Ensure that a WebSocket close message can be sent + after a close message has been received. (markt) +
fix + Correctly handle compression of partial messages when the final message + fragment has a zero length payload. (markt) +
add + Extend the WebSocket programmatic echo endpoint provided in the examples + to handle binary messages and also partial messages. This aligns the + code with Tomcat 8 and makes it easier to run the Autobahn testsuite + against the WebSocket implementation. (markt) +
fix + 59119: Correct read logic for WebSocket client when using + secure connections. (markt) +
fix + 59134: Correct client connect logic for secure connections + made through a proxy. (markt) +
fix + 59189: Explicitly release the native memory held by the + Inflater and Deflater when using + PerMessageDeflate and the WebSocket session ends. Based on a patch by + Henrik Olsson. (markt) +
+
+
Web Applications
+ + + + + + +
fix + Correct the description of the + ServletRequest.getServerPort() in Proxy How-To. + Issue reported via comments.apache.org. (violetagg) +
fix + Fix a potential indefinite wait in the Comet Chat servlet in the + examples web application. (markt) +
fix + 59229: Fix error in HTTP docs and make clear that the HTTP NIO + connector uses non-blocking I/O to read the HTTP request headers. + (markt) +
fix + Update in the documentation the link to the maven repository where + Tomcat snapshot artifacts are deployed. (markt/violetagg) +
fix + Clarify in the documentation that calls to + ServletContext.log(String, Throwable) or + GenericServlet.log(String, Throwable) are logged at the + SEVERE level. (violetagg) +
+
+
Tribes
+ + + + + +
fix + If promoting a proxy node to a primary node when getting a session, + notify the change of the new primary node to the original backup node. + (kfujino) +
fix + Avoid NPE when a proxy node failed to retrieve a backup entry. (kfujino) +
add + Add log of when received an unexpected messages. (kfujino) +
add + Add the flag indicating that member is a localMember. (kfujino) +
+
+
Other
+ + + + + + +
fix + 58283: Change the default download location for libraries + during the build process from /usr/share/java to + ${user.home}/tomcat-build-libs. Patch provided by + Ahmed Hosni. (markt) +
fix + 59031: When using the Windows uninstaller, do not remove the + contents of any directories that have been symlinked into the Tomcat + directory structure. (markt) +
update + Modify the default tomcat-users.xml file to make it harder + for users to configure the entries intended for use with the examples + web application for the Manager application. (markt) +
fix + 59211: Add hamcrest to Eclipse classpath. Patch is provided + by Huxing Zhang. (violetagg) +
update + 59280: Update the NSIS Installer used to build the + Windows Installers to version 2.51. (kkolinko) +
+
+
Tomcat 7.0.68 (violetagg)released 2016-02-16
+
General
+ + +
add + Allow to configure multiple JUnit test class patterns with the build + property test.name and document the property in + BUILDING.txt. (rjung) +
+
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + Correct implementation of + validateClientProvidedNewSessionId so client provided + session IDs may be rejected if validation is enabled. (markt) +
fix + 56785: Avoid NullPointerException if directory + exists on the class path that is not readable by the Tomcat user. + (kkolinko) +
fix + 57906: Suppress WebappClassLoader log messages when running + with a security manager on Java 6, caused by + java.beans.Introspector.findExplicitBeanInfo() calls + during evaluation of EL expressions. (kkolinko) +
fix + 58692: Make StandardJarScanner more robust. Log + a warning if a class path entry cannot be scanned rather than triggering + the failure of the web application. (markt) +
fix + 58701: Reset the instanceInitialized field in + StandardWrapper when unloading a Servlet so that a new + instance may be correctly initialized. (markt) +
fix + 58702: Ensure an access log entry is generated if the client + aborts the connection. (markt) +
fix + Fixed various issues reported by Findbugs. (violetagg) +
fix + 58735: Add support for the X-XSS-Protection + header to the HttpHeaderSecurityFilter. Patch provided by + Jacopo Cappellato. (markt) +
fix + 58751: Correctly handle the case where an + AsyncListener dispatches to a Servlet on an asynchronous + timeout and the Servlet uses sendError() to trigger an + error page. Includes a test case based on code provided by Andy + Wilkinson.(markt) +
fix + 58765: Change default for + mapperContextRootRedirectEnabled to true since + this is required for correct session management because of the default + for sessionCookiePathUsesTrailingSlash. (markt) +
fix + Add the StatusManagerServlet to the list of Servlets that + can only be loaded by privileged applications. (markt) +
fix + Simplify code and fix messages in + org.apache.catalina.core.DefaultInstanceManager class. + (kkolinko) +
fix + Ensure that the proper file encoding if specified will be used when + a readme file is served by DefaultServlet. (violetagg) +
fix + Fix declaration of localPort attribute of Connector MBean: + it is read-only. (kkolinko) +
fix + 58766: Make skipping non-class files during annotation + scanning faster by checking the file name first. Improve debug logging. + (kkolinko) +
fix + 58768: Log a warning if a redirect fails because of an + invalid location. (markt) +
fix + 58836: Correctly merge query string parameters when + processing a forwarded request where the target includes a query string + that contains a parameter with no value. (markt/kkolinko) +
fix + Make sure that shared Digester is reset in an unlikely error case + in HostConfig.deployWAR(). (kkolinko) +
fix + Fix a potential JDBC resource leak in DataSourceRealm. (schultz) +
fix + 58900: Correctly undeploy symlinked resources and prevent an + infinite cycle of deploy / undeploy. (markt) +
fix + Protect initialization of ResourceLinkFactory when + running with a SecurityManager. (kkolinko) +
add + Extend the feature available in the cluster session manager + implementations that enables session attribute replication to be + filtered based on attribute name to all session manager implementations. + Note that configuration attribute name has changed from + sessionAttributeFilter to + sessionAttributeNameFilter. Apply the filter on load as + well as unload to ensure that configuration changes made while the web + application is stopped are applied to any persisted data. (markt) +
add + Extend the session attribute filtering options to include filtering + based on the implementation class of the value and optional + WARN level logging if an attribute is filtered. These + options are available for all of the Manager implementations that ship + with Tomcat. When a SecurityManager is used filtering will + be enabled by default. (markt) +
fix + 58905: Ensure that Tomcat.silence() silences the + correct logger and respects the current setting. (markt) +
fix + 58946: Ensure that the request parameter map remains + immutable when processing via a RequestDispatcher. (markt) +
+
+
Coyote
+ + +
add + New configuration option ajpFlush for the AJP connectors + to disable the sending of AJP flush packets. (rjung) +
+
+
Jasper
+ + + +
fix + Fix handling of missing messages in + org.apache.el.util.MessageFactory. (violetagg) +
fix + Ignore engineOptionsClass and scratchdir when + running under a security manager. (markt) +
+
+
Cluster
+ + +
fix + In order to avoid that the heartbeat thread and the background thread to + run Channel.heartbeat simultaneously, if + heartbeatBackgroundEnabled of SimpleTcpCluster + set to true, ensure that the heartbeat thread does not + start. (kfujino) +
+
+
WebSocket
+ + + +
fix + 57489: Ensure onClose() is called when a + WebSocket connection is closed even if the sending of the close message + fails. Includes test cases by Barry Coughlan. (markt) +
fix + Fix a timing issue on session close that could result in an exception + being thrown for an incomplete message even through the message was + completed. (markt) +
+
+
Web Applications
+ + + + + + + +
fix + Correct some typos in the JNDI resources How-To. (markt) +
fix + Don't create sessions unnecessarily in the Manager application. (markt) +
fix + Don't create sessions unnecessarily in the Host Manager application. + (markt) +
fix + 58723: Clarify documentation and error messages for the text + interface of the manager to make clear that version must be used with + path when referencing contexts deployed using parallel deployment. + (markt) +
fix + Correct an error in the documentation of the expected behaviour for + automatic deployment. If a WAR is updated and an expanded directory is + present, the directory will always be deleted and recreated by expanding + the WAR if unpackWARs is true. (markt) +
fix + 58935: Remove incorrect references in the documentation to + using jar:file: URLs with the Manager application. (markt) +
+
+
Tribes
+ + + + + +
fix + Add support for the startup notification of local members in the static + cluster. (kfujino) +
fix + Ignore the unnecessary member remove operation from different domain. + (kfujino) +
fix + Add support for the shutdown notification of local members in the static + cluster. (kfujino) +
fix + Ensure that asynchronous session replication thread is a daemon thread. + (kfujino) +
+
+
Other
+ + +
update + Update the NSIS Installer used to build the Windows Installers to + version 2.50. (markt/kkolinko) +
+
+
Tomcat 7.0.67 (violetagg)released 2015-12-10
+
Catalina
+ + + + + +
add + 56917: As per RFC7231 (HTTP/1.1), allow HTTP/1.1 and later + redirects to use relative URIs. This is controlled by a new attribute + useRelativeRedirects on the Context and + defaults to true. (markt) +
fix + 58660: Correct a regression in 7.0.66 caused by the change + that moved the redirection for context roots from the Mapper to the + Default Servlet. (markt) +
fix + Fixed potential NPE in HostConfig while deploying an + application. Issue reported by coverity scan. (violetagg) +
fix + 58655: Fix an IllegalStateException when + calling HttpServletResponse.sendRedirect() with the + RemoteIpFilter. This was caused by trying to correctly + generate the absolute URI for the redirect. With the fix for + 56917, redirects may now be relative making the + sendRedirect() implementation for the + RemoteIpFilter much simpler. This also addresses issues + where the redirect may not have behaved as expected when redirecting + from http to https to from https to http. (markt) +
+
+
WebSocket
+ + +
fix + 58658: Correct a regression in 7.0.66 that prevented Tomcat + from starting on Java 6 unless the WebSocket JARs (that require Java 7) + were removed. (markt) +
+
+
Web Applications
+ + +
add + Add a description of the default value of + heartbeatSleeptime attribute and optionCheck + attribute in the cluster channel docs. (kfujino) +
+
+
Tribes
+ + +
fix + Fix potential NPE in AbstractReplicatedMap.breakdown(). + (kfujino) +
+
+
Tomcat 7.0.66 (violetagg)not released
+
General
+ + +
update + 58596: Clarify the description in RUNNING.txt of how + environment variables are used. (markt) +
+
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 34319: Only load those keys in StoreBase.processExpire + from JDBCStore, that are old enough, to be expired. Based on a patch + by Tom Anderson. (fschumacher) +
fix + 56777: Allow file based configuration resources (user + database, certificate revocation lists, keystores and trust stores) to + be configured using URLs as well as files. Back-port provided by Huxing + Zhang. (markt/violetagg) +
add + 57741: Enable the CGI servlet to use the standard error page + mechanism. Note that if the CGI servlet's debug init parameter is + set to 10 or higher then the standard error page mechanism will be + bypassed and a debug response generated by the CGI servlet will be + returned instead. (markt) +
add + 58486: Protect against two further possible memory leaks + associated with XML parsing. (markt) +
code + 58497: Make AbstractHttp11Processor easy to + extend. (markt) +
fix + 58508: Escape role names when generating associated MBeans in + case the role name contains characters not permitted in an MBean name. + (markt) +
fix + 58522: Fixed concurrency issue when iterating web + application's resources. (violetagg) +
fix + 58534: Removed repeated conditional tests in + o.a.tomcat.websocket.pojo.PojoMethodMapping and + o.a.tomcat.util.net.AprEndpoint + Patch provided by Anthony Whitford. (violetagg) +
fix + 58535: Use Collections.reverseOrder + when a reverse ordering is needed. (violetagg) +
fix + 58537: Some of the inner classes in + o.a.catalina.valves.ExtendedAccessLogValve are made static. + Patch provided by Anthony Whitford. (violetagg) +
fix + 58540: Removed unused code from + o.a.catalina.connector.Request. + Patch provided by Anthony Whitford. (violetagg) +
fix + 58541, 58544: It is more efficient to call + Integer.toString(int) instead of + Integer.valueOf(int).toString() when only a string + representation of a primitive is needed. Based on a patch provided by + Anthony Whitford. (violetagg) +
fix + 58541, 58547: It is more efficient to call + valueOf(...) instead of Number constructor. Based on a + patch provided by Anthony Whitford. (violetagg) +
fix + 58545: In some use cases it is more efficient to use + Map.entrySet() instead of Map.keySet() + Based on a patch provided by Anthony Whitford. (violetagg) +
add + Add a new RestCsrfPreventionFilter that provides basic CSRF protection + for REST APIs. (violetagg) +
fix + 58581: If a custom error page fails, fall back to the + standard error page rather than throwing an NPE. Based on a patch by + Huxing Zhang. (markt) +
fix + 58582: Combined realm should perform background processing + on its sub-realms. Based upon a patch provided by Aidan. (kkolinko) +
fix + Handle the unlikely case where different versions of a web application + are deployed with different session settings. (markt) +
add + Add a new Context option, enabled by default, that enables an additional + check that a client provided session ID is in use in at least one other + web application before allowing it to be used as the ID for a new + session in the current web application. (markt) +
add + Add support for DIGEST authentication to the JNDIRealm. Based on a patch + by Alexis Hassler. (markt) +
fix + 58603: Ensure that + HttpServletRequest.getRequestURL() returns the correct + value when using the RemoteIpFilter. (markt) +
fix + Ensure that in an embedded Tomcat the logging configuration is + not lost during garbage collection. (violetagg) +
add + Move the functionality that provides redirects for context roots and + directories where a trailing / is added from the Mapper to + the DefaultServlet. This enables such requests to be + processed by any configured Valves and Filters before the redirect is + made. This behaviour is configurable via the + mapperContextRootRedirectEnabled and + mapperDirectoryRedirectEnabled attributes of the Context + which may be used to restore the previous behaviour. (markt) +
fix + 58635: Enable break points to be set within agent code when + running Tomcat with a Java agent. Based on a patch by Huxing Zhang. + (markt) +
fix + Add path parameter handling to + HttpServletRequest.getContextPath(). This is a follow-up to + the fix for 57215. (markt) +
+
+
Jasper
+ + +
fix + 57136#c25: Implement a setting that controls what quoting + rule is used when parsing EL expressions in attributes on a JSP page + (chapter JSP.1.6 of specification). The setting name is + quoteAttributeEL and it is configured as initialisation + parameter of JSP Servlet (per web application configuration is possible) + and as a command line option for JspC. The default value was changed to + true, which restores behaviour implemented in + Tomcat 7.0.64. It means that attribute quoting is applied on top of EL + quoting. This provides better compatibility with older versions of + Tomcat and other implementations. (kkolinko) +
+
+
Cluster
+ + + + +
fix + Optimize the session lock range in DeltaManager.requestCompleted. + (kfujino) +
fix + Enable an explicit configuration of local member in the static cluster + membership. (kfujino) +
fix + Fix potential integer overflow in DeltaSession. + Reported by coverity scan. (fschumacher) +
+
+
Tribes
+ + + + + + +
code + Distinguish the handling of the shutdown payload and member verification + clearly. When handling shutdown payload, verification completion message + is not required. (kfujino) +
fix + When starting the StaticMembershipInterceptor, + StaticMembershipInterceptor checks the required + Interceptors. If the required Interceptor does not exist, it issues + warning logs. (kfujino) +
fix + Ensure that the static member is registered to the add suspect list even + if the static member that is registered to the remove suspect list has + disappeared. (kfujino) +
fix + Correct the warning log of when the member that is not registered in the + membership is detected. (kfujino) +
fix + When using a static cluster, add the members that have been cached in + the membership service to the map members list in order to ensure that + the map member is a static member. (kfujino) +
+
+
WebSocket
+ + + + +
fix + Use instance manager for server endpoint instances. (remm) +
add + 55006: The WebSocket client now honors the + java.net.java.net.ProxySelector configuration (using the + HTTP type) when establishing WebSocket connections to servers. Based on + a patch by Niki Dokovski. (markt) +
fix + 58624: Correct a thread safety issue that meant that blocking + message writes could block indefinitely if the WebSocket connection was + closed while a message write was in progress. (markt) +
+
+
Web applications
+ + + + +
add + Make it clear in the documentation for the CGI servlet that the debug + page is not considered secure and should not be used in production. + (markt) +
fix + The domain attribute of StaticMember is not + required but optional. (kfujino) +
fix + 58631: Correct the continuation character use in the Windows + Service How-To page of the documentation web application. (markt) +
+
+
jdbc-pool
+ + + + +
fix + 58489: Correct QueryStatsComparator to hold up the + general contract for Comparator. (fschumacher) +
fix + When creating a QueryStats object, ensure that + maxQueries is checked. If maxQueries is a + value less than or equal to 0, QueryStats are never + created. (kfujino) +
fix + Fix potential integer overflow in ConnectionPool and + PooledConnection. Reported by coverity scan. (fschumacher) +
+
+
Tomcat 7.0.65 (violetagg)released 2015-10-19
+
Catalina
+ + + + + + + + + + +
add + 57681: Add a web application class loader implementation that + supports the parallel loading of web application classes. Use of this + feature requires a Java 7 or later JRE. Based on a patch by Huxing + Zhang. (markt) +
fix + 58187: Correct a regression in the fix for 57765 + that meant that deployment of web applications deployed via the Manager + application was delayed until the next execution of the automatic + deployment background process. (markt) +
fix + 58284: Correctly implement session serialization so + non-serializable attributes are skipped with a warning. Patch provided + by Andrew Shore. (markt) +
fix + 58313: Fix concurrent access of encoders map when clearing + encoders prior to switch to async. (markt) +
fix + 58320: Fix concurrent access of request attributes which is + possible during asynchronous processing. (markt) +
code + In preparation for implementing enhancement 57681, replace + the use of the StandardClassLoader with + URLClassLoader. This removes the server class loader from + JMX. (markt) +
fix + 58352: Always trigger a thread dump if Tomcat fails to stop + gracefully from catalina.sh even if using + -force. Patch provided by Alexandre Garnier. (markt) +
fix + 58416: Correctly detect when a forced stop fails to stop + Tomcat because the Tomcat process is waiting on some system call or is + uninterruptible. (markt) +
fix + 58436: Fix some rare data races in JULI's + ClassLoaderLogManager during shutdown. (markt) +
+
+
Coyote
+ + + + + +
fix + Correct some edge cases in RequestUtil.normalize(). (markt) +
fix + 58275: The IBM JREs accept cipher suite names starting with + TLS_ or SSL_ but when listing the supported + cipher suites only the SSL_ version is reported. This can + break Tomcat's check that at least one requested cipher suite is + supported. Tomcat now includes a work-around so either form of the + cipher suite name can be used when running on an IBM JRE. (markt) +
fix + 58357: For reasons not currently understood when the + APR/native connector is used with OpenSSL reads can return an error code + when there is no apparent error. This was work-around for HTTP upgrade + connections by treating this as EAGAIN. The same fix has + now been applied to the standard HTTP connector. (markt) +
fix + 57799: Remove useless sendfile check for NIO SSL. (remm) +
+
+
Jasper
+ + + + + +
fix + 57136: Correct a regression in the previous fix for this + issue. \${ should only be an escape for ${ + within an EL expression. Within a JSP page \$ should be an + escape for $. The EL specification applies when parsing the + expression delimited by ${ and }. Parsing of + the delimiting ${ and } is the responsibility + of the JSP specification. (markt) +
fix + 58296: Fix a memory leak in the JSP unloading feature that + meant that using a value other than -1 for + maxLoadedJsps triggered a memory leak once the limit was + reached. (markt) +
fix + 58340: Improve error reporting for tag files packaged in + JARs. (markt) +
fix + 58444: Ensure that JSPs work with any custom base class that + meets the requirements defined in the JSP specification without + requiring that base class to implement Tomcat specific code. (markt) +
+
+
Cluster
+ + + +
fix + Fix a default clusterListeners in SimpleTcpCluster. The + optimal default value is different for each session manager. + ClusterSessionListener is never used in + BackupManager. (kfujino) +
fix + Correct log messages in case of using BackupManager. + (kfujino) +
+
+
WebSocket
+ + + +
fix + 58342: Fix a copy and paste error that meant MessageHandler + removal could fail for binary and pong MessageHandlers. Patch provided + by DJ. (markt) +
fix + 58414: Correctly handle sending zero length messages when + using per message deflate. (markt) +
+
+
Web applications
+ + +
fix + Correct documentation for cluster-howto. (kfujino) +
+
+
Extras
+ + +
fix + Ensure JULI adapters does not include the LogFactoryImpl class. Patch + provided by Benjamin Gandon. (markt) +
+
+
Tribes
+ + + +
add + Add support for configurations of ChannelListener and + MembershipListener in server.xml. (kfujino) +
fix + Correct log messages in case of using ReplicatedMap. + (kfujino) +
+
+
jdbc-pool
+ + +
fix + Make sure the pool has been properly configured when attributes that + related to the pool size are changed via JMX. (kfujino) +
+
+
Tomcat 7.0.64 (violetagg)released 2015-08-25
+
Catalina
+ + + + + + + + + + + +
add + 55317: Facilitate weaving by allowing ClassFileTransformer to + be added to WebappClassLoader. Patch by Nick Williams. (markt) +
fix + 58031: Make the (first) reason parameter parsing failed + available as a request attribute and then use it to provide a better + status code via the FailedRequstFilter (if configured). (markt) +
fix + 58086: Ensure that WAR URLs are handled properly when using + Apache Ant for web application deployment. (violetagg) +
fix + 58094: Fix cosmetic error log when using non standard + non cacheable resources, like with the empty resources used in some + tests. (remm) +
fix + 58096: Classes loaded from /WEB-INF/classes/ + should use that directory as their code base. (markt) +
fix + Fix possible resource leaks by closing streams properly. + Issues reported by Coverity Scan. (violetagg) +
fix + 58116: Fix a regression in the fix for 57281 that + broke Comet support when running under a security manager. Based on a + patch provided by Johno Crawford. (markt) +
fix + 58179: Fix a thread safety issues that could mean concurrent + threads setting the same attribute on a ServletContext + could both see null as the old value. (markt) +
fix + 58192: Correct a regression in the previous fix for + 58023. Ensure that classes are associated with their manifest + even if the class file is first read (and cached) without the manifest. + (markt) +
fix + Fix thread safety issue in the AsyncContext implementation + that meant a sequence of start();dispatch(); calls using + non-container threads could result in a previous dispatch interfering + with a subsequent start. (markt) +
+
+
Coyote
+ + + + + + + + +
fix + 57943: Prevent the same socket being added to the cache + twice. Patch based on analysis by Ian Luo / Sun Qi. (markt) +
fix + Add text/javascript,application/javascript to the default + list of compressable MIME types. (violetagg) +
fix + 58103: When pipelining requests, and the previous request was + an async request, ensure that the socket is removed from the waiting + requests so that the async timeout thread doesn't process it during the + next request. (markt) +
fix + Fix a concurrency issue that meant that a change in socket timeout (e.g. + when switching to asynchronous I/O) did not always take effect + immediately. (markt) +
fix + In the AJP and HTTP NIO connectors, ensure that the socket timeout is + correctly set before adding the socket back to the poller for read. + (markt) +
fix + 58157: Ensure that the handling of async timeouts does not + result in an unnecessary dispatch to a container thread that could + result in the current socket being added to the Poller multiple times + with multiple attempts to process the same event for the same socket. + (markt) +
fix + Correct a couple of edge cases in RequestUtil.normalize(). + (markt) +
+
+
Jasper
+ + + + +
fix + 58110: Like scriptlet sections, declaration sections of JSP + pages have a one-to-one mapping of lines to the generated .java file. + Use this information to provide more accurate error messages if a + compilation error occurs in a declaration section. (markt) +
fix + 58119: When tags are compiled they must be placed in the + org/apache/jsp/tag/web directory. Correct a regression in the fix for + 52725. (violetagg) +
fix + 58178: Expressions in a tag file should use the tag + file's PageContext rather than that of the containing + page. (markt) +
+
+
WebSocket
+ + + +
fix + 58166: Allow applications to send close codes in the range + 3000-4999 inclusive. (markt) +
fix + 58232: Avoid possible NPE when adding endpoints + programmatically to the + javax.websocket.server.ServerContainer. + Based on a patch provided by bastian.(violetagg) +
+
+
Web applications
+ + + + + +
fix + Correct the incorrect document of QueryTimeoutInterceptor. + The setting value is not in milliseconds but in seconds. (kfujino) +
fix + 58112: Update the documentation for using the Catalina tasks + in an Apache Ant build file. (markt) +
fix + Improve the Javadoc for some of the APR socket read functions that have + inconsistent behaviour for return values. (markt) +
add + 58255: Document the Semaphore valve. Patch provided by + Kyohei Nakamura. (markt) +
+
+
jdbc-pool
+ + + + + + +
fix + Fix potential NPE in QueryTimeoutInterceptor. (kfujino) +
fix + Add support for stopping the pool cleaner via JMX. (kfujino) +
fix + The fairness attribute and + ignoreExceptionOnPreLoad attribute do not allow a change + via JMX. (kfujino) +
fix + If the timeBetweenEvictionRunsMillis attribute is changed + via jmx, it should restart the pool cleaner because this attribute + affects the execution interval of the pool cleaner. (kfujino) +
fix + Eliminate the dependence on maxActive of busy queues and + idle queue in order to enable the expansion of the pool size via JMX. + (kfujino) +
+
+
Other
+ + +
fix + Update sample Eclipse IDE configuration to exclude test/webapp* and + similar paths from compiler sourcepath. (kkolinko) +
+
+
Tomcat 7.0.63 (violetagg)released 2015-07-06
+
Catalina
+ + + + + + + + + + +
fix + 57938: Correctly handle empty form fields when a form is + submitted as multipart/form-data, the + maxPostSize attribute of the Connector has been set to a + negative value and the Context has been configured with a value of + true for allowCasualMultipartParsing. The + meaning of the value zero for the maxPostSize has also been + changed to mean a limit of zero rather than no limit to align it with + maxSavePostSize and to be more intuitive. (markt) +
add + 54618: Add a new HttpHeaderSecurityFilter that + adds the Strict-Transport-Security, + X-Frame-Options and X-Content-Type-Options + HTTP headers to the response. (markt) +
fix + Add a workaround for issues with SPNEGO authentication when running on + Java 8 update 40 and later. The workaround should be safe for earlier + Java versions but it can be disabled with the + applyJava8u40Fix attribute of the SPNEGO authenticator if + necessary. (markt) +
add + 57154: Add support for web applications (Context elements) + that do not have a docBase. This is primarily for use when embedding but + it also fixes a rare issue when running the unit test. Patch provided by + Huxing Zhang. (markt) +
fix + 57959: Fixed deadlock in + org.apache.juli.FileHandler when log is rotated. + (violetagg) +
fix + 57977: Correctly bind and unbind the web application class + loader during execution of the PersistentValve. (markt) +
fix + 58023: Fix potentially excessive memory usage due to + unnecessary caching of JAR manifests in the web application class + loader. (markt) +
fix + 57700: Ensure that Container event + ADD_CHILD_EVENT will be sent in all cases. (violetagg) +
fix + Add configuration fields for header names in SSLValve. (remm) +
+
+
Coyote
+ + + + + + +
fix + 57265: Further fix to address a potential threading issue + for NIO when sendfile is used in conjunction with TLS. (markt) +
fix + 57931: Ensure that TLS connections with the NIO HTTP + connector that experience issues during the handshake (e.g. missing or + invalid client certificate) are closed cleanly and that the client + receives the correct error code rather than simply closing the + connection. (markt) +
add + 57943: Added a work-around to catch + ConcurrentModificationExceptions during Poller timeout + processing that were causing the Poller thread to stop. The root cause + of these exceptions is currently unknown. (markt) +
fix + Fix possible very long (1000 seconds) timeout with APR/native connector. + (markt) +
add + Support "-" separator in the SSLProtocol configuration of the + APR/native connector for protocol exclusion. (rjung) +
+
+
Cluster
+ + +
fix + Make sure that stream is closed after using it in + DeltaSession.applyDiff(). (kfujino) +
+
+
WebSocket
+ + + + + +
add + 57676: List conflicting WebSocket endpoint classes when + there is a path conflict. Based upon a patch proposed by yangkun. + (schultz) +
add + Extend support for the permessage-deflate extension to the + client implementation. +
fix + 57969: Provide path parameters to POJO via per session + javax.websocket.server.ServerEndpointConfig as they vary + between different requests. (violetagg) +
fix + 57974: Session.getOpenSessions should return all sessions + associated with a given endpoint instance, rather than all sessions + from the endpoint class. (remm) +
+
+
Web applications
+ + + + + +
fix + 57282: Update request processing sequence diagrams. Updated + diagrams provided by Stephen Chen. (markt) +
fix + 57971: Correct the documentation for the cluster + configuration setting recoverySleepTime. (markt) +
add + 57758: Add document of testOnConnect attribute + in jdbc-pool doc. (kfujino) +
add + Add description of validatorClassName attribute to testXXXX + attributes in jdbc-pool docs. (kfujino) +
+
+
Tribes
+ + + + +
fix + Ensure that the state transfer flag is updated to true only when the map + states have been transferred correctly from existing map members. + (kfujino) +
fix + Do not set the nodes that failed to replication to the backup nodes. + Ensure that the nodes that the data has been successfully replicated are + set to the backup node. (kfujino) +
fix + When failed to replication, rather than all member is handled as a + failed member, exclude the failure members from backup members. + (kfujino) +
+
+
jdbc-pool
+ + + +
fix + Refactoring of the removeOldest method in + SlowQueryReport to behave as expected. (kfujino) +
fix + 57783: Fix NullPointerException in + SlowQueryReport. To avoid this NPE, Refactor + SlowQueryReport#removeOldest and handle the abandoned + connection properly. (kfujino) +
+
+
Other
+ + + + +
update + Update package renamed Apache Commons BCEL to r1682271 to pick up some + some code clean up. (markt) +
update + Update package renamed Apache Commons File upload to r1682322 to pick up + the post 1.3.1 fixes. (markt) +
update + Update package renamed Apache Commons Codec to r1682326. No functional + changes. Javadoc only. (markt) +
+
+
Tomcat 7.0.62 (violetagg)released 2015-05-14
+
Catalina
+ + + + + + + + + + + +
add + Allow logging of the remote port in the access log using the format + pattern %{remote}p. (rjung) +
fix + 57765: When checking last modified times as part of the + automatic deployment process, account for the fact that + File.lastModified() has a resolution of one second to + ensure that if a file has been modified within the last second, the + latest version of the file is always used. Note that a side-effect of + this change is that files with modification times in the future are + treated as if they are unmodified. (markt) +
fix + Align redeploy resource modification checking with reload modification + checking so that now, in both cases, a change in modification time + rather than an increase in modification time is used to determine if the + resource has changed. (markt) +
fix + Cleanup o.a.tomcat.util.digester.Digester from debug + messages that do not give any valuable information. Patch provided + by Polina Genova. (violetagg) +
fix + 57772: When reloading a web application and a directory + representing an expanded WAR needs to be deleted, delete the directory + after the web application has been stopped rather than before to avoid + potential ClassNotFoundExceptions. (markt) +
fix + 57801: Improve the error message in the start script in case + the PID read from the PID file is already owned by a process. (rjung) +
fix + 57824: Correct a regression in the fix for 57252 + that broke request listeners for non-async requests that triggered an + error that was handled by the ErrorReportingValve. (markt/violetagg) +
fix + 57841: Improve error logging during web application start. + (markt) +
fix + 57856: Ensure that any scheme/port changes implemented by the + RemoteIpFilter also affect + HttpServletResponse.sendRedirect(). (markt) +
fix + 57896: Support defensive copying of "cookie" header so that + unescaping double quotes in a cookie value does not corrupt original + value of "cookie" header. This is an opt-in feature, enabled by + org.apache.tomcat.util.http.ServerCookie.PRESERVE_COOKIE_HEADER + or org.apache.catalina.STRICT_SERVLET_COMPLIANCE + system property. (kkolinko) +
+
+
Coyote
+ + + + +
fix + 57779: When an I/O error occurs on a non-container thread + only dispatch to a container thread to handle the error if using Servlet + 3+ asynchronous processing. This avoids potential deadlocks if an + application is performing I/O on a non-container thread without using + the Servlet 3+ asynchronous API. (markt) +
fix + 57833: When using JKS based keystores for NIO, ensure that + the key alias is always converted to lower case since that is what JKS + key stores expect. Based on a patch by Santosh Giri Govind M. (markt) +
fix + 57837: Add text/css to the default list of + compressable MIME types. (markt) +
+
+
Jasper
+ + + +
fix + 57845: Ensure that, if the same JSP is accessed directly and + via a <jsp-file> declaration in web.xml, updates to + the JSP are visible (subject to the normal rules on re-compilation) + regardless of how the JSP is accessed. (markt) +
fix + 57855: Explicitly handle the case where a + MethodExpression is invoked with null or the wrong number + of parameters. Rather than failing with an + ArrayIndexOutOfBoundsException or a + NullPointerException throw an + IllegalArgumentException with a useful error message. + (markt) +
+
+
Cluster
+ + + + + +
add + Add new attribute that send all actions for session across Tomcat + cluster nodes. (kfujino) +
fix + Remove unused pathname attribute in mbean definition of + BackupManager. (kfujino) +
fix + 57338: Improve the ability of the ClusterSingleSignOn valve + to handle nodes being added and removed from the Cluster at run time. + (markt) +
fix + Avoid unnecessary call of DeltaRequest.addSessionListener() + in non-primary nodes. (kfujino) +
+
+
WebSocket
+ + + + + + +
fix + 57762: Ensure that the WebSocket client correctly detects + when the connection to the server is dropped. (markt) +
fix + 57776: Revert the 8.0.21 fix for the + permessage-deflate implementation and incorrect op-codes + since the fix was unnecessary (the bug only affected trunk) and the fix + broke rather than fixed permessage-deflate if an + uncompressed message was converted into more than one compressed + message. (markt) +
fix + Fix log name typo in WsRemoteEndpointImplServer class, + caused by a copy-paste. (markt/kkolinko) +
fix + 57788: Avoid NPE when looking up a class hierarchy without + finding anything. (remm) +
add + Make WebSocket client more robust when handling errors during the close + of a WebSocket session. (markt) +
+
+
Web applications
+ + + +
add + 57759: Add information to the keyAlias documentation to make + it clear that the order keys are read from the keystore is + implementation dependent. (markt) +
fix + 57864: Update the documentation web application to make it + clearer that hex values are not valid for cluster send options. Based on + a patch by Kyohei Nakamura. (markt) +
+
+
Tribes
+ + + + + + + +
fix + Fix a concurrency issue when a backup message that has all session data + and a backup message that has diff data are processing at the same time. + This fix ensures that MapOwner is set to + ReplicatedMapEntry. (kfujino) +
fix + Clarify the handling of Copy message and Copy nodes. (kfujino) +
fix + Copy node does not need to send the entry data. It is enough to send + only the node information of the entry. (kfujino) +
fix + ReplicatedMap should send the Copy message when + replicating. (kfujino) +
fix + Fix behavior of ReplicatedMap when member has disappeared. + If map entry is primary, rebuild the backup members. If primary node of + map entry has disappeared, backup node is promoted to primary. (kfujino) +
fix + When a map member has been added to ReplicatedMap, make + sure to add it to backup nodes list of all other members. (kfujino) +
+
+
Tomcat 7.0.61 (violetagg)released 2015-04-07
+
Catalina
+ + +
fix + 55988: Correct the check used for Java 8 JSSE + server-preferred TLS cipher suite ordering. Ensure that SSL parameters + are provided to SSLServerSocket and SSLEngine. + Patch provided by Ognjen Blagojevic. (violetagg) +
+
+
WebSocket
+ + +
fix + 57761: Ensure that the opening HTTP request is correctly + formatted when the WebSocket client connects to a server root. (remm) +
+
+
Tomcat 7.0.60 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + Clarify threaded usage of variables by removing volatile marker + in NonceInfo. Issue reported by Coverity Scan. (fschumacher) +
add + 49785: Enable StartTLS connections for JNDIRealm. + (fschumacher) +
fix + 55988: Add support for Java 8 JSSE server-preferred TLS + cipher suite ordering. This feature requires Java 8 + and is controlled by useServerCipherSuitesOrder + attribute on an HTTP connector. + Based upon patches provided by Ognjen Blagojevic. (schultz) +
add + 56438: Add logging that reports when a JAR is scanned for + TLDs but nothing is found so that Tomcat may be configured to skip this + JAR in future. Based on a patch by VIN. (markt) +
fix + 56848: Use Locale.forLanguageTag to process + Locale headers when running on a Java 7 or later JRE. (markt) +
add + 57021: Improve logging in AprLifecycleListener and + jni.Library when Tomcat-Native DLL fails to load. Based on a patch by + Pravallika Peddi. (markt/kkolinko) +
fix + 57180: Further fixes to support the use of arbitrary HTTP + methods with the CORS filter. (markt) +
add + Warn about problematic setting of appBase. (fschumacher) +
fix + 57534: CORS Filter should only look at media type component of + Content-Type request header. (markt) +
fix + Ensure that user name checking in the optional SecurityListener is + case-insensitive (as documented) and than the case-insensitive + comparison is performed using the system default Locale. (markt) +
fix + When docBase refers internal war and unpackWARs is set to false, avoid + registration of the invalid redeploy resource that has been added ".war" + extension in duplicate. (kfujino) +
fix + If WAR exists, it is not necessary to trigger a reload when adding a + Directory. (kfujino) +
fix + 56608: When deploying an external WAR, add watched resources + in the expanded directory based on whether the expanded directory is + expected to exist rather than if it does exist. +
fix + When triggering a reload due to a modified watched resource, ensure + that multiple changed watched resources only trigger one reload rather + than a series of reloads. +
fix + 57601: Ensure that HEAD requests return the correct content + length (i.e. the same as for a GET) when the requested resource includes + a resource served by the Default servlet. (jboynes/markt) +
fix + 57602: Ensure that HEAD requests return the correct content + length (i.e. the same as for a GET) when the requested resource includes + a resource served by a servlet that extends HttpServlet. + (markt) +
fix + 57621: When an async request completes, ensure that any + remaining request body data is swallowed. (markt) +
fix + 57637: Do not create unnecessary sessions when using + PersistentValve. (jboynes/fschumacher) +
fix + 57645: Correct a regression in the fix for + 57190 that incorrectly required the path passed to + ServletContext.getContext(String) to be an exact match to a + path to an existing context. (markt) +
fix + Make sure that unpackWAR attribute of Context + is handled correctly in HostConfig. (kfujino) +
fix + When deploying a WAR file that contains a context.xml file and + unpackWARs is false ignore any context.xml + file that may exist in an expanded directory associated with the WAR. + (markt) +
fix + 57675: Correctly quote strings when using the extended + access log. (markt) +
fix + 57704: Fix potential NPEs during web application start/stop + when org.apache.tomcat.InstanceManager is not initialized. + (violetagg) +
fix + Add support for LAST_ACCESS_AT_START system property to + SingleSignOn. (kfujino) +
fix + 57723: Ensure that the Context name and path remain + consistent when adding a web application to an embedded Tomcat instance + via Tomcat.addWebapp(Host,String,String,String). (markt) +
fix + 57724: Handle the case in the CORS filter where a user agent + includes an origin header for a non-CORS request. (markt) +
code + Refactor Authenticator implementations to reduce code duplication. + (markt) +
fix + When searching for SCIs + o.a.catalina.Context.getParentClassLoader will be used + instead of java.lang.ClassLoader.getParent. Thus one can + provide the correct parent class loader when running embedded Tomcat in + other environments such as OSGi. (violetagg) +
+
+
Coyote
+ + + + + + + + + + + + + + + + +
fix + 57509: Improve length check when writing HTTP/1.1 + response headers: reserve space for 4 extra bytes. (kkolinko) +
add + 57540: Make TLS/SSL protocol available in a new request + attribute + (org.apache.tomcat.util.net.secure_protocol_version). + (Note that AJP connectors will require mod_jk 1.2.41 or later, + or an as-yet-unknown version of mod_proxy_ajp, or configure the proxy + to send the AJP_SSL_PROTOCOL request attribute to Tomcat. Please see + the bug comments for details.) + Based upon a patch provided by Ralf Hauser. (schultz) +
fix + 57544: Fix potential infinite loop when preparing a kept + alive HTTP connection for the next request. (markt) +
fix + 57546: Ensure that a dropped network connection does not + leave references to the UpgradeProcessor associated with the connection + in memory. (markt) +
fix + 57570: Make the processing of trailer headers with chunked + input optional and disabled by default. (markt) +
fix + When applying the maxSwallowSize limit to a connection read + that many bytes first before closing the connection to give the client a + chance to read the response. (markt) +
fix + Prevent an async timeout being processed multiple times for the same + socket when running on slow and/or heavily loaded systems. (markt) +
fix + 57581: Change statistics byte counter in coyote Request + object to be long to allow values above 2Gb. (kkolinko) +
fix + Fix a concurrency issue in the APR Poller that meant it was possible + under low load for a socket queued to be added to the Poller not to be + added for 10 seconds. (markt) +
fix + 57638: Avoid an IllegalArgumentException when an AJP request + body chunk larger than the socket read buffer is being read. This + typically requires a larger than default AJP packetSize. (markt) +
fix + 57674: Avoid a BufferOverflowException when an AJP response + body chunk larger than the socket write buffer is being written. This + typically requires a larger than default AJP packetSize. (markt) +
code + Refactor Connector authentication (only used by AJP) into a separate + method. (markt) +
add + 57708: Implement a new feature for AJP connectors - Tomcat + Authorization. If the new tomcatAuthorization attribute is set to + true (it is disabled by default) Tomcat will take an + authenticated user name from the AJP protocol and use the appropriate + Realm for the request to authorize (i.e. add roles) to that user. + (markt) +
fix + Fix an issue that meant that any pipe-lined data read by Tomcat before + an asynchronous request completed was lost during the completion of the + asynchronous request. This mean that the pipe-lined request(s) would be + lost and/or corrupted. (markt) +
update + Update the minimum recommended version of the Tomcat Native library (if + used) to 1.1.33. (markt) +
+
+
Jasper
+ + + +
fix + 57136: Ensure only \${ and \#{ are + treated as escapes for ${ and #{ rather than + \$ and \# being treated as escapes for + $ and # when processing literal expressions in + expression language. (markt) +
fix + 57148: When coercing an object to a given type and a + PropertyEditor has been registered for the type correctly + coerce the empty string to null if the + PropertyEditor throws an exception. (kkolinko/markt) +
+
+
Cluster
+ + +
fix + Remove unnecessary method that always returns true. The domain filtering + works on DomainFilterInterceptor. (kfujino) +
+
+
WebSocket
+ + +
fix + Correct a bug in the permessage-deflate implementation that + meant that the incorrect op-codes were used if an uncompressed message + was converted into more than one compressed message. (markt) +
+
+
Web applications
+ + + + + + + + +
fix + Fix possible resource leaks by closing streams properly. Issues + reported by Coverity Scan. (fschumacher) +
fix + 56058: Add links to the AccessLogValve documentation for + configuring reverse proxies and/or Tomcat to ensure that the desired + information is used entered in the access log when Tomcat is running + behind a reverse proxy. (markt) +
fix + 57503: Make clear that the JULI integration for log4j only + works with log4j 1.2.x. (markt) +
fix + Remove incorrect note from context configuration page in the + documentation web application that stated WAR files located outside the + appBase were never unpacked. (markt) +
update + 57644: Update examples to use Apache Standard Taglib 1.2.5. + (jboynes) +
fix + 57683: Ensure that if a client aborts their connection to the + stock ticker example (the only way a client can disconnect), the example + continues to work for existing and new clients. (markt) +
fix + Correct the documentation for deployOnStartup to make clear that if a + WAR file is updated while Tomcat is stopped and unpackWARs is true, + Tomcat will not detect the changed WAR file when it starts and will not + replace the unpacked WAR file with the contents of the updated WAR. + (markt) +
+
+
Extras
+ + +
fix + 57377: Remove the restriction that prevented the use of SSL + when specifying a bind address with the JMXRemoteLifecycleListener. Also + enable SSL to be configured for the registry as well as the server. + (markt) +
+
+
Tribes
+ + +
fix + Make sure that refuse the messages from a different domain in + DomainFilterInterceptor. (kfujino) +
+
+
Other
+ + + + + + + + +
add + Enhance bean factory used for JNDI resources. New attribute + forceString allows to support non-standard + string argument property setters. (rjung) +
fix + Fix TestAbstractAjpProcessor unit test failures on + Windows. (kkolinko) +
fix + Guard the digester from MbeansDescriptorsDigesterSource with its own + lock object. (fschumacher) +
fix + 57558: Add missing JAR in Ant task definition required by + the validate task. (markt/kkolinko) +
add + List names of Testsuites that have failed or skipped tests when + running tests with Ant. (kkolinko) +
fix + 57703: Update the http-method definition for + web applications using a Servlet 2.5 descriptor as per Servlet 2.5 MR 6. + (markt) +
update + Update to Tomcat Native Library version 1.1.33 to pick up the Windows + binaries that are based on OpenSSL 1.0.1m and APR 1.5.1. (markt) +
+
+
Tomcat 7.0.59 (violetagg)released 2015-02-04
+
Jasper
+ + +
fix + 57504: Initialize TLD locations cache when creating the + ServletContext. (jboynes) +
+
+
Tribes
+ + +
fix + Fix a possible deadlock when receiver thread invokes + mapMemberAdded() while ping thread invokes + memberAlive(). (kfujino) +
+
+
Tomcat 7.0.58 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 57173: Revert the fix for 56953 that broke + annotation scanning in some cases. (markt) +
fix + 57178: The CORS filter now treats null as a + valid origin that matches *. Patch provided by Gregor + Zurowski. (markt) +
fix + 57180: Do not limit the CORS filter to only accepting + requests that use an HTTP method defined in RFC 7231. (markt) +
fix + 57190: Fix ServletContext.getContext(String) + when parallel deployment is used so that the correct ServletContext is + returned. (markt) +
fix + 57208: Prevent NPE in JNDI Realm when no results are found + in a directory context for a user with specified user name. Based on + a patch provided by Jason McIntosh. (violetagg) +
add + 57209: Add a new attribute, userSearchAsUser to the JNDI + Realm. (markt) +
fix + 57215: Ensure that the result of calling + HttpServletRequest.getContextPath() is neither decoded nor + normalized as required by the Servlet specification. (markt) +
fix + 57216: Improve handling of invalid context paths. A context + path should either be an empty string or start with a + '/' and do not end with a + '/'. Invalid context path are automatically + corrected and a warning is logged. The null and + "/" values are now correctly changed to + "". (markt/kkolinko) +
fix + Correct message that is logged when load-on-startup servlet fails + to load. It was logging a wrong name. (kkolinko) +
fix + 57239: Correct several message typos. Includes patch by + vladk. (kkolinko) +
add + Make the session id generator extensible by adding a + SessionIdGenerator interface, an abstract + base class and a standard implementation. (rjung) +
add + Back-port clarification from Servlet 3.1 specification that during + async processing an IllegalStateException should be thrown + if getRequest() or getResponse() is called + after complete() or dispatch(). (markt) +
fix + Fix a concurrency issue in async processing. Ensure that a non-container + thread can not change the async state until the container thread has + completed. (markt) +
fix + 57252: Provide application configured error pages with a + chance to handle an async error before the built-in error reporting. + (markt) +
fix + 57281: Enable non-public Filter and Servlet classes to be + configured programmatically via the Servlet 3.0 API and then used + without error when running under a SecurityManager. (markt) +
fix + 57308: Remove unnecessary calls to + System.getProperty() where more suitable API calls are + available. (markt) +
add + Add unit tests for RemoteAddrValve and RemoteHostValve. (rjung) +
add + Allow to configure RemoteAddrValve and RemoteHostValve to + adopt behavior depending on the connector port. Implemented + by optionally adding the connector port to the string compared + with the patterns allow and deny. Configured + using addConnectorPort attribute on valve. (rjung) +
add + Optionally trigger authentication instead of denial in + RemoteAddrValve and RemoteHostValve. This only works in + combination with preemptiveAuthentication + on the application context. Configured using + invalidAuthenticationWhenDeny attribute on valve. (rjung) +
fix + Prevent file descriptors leak and ensure that files are closed after + retrieving the last modification time. (violetagg) +
fix + 57326: Enable AsyncListener implementations to + re-register themselves during AsyncListener.onStartAsync. + (markt) +
fix + 57331: Allow ExpiresFilter to use "year" as synonym for + "years" in its configuration. (kkolinko) +
update + Improve SnoopServlet in unit tests. (rjung) +
add + Add RequestDescriptor class to unit tests. + Adjust TestRewriteValve to use RequestDescriptor. (rjung) +
update + Add more AJP unit tests. (rjung) +
fix + 57363: Log to stderr if LogManager is unable to read + configuration files rather than swallowing the exception silently. + (markt) +
fix + 57420: Make UEncoder a local variable in + DirContextURLConnection to make it threadsafe. Based on ideas from + kkolinko and violetagg. (fschumacher) +
fix + 57425: Don't add attributes with null value or name to the + replicated context. (fschumacher) +
add + 57431: Enable usage of custom class for context creation when + using embedded tomcat. (fschumacher) +
fix + 57446: Ensure that ServletContextListeners that + have limited access to ServletContext methods are called + with the same ServletContext instance for both + contextInitialized() and contextDestroyed(). + (markt) +
fix + 57461: When an instance of + org.apache.catalina.startup.VersionLoggerListener logs the + result of System.getProperty("java.home") don't report it + in a manner that makes it look like the JAVA_HOME + environment variable. (markt) +
fix + While closing streams for given resources ensure that if an exception + happens it will be handled properly. Issue is reported by Coverity Scan. + (violetagg) +
fix + Change Response to use UEncoder instances with shared safeChars. + (fschumacher) +
add + Allow VersionLoggerListener to log all system properties. + This feature is off by default. (kkolinko) +
+
+
Coyote
+ + + + + + +
fix + 57234: Make SSL protocol filtering to remove insecure + protocols case insensitive. (markt) +
fix + 57265: Fix some potential concurrency issues with sendFile + and the NIO connector. (markt) +
fix + 57324: If the client uses Expect: 100-continue + and Tomcat responds with a non-2xx response code, Tomcat also closes the + connection. If Tomcat knows the connection is going to be closed when + committing the response, Tomcat will now also send the + Connection: close response header. (markt) +
fix + 57340: When using Comet, ensure that Socket and SocketWrapper + are only returned to their respective caches once on socket close (it is + possible for multiple threads to call close concurrently). (markt) +
fix + 57446: Ensure that ServletContextListeners that + have limited access to ServletContext methods are called + with the same ServletContext instance for both + contextInitialized() and contextDestroyed(). + (markt) +
+
+
Jasper
+ + + + +
fix + CVE-2014-7810: + Do not use a privileged code block when evaluating EL expressions + when running under a security manager, which allowed to bypass code + restrictions. (markt) +
fix + Fix an issue with BeanELResolver when running under a security + manager. Some classes may not be accessible but may have accessible + interfaces. (markt) +
fix + 57316: Fix JspC when directory name contains a character + sequence that appears to be URL encoded. (markt) +
+
+
Cluster
+ + + + +
fix + In order to enable define in Cluster element, + ClusterSingleSignOn implements ClusterValve. + (kfujino) +
fix + Fix mbean descriptor of ClusterSingleSignOn. (kfujino) +
fix + 57473: Add sanity check to FarmWebDeployer's WarWatcher to + detect suspected incorrect permissions on the watch directory. (schultz) +
+
+
WebSocket
+ + + + + + + + + + + +
fix + Correct multiple issues with the flushing of batched messages that could + lead to duplicate and/or corrupt messages. (markt) +
fix + Correctly implement headers case insensitivity. (markt/remm) +
fix + Allow optional use of user extensions. (remm) +
fix + Allow using partial binary message handlers. (remm) +
fix + Limit ping/pong message size. (remm) +
fix + Allow configuration of the time interval for the periodic event. (remm) +
fix + More accurate annotations processing. (remm) +
fix + Allow optional default for origin header in the client. (remm) +
fix + 57490: Make it possible to use Tomcat's WebSocket client + within a web application when running under a SecurityManager. Based on + a patch by Mikael Sterner. (markt) +
add + Add some debug logging to the WebSocket session to track session + creation and session closure. (markt) +
+
+
Web applications
+ + + + + + + + + + +
fix + Update documentation for CGI servlet. Recommend to copy the servlet + declaration into web application instead of enabling it globally. + Correct documentation for cgiPathPrefix. (kkolinko) +
update + Improve HTML version of build instructions and align with + BUILDING.txt. Document creating second Eclipse project to compile + WebSocket classes with Java 7 (ide-eclipse-websocket + target added in 7.0.56). (kkolinko) +
update + Improve Tomcat Manager documentation. Rearrange, add section on + HTML GUI, document /expire command and Server Status page. (kkolinko) +
fix + Fix ambiguity of section links on Valves configuration reference page. + (kkolinko) +
update + 57238: Update information on SSL/TLS on Security and SSL + documentation pages. Based on patch by Glen Peterson. (kkolinko) +
add + 57261: Add vminfo and threaddump commands to Manager + application. Implement VminfoTask and + ThreaddumpTask Ant tasks. (kkolinko) +
fix + 57323: Correct display of outdated sessions in sessions + count listing in Manager application. (kkolinko) +
add + Add document of ClusterSingleSignOn. (kfujino) +
update + Clarify documentation for useBodyEncodingForURI + attribute of a connector. (kkolinko) +
+
+
Other
+ + + + + + +
update + When downloading required libraries at build time, use random name + for temporary file and automatically create destination directory + (base.path). (kkolinko) +
update + Update optional Checkstyle library to 6.1.1. (kkolinko) +
update + Simplify setproxy task in build.xml. + Taskdef there is not needed since Ant 1.8.2. (kkolinko) +
fix + Improve Java 7 support in build.xml. Check whether + the specified ${java.7.home} is valid. By default use Java that + runs Ant (${java.home}) instead of the one found on $PATH + to run JUnit tests. (kkolinko) +
add + 57344: Provide sha1 checksum files for Tomcat downloads. + Correct filename patterns for apache-tomcat-*-embed.tar.gz archive + to exclude an *.asc file. (kkolinko) +
+
+
Tomcat 7.0.57 (violetagg)released 2014-11-11
+
Catalina
+ + + + + + + + + + + + +
add + 47919: Extend the information logged when Tomcat starts to + optionally log the values of command line arguments (enabled by + default) and environment variables (disabled by default). Note that + the values added to CATALINA_OPTS and JAVA_OPTS environment variables + will be logged, as they are used to build up the command line. (markt) +
add + 56401: Log version information when Tomcat starts. + (markt/kkolinko) +
fix + 57022: Ensure SPNEGO authentication continues to work with + the JNDI Realm using delegated credentials with recent Oracle JREs. + (markt) +
fix + Correct a couple of NPEs in the JNDI Realm that could be triggered with + when not specifying a roleBase and enabling roleSearchAsUser. (markt) +
fix + Remove the unnecessary registration of context.xml as a redeploy + resource. The context.xml having an external docBase has already been + registered as a redeploy resources at first. (kfujino) +
fix + Improve the previous fix for 56401. Avoid logging version + information in the constructor since it then gets logged at undesirable + times such as when using StoreConfig. (markt) +
fix + 57105: When parsing web.xml do not limit the buffer element + of the jsp-property-group element to integer values as the allowed + values are <number>kb or none. (markt) +
update + Update the minimum required version of the Tomcat Native library (if + used) to 1.1.32. (markt) +
update + 57144: Improve ClientAbortException to provide non-null + message. (kkolinko) +
fix + AsyncContext should remain usable until fireOnComplete is called. (remm) +
fix + AsyncContext createListener should wrap any instantiation exception + using a ServletException. (remm) +
+
+
Coyote
+ + + + + + +
add + 53952: Add support for TLSv1.1 and TLSv1.2 for APR connector. + Based upon a patch by Marcel Šebek. This feature requires + Tomcat Native library 1.1.32 or later. (schultz/jfclere) +
add + Disable SSLv3 by default for JSSE based HTTPS connectors (BIO and NIO). + The change also ensures that SSLv2 is disabled for these connectors + although SSLv2 should already be disabled by default by the JRE. (markt) +
add + Disable SSLv3 by default for the APR/native HTTPS connector. (markt) +
fix + Do not increase remaining counter at end of stream in + IdentityInputFilter. (kkolinko) +
fix + Async state MUST_COMPLETE should still be started. (remm) +
+
+
Jasper
+ + +
fix + 57099: Ensure that semi-colons are not permitted in JSP + import page directives. (markt) +
+
+
Cluster
+ + +
fix + Avoid possible integer overflows reported by Coverity Scan. (fschumacher) +
+
+
WebSocket
+ + + + + + +
fix + 57054: Correctly handle the case in the WebSocket client + when the HTTP response to the upgrade request can not be read in a + single pass; either because the buffer is too small or the server sent + the response in multiple packets. (markt) +
fix + Fix client subprotocol handling. (remm) +
fix + Add null checks for arguments in remote endpoint. (remm/kkolinko) +
fix + 57091: Work around the behaviour of the Oracle JRE when + creating new threads in an applet environment that breaks the WebSocket + client implementation. Patch provided by Niklas Hallqvist. (markt) +
fix + 57118: Ensure that an EncodeException is + thrown by RemoteEndpoint.Basic.sendObject(Object) rather + than an IOException when no suitable Encoder + is configured for the given Object. (markt) +
+
+
Web applications
+ + + + + + +
fix + Correct documentation for ServerCookie.ALLOW_NAME_ONLY + system property. (kkolinko) +
fix + 57049: Clarified that jvmRoute can be set in + <Engine>'s jvmRoute or in a system + property. (schultz) +
fix + Correct version of Java WebSocket mentioned in documentation + (s/1.0/1.1/). (markt/kkolinko) +
update + In examples web application move Async and Comet examples from JSP + to Servlet examples page. (kkolinko) +
update + Suppress timestamp comments and enable charset header in Javadoc. + (kkolinko) +
+
+
jdbc-pool
+ + + +
fix + 57079: Use Tomcat version number for jdbc-pool module when + building and shipping the module as part of Tomcat. (markt/kkolinko) +
fix + Fix broken overview page in javadoc generated via "javadoc" task in + jdbc-pool build.xml file. (kkolinko) +
+
+
Other
+ + + + + + +
update + 56079: The Apache Tomcat Windows service and the Apache + Tomcat Windows service monitor application are now digitally + signed. (markt) +
fix + Fix timestamps in Tomcat build and jdbc-pool to use 24-hour format + instead of 12-hour one and use UTC timezone. (markt/kkolinko) +
update + Improve Tomcat build script to ensure that only one ecj-nn.jar file + is present in Tomcat lib directory when Eclipse JDT + Compiler is updated to a new version. (kkolinko) +
update + 56596: Update to Tomcat Native Library version 1.1.32 to + pick up the Windows binaries that are based on OpenSSL 1.0.1j and APR + 1.5.1. (markt) +
code + In Tomcat tests: log name of the current test method at start time. + (kkolinko) +
+
+
Tomcat 7.0.56 (violetagg)released 2014-10-06
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + When scanning class files (e.g. for annotations) and reading the number + of parameters in a MethodParameters structure only read a + single byte (rather than two bytes) as per the JVM specification. Patch + provided by Francesco Komauli. (markt) +
fix + Allow the JNDI Realm to start even if the directory is not available. + The directory not being available is not fatal once the Realm is started + and it need not be fatal when the Realm starts. Based on a patch by + Cédric Couralet. (markt) +
fix + 56736: Avoid an incorrect IllegalStateException + if the async timeout fires after a non-container thread has called + AsyncContext.dispatch() but before a container thread + starts processing the dispatch. (markt) +
fix + 56739: If an application handles an error on an application + thread during asynchronous processing by calling + HttpServletResponse.sendError(), then ensure that the + application is given an opportunity to report that error via an + appropriate application defined error page if one is configured. (markt) +
fix + 56771: When lookup for a resource in all the alternate or + backup javax.naming.directory.DirContext, + javax.naming.NameNotFoundException will be thrown at the + end of the search if the resource is not available in these alternate + or backup javax.naming.directory.DirContext. Based on a + patch by Sheldon Shao. (violetagg) +
fix + 56796: Remove unnecessary sleep when stopping a web + application. (markt) +
fix + 56801: Improve performance of + org.apache.tomcat.util.file.Matcher which is to filter JARs + for scanning during web application start. Based on a patch by Sheldon + Shao. (kkolinko) +
fix + 56825: Enable pre-emptive authentication to work with the + SSL authenticator. Based on a patch by jlmonteiro. (markt) +
fix + 56857: Fix thread safety issue when calling ServletContext + methods while running under a security manager. (markt) +
code + 56882: Add testcase for processing of forwards and includes + when Context have been reloaded. (kkolinko) +
fix + 56900: Fix some potential resource leaks when reading + property files reported by Coverity Scan. Based on patches provided by + Felix Schumacher. (markt) +
fix + 56902: Fix a potential resource leak in the Default Servlet + reported by Coverity Scan. Based on a patch provided by Felix + Schumacher. (markt) +
fix + 56903: Correct the return value for + StandardContext.getResourceOnlyServlets() so that multiple + names are separated by commas. Identified by Coverity Scan and fixed + based on a patch by Felix Schumacher. (markt) +
fix + Fixed the multipart elements merge operation performed during web + application deployment. Identified by Coverity Scan. (violetagg) +
fix + Correct the information written by + ExtendedAccessLogValve when a format token x-O(XXX) is + used so that multiple values for a header XXX are separated by commas. + Identified by Coverity Scan. (violetagg) +
fix + Fix a potential resource leak when reading MANIFEST.MF file for + extension dependencies reported by Coverity Scan. (violetagg) +
fix + Correctly handle multiple accept-language headers rather + than just using the first header to determine the user's preferred + Locale. (markt) +
fix + Fix some potential resource leaks when reading properties, files and + other resources. Reported by Coverity Scan. (violetagg) +
fix + When using parallel deployment and undeployOldVersions + feature is enabled on a Host, correctly undeploy context of old + version. Make sure that Tomcat does not undeploy older Context if + current context is not running. (kfujino) +
fix + When deploying war, add XML file in the config base to the redeploy + resources if war does not have META-INF/context.xml or + deployXML is false. If XML file is created in the config + base, redeploy will occur. (kfujino) +
code + Various changes to reduce unnecessary code in Tomcat's copy of + Apache Commons BCEL to reduce the time taken for annotation scanning + when web applications start. Includes contributions from kkolinko and + hzhang9. (markt) +
fix + 56938: Ensure web applications that have mixed case context + paths and are deployed as directories are correctly removed on undeploy + when running on a case sensitive file system. (markt) +
add + 57004: Add stuckThreadCount property to + StuckThreadDetectionValve's JMX bean. Patch provided by + Jiří Pejchal. (schultz) +
fix + 57011: Ensure that the request and response are correctly + recycled when processing errors during async processing. (markt) +
fix + 57016: When using the PersistentValve do not + remove sessions from the store when persisting them. (markt) +
+
+
Coyote
+ + + + +
fix + 56780: Enable Tomcat to start when using SSL with an IBM JRE + in strict SP800-131a mode. (markt) +
fix + 56910: Prevent the invalid value of -1 being + used for maxConnections with APR connectors. (markt) +
fix + Ensure that AjpNioProtocol and AjpAprProtocol + enable the KeepAliveTimeout. (kfujino) +
+
+
Jasper
+ + + + + + + + +
fix + 43001: Enable the JspC Ant task to set the JspC option + mappedFile. (kkolinko) +
fix + 56797: When matching a method in an EL expression, do not + treat bridge methods as duplicates of the method they bridge to. In this + case always call the target of the bridge method. (markt) +
fix + Correct a logic error in the JasperElResolver. There was no + functional impact but the code was less efficient as a result of the + error. Based on a patch by martinschaef. (markt) +
fix + Ensure that the implementation of + javax.servlet.jsp.PageContext.include(String) + and + javax.servlet.jsp.PageContext.include(String, boolean) + will throw IOException when an I/O error occur during + the operation. (violetagg) +
fix + 56908: Fix some potential resource leaks when reading jar + files. Reported by Coverity Scan. Based on patch provided by Felix + Schumacher. (violetagg) +
fix + 56991: Deprecate the use of a request attribute to pass a + <jsp-file> declaration to Jasper and prevent an infinite loop + if this technique is used in conjunction with an include. (markt) +
fix + Fix a potential resource leak in JDTCompiler when checking whether + a resource is a package. Reported by Coverity Scan. (fschumacher) +
+
+
WebSocket
+ + + + + + + + + + +
code + 56446: Clearer handling of exceptions when calling a method + on a POJO based WebSocket endpoint. Based on a suggestion by Eugene + Chung. (markt) +
fix + 56746: Allow secure WebSocket client threads to use the + current context class loader rather than explicitly setting it to the + class loader that loaded the WebSocket implementation. This allows + WebSocket client connections from within web applications to access, + amongst other things, the JNDI resources associated with the web + application. (markt) +
fix + 56905: Make destruction on web application stop of thread + group used for WebSocket connections more robust. (kkolinko/markt) +
fix + 56907: Ensure that client IO threads are stopped if a secure + WebSocket client connection fails. (markt) +
fix + When a WebSocket client attempts to write to a closed connection, handle + the resulting IllegalStateException in a manner consistent + with the handling of an IOException. (markt) +
add + Add support for the permessage-deflate extension. This is + currently limited to decompressing incoming messages on the server side. + It is expected that support will be extended to outgoing messages and to + the client side shortly. (markt) +
add + Extend support for the permessage-deflate extension to + compression of outgoing messages on the server side. (markt) +
fix + 56982: Return the actual negotiated extensions rather than an + empty list for Session.getNegotiatedExtensions(). (markt) +
update + Update the WebSocket implementation to support the Java WebSocket + specification version 1.1. (markt) +
+
+
Web applications
+ + + + +
fix + Correct the label in the list of sessions by idle time for the bin that + represents the idle time immediately below the maximum permitted idle + time when using the expire command of the Manager application. (markt) +
update + Update the Windows authentication documentation after some additional + testing to answer the remaining questions. (markt) +
fix + Correct a couple of broken links in the Javadoc. (markt) +
+
+
Other
+ + + + + + +
add + 56788: Display the full version in the list of installed + applications when installed via the Windows installer package. Patch + provided by Alexandre Garnier. (markt) +
add + 56829: Add the ability for users to define their own values + for _RUNJAVA and _RUNJDB environment + variables. Be more strict with executable filename on Windows + (s/java/java.exe/). Based on a patch by Neeme Praks. (markt/kkolinko) +
fix + 56895: Correctly compose JAVA_OPTS in + catalina.bat so that escape sequences are preserved. Patch + by Lucas Theisen. (markt) +
update + 56988: Allow to use relative path in base.path + setting when building Tomcat. (kkolinko) +
fix + 56990: Ensure that the ide-eclipse build target + downloads all the libraries required by the default Eclipse + configuration files and configures Eclipse to use Java 6 for the + project. Add build target ide-eclipse-websocket that + creates a separate linked project that compiles websocket classes + of Tomcat 7 with Java 7 compiler. (kkolinko) +
+
+
Tomcat 7.0.55 (violetagg)released 2014-07-27
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 44312: Log an error if there is a conflict between Host and + Alias names. Improve host management methods in Mapper + to avoid occasionally removing a wrong host. Check that host management + operations are performed on the host and not on an alias. (kkolinko) +
fix + 55282: Ensure that one and the same application listener is + added only once when starting the web application. (violetagg) +
add + 56461: New failCtxIfServletStartFails attribute + on Context and Host configuration to force the context startup to fail + if a load-on-startup servlet fails its startup. (slaurent) +
add + 56526: Improved the StuckThreadDetectionValve to + optionally interrupt stuck threads to attempt to unblock them. + (slaurent) +
fix + 56545: Pre-load an additional class, the loading of which + may otherwise be triggered by a web application which in turn would + trigger an exception when running under a security manager. (kkolinko) +
fix + 56578: Correct regression in the fix for 56339 + that prevented sessions from expiring when using clustering. (markt) +
code + 56588: Update deprecation of Context.addApplicationListener() + methods according to changes in Tomcat 8. (kkolinko) +
fix + 56600: In WebdavServlet: Do not waste time generating + response for broken PROPFIND request. (kkolinko) +
fix + Provide a better error message when asynchronous operations are not + supported by a filter or servlet. Patch provided by Romain Manni-Bucau. + (violetagg) +
fix + 56606: User entries in tomcat-users.xml file + are recommended to use "username" attribute rather than legacy "name" + attribute. Fix inconsistencies in Windows installer, examples. Update + digester rules and documentation for MemoryRealm. + (markt/kkolinko) +
code + 56611: Refactor code to remove inefficient calls to + Method.isAnnotationPresent(). Based on a patch by Jian Mou. + (markt/kkolinko) +
fix + 56653: Fix concurrency issue with lists of contexts in + Mapper when stopping Contexts. (kkolinko) +
fix + 56657: When using parallel deployment, if the same session id + matches different versions of a web application, prefer the latest + version. Ensure that remapping selects the version that we expect. + (kkolinko) +
fix + Assert that mapping result object is empty before performing mapping + work in Mapper. (kkolinko) +
fix + 56658: Avoid delay between registrations of mappings for + context and for its servlets. (kkolinko) +
fix + 56665: Correct the generation of the effective web.xml when + elements contain an empty string as value. (violetagg) +
fix + 56666: When clearing the SSO cookie use the same values for + domain, path, httpOnly and secure as were used to set the SSO cookie. + (markt) +
fix + 56677: Ensure that + HttpServletRequest.getServletContext() returns the correct + value during a cross-context dispatch. (markt) +
fix + 56684: Ensure that Tomcat does not shut down if the socket + waiting for the shutdown command experiences a + SocketTimeoutException. (markt) +
fix + When the current PathInfo is modified as a result of dispatching a + request, ensure that a call to + HttpServletRequest.getPathTranslated() returns a value that + is based on the modified PathInfo. (markt) +
fix + 56698: When persisting idle sessions, only persist newly idle + sessions. Patch provided by Felix Schumacher. (markt) +
fix + 56710: Do not map requests to servlets when context is + being reloaded. (kkolinko) +
fix + 56712: Fix session idle time calculations in + PersistenceManager. (kkolinko) +
fix + 56717: Fix duplicate registration of + MapperListener during repeated starts of embedded Tomcat. + (kkolinko) +
add + 56724: Write an error message to Tomcat logs if container + background thread is aborted unexpectedly. (kkolinko) +
+
+
Coyote
+ + + + + + + + + + + + + +
fix + 56518: When using NIO, do not attempt to write to the socket + if the thread is marked interrupted as this will lead to a connection + limit leak. This fix was based on analysis of the issue by hanyong. + (markt) +
fix + 56521: Re-use the asynchronous write buffer between writes to + reduce allocation and GC overhead. Based on a patch by leonzhx. Also + make the buffer size configurable and remove copying of data within + buffer when the buffer is only partially written on a subsequent write. + (markt) +
fix + Correct a copy/paste error and return a 500 response rather than a 400 + response when an internal server error occurs on early stages of + request processing. (markt) +
code + 56582: Use switch(actionCode) in processors instead of a + chain of "elseif"s. (kkolinko) +
fix + Fix CVE-2014-0227: + Various improvements to ChunkedInputFilter including clean-up, i18n for + error messages and adding an error flag to allow subsequent attempts at + reading after an error to fail fast. (markt) +
fix + If request contains an unrecognized Expect header, respond with error + 417 (Expectation Failed), according to RFC2616 chapter 14.20. (markt) +
fix + When an error occurs after the response has been committed close the + connection immediately rather than attempting to finish the response to + make it easier for the client to differentiate between a complete + response and one that failed part way though. (markt) +
fix + 56620: Avoid bogus access log entries when pausing the NIO + HTTP connector and ensure that access log entries generated by error + conditions use the correct request start time. (markt) +
add + Fix CVE-2014-0230: + Add a new limit, defaulting to 2MB, for the amount of data Tomcat will + swallow for an aborted upload. The limit is configurable by + maxSwallowSize attribute of an HTTP connector. (markt) +
update + Allow to configure maxSwallowSize attribute of an HTTP + connector via JMX. (kkolinko) +
fix + 56661: Fix getLocalAddr() for AJP connectors. + The complete fix is only available with a recent AJP forwarder like + the forthcoming mod_jk 1.2.41. (rjung) +
fix + 59451: Correct Javadoc for MessageBytes. Patch + provided by Kyohei Nakamura. (markt) +
+
+
Jasper
+ + + + + + + +
fix + 56334#c15: Fix a regression in EL parsing when quoted string + follows a whitespace. (kkolinko/markt) +
fix + 56543: Update to the Eclipse JDT Compiler 4.4. (violetagg) +
fix + 56561: Avoid NoSuchElementException while handling + attributes with empty string value. (violetagg) +
update + 56581: If an error on a JSP page occurs when response has + already been committed, do not clear the buffer of JspWriter, but flush + it. It will make more clear where the error occurred. (kkolinko) +
fix + 56612: Correctly parse two consecutive escaped single quotes + when used in UEL expression in a JSP. (markt) +
update + Move code that parses EL expressions within JSP template text from + Parser to JspReader class for better + performance. (kkolinko) +
+
+
WebSocket
+ + +
fix + 56577: Improve the executor configuration used for the + callbacks associated with asynchronous writes. (markt) +
+
+
Web applications
+ + + +
fix + Set the path for cookies created by the examples web application so they + only returned to the examples application. This reduces the opportunity + for using such cookies for malicious purposes should the advice to + remove the examples web application from security sensitive systems be + ignored. (markt/kkolinko) +
fix + Attempt to obfuscate session cookie values associated with other web + applications when viewing HTTP request headers with the Request Header + example from the examples web application. This reduces the opportunity + to use this example for malicious purposes should the advice to remove + the examples web application from security sensitive systems be ignored. + (markt) +
+
+
Other
+ + + + +
update + Update optional Checkstyle library to 5.7. (kkolinko) +
fix + 56685: Add quotes necessary for daemon.sh to + work correctly on Solaris. Based on a suggestion by lfuka. (markt) +
update + 56596: Update to Tomcat Native Library version 1.1.31 to pick + up the Windows binaries that are based on OpenSSL 1.0.1h. (markt) +
+
+
Tomcat 7.0.54 (violetagg)released 2014-05-22
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + Fix custom UTF-8 decoder so that a byte of value 0xC1 is always rejected + immediately as it is never valid in a UTF-8 byte sequence. Update UTF-8 + decoder tests to account for UTF-8 decoding improvements in Java 8. + The custom UTF-8 decoder is still required due to bugs in the UTF-8 + decoder provided by Java. Java 8's decoder is better than Java + 7's but it is still buggy. (markt) +
fix + 56027: Add more options for managing FIPS mode in the + AprLifecycleListener. (schultz/kkolinko) +
fix + 56321: When a WAR is modified, undeploy the web application + before deleting any expanded directory as the undeploy process may + refer to classes that need to be loaded from the expanded directory. If + the expanded directory is deleted first, any attempt to load a new class + during undeploy will fail. (markt) +
fix + 56339: Avoid an infinite loop if an application calls + session.invalidate() from the session destroyed event for + that session. (markt) +
update + 56365: Simplify file name pattern matching code in + StandardJarScanner. Ignore leading and trailing whitespace + and empty strings when configuring patterns. Improve documentation. + (kkolinko) +
fix + 56369: Ensure that removing an MBean notification listener + reverts all the operations performed when adding an MBean notification + listener. (markt) +
add + 56382: Information about finished deployment and its execution + time is added to the log files. Patch is provided by Danila Galimov. + (violetagg) +
add + 56383: Properties for disabling server information and error + report are added to the org.apache.catalina.valves.ErrorReportValve. + Based on the patch provided by Nick Bunn. (violetagg/kkolinko) +
fix + Fix CVE-2014-0119: + Only create XML parsing objects if required and fix associated potential + memory leak in the default Servlet. + Extend XML factory, parser etc. memory leak protection to cover some + additional locations where, theoretically, a memory leak could occur. + Ensure that a TLD parser obtained from the cache has the correct value + of blockExternal. (markt) +
fix + Modify generic exception handling so that + StackOverflowError is not treated as a fatal error and can + handled and/or logged as required. (markt) +
fix + 56409: Avoid StackOverflowError on non-Windows + systems if a file named \ is encountered when scanning for + TLDs. (markt) +
add + 56430: Extend checks for suspicious URL patterns to include + patterns of the form *.a.b which are not valid patterns for + extension mappings. (markt) +
fix + 56441: Raise the visibility of exceptions thrown when a + problem is encountered calling a getter or setter on a component + attribute. The logging level is raised from debug to warning. (markt) +
fix + 56451: Make resources accessed via a context alias accessible + via JNDI in the same way standard resources are available. (markt) +
add + 56463: Property for disabling server information is added to + the DefaultServlet. Server information is presented in the + response sent to the client when directory listings is enabled. + (violetagg) +
add + Add the org.apache.naming package to the packages requiring + code to have the defineClassInPackage permission when + running under a security manager. (markt) +
add + Add the org.apache.naming.resources package to the packages + requiring code to have the accessClassInPackage permission + when running under a security manager. (markt) +
fix + Make the naming context tokens for containers more robust. Require + RuntimePermission when introducing a new token. (markt/kkolinko) +
fix + 56472: Allow NamingContextListener to clean up on stop if its + start failed. (kkolinko) +
add + 56492: Avoid eclipse debugger pausing on uncaught exceptions + when tomcat renews its threads. (slaurent) +
fix + Minor fixes to ThreadLocalLeakPreventionListener. Do not + trigger threads renewal for failed contexts. Do not ignore + threadRenewalDelay setting. Improve documentation. (kkolinko) +
fix + Correct regression introduced in r797162 that broke + authentication of users when using the + JAASMemoryLoginModule. (markt) +
fix + 56501: HttpServletRequest.getContextPath() + should return the undecoded context path used by the user agent. (markt) +
fix + 56523: When using SPNEGO authentication, log the exceptions + associated with failed user logins at debug level rather than error + level. (markt) +
fix + 56536: Ensure that + HttpSessionBindingListener.valueUnbound() uses the correct + class loader when the SingleSignOn valve is used. (markt) +
+
+
Coyote
+ + + +
add + 56399: Assert that both Coyote and Catalina request objects + have been properly recycled. (kkolinko) +
fix + 56416: Correct documentation for default value of socket + linger for the AJP and HTTP connectors. (markt) +
+
+
Jasper
+ + + + + +
fix + 56334: Fix a regression in the handling of back-slash + escaping introduced by the fix for 55735. (markt/kkolinko) +
fix + 56425: Improve method matching for EL expressions. When + looking for matching methods, an exact match between parameter types is + preferred followed by an assignable match followed by a coercible match. + (markt) +
fix + Correct the handling of back-slash escaping in the EL parser and no + longer require that \$ or \# must be followed + by { in order for the back-slash escaping to take effect. + (markt) +
fix + 56529: Avoid NoSuchElementException while handling + attributes with empty string value in custom tags. Patch provided by + Hariprasad Manchi. (violetagg) +
+
+
Cluster
+ + + + + + + + +
fix + Remove cluster and replicationValve from cluster manager template. These + instance are not necessary to template. (kfujino) +
fix + Add support for cross context session replication to + org.apache.catalina.ha.session.BackupManager. (kfujino) +
fix + Remove the unnecessary cross context check. It does not matter whether + the context that is referenced by other context is set to + crossContext=true. The context that refers to the different + context must be set to crossContext=true. (kfujino) +
code + Move to org.apache.catalina.ha.session.ClusterManagerBase + common logics of + org.apache.catalina.ha.session.BackupManager and + org.apache.catalina.ha.session.DeltaManager. (kfujino) +
code + Simplify the code of o.a.c.ha.tcp.SimpleTcpCluster. In + order to add or remove cluster valve to Container, use pipeline instead + of IntrospectionUtils. (kfujino) +
fix + There is no need to set cluster instance when + SimpleTcpCluster.unregisterClusterValve is called. + Set null than cluster instance for cleanup. (kfujino) +
code + Backport refactoring of AbstractReplicatedMap to implement + Map rather than extend ConcurrentHashMap to + enable Tomcat 7 to be built with Java 8. (markt) +
+
+
WebSocket
+ + + + + + + + +
fix + 56343: Avoid a NPE if Tomcat's Java WebSocket 1.0 + implementation is used with the Java WebSocket 1.0 API JAR from the + reference implementation. (markt) +
fix + Increase the default maximum size of the executor used by the WebSocket + implementation for call backs associated with asynchronous writes from + 10 to 200. (markt) +
add + Add a warning if the thread group created for WebSocket asynchronous + write call backs can not be destroyed when the web application is + stopped. (markt) +
fix + Ensure that threads created to support WebSocket clients are stopped + when no longer required. This will happen automatically for WebSocket + client connections initiated by web applications but stand alone clients + must call WsWebSocketContainer.destroy(). (markt) +
fix + 56449: When creating a new session, add the message handlers + to the session before calling Endpoint.onOpen() so the + message handlers are in place should the onOpen() method + trigger the sending of any messages. (markt) +
fix + 56458: Report WebSocket sessions that are created over secure + connections as secure rather than as not secure. (markt) +
fix + Stop threads used for secure WebSocket client connections when they are + no longer required and give them better names for easier debugging while + they are running. (markt) +
+
+
Web applications
+ + + + + + + + + +
fix + Add Support for copyXML attribute of Host to Host Manager. + (kfujino) +
fix + Ensure that "name" request parameter is used as a application base of + host if "webapps" request parameter is not set when adding host in + HostManager Application. (kfujino) +
fix + Correct documentation on Windows service options, aligning it with + Apache Commons Daemon documentation. (kkolinko) +
update + 55215: Improve log4j configuration example. Clarify access + logging documentation. Based on patches provided by Brian Burch. + (kkolinko) +
update + 55383: Backport improved HTML markup for tables and code + fragments from Tomcat 8 documentation. (kkolinko) +
fix + 56418: Ensure that the Manager web application does not + report success for a web application deployment that fails. (slaurent) +
fix + Fix target and rel attributes on links in documentation. They were + lost during XSLT transformation. (kkolinko) +
update + Improve valves documentation. Split valves into groups. (kkolinko) +
+
+
Other
+ + + + + +
fix + Align DisplayName of Tomcat installed by service.bat with + one installed by the *.exe installer. Print a warning in case if neither + server nor client jvm is found by service.bat. (kkolinko) +
update + 56363: Update to version 1.1.30 of Tomcat Native library. + (schultz) +
update + Update package renamed Apache Commons BCEL to r1593495 to pick up some + additional changes for Java 7 support and some code clean up. (markt) +
add + In tests: allow to configure directory where JUnit reports and access + log are written to. (kkolinko) +
+
+
Tomcat 7.0.53 (violetagg)released 2014-03-30
+
Catalina
+ + + + + + + + + + + +
add + Make it easier for applications embedding and/or extending Tomcat to + modify the javaseClassLoader attribute of the + WebappClassLoader. (markt) +
fix + Improve the robustness of web application undeployment based on some + code analysis triggered by the report for 54315. (markt) +
fix + 56219: + Improve merging process for web.xml files to take account of the + elements and attributes supported by the Servlet version of the merged + file. (markt) +
fix + 56190: The response should be closed (i.e. no further output + is permitted) when a call to AsyncContext.complete() takes + effect. (markt) +
fix + 56236: Enable Tomcat to work with alternative Servlet and + JSP API JARs that package the XML schemas in such as way as to require + a dependency on the JSP API before enabling validation for web.xml. + Tomcat has no such dependency. (markt) +
fix + 56246: Fix NullPointerException in MemoryRealm when + authenticating an unknown user. (markt) +
fix + 56248: Allow the deployer to update an existing WAR file + without undeploying the existing application if the update flag is set. + This allows any existing custom context.xml for the application to be + retained. To update an application and remove any existing context.xml + simply undeploy the old version of the application before deploying the + new version. (markt) +
fix + Fix CVE-2014-0096: + Redefine the globalXsltFile initialisation parameter of the + DefaultServlet as relative to CATALINA_BASE/conf or CATALINA_HOME/conf. + Prevent user supplied XSLTs used by the DefaultServlet from defining + external entities. (markt) +
add + Add a work around for validating XML documents (often TLDs) that use + just the file name to refer to the JavaEE schema on which they + are based. (markt) +
fix + 56293: Cache resources loaded by the class loader from + /META-INF/services/ for better performance for repeated + look ups. (markt) +
+
+
Coyote
+ + + + + + +
fix + 53119: Make sure the NIO AJP output buffer is cleared on any + error to prevent any possible overflow if it is written to again before + the connection is closed. This extends the original fix for the + APR/native output buffer to the NIO connector. (kkolinko) +
fix + 56172: Avoid possible request corruption when using the AJP + NIO connector and a request is sent using more than one AJP message. + Patch provided by Amund Elstad. (markt) +
fix + 56213: Reduce garbage collection when the NIO connector is + under heavy load. (markt) +
fix + Fix CVE-2014-0075: + Improve processing of chuck size from chunked headers. Avoid overflow + and use a bit shift instead of a multiplication as it is marginally + faster. (markt/kkolinko) +
fix + Fix CVE-2014-0099: + Fix possible overflow when parsing long values from a byte array. + (markt) +
+
+
Jasper
+ + + + + + + + +
fix + 54475: Add Java 8 support to SMAP generation for JSPs. Patch + by Robbie Gibson. (markt) +
fix + 55483: Improve handing of overloaded methods and constructors + in expression language implementation. (markt) +
fix + 56208: + Restore the validateXml option to Jasper that was previously renamed + validateTld. Both options are now supported. validateXml controls the + validation of web.xml files when Jasper parses them and validateTld + controls the validation of *.tld files when Jasper parses them. (markt) +
fix + 56223: Throw an IllegalStateException if a call + is made to ServletContext.setInitParameter() after the + ServletContext has been initialized. (markt) +
fix + 56265: Do not escape values of dynamic tag attributes + containing EL expressions. (kkolinko) +
fix + Make the default compiler source and target versions for JSPs Java 6 + since Tomcat 7 requires Java 6 as a minimum. (markt) +
update + 56283: Update to the Eclipse JDT Compiler P20140317-1600 + which adds support for Java 8 syntax to JSPs. Add support for value + "1.8" for the compilerSourceVM and + compilerTargetVM options. (markt) +
+
+
WebSocket
+ + + +
fix + Avoid a possible deadlock when one thread is shutting down a connection + while another thread is trying to write to it. (markt) +
fix + Call onError if an exception is thrown calling onClose when closing + a session. (remm) +
+
+
Web applications
+ + + + + + + + + +
code + In the documentation: add support for several documentation tags from + Tomcat 8. Such as <version-major/>. (kkolinko) +
add + 56093: Add the SSL Valve to the documentation web + application. (markt) +
fix + 56217: Improve readability by using left alignment for the + table cell containing the request information on the Manager application + status page. (markt) +
fix + Fixed java.lang.NegativeArraySizeException when using + "Expire sessions" command in the manager web application on a + context where the session timeout is disabled. (kfujino) +
fix + Add support for LAST_ACCESS_AT_START system property to + Manager web application. (kfujino) +
fix + Add definition of org.apache.catalina.ant.FindLeaksTask. + (kfujino) +
fix + 56273: If the Manager web application does not perform an + operation because the web application is already being serviced, report + an error rather than reporting success. (markt) +
fix + 56304: Add a note to the documentation about not using + WebSocket with BIO HTTP in production. (markt) +
+
+
Other
+ + + + + + + + + + +
fix + 56143: Improve service.bat so that it can be + launched from a non-UAC console. This includes using a single call to + tomcat7.exe to install the Windows service rather than + three calls, and using command line arguments instead of environment + variables to pass the settings. (markt/kkolinko) +
fix + Fix regression in 7.0.52: when using service.bat install + to install the service the values for --StdOutput, --StdError options + were passed as blank instead of "auto". (kkolinko) +
fix + Align options between service.bat and exe + Windows installer. For service.bat the changes are in + --Classpath, --DisplayName, --StartPath, --StopPath. For + exe installer the changes are in --JvmMs, --JvmMx options, + which are now 128 Mb and 256 Mb respectively instead of being empty. + Explicitly specify --LogPath path when uninstalling Windows service, + avoiding default value for that option. (kkolinko) +
code + Simplify Windows *.bat files: remove %OS% checks, as java 6 does + not run on ancient non-NT operating systems. (kkolinko) +
fix + 56137: Explicitly use the BIO connector in the SSL example in + server.xml so it doesn't break if APR is enabled. (markt) +
fix + 56139: Avoid a web application class loader leak in some unit + tests when running on Windows. (markt) +
fix + Correct build script to avoid building JARs with empty packages. (markt) +
add + Allow to limit JUnit test run to a number of selected test case + methods. (kkolinko) +
fix + 56189: Remove used file cpappend.bat from the distribution. + (markt) +
+
+
Tomcat 7.0.52 (violetagg)released 2014-02-17
+
Catalina
+ + +
fix + Generate a valid root element for the effective web.xml for a web + application for all supported versions of web.xml. (markt) +
+
+
Coyote
+ + + +
code + Pull up SocketWrapper to AbstractProcessor. + (markt) +
fix + In some circumstances asynchronous requests could time out too soon. + (markt) +
+
+
Tomcat 7.0.51 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + +
fix + 55287: ServletContainerInitializer defined in + the container may not be found. (markt/jboynes) +
fix + 55855: Provide a per Context option (containerSciFilter) to + exclude container SCIs. (markt) +
fix + 55937: When deploying applications, treat a context path of + /ROOT as equivalent to /. (markt) +
fix + 55943: Improve the implementation of the class loader check + that prevents web applications from trying to override J2SE + implementation classes. As part of this fix, refactor the way a null + parent class loader is handled which enables a number of null checks and + object creation calls to be removed. Note that this change means that, + by default, the web application class loader is now a higher priority + for loading classes than the system class loader. (markt) +
fix + 55958: Differentiate between foo.war the WAR + file and foo.war the directory. (markt) +
fix + 55960: Improve the single sign on (SSO) unit tests. Patch + provided by Brian Burch. (markt) +
fix + 55974: Retain order when reporting errors and warnings while + parsing XML configuration files. (markt) +
fix + 56013: Fix issue with SPNEGO authentication when using IBM + JREs. IBM JREs only understand the option of infinite lifetime for + Kerberos credentials. Based on a patch provided by Arunav Sanyal. + (markt) +
fix + 56016: When loading resources for XML schema validation, take + account of the possibility that servlet-api.jar and jsp-api.jar may not + be loaded by the same class loader. Patch by Juan Carlos Estibariz. + (markt) +
fix + 56025: When creating a WebSocket connection, always call + ServerEndpointConfig.Configurator.getNegotiatedSubprotocol() + and always create the EndPoint instance after calling + ServerEndpointConfig.Configurator.modifyHandshake(). + (markt) +
fix + 56032: Ensure that the WebSocket connection is closed after + an IO error or an interrupt while sending a WebSocket message. (markt) +
fix + 56042: If a request in async mode has an error but has + already been dispatched don't generate an error page in the + ErrorReportValve so the dispatch target can handle it. (markt) +
fix + Add missing javax.annotation.sql.* classes to + annotations-api.jar. (markt) +
fix + The type of logger attribute of Context MBean should be not + org.apache.commons.logging.Log but + org.apache.juli.logging.Log. (kfujino) +
fix + 56082: Fix a concurrency bug in JULI's LogManager + implementation. (markt) +
fix + 56096: When the attribute rmiBindAddress of the + JMX Remote Lifecycle Listener is specified it's value will be used when + constructing the address of a JMX API connector server. Patch is + provided by Jim Talbut. (violetagg) +
fix + When environment entry with one and the same name is defined in the web + deployment descriptor and with annotation then the one specified in the + web deployment descriptor is with priority. (violetagg) +
fix + Change default value of xmlBlockExternal attribute of + Context. It is true now. (kkolinko) +
+
+
Coyote
+ + + + + + +
fix + Avoid possible NPE if a content type is specified without a character + set. (markt) +
fix + 55956: Make the forwarded remote IP address available to the + Connectors via a request attribute. (markt) +
fix + 55976: Fix sendfile support for the HTTP NIO connector. + (markt) +
fix + 55996: Ensure Async requests timeout correctly when using the + NIO HTTP connector. (markt) +
add + 56021: Make it possible to use the Windows-MY key store with + the BIO and NIO connectors for SSL configuration. It requires a + keystoreFile="" keystoreType="Windows-My" + to be set on the connector. Based on a patch provided by Asanka. (markt) +
+
+
Jasper
+ + + + + + + + + +
fix + Correct a regression in the XML refactoring that meant that errors in + TLD files were swallowed. (markt) +
fix + 55671: Correct typo in the log message for a wrong value of + genStringAsCharArray init-param of JspServlet. This parameter + had a different name in Tomcat 6. (kkolinko) +
fix + 55973: Fix processing of XML schemas when validation is + enabled in Jasper. (kkolinko) +
fix + 56010: Don't throw an + IllegalArgumentException when + JspFactory.getPageContext is used with + JspWriter.DEFAULT_BUFFER. Based on a patch by Eugene Chung. + (markt) +
fix + 56012: When using the extends attribute of the page directive + do not import the super class if it is in an unnamed package as imports + from unnamed packages are now explicitly illegal. (markt) +
fix + 56029: A regression in the fix for 55198 meant + that when EL containing a ternary expression was used in an attribute + a compilation error would occur for some expressions. (markt) +
fix + Correct several errors in jspxml Schema and DTD. (kkolinko) +
fix + Change default value of the blockExternal attribute of + JspC task. The default value is true. Add support for + -no-blockExternal switch when JspC is run as a + standalone application. (kkolinko) +
+
+
Cluster
+ + +
code + Simplify the code of + o.a.c.ha.tcp.SimpleTcpCluster.createManager(String). + Remove unnecessary class cast. (kfujino) +
+
+
WebSocket
+ + +
fix + Do not return an empty string for the + Sec-WebSocket-Protocol HTTP header when no sub-protocol has + been requested or no sub-protocol could be agreed as RFC6455 requires + that no Sec-WebSocket-Protocol header is returned in this + case. (markt) +
+
+
Web applications
+ + + + + + + + +
fix + Add index.xhtml to the welcome files list for the examples web + application. (kkolinko) +
fix + Clarify that the connectionTimeout may also be used as the read timeout + when reading a request body (if any) in the documentation web + application. (markt) +
fix + Clarify the behaviour of the maxConnections attribute for a connector in + the documentation web application. (markt) +
fix + 55888: Update the documentation web application to make it + clearer that a Container may define no more than one Realm. (markt) +
fix + 55956: Where available, displayed the forwarded remote IP + address available on the status page of the Manager web application. + (markt) +
fix + Correct links to the Tomcat mailing lists in the ROOT web application. + (kkolinko) +
fix + In Manager web application improve handling of file upload errors. + Display a message instead of error 500 page. Simplify parts handling + code, as it is known that Tomcat takes care of them when recycling a + request. (kkolinko) +
+
+
Extras
+ + + +
fix + 55166, 56045: Copy the XML schemas used for + validation that are packaged in jsp-api.jar to servlet-api.jar so that + an embedded Tomcat instance can start without Jasper being available. + This also enables validation to work without Jasper being available. + (markt/kkolinko) +
fix + 56039: Enable the JmxRemoteLifecycleListener to work over + SSL. Patch by esengstrom. (markt) +
+
+
Other
+ + + + + + + +
fix + 55743: Enable the stop script to work when the shutdown port + is disabled and a PID file is defined. This is only available on + platforms that use catalina.sh. (markt) +
fix + 55986: When forcing Tomcat to stop via + kill -9 $CATALINA_PID, the catalina.sh script + could incorrectly report that Tomcat had not yet completely stopped when + it had. Based on a patch by jess. (markt) +
fix + Package correct license and notice files with embedded JARs. (markt) +
code + Remove svn keywords (such as $Id) from source files and documentation. + (kkolinko) +
fix + Fix CVE-2014-0050, a denial of service with a malicious, malformed + Content-Type header and multipart request processing. Fixed by merging + latest code (r1565163) from Commons FileUpload. (markt) +
fix + 56115: Expose the httpusecaches property of + Ant's get task as some users may need to change the + default. Based on a suggestion by Anthony. (markt) +
+
+
Tomcat 7.0.50 (violetagg)released 2014-01-08
+
Catalina
+ + + + + + + +
fix + Handle the case where a context.xml file is added to a + web application deployed from a directory. Previously the file was + ignored until Tomcat was restarted. Now (assuming automatic deployment + is enabled) it will trigger a redeploy of the web application. (markt) +
fix + Fix string comparison in HostConfig.setContextClass(). + (kkolinko) +
code + Streamline handling of WebSocket messages when no handler is configured + for the message currently being received. (markt) +
fix + Handle the case where a WebSocket annotation configures a message size + limit larger than the default permitted by Tomcat. (markt) +
fix + 55855: This is a partial fix that bypasses the relatively + expensive check for a WebSocket upgrade request if no WebSocket + endpoints have been registered. (markt) +
fix + 55905: Prevent a NPE when web.xml references a taglib file + that does not exist. Provide better error message. (violetagg) +
+
+
Coyote
+ + +
fix + When using the BIO connector with an internal executor, do not display a + warning that the executor has not shutdown as the default configuration + for BIO connectors is not to wait. This is because threads in + keep-alive connections cannot be interrupted and therefore the warning + was nearly always displayed. (markt) +
+
+
Jasper
+ + +
fix + JspC uses servlet context initialization parameters to pass + configuration so ensure that the servlet context used supports + initialization parameters. (markt) +
+
+
Cluster
+ + + +
fix + In AbstractReplicatedMap#finalize, remove rpcChannel from + channel Listener of group channel before sending + MapMessage.MSG_STOP message. This prevents that the node + that sent the MapMessage.MSG_STOP by normal shutdown is + added to member map again by ping at heartbeat thread in the node that + received the MapMessage.MSG_STOP. (kfujino) +
fix + Add time stamp to GET_ALL_SESSIONS message. (kfujino) +
+
+
Web applications
+ + +
fix + Fix the sample configuration of StaticMembershipInterceptor + in order to prevent warning log. uniqueId must be 16 bytes. (kfujino) +
+
+
Extras
+ + +
update + Update dependencies that are used to build tomcat-juli extras component. + Apache Avalon Framework is updated to version 4.1.5, Apache Log4J to + version 1.2.17. (rjung) +
+
+
Tomcat 7.0.49 (violetagg)not released
+
Catalina
+ + + +
fix + Correct a regression in the new XML local resolver that triggered false + failures when XML validation was configured. (markt) +
fix + Prevent a NPE when destroying HTTP upgrade handler for WebSocket + connections. (violetagg) +
+
+
Tomcat 7.0.48 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
add + 51294: Add support for unpacking WARs located outside of the + Host's appBase in to the appBase. (markt) +
fix + 55656: Configure the Digester to use the server class loader + when parsing server.xml rather than the class loader that loaded + StandardServer. Patch provided by Roberto Benedetti. (markt) +
fix + 55664: Correctly handle JSR 356 WebSocket Encoder, Decoder + and MessageHandler implementations that use a generic type such as + Encoder.Text<List<String>>. Includes a test + case by Niki Dokovski. (markt) +
fix + Correctly handle WebSocket Encoders, Decoders + and MessageHandlers that use arrays of generic types. + (markt) +
fix + 55681: Ensure that the WebSocket session is made available + to MessageHandler method calls. (markt) +
fix + Updated servlet spec version and documentation section-number reported + when JAR files are rejected for containing a trigger class + (e.g. javax.servlet.Servlet). (schultz) +
add + Modify the WebSocket handshake process so that the user properties + Map exposed by the ServerEndpointConfig during + the call to Configurator.modifyHandshake() is unique to the + connection rather than shared by all connections associated with the + Endpoint. This allows for easier configuration of per connection + properties from within modifyHandshake(). (markt) +
fix + 55684: Log a warning but continue if the memory leak + detection code is unable to access all threads to check for possible + memory leaks when a web application is stopped. (markt) +
fix + Define the web-fragment.xml in tomcat7-websocket.jar as a Servlet 3.0 + web fragment rather than as a Servlet 3.1 web fragment. (markt) +
fix + 55715: Add a per web application executor to the WebSocket + implementation and use it for calling + SendHandler.onResult() when there is a chance that the + current thread also initiated the write. (markt) +
fix + Prevent file descriptors leak and ensure that files are closed when + configuring the web application. (violetagg) +
fix + Fixed the name of the provider-configuration file located in + tomcat7-websocket.jar!/META-INF/services that exposes + information for + javax.websocket.server.ServerEndpointConfig$Configurator + implementation. (violetagg) +
fix + 55760: Remove the unnecessary setting of the + javax.security.auth.useSubjectCredsOnly system property in + the SpnegoAuthenticator as in addition to it being + unnecessary, it causes problems with using SPNEGO with IBM JDKs. Patch + provided by Arunav Sanyal. (markt) +
fix + 55772: Ensure that the request and response are recycled + after an error during asynchronous processing. Includes a test case + based on code contributed by Todd West. (markt) +
fix + 55778: Add an option to the JNDI Realm to control the QOP + used for the connection to the LDAP server after authentication when + using SPNEGO with delegated credentials. This value is used to set the + javax.security.sasl.qop environment property for the LDAP + connection. (markt) +
fix + 55798: Log an error if the MemoryUserDatabase is unable to + find the specified user database file. (markt) +
fix + 55799: Correctly enforce the restriction in JSR356 that no + more than one data message may be sent to a remote WebSocket endpoint at + a time. (markt) +
fix + When Catalina parses TLD files, always use a namespace aware parser to + be consistent with how Jasper parses TLD files. The + tldNamespaceAware attribute of the Context is now ignored. + (markt) +
fix + Deprecate the tldNamespaceAware Context attribute as TLDs + are always parsed with a namespace aware parser. (markt) +
fix + Correct a logic error that meant that unpackWARs was ignored and the WAR + was always expanded if a WAR failed to deploy. (markt) +
add + Add support for defining copyXML on a per Context basis. + (markt) +
fix + Define the expected behaviour of the automatic deployment and align the + implementation to that definition. (markt) +
add + When running under a security manager, change the default value of the + Host's deployXML attribute to false. + (markt) +
add + If a Host is configured with a value of false for + deployXML, a web application has an embedded + descriptor at META-INF/context.xml and no explicit + descriptor has been defined for this application, do not allow the + application to start. The reason for this is that the embedded + descriptor may contain configuration necessary for secure operation + such as a RemoteAddrValve. (markt) +
fix + Prevent an NPE in the WebSocket ServerContainer when + processing an HTTP session end event. (markt) +
add + 55801: Add the ability to set a custom + SSLContext to use for client wss connections. Patch + provided by Maciej Lypik. (markt) +
fix + 55804: If the GSSCredential for the cached Principal expires + when using SPNEGO authentication, force a re-authentication. (markt) +
add + 55811: If the main web.xml contains an empty + absolute-ordering element and validation of web.xml is not enabled, skip + parsing any web-fragment.xml files as the result is never used. (markt) +
fix + 55839: Extend support for digest prefixes {MD5}, {SHA} and + {SSHA} to all Realms rather than just the JNDIRealm. (markt) +
fix + 55842: Ensure that if a larger than default response buffer + is configured that the full buffer is used when a Servlet outputs via a + Writer. (markt) +
fix + 55851: Further fixes to enable SPNEGO authentication to work + with IBM JDKs. Based on a patch by Arunav Sanyal. (markt) +
add + Fix CVE-2013-4590: + Add an option to the Context to control the blocking of XML external + entities when parsing XML configuration files and enable this blocking + by default when a security manager is used. The block is implemented via + a custom resolver to enable the logging of any blocked entities. (markt) +
+
+
Coyote
+ + + + + + + + +
code + Implement a number of small refactorings to the APR/native handler for + upgraded HTTP connections. (markt) +
fix + Fix an issue with upgraded HTTP connections over HTTPS (e.g. secure + WebSocket) when using the APR/native connector that resulted in the + unexpected closure of the connection. (markt) +
fix + Ensure that the application class loader is used when calling the + ReadListener and WriteListener methods when + using non-blocking IO. A side effect of not doing this was that JNDI was + not available when processing WebSocket events. (markt) +
add + Make the time that the internal executor (if used) waits for request + processing threads to terminate before continuing with the connector + stop process configurable. (markt) +
fix + 55749: Improve the error message when SSLEngine + is disabled in the AprLifecycleListener and SSL is + configured for an APR/native connector. (markt) +
add + If a request that includes an Expect: 100-continue header + receives anything other than a 2xx response, close the connection This + protects against misbehaving clients that may not sent the request body + in that case and send the next request instead. (markt) +
fix + Improve the parsing of trailing headers in HTTP requests. (markt) +
+
+
Jasper
+ + + +
fix + 55735: Fix a regression caused by the fix to + 55198. When processing JSP documents, attributes in XML + elements that are template content should have their text xml-escaped, + but output of EL expressions in them should not be escaped. (markt) +
fix + 55807: The JSP compiler used a last modified time of -1 for + TLDs in JARs expanded in to WEB-INF/classes (IDEs often do this + expansion) when creating the dependency list for JSPs that used that + TLD. This meant JSPs using that TLD were recompiled on every access. + (markt) +
+
+
Cluster
+ + + + + + + + + + + + +
add + Add log message that initialization of + AbstractReplicatedMap has been completed. (kfujino) +
fix + The logger of AbstractReplicatedMap should be non-static in + order to enable logging of each application. Side-effects of this change + is to throw RuntimeException in + MapMessage#getKey() and getValue() instead of + Null return and error log. (kfujino) +
code + Simplify the code of DeltaManager#startInternal(). Reduce + unnecessary nesting for acquisition of cluster instance. (kfujino) +
fix + Remove unnecessary attributes of + stateTransferCreateSendTime and receiverQueue + from cluster manager template. These attributes should not be defined as + a template. (kfujino) +
fix + Fix MBean attribute definition of stateTransfered. The + method name is not isStateTransfered() but + getStateTransfered(). (kfujino) +
fix + Correct stop failure log of cluster. Failure cause is not only Valve. + (kfujino) +
fix + Remove unnecessary sleep when sending session blocks on session sync + phase. (kfujino) +
fix + Expose stateTimestampDrop of + org.apache.catalina.ha.session.DeltaManager via JMX. + (kfujino) +
fix + When the ping timeouted, make sure that memberDisappeared + method is not called by specifying the members that has already been + removed. (kfujino) +
add + Add log message of session relocation when member disappeared. (kfujino) +
fix + If ping message fails, prevent wrong timeout detection of normal member + that is no failure members. (kfujino) +
+
+
Web applications
+ + + + + + + + + + +
add + Add some documentation on the SSL configuration options for WebSocket + clients. (markt) +
add + Add to cluster document a description of + notifyLifecycleListenerOnFailure and + heartbeatBackgroundEnabled. (kfujino) +
fix + Update the documentation with information for WebSocket 1.0 specification + and javadoc. (violetagg) +
fix + 55703: Clarify the role of the singleton attribute for JNDI + resource factories. (markt) +
fix + 55746: Add documentation on the allRolesMode to + the CombinedRealm and LockOutRealm. Patch by + Cédric Couralet. (markt) +
add + Expand the information on web applications that ship as part of Tomcat + in the security how-to section of the documentation web application. + (markt) +
fix + Expand the description of the WebSocket buffers in the documentation web + application to clarify their purpose. (markt) +
add + Correct the documentation for Cluster manager. (kfujino) +
add + Add information on how to configure integrated Windows authentication + when Tomcat is running on a non-Windows host. (markt) +
+
+
Extras
+ + +
update + Update commons-logging to version 1.1.3. (rjung) +
+
+
Other
+ + + + +
add + 52323: Add support for the Cobertura code coverage tool + when running the unit tests. Based on a patch by mhasko. + (markt/kkolinko) +
update + Update sample Eclipse IDE project. Explicitly use a Java 6 SE JDK. + Exclude JSR356 WebSocket classes from build path, as they cannot be + compiled with Java 6. (kkolinko) +
update + Update the Eclipse compiler to 4.3.1. (kkolinko/markt) +
+
+
Tomcat 7.0.47 (violetagg)released 2013-10-24
+
Coyote
+ + +
fix + Fix regression with legacy WebSocket implementation in NIO and APR + connectors. (markt) +
+
+
Web applications
+ + +
fix + Avoid hang observed with Java 6 on Windows when stopping the Tomcat + process via CTRL-C. (markt) +
+
+
Other
+ + +
fix + 55663: NOTICE files are corrected according to + NOTICE files requirements. + (violetagg) +
+
+
Tomcat 7.0.46 (violetagg)not released
+
Catalina
+ + + +
fix + Only send a WebSocket close message on an IOException if the client has + not yet received a close control message from the server as the + IOException may be in response to the client continuing to send a + message after the server sent a close control message. (markt) +
fix + 49134: Ensure nested realms are correctly destroyed, when a + CombinedRealm is destroyed. This ensures that the associated MBeans are + deregistered. (markt) +
+
+
Coyote
+ + + + +
code + Refactor APR/native connector to reduce the scope of + localAddList. (markt) +
fix + 55602: Ensure that sockets removed from the Poller and then + closed in the APR/native connector are removed and then closed in a + thread-safe manner. (markt) +
fix + Update the APR/native connector to version 1.1.29. (violetagg) +
+
+
Jasper
+ + +
fix + 55642: Correct logic error in the JSP parser that was + incorrectly identifying EL expressions in jsp:param element values as a + literal string. (markt) +
+
+
Cluster
+ + +
add + Add support for notify periodic event of cluster. (kfujino) +
+
+
Web applications
+ + + + + + + + + +
fix + Correct the javadoc for org.apache.catalina.Lifecycle. + (kfujino) +
add + Add document for sessionIdAttribute attribute in + org.apache.catalina.ha.session.JvmRouteBinderValve. + (kfujino) +
fix + Handle the case when a user closes the browser whilst playing the + snake game in the JSR356 WebSocket examples. (markt) +
fix + Ensure Javadoc comments are associated with the correct elements in + org.apache.tomcat.jni.Poll. (markt) +
add + Expand Context documentation for the use of + sessionCookiePath="/" to make the implications + for session fixation protection clearer. (markt) +
fix + 55629: Ensure that the JMX notification listener added during + initialization of the servlet org.apache.catalina.manager.StatusManagerServlet + is removed in the destroy phase. (violetagg) +
fix + Correct the documentation for Deployment Organization in the App Dev + Guide. (violetagg) +
add + 55639: Add a Drawboard WebSocket example. (kpreisser) +
+
+
Tomcat 7.0.45 (violetagg)not released
+
Catalina
+ + +
add + 55576: Preserve the order in which request parameters were + received when accessing them via the Servlet API. (markt) +
+
+
Cluster
+ + +
fix + Logger instance of cluster session manager is changed to non-static in + order to enable logging of each application. (kfujino) +
+
+
Tomcat 7.0.44 (violetagg)not released
+
Jasper
+ + +
fix + 55582: Correct concurrency issue that can result in two + instances of JspServletWrapper being created for one tag Patch provided + by Sheldon Shao. (markt) +
+
+
Tomcat 7.0.43 (violetagg)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
add + 51526: o.a.catalina.startup.Tomcat#addWebapp + methods now process the web application's META-INF/context.xml + when it is available in the provided path. (violetagg) +
fix + 55186: Ensure local name is recycled between requests so IP + virtual hosting works correctly. (markt) +
fix + 55210: Correct the processing of the provider-configuration + file for javax.servlet.ServletContainerInitializer in the + resource directory META-INF/services when this file + contains comments and multiple SCIs. Patch provided by Nick Williams. + (violetagg) +
fix + 55230: Use the correct resource path when obtaining an + InputStream for resources served by a ProxyDirContext. (markt) +
fix + Ensure that the JAR scanning process scans the Apache Log4j version 2 + JARs. Patch provided by Nick Williams. (markt) +
fix + 55261: Fix failing unit test for file upload checks when + running on platform / JVM combinations that have large network buffers. + (markt) +
fix + 55268: Added optional --service-start-wait-time + command-line option to change service start wait time from default of 10 + seconds. +
fix + The contextClass attribute of HostConfig + refers to the value of the contextClass attribute of Host. + (kfujino) +
fix + 55331: Dispatching to an asynchronous servlet from + AsyncListener.onTimeout() should not trigger an + IllegalStateException. (markt) +
fix + 55333: Correct a regression in the fix for 55071. + (markt) +
fix + When using a security manager, ensure that calls to the ServletContext + that are routed via an AccessController.doPrivileged block + do not result in a call to a different underlying method on the + ServletContext. (markt) +
fix + 55354: Ensure that the naming context environment parameters + are restored after associating the Principle with the user name. Based + on patch provided by Richard Begg. (violetagg) +
fix + 55357: Ensure the web application class loader is set as a + thread context class loader during session deserialization. (violetagg) +
fix + 55404: Log warnings about using security roles in web.xml + without defining them as warnings. (markt) +
fix + 55439: Don't try a forced stop when stop + -force is used if Tomcat has already been stopped. This avoids + error messages when the PID file has been cleared. If a forced stop is + required, improve handling of the case when the PID file can be read + from or written to but not deleted. (markt) +
fix + 55454: Avoid NPE when parsing an incorrect content type. + (violetagg) +
update + Back-port the JSR-356 Java WebSocket 1.0 implementation from Tomcat 8. + Note that use of this functionality requires Java 7. (markt) +
update + Deprecate the Tomcat proprietary WebSocket API in favour of the new + JSR-356 implementation. (markt) +
fix + 55494: Reduce severity of log message from warning to + information for JNDI Realm connection issues where the JNDI Realm + automatically re-tries the action that failed. Make clear in the log + message that the action is being re-tried. (markt) +
fix + Correct several incorrect formats of JdkLoggerFormatter. + (kfujino) +
fix + 55521: Ensure that calls to + HttpSession.invalidate() do not return until the session + has been invalidated. Also ensure that checks on the validity of a + session return a result consistent with any previous call to + HttpSession.invalidate(). (markt) +
fix + 55524: Refactor to avoid a possible deadlock when handling an + IOException during output when using Tomcat' + proprietary (and deprecated) WebSocket API. (markt) +
fix + The loaded attribute never exists in PersistentManager. + isLoaded is defined as operation in mbeans-descriptors. (kfujino) +
add + Added logging of logging.properties location when system property + org.apache.juli.ClassLoaderLogManager.debug=true + is set. +
fix + 55570: Correctly log exceptions for all error conditions in + the SPNEGO authenticator. (markt) +
+
+
Coyote
+ + + + + + + + + + + + + +
fix + 55228: Allow web applications to set a HTTP Date header. + (markt) +
add + Expose the current connection count for each protocol handler via JMX. + (markt) +
fix + 55267: If an application configures a timeout for a Comet + connection ensure it is only used for read and not write operations. + This prevents a long timeout delaying the closing of the socket + associated with a Comet connection after an error occurs. (markt) +
fix + Ensure that java.lang.VirtualMachineErrors are not + swallowed when using the HTTP or AJP NIO connectors. (markt) +
fix + 55399: Use the response locale to select the language to use + for the status message in the HTTP response. (markt) +
update + Refactor the connectors to support the new JSR-356 Java WebSocket + 1.0 implementation. The most noticeable change is that the AJP + APR/native and HTTP APR/native connectors no longer support multiple + poller threads. Both connectors now use a single poller thread. (markt) +
fix + Internally, content length is managed as a long. Fix a few + places in the AJP connector where this was restricted to an + int. (markt) +
fix + 55453: Ensure that the AJP connector does not permit response + bodies to be included for responses with status codes and/or request + methods that are not permitted to have a response body. (markt) +
fix + 55500: Don't ignore the value of an asynchronous context + timeout when using the AJP NIO connector. (markt) +
fix + Fix CVE-2013-4286: + Better adherence to RFC2616 for content-length headers. (markt) +
fix + Fix CVE-2013-4322: Add support for limiting the size of chunk extensions + when using chunked encoding. (markt) +
fix + Update the APR/native connector to version 1.1.28. Make this the minimum + acceptable version as the correct behaviour of the JSR-356 WebSocket + implementation when using the APR/native HTTP connector depends on a bug + fix in the 1.1.28 release. (markt) +
+
+
Jasper
+ + + + + + + + + + +
fix + 55198: Ensure attribute values in tagx files that include EL + and quoted XML characters are correctly quoted in the output. (markt) +
fix + Ensure that javax.el.ELContext.getContext(Class) will + throw NullPointerException when the provided class is + null. (violetagg) +
fix + Ensure that FeatureDescriptor objects returned by + javax.el.MapELResolver.getFeatureDescriptors(ELContext,Object) + will be created with a correct shortDescription - an empty string and + a named attribute ELResolver.RESOLVABLE_AT_DESIGN_TIME - + true. (violetagg) +
fix + Ensure that FeatureDescriptor objects returned by + javax.el.ResourceBundleELResolver.getFeatureDescriptors(ELContext,Object) + will be created with a correct shortDescription - an empty + string. + javax.el.ResourceBundleELResolver.isReadOnly(ELContext,Object,Object) + returns true if the base object is an instance of ResourceBundle. + (violetagg) +
fix + 55207: Enforce the restriction that a <jsp:text> + element may not contain any sub-elements from any namespace. Patch + provided by Jeremy Boynes. (markt) +
fix + Ensure that + javax.el.ListELResolver.getFeatureDescriptors(ELContext,Object) + will always return null. + javax.el.ListELResolver.isReadOnly(ELContext,Object,Object) + will return a result when the property cannot be coerced into an + integer. (violetagg) +
fix + Ensure that + javax.el.ArrayELResolver.getFeatureDescriptors(ELContext,Object) + will always return null. + javax.el.ArrayELResolver.isReadOnly(ELContext,Object,Object) + and + javax.el.ArrayELResolver.getType(ELContext,Object,Object) + will return a result when the property cannot be coerced into an + integer. (violetagg) +
fix + 55309: Fix concurrency issue with JSP compilation and the + tag plug-in manager. Patch provided by Sheldon Shao. (markt) +
fix + Ensure that + javax.el.BeanELResolver.getFeatureDescriptors(ELContext,Object) + and + javax.el.BeanELResolver.getCommonPropertyType(ELContext,Object) + do not throw NullPointerException when the provided context + is null. (violetagg) +
+
+
Cluster
+ + + + + + + +
add + Add new attribute terminateOnStartFailure. Set to true if you wish to + terminate replication map when replication map fails to start. + If replication map is terminated, associated context will fail to start. + If you set this attribute to false, replication map does not end. + It will try to join the map membership in the heartbeat. Default value + is false. (kfujino) +
fix + Avoid ConcurrentModificationException when sending a heartbeat. + (kfujino) +
fix + Avoid NPE when the channel fails to start. (kfujino) +
fix + 55301: Fix IllegalArgumentException thrown by + simple test for McastService. (kfujino) +
fix + 55332: Fix NPE in FileMessageFactory.main when + specify empty file as arguments. (kfujino) +
fix + More definite thread name for MessageDispatch15Interceptor. + (kfujino) +
+
+
Web applications
+ + + + + + + +
update + Remove the experimental label from the AJP NIO connector documentation. + (markt) +
fix + Correctly associated the default resource bundle with the English locale + so that requests that specify an Accept-Language of English ahead of + French, Spanish or Japanese get the English messages they asked for. + (markt) +
fix + 55469: Fixed tags that were not properly closed. Based on a + patch provided by Larry Shatzer, jr. (violetagg) +
update + The WebSocket examples in the examples web application have been changed + to use the new JSR-356 Java WebSocket 1.0 implementation. (markt) +
add + Add document for + org.apache.catalina.tribes.group.GroupChannel. (kfujino) +
fix + Correct Realm Component page of Tomcat documentation. (violetagg) +
+
+
jdbc-pool
+ + + + + + +
fix + 54693: Add a validationQueryTimeout property. Patch provided + by Daniel Mikusa. (kfujino) +
fix + 54693#c6: Avoid NPE caused by createConnection() + method returns null. Patch provided by Daniel Mikusa. (kfujino) +
fix + 55342: Remove unnecessary reset of interrupted flag. If + InterruptedException is thrown, the interrupted flag has + been cleared. (kfujino) +
fix + 55343: Add flag to ignore exceptions of connection creation + while initializing the pool. (kfujino) +
fix + Add undefined attributes and operations to mbeans-descriptor. (kfujino) +
+
+
Other
+ + + + + + + + + +
add + 45428: Trigger a thread dump written to standard out if + Tomcat fails to stop in a timely manner to aid diagnostics. This is only + available on platforms that use catalina.sh. (markt) +
fix + 55204: Correct namespace used in Servlet 2.4 test web + application. Patch provided by Jeremy Boynes. (markt) +
fix + 55205: Reorder elements so web.xml complies with schema for + Servlet 3.0 test web application. Patch provided by Jeremy Boynes. + (markt) +
fix + 55211: Correct namespace in TLD files used in test web + applications. Rename elements tagclass to + tag-class so TLD files complies with DTD/schema. Patch + provided by Jeremy Boynes. (violetagg) +
update + Update package renamed version of Commons BCEL to the latest code from + Commons BCEL trunk. (markt) +
update + Update package renamed version of Commons FileUpload to the latest code + from Commons FileUpload trunk. (markt) +
fix + 55297: When looking for the jsvc executable, if an explicit + path is not set and it is not found in $CATALINA_BASE, look in + $CATALINA_HOME as well. (markt) +
fix + 55336: Correctly escape parameters passed to eval in the + catalina.sh script to ensure that Tomcat starts when installed on a path + that contains multiple consecutive spaces. (markt) +
+
+
Tomcat 7.0.42 (markt)released 2013-07-05
+
Catalina
+ + + + + + + + + + + + + + + + + + +
fix + Enforce the restriction described in section 4.4 of the Servlet 3.0 + specification that requires the new pluggability methods only to be + available to ServletContextListeners defined in one of the + specified ways. (markt) +
fix + Better handle FORM authentication when requesting a resource as an + unauthenticated user that is only protected for a sub-set of HTTP + methods that does not include GET. (markt) +
fix + 53777: Add support for a JAAS Realm instance to use a + dedicated configuration rather than the JVM global JAAS configuration. + This is most likely to be useful for per web application JAAS Realms. + Based on a patch by eolivelli. (markt) +
fix + 54745: Fix JAR file scanning when Tomcat is deployed via Java + Web Start. Patch provided by Nick Williams. (markt) +
add + 55017: Add the ability to configure the RMI bind address when + using the JMX remote lifecycle listener. Patch provided by Alexey + Noskov. (markt) +
fix + 55071: Ensure original exception is reported if JDBC Realm + fails to read a user's credentials. (markt) +
fix + 55073, 55108, 55109, 55110, + 55158 & 55159: Small performance improvements. + Patches provided by Adrian Nistor. (markt/violetagg) +
add + 55102: Add support for time to first byte in the + AccessLogValve. Patch provided by Jeremy Boynes. (markt) +
fix + 55125: If the Server container fails to start, don't allow + the Catalina wrapper to start (used when running from the command line + and when running as a service) since Tomcat will not be able to do any + useful work. (markt) +
fix + Update the JreMemoryLeakPreventionListener to take account + of changes in the behaviour of + java.beans.Introspector.flushCaches() and + sun.awt.AppContext.getAppContext() in Java 7. (markt) +
fix + Avoid WARNING log message of + Users:type=UserDatabase,database=UserDatabase at Tomcat + shutdown. (pero) +
fix + Avoid ClassCastException when an asynchronous dispatch is + invoked in an asynchronous cycle which is started by a call to + ServletRequest.startAsync(ServletRequest,ServletResponse) + where ServletRequest/ServletResponse are custom implementations. + (violetagg) +
fix + Correct a regression introduced in 7.0.39 (refactoring of base 64 + encoding and decoding) that broke the JNDI Realm when + userPassword was set and passwords were hashed with MD5 or + SHA1. (markt/kkolinko) +
fix + Correct the mechanism for the path calculation in + AsyncContext.dispatch(). (violetagg) +
fix + 55155: Avoid constant focus grabbing when running the Tomcat + unit tests under Java 6 on OSX. Patch provided by Casey Lucas. (markt) +
fix + 55160: Don't ignore connectionUploadTimeout setting when + using HTTP NIO connector. (markt) +
fix + 55176: Correctly handle regular expressions within SSI + expressions that contain an equals character. (markt) +
+
+
Coyote
+ + + +
fix + 55177: Correctly handle infinite soTimeout for BIO HTTP + connector. Based on a patch by Nick Bunn. (markt) +
fix + 55180: Correctly handle infinite soTimeout when + disableUploadTimeout is set to false. Patch provided by + Nick Bunn. (violetagg) +
+
+
Cluster
+ + + + + + +
fix + Delete leftover of war file from tempDir when removing invalid + FileMessageFactory. (kfujino) +
fix + Ensure that the keepAlive of NioSender works correctly when + keepAliveCount/keepAliveTime is set to a value + greater than 0. (kfujino) +
add + Add logging of when a member is unable to join the cluster. (kfujino) +
fix + Replace Tribes's TaskQueue as executor's + workQueue in order to ensure that executor's maxThread + works correctly. (kfujino) +
fix + 54086: Fix an additional code path that could lead to + multiple threads attempting to modify the same selector key set. (markt) +
+
+
Web applications
+ + + + +
add + Complete the document for MessageDispatch15Interceptor. + (kfujino) +
add + 53655: Document the circumstances under which Tomcat will add + a javax.mail.Authenticator to mail sessions created via a + JNDI resource. (markt) +
fix + 55179: Correct the Javadoc for the remote IP valve so the + correct name is used to refer to the proxiesHeader + property. (markt) +
+
+
jdbc-pool
+ + +
fix + 55031: Fixed Export-Package header and + uses directives in MANIFEST.MF. Change the version for + package org.apache.juli.logging to "0" in + Import-Package header. Thus any version of that package + can be used. Patch provided by Martin Lichtin. (violetagg) +
+
+
Other
+ + + + + +
update + Update Maven Central location used to download dependencies at build time + to be repo.maven.apache.org. (kkolinko) +
update + Update JUnit to version 4.11. Configure separate download for Hamcrest + 1.3 core library as its classes are no longer included in junit.jar. + (kkolinko) +
fix + 54013: When using a forced stop, allow a short period of time + (5s) for the process to die before returning. Patch provided by + mukarram.baig. (markt) +
fix + 55119: Ensure that the build process produces Javadoc that is + not vulnerable to CVE-2013-1571. Based on a patch by Uwe Schindler. + (markt) +
+
+
Tomcat 7.0.41 (markt)released 2013-06-10
+
Catalina
+ + + + + + + + + + + + + + + + + +
fix + 54703: Make parsing of HTTP Content-Type headers tolerant of + any CR or LF characters that appear in the value passed by the + application. Also fix some whitespace parsing issues identified by the + additional test cases. (markt) +
fix + Prevent possible WAR file locking when reading a context.xml file from + an unexpanded WAR file. Note that in normal usage, the + JreMemoryLeakPreventionListener would protect against this. + (markt) +
fix + Ensure that when auto deployment runs for a Host, it uses the latest + values for copyXML, deployXML and unpackWARs. (markt) +
fix + 54939: Provide logging (using a UserDataHelper) when HTTP + header parsing fails (e.g. when maxHeaderCount is exceeded). (markt) +
add + 54944: Enhancements to the unit tests for FORM + authentication. Patch provided by Brian Burch. (markt) +
fix + 54955: When a reload of the application is performed ensure + that a subsequent request to the context root does not result in a 404 + response. (violetagg) +
fix + 54971: Ensure that the correct location is used when writing + files via javax.servlet.http.Part.write(String). (markt) +
fix + 54974: Ensure that + SessionCookieConfig#set<methods> + will throw IllegalStateException if the + ServletContext from which this + SessionCookieConfig was acquired has already been + initialized. (violetagg) +
fix + 54981: Ensure that + ServletContext#getJspConfigDescriptor() will return + null when there is no jsp configuration provided by + web.xml/web-fragment.xml. (violetagg) +
fix + Ensure that when Tomcat's anti-resource locking features are used + that the temporary copy of the web application and not the original is + removed when the web application stops. (markt) +
fix + 54984: Use the correct encoding when processing a form data + posted as multipart/form-data even when the request parameters are not + parsed. (violetagg) +
fix + 54999: The old JSESSIONIDSSO needs to be removed when SSO is + being used and logout() and login() occur within a single request. Patch + provided by Keith Mashinter. (markt) +
add + 55035: Add support for the version attribute to the deploy + command of the Ant tasks for interfacing with the text based Manager + application. Patch provided by Sergey Tcherednichenko. (markt) +
add + 55046: Add a Servlet Filter that implements + CORS. Patch + provided by Mohit Soni. (markt) +
add + 55052: JULI's LogManager now additionally looks for + logging properties without prefixes if the property cannot be found with + a prefix. (markt) +
fix + Ensure that only the first asynchronous dispatch operation for a given + asynchronous cycle will be performed. Any subsequent asynchronous + dispatch operation for the same asynchronous cycle will be ignored and + IllegalStateException will be thrown. (violetagg) +
+
+
Coyote
+ + +
fix + 54947: Fix the HTTP NIO connector that incorrectly rejected a + request if the CRLF terminating the request line was split across + multiple packets. Patch by Konstantin Preißer. (markt) +
+
+
Jasper
+ + + +
fix + 54964: Allow tag plug-ins to be packaged with a web + application. Patch provided by Sheldon Shao. (markt) +
fix + 54968: Return the correct version number (2.2) of the JSP + specification that is supported by the JSP engine when + javax.servlet.jsp.JspEngineInfo#getSpecificationVersion() + is invoked. (violetagg) +
+
+
Cluster
+ + + + + + +
add + Add maxValidTime attribute to prevent the leak of + FileMessageFactory in FarmWarDeployer. + (kfujino) +
code + Simplify the code of ReplicationValve: Rather than get + cluster instance from container on every request, use instance variable. + (kfujino) +
add + Add maxWait attribute that the senderPool will wait when + there are no available senders. (kfujino) +
add + Improve error message by including specified timeout if failed to + retrieve a data sender. (kfujino) +
add + Add removeSuspectsTimeout attribute in order to remove a + suspect node in TcpFailureDetector. (kfujino) +
+
+
Web applications
+ + + + +
fix + 54931: Add information to the Window Service how-to about + installing and running multiple instances. Based on a patch by Chris + Derham. (markt) +
fix + 54932: Correct the link to Tribes documentation. (violetagg) +
add + Add document for + o.a.c.tribes.group.interceptors.TcpFailureDetector. + (kfujino) +
+
+
Tomcat 7.0.40 (markt)released 2013-05-09
+
Catalina
+ + + + + + + + +
update + Update Tomcat's internal copy of Commons FileUpload to FileUpload 1.3. + (markt) +
fix + 54178, CVE-2013-2071: Protect against + AsyncListener implementations that throw + RuntimeExceptions in response to an event. (markt) +
fix + 54791: Restore tools.jar entry in + jarsToSkip property to prevent warnings when running Tomcat + from Eclipse. (markt) +
fix + 54851: When scanning for web fragments, directories without + any web-fragment.xml should not impact the status of distributable + element. Patch provided by Trask Stalnaker. (violetagg) +
fix + When an error occurs during the sending of a WebSocket message, notify + the Inbound side (where all the events occur that the application reacts + to) that an error has occurred and that the connection is being closed. + (markt) +
fix + 54906: Better error message if a + ConcurrentModificationException occurs while checking for + memory leaks when a web application stops. Also ensure that the + exception does not cause remaining checks to be skipped. Based on a + patch by NateC. +
fix + Allow 204 responses (no content) to include entity headers as required + by RFC2616. (markt) +
+
+
Coyote
+ + +
fix + Ensure write errors when using HTTP Upgrade with the APR/native + connector result in IOExceptions rather than errors being + silently swallowed. (markt) +
+
+
Jasper
+ + + + + +
fix + 54802: Provide location information for exceptions thrown + by JspDocumentParser. (kkolinko) +
fix + 54801: Do not attempt to parse text that looks like an EL + expressions inside a scriptlet in a JSP document because EL expressions + are not permitted in scriptlets. (kkolinko/markt) +
fix + 54821: Do not attempt to parse text that looks like an EL + expressions in a JSP document if EL expressions have been disabled. + (kkolinko/markt) +
fix + 54888: Add support for CSV lists with the ForEach tag plugin. + Patch provided by Sheldon Shao. (markt) +
+
+
Cluster
+ + +
fix + Add several improvements for FarmWarDeployer. (kfujino) +
+
+
Web applications
+ + +
fix + 54872: Correct Cluster Receiver page of Tomcat + documentation. (violetagg) +
+
+
jdbc-pool
+ + + + + +
update + Document StatementCache interceptor. (kkolinko) +
fix + Fix minor threading issue in ConnectionPool. + (markt/kkolinko) +
fix + 54732: Fix leak of statements in StatementCache + interceptor. (kkolinko) +
fix + Fix NPE in SlowQueryReportJmx when running + TestSlowQueryReport test. (kkolinko) +
+
+
Other
+ + + + + +
update + Update to Eclipse JDT Compiler 4.2.2. (kkolinko) +
update + 54890: Update to Apache Commons Daemon 1.0.15. (mturk) +
update + Convert remaining unit tests to JUnit 4 and enable Checkstyle rule + that forbids use of methods from JUnit 3. (markt/kkolinko) +
fix + Remove unneeded permissions for reading UserDataHelper properties + from catalina.policy file. The class that needed those + was moved in 7.0.26. (kkolinko) +
+
+
Tomcat 7.0.39 (markt)released 2013-03-26
+
Catalina
+ + + + + + + + + + + +
fix + Ensure a log message is generated when a web application fails to start + due to an error processing a ServletContainerInitializer. (markt) +
fix + Prevent NPE in JAR scanning when running in an environment where the + bootstrap class loader is not an ancestor of the web application class + loader such as OSGi environments. (violetagg) +
fix + Ensure that, if a call to UEncoder#encodeURL is made, all internal + structures are properly cleaned. (violetagg) +
add + 54660: Enable the modification of an access log's + fileDateFormat attribute while the access log is in use. + The change will take effect when the next entry is made to the access + log. (markt) +
update + Update Tomcat's internal copy of Commons FileUpload to FileUpload trunk, + revision 1458500 and the associated extract from Commons IO to 2.4. + (markt) +
fix + 54702: Prevent file descriptors leak and ensure that files + are closed when parsing web application deployment descriptors. + (violetagg) +
fix + 54707: Further relax the parsing of DIGEST authentication + headers to allow for buggy clients that quote values that RFC2617 states + should not be quoted. (markt/kkolinko) +
fix + Enable support for MBeans with multiple operations with the same name + but different signatures. (markt) +
code + Deprecate Tomcat's internal Base 64 encoder/decoder and switch to + using a package renamed copy of the Commons Codec implementation. + (markt) +
fix + Ensure that StandardJarScanner#scan will use the provided class loader + when scanning the class loader hierarchy. (violetagg) +
+
+
Coyote
+ + +
fix + 54690: Fix a regression caused by the previous fix for + 54406. If no values are specified for sslEnabledProtocols or + ciphers use the default values for server sockets rather than the + default values for client sockets. (markt) +
+
+
Web applications
+ + +
update + Correct Deployer, Manager and Context pages of Tomcat documentation. + (kkolinko) +
+
+
jdbc-pool
+ + + + +
fix + 52318: Version for imported package + org.apache.juli.logging is extended to include also 7.0.x + versions. The fix is applicable only when running in OSGi environment. + Patch provided by Martin Lichtin. (violetagg) +
fix + 54599: Do not print connection password in + PoolProperties.toString(). Based on a patch by + Daniel Mikusa. (kkolinko) +
fix + 54684: Add javax.naming.spi to + Import-Package header in MANIFEST.MF in order to resolve + ClassNotFoundException when running in OSGi environment. + (violetagg) +
+
+
Other
+ + + +
fix + Update to Apache Commons Daemon 1.0.14 to resolve 54609 + which meant that installation of Windows service could fail + producing incorrect service launch command. (mturk) +
fix + Ensure HEAD requests return the correct content length when the + requested resource uses a Writer. Patch by Nick Williams. (markt) +
+
+
Tomcat 7.0.38 (markt)not released
+
Catalina
+ + + + + + + + + + + + +
fix + Ensure that the request start time (used by the access log valve to + calculate request processing time) is correctly recorded for the HTTP + NIO connector. In some cases the request processing time may have been + longer than that recorded. (markt) +
update + Add one more library from JDK 7 to the value of jarsToSkip + property in the catalina.properties file. (kkolinko) +
add + 53871: If annotation scanning results in a + StackOverflowError due to broken class dependencies, add + the class hierarchy that triggered the exception to the error message. + (markt) +
add + Add a new option to the standard JarScanner implementation + (scanBootstrapClassPath) to control if the bootstrap + classpath is scanned or not. By default, it will not be scanned. (markt) +
update + Provide more consolidated servlet MBean data in the webapp MBean. + (rjung) +
fix + 54584: Take account of the delegate attribute when building + the web application class path to pass to the JSP compiler. (markt) +
fix + Copy the updated and re-packaged UTF-8 decoder from Tomcat 8.0.x and use + this improved decoder for WebSocket connections. Remove the WebSocket + specific UTF-8 decoder. (markt) +
fix + 54602: Recycle the byte to character converter used for URIs + between requests to ensure an error in one request does not trigger a + failure in the next request. (markt) +
fix + Use the newly added improved UTF-8 decoder for decoding UTF-8 encoded + URIs and UTF-8 encoded request bodies. Invalid UTF-8 URIs will not + cause an error but will make use of the replacement character when an + error is detected. This will allow web applications to handle the URI + which will most likely result in a 404 response. The fall-back to + decoding with ISO-8859-1 if UTF-8 decoding fails has been removed. + Invalid UTF-8 sequences in a request body will trigger an IOException. + The way the decoder is used has also been improved. The notable change + is that invalid sequences at the end of the input now trigger an error + rather than being silently swallowed. (markt) +
fix + 54624: Ensure that the correct request body length is used + when swallowing a request body after FORM authentication prior to + restoring the original request preventing possible hanging when + restoring POST requests submitted over AJP. (markt) +
fix + 54628: When writing binary WebSocket messages write from + start position in array rather than the start of the array. Patch + provided by blee. (markt) +
+
+
Coyote
+ + +
code + Refactor char encoding/decoding using NIO APIs. (remm) +
+
+
Web applications
+ + + + + + + +
fix + 54203: Complete the Javadoc for + javax.servlet.http.Part. (markt) +
fix + 54638: Fix display of "Used" memory value for memory pools + on the status page in Manager web application when the page is rendered + as XML. (kkolinko) +
fix + Correct typos in configuration samples on SSL Configuration page + of Tomcat documentation. (kkolinko) +
update + Disable support for comments on Changelog page of Tomcat + documentation. (kkolinko) +
fix + Fix several issues with status.xsd schema in Manager web + application, testing it against actual output of StatusTransformer + class. (kkolinko) +
fix + Clarify the documentation on how context paths may be configured for web + applications. (markt) +
+
+
Other
+ + +
update + 54601: Change catalina.sh to consistently use + LOGGING_MANAGER variable to configure logging, + instead of modifying JAVA_OPTS one. (kkolinko) +
+
+
Tomcat 7.0.37 (markt)released 2013-02-18
+
Catalina
+ + + + +
fix + 54521: Ensure that concurrent requests that require a DIGEST + authentication challenge receive different nonce values. (markt) +
fix + 54534: Ensure that, if a call to + StandardWrapper#isSingleThreadModel() triggers the loading + of a Servlet, the correct class loader is used. (markt) +
fix + 54536: Ensure the default error page is displayed if a custom + HTTP status code is used when calling + HttpServletResponse#sendError(int, String). (markt) +
+
+
Coyote
+ + + +
fix + 54456: Ensure that if a client aborts a request when sending + a chunked request body that this is communicated correctly to the client + reading the request body. (markt) +
update + Update the native component of the APR/native connector to 1.1.27 and + make that version the recommended minimum version. (markt) +
+
+
Jasper
+ + +
add + 54239: Enable web applications to provide their own + Expression Language interpreter to enable them to optimise processing of + expressions. Based on a patch by Sheldon Shao. (markt) +
+
+
Web applications
+ + +
add + 54505: Create clearer links from the JNDI How-To to the + Tomcat specific options for configuring JNDI resources. (markt) +
+
+
Other
+ + +
update + Update to Apache Commons Daemon 1.0.13. (markt) +
+
+
Tomcat 7.0.36 (markt)not released
+
Catalina
+ + + + + + + + + + + + + +
fix + Make additional allowances for buggy client implementations of HTTP + DIGEST authentication. This is a follow-on to 54060. (markt) +
fix + 54438: Fix a regression in the fix for 52953 that + triggered a NPE when digested passwords were used and an authentication + attempt was made for a user that did not exist in the realm. (markt) +
fix + 54448: Correctly handle @Resource annotations on + primitives. Patch provided by Violeta Georgieva. (markt) +
fix + 54450: Correctly handle resource injection when part of the + servlet properties uses @Resource and the other uses + injection-target. Patch provided by Violeta Georgieva. + (markt) +
fix + 54458: Include exception when logging errors in the + DataSourceRealm. Patch provided by Violeta Georgieva. (markt) +
fix + 54483: Correct one of the Spanish translations. Based on a + suggestion from adinamita. (markt) +
fix + Prevent the SSO deregister when web application is stopped or reloaded. + When StandardManager(pathname="") or DeltaManager stops normally, all + sessions in the context are expired. + In this case, because most sessions is not time-out, SSO deregister was + triggered. (kfujino) +
fix + Include the exception in the log message if the parsing of the + context.xml file fails. (markt/kkolinko) +
fix + 54497: Make memory leak detection code more robust so a + failure in the leak detection code does not prevent the Context from + stopping unless the error is fatal to the JVM. (markt) +
fix + 54507: Do not start the background thread that is used for + expiring sessions (amongst other things) until the web application is + fully started. Stop the background thread as soon as the web application + is stopped. (markt) +
fix + Allow WebSocket Ping/Pong messages to be sent between fragments of a + fragmented message. (markt) +
fix + 54612: Check if the socket is closed before trying to write a + WebSocket message to it. Also, flush any partial buffered data before + closing the socket. (markt) +
+
+
Coyote
+ + + + +
fix + 54324: Allow APR connector to disable TLS compression + if OpenSSL supports it. (schultz) +
fix + 54406: Fix NIO HTTPS connector to prune specified + ciphers and sslEnableProtocols options to those + supported by the SSL implementation, sharing logic with the BIO + connector. Modified ciphers and sslEnabledProtocols option pruning to + not silently revert to JVM defaults when none of the options specified + are supported - new behaviour is to warn and explicitly enable no + options. (timw) +
fix + Align NIO HTTP connector with other HTTP connectors and include leading + blank lines when determining the size of the HTTP headers. (markt) +
+
+
Jasper
+ + + + +
fix + 53869: Performance improvement for pages with lots of heavily + nested tags. Retain a reference to the root JSP context rather than + traversing the hierarchy on every call. Based on a patch suggested by + Sheldon Shao. (markt) +
fix + 54440: Correct a regression caused by the changes for + 54240 that broke compilation of JSPs with JspC. Patch + provided by Sheldon Shao. (markt) +
fix + 54466: Improve error message by including the name of the + file when the java file generated from a tag file cannot be compiled. + Based on a patch by Sheldon Shao. (markt) +
+
+
Cluster
+ + + + + +
fix + Fix incorrect increment of counterSend_EVT_SESSION_EXPIRED + and counterSend_EVT_CHANGE_SESSION_ID. These values are not + incremented if no members active in cluster group. (kfujino) +
fix + 54476: Correct error in Javadoc of GroupChannel send methods + to maker clear that the minimum length of the destination member array + is one, not two. (markt) +
fix + Prevent SSO deregister when node shutdown normally in cluster + environment. (kfujino) +
fix + Check cluster member before sending replicate message in + ClusterSingleSignOn. (kfujino) +
+
+
Web applications
+ + + +
fix + 54461: Improve the documentation for the compiler attribute + in the Jasper how-to. (markt) +
add + Add Jespa to the list of third-party Windows authentication providers + and make external links in the documentation for those providers + no-follow. (markt) +
+
+
Tribes
+ + +
fix + 54496: Don't use a hard-coded class name in + MemberImpl.toString(). (markt) +
+
+
Other
+ + +
update + Update to Apache Commons Daemon 1.0.12. (markt) +
+
+
Tomcat 7.0.35 (markt)released 2013-01-16
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + +
fix + 54247: Prevent ClassNotFoundExceptions on stop + when running as a service. (markt) +
fix + 54249: Ensure resource properties are available when the + context path contains encoded characters such as a space. This triggered + compilation issues in Jasper. Patch provided by Polina Genova. (markt) +
fix + 54256: Improve error reporting when a JAR file fails + extension validation by including the name of the JAR file in the + exception. (markt) +
fix + Allow web applications to be stopped cleanly even if filters throw + exceptions when their destroy() method is called. (markt/kkolinko) +
fix + Fix memory leak of servlet instances when running with a + SecurityManager and either init() or destroy() methods fail + or the servlet is a SingleThreadModel one. (kkolinko) +
code + Cleanup method cache lookup code in SecurityUtil class. + (kkolinko) +
add + Make the Tomcat 7 non-JSR356 WebSocket implementation non-blocking + (where supported by the connector) between the HTTP upgrade and the + first WebSocket message from the client to the server. (markt) +
fix + 54262: Ensure that an empty + <absolute-ordering /> element in the main web.xml + file disables scanning for web fragments. Based on a patch by Violeta + Georgieva. (markt) +
fix + 54284: As per clarification from the Servlet EG, anonymous + Filters and Servlets are not permitted. Patch by Violeta Georgieva. + (markt) +
fix + 54371: Prevent exceptions when processing web fragments for + unexpanded WAR files when the context path contains characters that + need to be encoded in URLs such as spaces. Based on a patch by Polina + Genova. (markt) +
add + 54372: Make HTTP Digest authentication header parsing + tolerant of invalid headers sent by known buggy clients. (markt) +
fix + 54377: Correctly set request attributes for AccessLog in + RemoteIpFilter. Patch by Violeta Georgieva. (markt) +
fix + 54379: Implement support for post-construct and pre-destroy + elements in web.xml. Patch by Violeta Georgieva. (markt) +
fix + 54380: Do not try to register servlets or contexts into the + mapper too early (which just caused a warning to be logged). (kkolinko) +
fix + Fix NPE in WebappLoader.stopInternal when stop is called + after a failed start. (kkolinko) +
add + 54381: Add support for receiving WebSocket pong messages. + (markt) +
fix + 54382: Fix NPE when SSI processing is enabled and an empty + SSI directive is present. (markt) +
fix + Fix ArrayIndexOutOfBoundsException in + HttpParser when parsing incorrect HTTP headers. (kkolinko) +
fix + 54387: Deployment must fail when multiple servlets are mapped + to the same url-pattern. (markt) +
fix + 54391: Provide a value for the + javax.servlet.context.orderedLibs attribute. (markt) +
+
+
Coyote
+ + + +
fix + 54248: Ensure that byte order marks are swallowed when using + a Reader to read a request body with a BOM for those encodings that + require byte order marks. (markt) +
fix + Fix release of processors in AjpNioProtocol. Wrong object + was used as a key in the connections map. (kkolinko) +
+
+
Jasper
+ + + + + + + +
add + 54240: Add support for auto-detection and configuration of + JARs on the classpath that provide tag plug-in implementations. Based on + a patch by Sheldon Shao. (markt) +
fix + 54241: Revert the fix for 35410 as it was not + compliant with the JSP specification, specifically that + <%= obj %> must be translated to + out.print(obj) which in turn becomes + out.write(String.valueOf(obj)). This will trigger a + NullPointerException if obj.toString() returns + null. The fix for 35410 incorrectly suppressed + the NullPointerException in this case. (markt) +
fix + 54242: Correct handle null iterations with in the JSTL + ForEach tag plug-in implementation. Patch provided by Sheldon Shao. + (markt) +
fix + 54260: Avoid NullPointerException when using + JSP unloading and tag files. (markt) +
fix + 54370: Improve handling of nulls when trying to match sets of + parameters to a method in EL. (markt) +
fix + 54338: Correctly coerce the value to the expected type when + using the tag plug-in for the JSTL set tag. Patch provided by Sheldon + Shao. (markt) +
+
+
Web applications
+ + + +
fix + 54244: Clarify the documentation for the BIO and NIO SSL + configuration attributes sslEnabledProtocols and + sslProtocol within the documentation web application. + (markt) +
add + Integrate documentation of Tomcat 7 with Apache Comments System. + People can leave their comments when reading documentation online + at the tomcat.apache.org + site. (rjung) +
+
+
Other
+ + +
fix + 54390: Use 'java_home' on Mac OS X to auto-detect JAVA_HOME. + (schultz) +
+
+
Tomcat 7.0.34 (markt)released 2012-12-12
+
Catalina
+ + + + + + + + +
fix + 53871: Improve error message if annotation scanning fails + during web application start due to poor configuration or illegal + cyclic inheritance with the application's classes. (markt) +
fix + Fix unit test for AccessLogValve when using non-GMT time zone. (rjung) +
fix + 54170: Ensure correct registration of Filters and Servlets in + the JMX registry if the Filter or Servlet name includes a character that + must be quoted if used in an ObjectName value. (markt) +
add + Add new attribute renameOnRotate to the AccessLogValve. + (rjung) +
fix + 54190: Correct unit tests for BASIC authentication so that + session timeout is correctly tested. Also refactor unit test to make it + easier to add additional tests. Patch by Brian Burch. (markt) +
fix + 54220: Ensure the ErrorReportValve only generates an error + report if the error flag on the response has been set. (markt) +
fix + Simplify time zone handling in the access log valve and correctly handle + various edge cases for non-standard DST changes. (markt) +
+
+
Web applications
+ + + +
fix + 54198: Clarify that + HttpServletResponse.sendError(int) results in an HTML + response by default. (markt) +
fix + 54207: Correct JNDI factory package name in Javadoc for + org.apache.naming.java.javaURLContextFactory. (markt) +
+
+
jdbc-pool
+ + + + +
code + Fix a handful of Eclipse warnings in the JDBC pool source code including + the warnings reported in 53565. (markt) +
fix + 54150: Make sure that SlowQueryReportJmx mbean deregistered + during webapp shutdown. Reported by Alex Franken. (kfujino) +
fix + 54194: Make sure that connection pool mbean is not registered + when jmxEnabled is false. Patch provided by tobias.gierke. (kfujino) +
+
+
Other
+ + +
update + Update to Eclipse JDT Compiler 4.2.1. (markt) +
+
+
Tomcat 7.0.33 (markt)released 2012-11-21
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + +
add + 53960, 54115: Extensions to HttpClient test + helper class. Patches by Brian Burch. (markt/kkolinko) +
fix + 53993: Avoid a possible NPE in the AccessLogValve when the + session ID is logged and a session is invalidated. (markt) +
fix + Add support for LAST_ACCESS_AT_START system property to + PersistentManager. (kfujino) +
add + Update MIME type mapping with additional / updated mime.types from the + Apache web server. (markt) +
fix + 54007: Fix a memory leak that prevented deletion of a + context.xml file associated with a Context that had failed to deploy. + Also fix the problems uncovered with undeploying such a Context once the + leak had been fixed and the file could be deleted. (markt) +
fix + 54044: Correct bug in timestamp cache used by logging + (including the access log valve) that meant entries could be made with + an earlier timestamp than the true timestamp. (markt) +
fix + 54054: Do not share shell environment variables between + multiple instances of the CGI servlet. (markt) +
fix + 54060: Use a simple parser rather than a regular expression + to parse HTTP Digest authentication headers so the header is correctly + parsed. The new approach is also faster and generates less garbage. + (markt) +
fix + 54068: Rewrite the web fragment ordering algorithm to resolve + multiple issues that resulted in incorrect ordering or failure to find + a correct, valid order. (markt) +
update + The HTTP header parser added to address 52811 has been + removed and replaced with the light-weight HTTP header parser created to + address 54060. The new parser includes a work-around for a + bug in the Adobe Acrobat Reader 9.x plug-in for Microsoft Internet + Explorer that was identified when the old parser was introduced + (53814). +
fix + 54076: Add an alternative work-around for clients that use + SPNEGO authentication and expect the authenticated user to be cached + per connection (Tomcat only does this if an HTTP session is available). + (markt) +
fix + 54087: Correctly handle (ignore) invalid If-Modified-Since + header rather than throwing an exception. (markt) +
fix + 54096: In web.xml, <env-entry> should accept any type + that has a constructor that takes a single String or char. (markt) +
add + 54127: Add support for sending a WebSocket Ping. Patch + provided by Sean Winterberger. (markt) +
fix + Fix CVE-2013-2067: + In FormAuthenticator: If it is configured to change Session IDs, + do the change before displaying the login form. (kkolinko) +
fix + Ensure AsyncListener.timeout() and + AsyncListener.complete() are called with the correct + thread context class loader. (fhanik) +
fix + 54123: If an asynchronous request times out without any + AsyncListeners defined, a 500 error will be triggered. + (markt) +
fix + 54124: Correct provided value of request attribute + javax.servlet.async.request_uri and add missing request + attribute javax.servlet.async.path_info. (markt) +
add + Add denyStatus initialization parameter to + CsrfPreventionFilter, allowing to customize the HTTP + status code used for denied requests. (kkolinko) +
fix + 54141: Increase the permitted number of nested Realm levels + from 2 to 3 by default and make the limit configurable via a system + property. (markt) +
fix + Revert occasional API change in BaseDirContext class that + was done in 7.0.32. Methods should not be final. (kkolinko) +
fix + Prevent failures in the AccessLogValve when running under a + SecurityManager and the first request received is an asynchronous one. + (markt) +
+
+
Coyote
+ + + + +
fix + Correct an issue that prevented WebSockets from being used over SSL when + using the HTTP NIO connector. (markt) +
fix + 54022: Ensure the Comet END event is triggered on client + disconnect with APR/native on Windows Vista/2k8 or later. Patch provided + by Douglas Beachy. (markt) +
fix + 54067: Ensure responses with 1xx response codes are correctly + marked as not containing an entity body. This caused an issue for some + WebSocket clients when an Transfer-Encoding header was sent with the + 101 (HTTP upgrade) response. (markt) +
+
+
Jasper
+ + + + + + + + + +
code + 53867: Optimise the XML escaping provided by the PageContext + implementation. Based on a patch by Sheldon Shao. (markt) +
code + 53896: Use an optimised CompositeELResolver for Jasper that + skips resolvers that are known to be unable to resolve the value. Patch + by Jarek Gawor. (markt) +
fix + 53986: Correct a regression introduced by the fix for + 53713. JSP comments that ended with the sequence ---%> (or + any similar sequence with a odd number of - characters) was not + correctly parsed. (markt) +
fix + 54011: Fix a bug in the tag plug-in for + <c:out> that triggered a JSP compilation error if the + escapeXml attribute was used. Patch provided by Sheldon + Shao. (markt) +
code + Follow up to 54011. Simplify generated code for + <c:out>. Based on a patch by Sheldon Shao. (markt) +
fix + 54012: Fix a bug in the tag plug-in infrastructure that meant + the <c:set> triggered a JSP compilation error when + used in a tag file. Based on a patch provided by Sheldon Shao. (markt) +
code + 54017: Simplify coercion of String instances to + Object. (markt) +
fix + 54144: Fix a bug in the tag plug-in for + <c:out> that meant that if the value of the tag + evaluated to a java.io.Reader object then it was not + correctly handled. (markt) +
+
+
Cluster
+ + + +
fix + Add getSessionIdsFull operation to mbeans-descriptor. listSessionIdsFull + no longer exist. (kfujino) +
fix + 54086: Fix threading issue when stopping an + NioReceiver. (markt) +
+
+
Web applications
+ + +
add + 54143: Add display of the memory pools usage (including + PermGen) to the Status page of the Manager web application. (kkolinko) +
+
+
Tribes
+ + +
fix + 54045: Make sure getMembers() returns available member when + TcpFailureDetector works in static cluster. (kfujino) +
+
+
Tomcat 7.0.32 (markt)released 2012-10-09
+
Catalina
+ + + +
fix + Revert multiple operation support for the JMXProxyServlet + pending further discussion. (schultz) +
fix + CVE-2012-4431: Fix bypass of CsrfPreventionFilter when + there is no session. Improve session management in the filter. + (kkolinko) +
+
+
Web applications
+ + +
fix + Correct the couple of broken links in the Tomcat Javadoc. (markt) +
+
+
Other
+ + +
update + Update optional Checkstyle library to 5.6. (kkolinko) +
+
+
Tomcat 7.0.31 (markt)not released
+
Catalina
+ + + + + + + + + +
update + Add one library from JDK 7 to the value of jarsToSkip + property in the catalina.properties file. (kkolinko) +
add + 52777: Add an option to automatically remove old, unused + versions (ones where there are no longer any active sessions) of + applications deployed using parallel deployment. (markt) +
fix + 53828: Use correct status code when closing a WebSocket + connection normally in response to a close frame from a client. (markt) +
update + JMXProxyServlet now allows multiple operation commands like + invokeAndSet, invokeAndGet, + etc. (schultz) Note: reverted in 7.0.32. +
fix + 53843: request.isAsyncStarted() must continue to + return true until the dispatch actually happens (which at the earliest + isn't until the thread where startAsync() was called + returns to the container). (markt) +
fix + 53863: Ensure that the implicit servlets (JSP and default) are + marked as override-able when using embedded mode. (markt) +
fix + When the DefaultServlet is under heavy load, the HTTP + header parser added to address 52811 generates large amounts + of garbage and uses significant CPU time. A cache has been added that + significantly reduces the overhead of this parser. (markt) +
fix + 53854: Make directory listings work correctly when aliases + are used. (markt) +
+
+
Jasper
+ + +
code + 53713: Performance improvement of up to four times faster + parsing of JSP pages. Patch provided by Sheldon Shao. (markt) +
+
+
Cluster
+ + + +
add + Make the cluster members and the cluster deployer associated with the + cluster accessible via JMX. (markt) +
fix + Fix a behavior of TcpPingInterceptor#useThread. If set to false, ping + thread is never started. (kfujino) +
+
+
Web applications
+ + + +
add + Improve the documentation web application to clarify the difference + between the tag and version parameters when using text interface of the + Manager web application. (markt) +
add + Make sessions saved in the Store associated with a + Manager that extends PersistentManager + optionally visible (via the showProxySessions Servlet initialisation + parameter in web.xml) to the Manager web application. (markt) +
+
+
Tomcat 7.0.30 (markt)released 2012-09-06
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + Automatically delete temporary files used by Servlet 3.0 file + upload (for parts which size is greater than + file-size-threshold option in web.xml) + when request processing completes. (kkolinko) +
fix + 53071: This additional fix for this issue improves the + formatting of Jasper errors (or any exceptions that use a multi-line + message) with the ErrorReportValve. (markt) +
fix + 53469: If a URL passed to + javax.servlet.http.HttpServletResponse.encodeURL() cannot + be made absolute, never encode it and return it unchanged. Previously, + the fix for 53062 meant than an + IllegalArgumentException was thrown. (markt) +
fix + 53481: Added support for SSLHonorCipherOrder to allow + the server to impose its cipher order on the client. Based on a patch + provided by Marcel Šebek. This feature requires + Tomcat Native 1.1.25 or later. (schultz) +
fix + 53498: Fix atomicity bugs in use of concurrent collections. + Based on a patch by Yu Lin. (markt) +
fix + Correct a regression in the previous fix for 53062 that did + not always correctly normalize redirect URLs when the redirect URL + included a query string or fragment component. (markt) +
fix + Add missing getter and setter for roleSearchAsUser option + on JNDI Realm. (markt) +
update + Add some HTTP status codes registered at IANA. (rjung) +
fix + 53531: Fix ExpandWar.expand to check the return value of + File.mkdir and File.mkdirs. (schultz) +
fix + 53535: Reduce memory footprint when performing class scanning + on Context start. Patch provided by Cedomir Igaly. (markt) +
fix + 53541: Fix JAR scanning when WEB-INF/lib is provided via + VirtualDirContext. Patch provided by Philip Zuev. (markt) +
fix + 53574: Ensure Servlets defined using jsp-file are available + when metadata-complete is true. (markt) +
fix + 53584: Ignore path parameters when comparing URIs for FORM + authentication. This prevents users being prompted twice for passwords + when logging in when session IDs are being encoded as path parameters. + (markt) +
fix + 53623: When performing a asynchronous dispatch after series + of forwards, ensure that the request properties are correct for the + request at each stage. (markt) +
fix + 53624: Ensure that + HttpServletResponse.sendRedirect() works when called after + a dispatch from an AsyncContext. (markt) +
fix + 53641: Correct name of HTTP header used in WebSocket + handshake for listing the preferred protocols. (markt) +
code + Document the constants that were added to the + RequestDispatcher interface in Servlet 3.0. (kkolinko) +
fix + Ensure custom error pages are not truncated if the page that triggered + the error set a content length header. (markt) +
fix + 53677: Ensure that a 500 response rather than no response is + returned if the HTTP headers exceed the size limit. (markt) +
fix + 53702: When merging web.xml fragments, allow for + <jsp-property-group> elements having multiple + <url-pattern> elements. (markt) +
add + Always make the resulting web.xml available even if metadata-complete is + true. (markt) +
fix + 53714: Provide separate system properties to control which + JARs are excluded from which scans when using the JarScanner. This + allows JARs to be excluded from all scans or only from TLD scanning + and/or Servlet 3.0 pluggability scanning. (markt) +
update + Add several JDK libraries to the value of jarsToSkip + property in the catalina.properties file. (markt, kkolinko) +
fix + Fix typos etc. in the code that logs merged web.xml (as enabled by + logEffectiveWebXml option on Context). (kkolinko) +
fix + 53758: When adding filters via + FilterRegistration.Dynamic the filters were added at the + wrong point because the isMatchAfter logic was inverted. + (markt) +
fix + 53783: Correctly handle JARs generated by tools that do not + create specific entries for directories. Patch provided by Violeta + Georgieva. (markt) +
fix + Improvements to DIGEST authenticator including the disabling caching of + authenticated user in session by default, tracking server rather than + client nonces and better handling of stale nonce values. (markt) +
fix + Improve performance of DIGEST authenticator for concurrent requests. + (markt) +
fix + CVE-2012-3546: Fix bypass of security constraint checks with FORM + authentication. Remove unneeded processing in RealmBase. + (kkolinko) +
fix + 53800: FileDirContext.list() did not provide + correct paths for subdirectories. Patch provided by Kevin Wooten. + (kkolinko) +
fix + 53801: Overlapping URL patterns were sometimes merged + incorrectly in security constraints leading to incorrect 401 responses. + Note: it was possible for access to be denied when it should have been + granted but it was not possible for access to be granted when it should + have been denied. (markt) +
+
+
Coyote
+ + + + + + + + +
fix + Remove the socket.soTrafficClass from the BIO and NIO + HTTP and AJP connectors because any use of the option is either ignored + or in some cases (Java 7 with NIO) throws an Exception. (markt) +
fix + Prevent possible NPE when processing Comet requests during Connector + shutdown. (markt) +
fix + 42181: Better handling of edge conditions in chunk header + processing. (kkolinko) +
fix + 53697: Correct a regression in the fix for 51881 + that mean that in some circumstances the comet flag was not + reset on HttpAprProcessor instances. This caused problems + when the Processor was re-used for a new connection that would trigger a + NullPointerException and could result in a JVM crash. + (markt) +
fix + 53725: Fix possible corruption of GZIP'd output. + (markt/kkolinko) +
fix + Better parsing of line-terminators for requests using chunked encoding. + (markt) +
fix + Further improvements to handling of Comet END events when the connector + is stopped. (markt) +
+
+
Jasper
+ + + + +
fix + 53545: Ensure buffered data is cleared when using a + jsp:forward action inside a classic custom tag. (markt) +
fix + 53654: Support file:// URLs for JSP + dependencies. Patch provided by Viola Lu. (markt) +
fix + 53792: Support MethodExpressions that include a + method invocation that is not at the end of the expression. (markt) +
+
+
Cluster
+ + + +
fix + Fix an issue when running under Java 7 which throws exceptions when + trying to set an invalid option whereas Java 6 silently swallowed them. + The option using the problem was soTrafficClass. + Investigations showed that this option had no effect for Cluster Channel + Receivers so it was removed. (markt) +
fix + 53513: Fix race condition between the processing of session + sync message and transfer complete message. (kfujino) +
+
+
Web applications
+ + + + + + +
fix + Update JSTL version information in the JNDI section of the documentation + web application. (markt) +
fix + 53524: Correct a typo in the cluster how-to section of the + documentation web application. Also fix a handful of spelling errors. + (markt) +
fix + 53601: Clarify in documentation that building Apache Tomcat 7 + from sources requires a Java 6 JDK. (kkolinko) +
fix + 53653: Allow for wrapped source code example in + config/context.html. Patch provided by Terence Bandoian. (schultz) +
update + 53793: Change links on the list of applications in the + Manager to point to '/appname/' instead of '/appname'. (kkolinko) +
+
+
Tribes
+ + + + +
fix + Avoid potential NPE identified by Find Bugs in + org.apache.catalina.tribes.io.ReplicationStream. (markt) +
fix + 53606: Fix potential NPE in TcpPingInterceptor. + Based on a patch by F. Arnoud. (markt) +
fix + 53607: To avoid NPE, set TCP PING data to ChannelMessage. + Patch provided by F.Arnoud (kfujino) +
+
+
Other
+ + + + +
fix + 53701: Javadoc fixes. Patch provided by sebb. (markt) +
code + Remove some unused code from Tomcat's package renamed, cut-down + copy of Commons BCEL used for annotation scanning. (markt) +
add + 53735: Add support for Java 7 byte code to Tomcat's + package renamed, cut-down copy of Commons BCEL used for annotation + scanning. (markt) +
+
+
Tomcat 7.0.29 (markt)released 2012-07-08
+
Catalina
+ + + + + + + + + + + +
add + Add support for searching for roles in JNDI/LDAP + using another value than the actual DN or username specified. + Rather it will use a value from the users directory entry. + The new attribute introduced to the JNDIRealm is userRoleAttribute + (fhanik) +
fix + Fix checking of recommended tcnative library version when using the APR + connector. (rjung) +
update + 50306: Improve StuckThreadDetectionValve: add + stuckThreadNames property as a pair for the stuckThreadIds one, + add thread ids to the log messages. (kkolinko) +
add + 52135: Add support for a default error page to be defined in + web.xml by defining an error page with just a nested location element. + It appears this feature was intended to be included in the Servlet 3.0 + specification but was accidently left out. (markt) +
fix + 53450: Correct regression in fix for 52999 that + could easily trigger a deadlock when deploying a ROOT web application. + (markt) +
fix + As per section 1.6.2 of the Servlet 3.0 specification and clarification + from the Servlet Expert Group, the servlet specification version + declared in web.xml no longer controls if Tomcat scans for annotations. + Annotation scanning is now always performed - regardless of the version + declared in web.xml - unless metadata complete is set to true. (markt) +
fix + 53619: As per clarification from the Servlet Expert Group, + JARs will always be scanned for ServletContainerInitializers regardless + of the setting of metadata complete. However, if an absolute ordering is + specified and a JAR is excluded from that ordering it will not be + scanned for ServletContainerInitializers nor will it be scanned for + matches to any HandleTypes annotations. (markt) +
add + 53465: Populate mapped-name property for resources defined in + web.xml. Based on a patch by Violeta Georgieva. (markt) +
add + Make the request available when establishing a WebSocket connection. + (markt) +
fix + 53467: Correct a regression in the fix for 53257 + that introduced problems for JSPs that used characters that must be + encoded if used in a URI. (markt) +
+
+
Coyote
+ + +
fix + 53430: Avoid a JVM crash when a connector that requires the + APR/native library is explicitly specified and the library, or a recent + enough version of it, is not available. (markt) +
+
+
Jasper
+ + + +
fix + 53421: Provide a more helpful error message if a getter or + setter cannot be found for a bean property when using expression + language. (markt) +
fix + 53460: Allow container to handle errors if the creation of the + PageContext fails rather than swallowing the error. (markt) +
+
+
Web applications
+ + + + + + + +
fix + Update the WebSocket examples in the examples web application so that + they work with secure connections (wss) as well as non-secure (ws) + connections. (markt) +
fix + 53456: Minor corrections and improvements to the HTTP + connector configuration reference. Patch provided by sebb. (markt) +
fix + 53459: Correction and clarifications to the SSL Connector + configuration examples in the SSL how-to. (markt) +
fix + 53464: Correct reference to sample init.d script for use with + jsvc in the documentation web application. (markt) +
fix + 53473: Correct the allowed values for the SSI option + isVirtualWebappRelative which are true or + false. (markt) +
fix + Document roleNested property of JNDIRealm + in Configuration Reference. (kkolinko) +
+
+
jdbc-pool
+ + + +
fix + 53445 (r1354173): + Allow configurable name for SlowQueryReportJmx (fhanik) +
fix + 53416 (r1354641): + Multiple pools with the same name should register under JMX (fhanik) +
+
+
Other
+ + + + + + +
fix + Fix cleanup of temporary files in TestNamingContext test. + (kkolinko) +
fix + Remove a few files from the source distribution that are not required + since they are copied / generated during the build. (markt) +
fix + Add manifest files to the set of files for which the line-ending is + changed to match the OS defaults in the source distributions. (markt) +
code + Align Jk Ant tasks definitions between antlib.xml and catalina.tasks + files, introducing jkupdate as synonym for + jkstatus. The latter one is deprecated. + Simplify bin/catalina-tasks.xml, replacing + taskdef with typedef and adding Ant condition + implementations used with JMX to jmxaccessor.tasks file. + (kkolinko) +
fix + 53454: Return correct content-length header for HEAD requests + when content length is greater than 2GB. (markt) +
+
+
Tomcat 7.0.28 (markt)released 2012-06-19
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 52055: An additional fix to ensure that the + ChunkedInputFilter is correctly recycled. (markt) +
add + 52954: Make DIGEST authentication tolerant of clients (mainly + older Android implementations) that do not follow RFC 2617 exactly. + (markt) +
update + 52955: Implement custom thread factory for container + start-stop thread pool. It allows to use daemon threads and give + them more distinct names. (kfujino) +
fix + 52999: Remove synchronization bottleneck from the firing of + Container events. (markt) +
add + 53008: Additional test cases for BASIC authentication and + RFC2617 compliance. Patch provided by Brian Burch. (markt) +
fix + 53021: Correct WebSocket protocol version detection. (pero) +
add + Add new attributes of allow and deny to + UserConfig. (kfujino) +
fix + 53024: Fix context reloading so requests received during the + reload are paused and processed when reloading completes rather than + receiving 404 responses. (markt) +
add + Improve the handling of watched resources so that changes trigger a + reload rather than a stop followed by a start which allows requests + received to be paused and processed when reloading completes rather than + receiving 404 responses. (markt) +
fix + Remove potential bottleneck on creation of new WebSocket connections. + (markt) +
fix + 53047: If a JDBC Realm or DataSource Realm is configured for + an all roles mode that only requires authorization (and no roles) and no + role table or column is defined, don't populate the Principal's roles. + (markt) +
fix + 53056: Add APR version number to tcnative version INFO log + message. (schultz) +
fix + 53057: Add OpenSSL version number INFO log message when + initializing. (schultz) +
update + Save a bit of memory in annotations cache in + DefaultInstanceManager by trimming annotation lists + to their size. (kkolinko) +
fix + Correctly configure the parser used to process server.xml so that + external entities may be used to include the content of external files + into server.xml. (markt) +
fix + Make sure ContextMBean#findFilterDefs returns correct filter + definitions. (kfujino) +
add + Ensure that maxParameterCount applies to multi-part + requests handled via the Servlet 3 file upload API. (markt) +
fix + 53062: When constructing absolute URLs for redirects from + relative URLs ensure that the resulting URLs are normalized. (markt) +
fix + 53067: Ensure the WebSocket Servlet continues to work when + requests are wrapped. (markt) +
fix + Enable host's xmlBase attribute in ContextConfig. (kfujino) +
fix + 53071: Use the message from the throwable (if there is one) + when generating the report in the ErrorReportValve and no + message has been specified via sendError(). (markt) +
fix + 53074: Switch to an infinite socket timeout by default for + WebSocket connections. (markt) +
fix + 53081: Do not always cache resources loaded by the web + application class loader since they may be very large which in turn + could trigger a memory leak. Calls to the web application class + loader's getResourceAsStream() method will now access + the resource directly rather than via the cache in most cases. (markt) +
fix + 53090: Include superclasses when considering injection + targets. Patch provided by Borislav Kapukaranov. (markt) +
fix + 53161: Provide a better error message if a + ClassFormatException occurs during annotation scanning and + do not prevent the web application from starting in this case. (markt) +
fix + 53180: Improve check for setter method when processing + annotations. Patch provided by Violeta Georgieva. (markt) +
fix + 53225: Fix an IllegalStateException due to the JAR file being + closed when accessing static resources in a JAR file when + urlCacheProtection="false" in the + JreMemoryLeakPreventionListener. (markt) +
fix + 53230: Changed ManagerBase to throw + TooManyActiveSessionsException instead of IllegalStateException + when the maximum number of sessions has been exceeded and a new + session will not be created. (schultz) +
fix + 53257: Ensure that resources, including JSP files, that have + names that include characters with special meanings in URLs (such as + ampersand, semicolon, plus, hash and percent) are correctly handled. + This bug is partially a regression caused by the original fix for + 51584 and partially an existing issue that had not previously + been identified. This fix reverts the original fix for 51584, + correctly fixes that issue and fixes the additional issues identified by + the test cases that were also added as part of this fix. + (markt/kkolinko) +
fix + 53266: If a class specified in a @HandlesTypes + annotation on a ServletContainerInitializer is missing + log a more helpful message and do not prevent the web application from + starting. (markt) +
fix + 53267: Ensure that using the GC Daemon Protection feature of + the JreMemoryLeakPreventionListener does not trigger a + full GC every hour. (markt) +
fix + 53285: Do not require security-role-ref elements + to contain a role-link element. (markt) +
fix + 53301: Prevent double initialization of pre-created Servlet + instances when used in embedded mode. (markt) +
fix + 53322: When processing resource injection, correctly infer + property name from its setter method if the name starts with several + uppercase characters. (kkolinko) +
fix + 53333: When processing JNDI resources, take account of the + types of any specified injection targets to ensure that the resource + definition and the injection target types are consistent. Based on a + patch provided by Violeta Georgieva. (markt) +
fix + 53337: Forwarding via a RequestDispatcher to an + asynchronous Servlet always failed. Includes a test case based on code + by Rossen Stoyanchev. (markt) +
fix + 53339: Ensure WebSocket call backs (onOpen etc.) + are called using the web application's class loader. (markt) +
fix + 53342: To avoid BindException, make startStopThreads into a + demon thread. (kfujino) +
fix + 53353: Make the internal HTTP header parser more tolerant of + Content-Type values that contain invalid parameters by ignoring the + invalid parameters. It is a followup to bug 52811. (markt) +
fix + 53354: Correctly handle @WebFilter annotations + that do not include a mapping. (markt) +
fix + 53356: Add support for servlets mapped explicitly to the + context root of a web application. (markt) +
fix + 53366: Ensure new HTTP header parser works correctly when + running Tomcat under a security manager. (markt/kkolinko) +
fix + 53368: Configure the default security policy to allow web + applications to use WebSocket when running under a security manager. + (markt/kkolinko) +
fix + 53373: Allow whitespace around delimiters in <Context> + aliases for readability. (schultz) +
+
+
Coyote
+ + + + + + + + + + + + + + + +
fix + 52858, CVE-2012-4534: Correct fix for high CPU load. + (fhanik) +
fix + 53138: Broken Sendfile on SSL introduced in 7.0.27 + (fhanik) +
fix + 52055: Additional fix required to ensure that + InputFilters are recycled between requests. (markt) +
fix + 53061: Fix a problem in the NIO connector whereby if the + poller was under low but consistent load (>1 request/per second and + always less than 1 second between requests) timeouts never took place. + (markt) +
fix + 53063: When using an Executor with BIO, use the + executor's maxThreads as the default for maxConnections. (markt) +
fix + 53119: Prevent buffer overflow errors being reported when a + client disconnects before the response has been fully written from an + AJP connection using the APR/native connector. (markt) +
add + 53169: Allow developers to avoid chunked encoding for a + response of unknown length by setting the Connection: close + header. Based on a patch suggested by Philippe Marschall. (markt) +
fix + 53173: Properly count down maxConnections (fhanik) +
update + Update default value of pollerThreadCount for the NIO connector. + The new default value will never go above 2 regardless of + available processors. (fhanik) +
add + Allow to retrieve the current connectionCount + via getter from the endpoint and as JMX attribute of the ThreadPool + mbean. (rjung) +
fix + Correct an edge case where Comet END events were not send to connected + clients when the Tomcat connector was stopped. (markt) +
fix + 53406: Fix possible stack overflow on connection close when + using Comet. (fhanik) +
fix + Improve InternalNioInputBuffer.parseHeaders(). (kkolinko) +
add + Implement maxHeaderCount attribute on Connector. + It is equivalent of LimitRequestFields directive of + Apache HTTPD. + Default value is 100. (kkolinko) +
+
+
Jasper
+ + + +
fix + 48097#c7, 53366#c1: If JSP page unexpectedly + fails to initialize PageContext instance, write exception to the logs + instead of silent swallowing. (kkolinko) +
fix + 53032: Modify JspC so it extends + org.apache.tools.ant.Task enabling it to work with features + such as namespaces within build.xml files. (markt) +
+
+
Cluster
+ + + + +
fix + Avoid NPE when reload if a state of a BackupManager is FAILED. (kfujino) +
fix + 53087: In order to avoid that a backup node expire a session, + replicate session access time in BackupManager. (kfujino) +
add + Add support for SecureRandom to cluster manager template. (kfujino) +
+
+
Web applications
+ + + + + + + + + + +
fix + Remove obsolete bug warning from Windows service + documentation page. (rjung) +
add + 50182: Various improvements to the Compression Filter. Patch + provided by David Becker. (markt) +
fix + 52853: Clarify how Jar Scanner handles directories. (markt) +
fix + 53158: Fix documented defaults for DBCP 1.x. + Patch provided by ph.dezanneau at gmail.com. (rjung) +
fix + 53203: Correct documentation for the default value + of connectionTimeout attribute for AJP protocol + connectors. (kkolinko) +
update + 53289: Clarify ResourceLink example that + uses DataSource.getConnection(username, password) method. Not all + data source implementations support it. (kkolinko) +
fix + Fix several HTML markup errors in servlets of examples web application. + (kkolinko) +
fix + 53398: Correct spelling of "received" in the + Manager application's XML output. (markt) +
fix + 53403: Update a reference to the Servlet specification in the + first web application section of the documentation web application to + include newer versions of the specification. (markt) +
+
+
jdbc-pool
+ + + + + + +
fix + 50864 (r1311844): + JMX enable most pool properties (fhanik) +
add + 53254 (r1340160): + Add in the ability to purge connections from the pool (fhanik) +
update + 53367 (r1346691): + Prevent pool from hanging during database failure (fhanik) +
update + When a connection is reconnected due to failed validation + make sure the ConnectionState is reset or it will assume + incorrect values (fhanik) +
fix + 53374 (r1348056): + Add support for the following properties in DataSourceFactory: + commitOnReturn, rollbackOnReturn, + useDisposableConnectionFacade, + logValidationErrors and + propagateInterruptState. + Based on patch proposed by Suresh Avadhanula. (kkolinko) +
+
+
Other
+ + + + + + + + +
update + Update to Eclipse JDT Compiler 3.7.2 at maven tomcat-jasper.pom. (pero) +
update + Update the native component of the Tomcat APR/native connector to + 1.1.24. (markt) +
fix + Add missing dependencies in pom files. (markt) +
add + 53034: Add project.url and + project.licenses sections to the POMs for the Maven + artifacts. (markt) +
fix + Properly mention jsp_2_2.xsd in the main LICENSE and + INSTALLLICENSE files. (kkolinko) +
fix + 53115: Fix using the command "catalina.bat run" + when the value of %TEMP% contains spaces. (kkolinko) +
update + Add dependencies and description to "validate" target in + build.xml, so that it could be run separately. + Improve BUILDING.txt and RUNNING.txt. + (kkolinko) +
+
+
Tomcat 7.0.27 (markt)released 2012-04-05
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + +
update + Explicitly ignore empty path values in virtualClasspath + attribute of VirtualWebappLoader class. Document that + whitespace around the values is trimmed. Reformat documentation + examples to make them more readable. (kkolinko) +
fix + Further improve fix for 51197 to allow an error reporting + Valve to write a response body if sendError() is called + during an asynchronous request on a container thread. (markt) +
fix + Correct fix for 51741 (r1307600): + If VirtualDirContext class is configured with non-empty + value of extraResourcePaths option (a feature added + in 7.0.24), do not implicitly set allowLinking option to + the value of true. If it is really needed, it should be + set explicitly. (kkolinko) +
add + 52500: Added configurable mechanism to retrieve user names + from X509 client certificates. Based on a patch provided by + Michael Furman. (schultz) +
fix + 52719: Fix a theoretical resource leak in the JAR validation + that checks for non-permitted classes in web application JARs. (markt) +
code + Code clean-up identified by 52723, 52724, + 52726, 52727, 52729, 52731 + and 52732. (markt) +
fix + 52792: Improve error message when a JNDI resource can not be + found. (markt) +
fix + 52811: Fix parsing of Content-Type header in + HttpServletResponse.setContentType(). Introduces + a new HTTP header parser that follows RFC2616. (markt/kkolinko) +
fix + 52830: Correct JNDI lookups when using + javax.naming.Name to identify the resource rather than a + java.lang.String. (markt) +
fix + 52833: Handle the case where the parent class loader for the + Catalina object does not have the system class loader in its hierarchy. + This may happen when embedding. Patch provided by olamy. (markt) +
add + 52839: Add a unit test for DigestAuthenticator and + SingleSignOn. Patch provide by Brian Burch. (markt) +
fix + 52846: Make sure NonLoginAuthenticator registers not + MemoryUser but GenericPrincipal into a session when UserDatabaseRealm + is used. (kfujino) +
add + 52850: Extend memory leak prevention and detection code to + work with IBM as well as Oracle JVMs. Extend unit tests to check direct + and indirect ThreadLocal memory leak detection. Based on a patch + provided by Rohit Kelapure. (markt) +
add + Add support for the WebSocket protocol (RFC6455). Both streaming and + message based APIs are provided and the implementation currently fully + passes the Autobahn test suite. Also included are several examples. + A significant contribution to this new functionality was provided by + Johno Crawford — particularly the examples. Contributions were + also provided by Petr Praus, Jonathan Drake & Slávka. (markt) +
fix + When stopping a Context, ensure that any Servlets registered with JMX + are unregistered. (markt) +
code + Make the implementation of Catalina.getParentClassLoader + consistent with similar methods across the code base and have it return + the system class loader if no parent class loader is set. (markt) +
fix + 52953: Ensure users can authenticate when using DIGEST + authentication with digested passwords if the digested password is + stored using upper case hexadecimal characters since DIGEST + authentication expects digests to use lower case characters. Based on a + patch provided by Neale Rudd. (markt) +
fix + 52957: Ensure that a Valve implements Lifecycle before + calling any Lifecycle methods on that Valve. (markt) +
fix + 52958: Fix MBean descriptors for + org.apache.catalina.realm package. (markt) +
fix + 52974: Fix NameNotFoundException when + field/method is annotated with @Resource annotation. Patch + provided by Violet Agg. (markt) +
add + Add support for multi-thread deployment in UserConfig. (kfujino) +
+
+
Coyote
+ + + + + + + + +
fix + Correctly register NIO sockets with poller after processing Comet events + to ensure that no read events are missed. This fixes an intermittent + issue observed in the unit tests. (fhanik/markt) +
fix + 52770: Fix a bug in the highly unlikely circumstance that + an infinite timeout was specified for writing data to a client when + using NIO. (markt) +
fix + 52858: Fix high CPU load with SSL, NIO and sendfile when + client breaks the connection before reading all the requested data. + (markt) +
fix + 52926: Avoid NPE when an NIO Comet connection times out on + one thread at the same time as it is closed on another thread. (markt) +
add + Include port number when known in connector name when logging messages + from connectors that use automatic free port allocation. (markt) +
fix + Don't try an unlock the acceptor thread if it is not locked. This is + unlikely to impact normal usage but it does fix some unit test issues. + (markt) +
fix + When using the APR connector ensure that any connections in a keep-alive + state are closed when the connector is stopped rather than when the + connector is destroyed. This is important when stop() followed by + start() is called on the connector. (markt) +
+
+
Jasper
+ + + + + + + + + +
fix + 52725: Use configurable package name for tags rather than + hard-coded value so configuration actually works. (markt) +
code + 52758: Implement additional interface methods in Eclipse JDT + integration required for Jasper to correctly with the latest Eclipse + development code. (markt) +
fix + 52772: Ensure uriRoot is fully validated before it is used. + Patch based on a suggestion by Eugene Chung. (markt) +
fix + 52776: Refactor the code so JspFragment.invoke cleans up + after itself. Patch provided by Karl von Randow. (markt) +
fix + 52970: Take account of coercion rules when invoking methods + via EL. (markt) +
fix + 52998: Partial fix. Remove static references to the EL + expression factory and use per web application references instead. + (markt) +
fix + 52998: Remainder of fix. Cache the class to use for the EL + expression factory per class loader. (kkolinko) +
fix + 53001: Revert the fix for 46915 since the use case + described in the bug is invalid since it breaks the EL specification. + (markt) +
+
+
Cluster
+ + +
fix + Replicate principal in ClusterSingleSignOn. (kfujino) +
+
+
Web applications
+ + + + + +
fix + 52760: Fix expires filter mime type in javascript examples. + (rjung) +
fix + 52842: Exception in MBeanDumper when dumping MBean for + StandardThreadExecutor. (rjung) +
update + Bring built-in mime types for embedded Tomcat more in line with the + ones defined in the default web.xml configuration file. (rjung) +
add + Add support to the JMXProxyServlet which is part of the Manager + application for fetching a specific key from a + CompositeData value. Updated documentation, so that + the entire 'get' command for the JMX proxy servlet is documented, + including the new optional 'key' parameter. (schultz/markt) +
+
+
jdbc-pool
+ + + + + + + + + +
update + Pool cleaner thread should be created using the classloader + that loaded the pool, not the context loader (fhanik) +
fix + 52804: Make pool properties serializable and cloneable. + (fhanik) +
fix + 51237 (r1302902): + Slow Query Report should log using WARN level when queries are slow + and within the threshold of caching it. (fhanik) +
fix + 52002 (r1302948): + Add in configuration option to disallow connection reuse. + (r1305862): + useDisposableConnectionFacade is by default enabled (fhanik) +
fix + 52493 (r1302969): + Java 7 DataSource method addition. (fhanik) +
fix + 51893 (r1302990): + Throw an error and notification when pool is exhausted. (fhanik) +
fix + 50860 (r1303031): + Add in option to configure logging for validation errors. (fhanik) +
fix + 52066 (r1305931): + Add in configuration option, progagateInterruptState, to allow threads to + retain the interrupt state. (fhanik) +
+
+
Other
+ + + + + + +
fix + 52750: Fix the way how daemon.sh parses command options so + that more then one can be provided. (mturk) +
update + Rearrange validate-eoln target in build.xml + so that it could be run ahead of compilation. (kkolinko) +
update + Update Apache Commons Daemon to 1.0.10. (mturk) +
update + Update the native component of the Tomcat APR/native connector to + 1.1.23 and take advantage of the simplified distribution. (mturk) +
update + Update to Eclipse JDT Compiler 3.7.2. (markt) +
+
+
Tomcat 7.0.26 (markt)released 2012-02-21
+
Catalina
+ + + + + + + + + + + + + + + + + + + + +
code + Provide constants for commonly used Charset objects and use + these constants where appropriate. (markt) +
fix + Refactor the fix for 52184 to correct two issues (a missing + class and incorrect class/method names) when using the extras logging + packages. (markt) +
fix + 52444: Only load classes during HandlesTypes processing if + the class is a match. Previously, every class in the web application was + loaded regardless of whether it was a match or not. (markt) +
fix + 52488: Correct typo: exipre -> expire. (markt) +
add + Add a unit test for SSO authentication. Patch provided by Brian Burch. + (markt) +
fix + 52511: Correct regression in the fix for 51741 + that caused a harmless exception to be logged when scanning for + annotations and WEB-INF/classes did not exist. (markt) +
code + Refactor to remove a circular dependency between + org.apache.catalina and org.apache.naming. + (markt) +
code + Remove some initialisation code from the standard start process (i.e. + via the scripts) that was intended for embedding but is not required + when performing a standard start.(markt) +
add + Add new method to MBeanFactory that allows any Valve to be + created and deprecate the methods to create specific Valves. (markt) +
add + Partial sync of MIME type mapping with mime.types from the Apache web + server. (rjung) +
fix + 52577: Fix a regression in the fix for 52328. + Prevent output truncation when reset() is called on a + response. (markt) +
fix + 52586: Remove an old and now unnecessary hack that modified + the path info reported via the + javax.servlet.forward.path_info request attribute when + forwarding to an error page. (markt) +
fix + 52587: Ensure that if it is necessary to fall back to the + default NullRealm, the NullRealm instance is created early enough for it + to be correctly initialised. (markt) +
fix + Fix millisecond output in AccessLogValve when using a + SimpleDateFormat based time pattern. (rjung) +
fix + 52591: When dumping MBean data, skip attributes where getters + throw UnsupportedOperationException. (markt) +
fix + 52607: Ensure that the extension validator checks the JARs in + the shared and common class loaders for extensions. (markt) +
fix + Correct a threading issue in the generation of the list of standard + authenticators during Context initialization that could lead to a web + application failing to start if Contexts were started in parallel. + (markt) +
fix + 52669: Correct regression that broke annotation processing in + /WEB-INF/classes for web applications deployed as WARs, + packageless classes and some embedding scenarios. The regression was + introduced by the invalid assumptions made in the fix for + 51741. (markt) +
fix + 52671: When dumping MBean data, skip attributes where getters + throw NullPointerException. (markt) +
+
+
Coyote
+ + + + + +
add + 51543: Provide a meaningful error message when writing more + response headers than permitted. (markt) +
fix + 52547: Ensure that bytes written (which is used by the access + log) is correctly reset after an HTTP 1.0 request has been processed. + (markt) +
code + Minor refactoring to reduce code duplication in the HTTP connectors. + (markt) +
fix + 52606: Ensure that POST bodies are available for reply after + FORM authentication when using the AJP connectors. (markt) +
+
+
Jasper
+ + + + +
fix + 52474: Ensure that leading and trailing white space is + removed from listener class names when parsing TLD files. (markt) +
fix + 52480: When converting class path entries from URLs to + files/directories, ensure that any URL encoded characters are converted. + Fixes JSP compilation with javac when Tomcat is installed at a path that + includes spaces. (markt) +
fix + 52666: Correct coercion order in EL when processing the + equality and inequality operators. (markt) +
+
+
Web applications
+ + + + + + +
update + Improve BUILDING.txt. Update instructions for + building. Add instructions for using Checkstyle and running the + tests. (kkolinko) +
add + 38216: Improve handling of null return values in + the JMX proxy servlet which is part of the Manager application. + (kkolinko) +
fix + 52515: Make it clear in the Realm how-to in the documentation + web application that digested password storage when using DIGEST + authentication requires that MD5 digests are used. (markt) +
fix + 52634: Fix typos in JSP examples. Patch provided by + Felix Schumacher. (rjung) +
fix + 52641: Remove mentioning of ldap.jar from docs. + Patch provided by Felix Schumacher. (rjung) +
+
+
jdbc-pool
+ + + +
fix + Fix code style issues and enable Checkstyle checks for jdbc-pool when + it is built within Tomcat. (kkolinko) +
fix + 51582 Correct set and reset the query cache to avoid NPE (fhanik) +
+
+
Other
+ + + +
fix + Update Commons Daemon to 1.0.9 to resolve 52548 which meant + that services created with service.bat did not set the + catalina.home and catalina.base system + properties. (markt) +
add + Implement check for correct end-of-line characters in the source + files. It is run as separate target in build.xml. + (kkolinko) +
+
+
Tomcat 7.0.25 (markt)released 2012-01-21
+
Web applications
+ + +
fix + Restore format of the first line of error message for JMX proxy + servlet in case scripts were depending on it. (markt) +
+
+
Other
+ + + + + +
fix + When building a Windows installer do not copy whole "res" folder to + output/dist, but only the files that we need. Apply fixcrlf filter + only after the files are copied, so that INSTALLLICENSE + file had correct line ends. (kkolinko) +
update + Remove res/License.rtf. The file that is actually shown + by the Windows installer is res/INSTALLLICENSE. + (kkolinko) +
add + Automate the OpenPGP signature generation for the release process. + (markt) +
fix + Don't exclude directories named target from the build process. + (rjung) +
+
+
Tomcat 7.0.24 (markt)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + +
add + 52184: Provide greater control over the logging of errors + triggered by invalid input data (i.e. data over which Tomcat has no + control). (markt/kkolinko) +
fix + 52225: Fix ClassCastException in an Alias added to + existing host through JMX. (kkolinko) +
fix + Do not throw IllegalArgumentException from parseParameters() call + when chunked POST request is too large, but treat it like an IO error. + The FailedRequestFilter filter can be used to detect this + condition. (kkolinko) +
fix + 52245: Don't allow web applications to package classes from + the javax.el package. Patch provided by pid. (markt) +
fix + 52259: Fix regression caused by the addition of the threaded + component start (46264) that triggered a deadlock on startup + if no Realm was configured. (markt) +
fix + 52293: Correctly handle the case when + antiResourceLocking is enabled at the Context level when + unpackWARs is disabled at the Host level. Based on a patch + by Justin Miller. (markt) +
fix + In ExtendedAccessLogValve when printing %-encoded value of + a parameter, use UTF-8 encoding to convert parameter value to bytes + instead of platform default encoding. (markt/kkolinko) +
fix + 52303: Allow web applications that do not have a login + configuration to participate in a SSO session. Patch provided by Brian + Burch. (markt) +
fix + 52316: When using sendfile, use the number of bytes requested + to be written to the response in the access log valve for bytes written + rather than recording a value of zero. (markt) +
fix + 52326: Reduce log level for class loading errors during + @HandlesTypes processing to debug. (markt) +
fix + 52328: Improve performance when large numbers of single + characters and/or small strings are written to the response via a + Writer. (markt) +
fix + 52384: Do not fail with parameter parsing when debug logging + is enabled. (kkolinko) +
fix + Do not flag extra '&' characters in parameters as parse errors. + (kkolinko) +
fix + Reduce log level for the message about hitting + maxParameterCount limit from WARN to INFO. (kkolinko) +
fix + 52387: Ensure that the correct host is used when configuring + logging when Tomcat is embedded. Patch provided by David Calavera. + (markt) +
update + 52405: Align the Servlet 3.0 implementation with the changes + defined in the first maintenance release (also know as Rev. A). See the + JCP documentation for a detailed list of changes + (markt) +
fix + Improve JMX names for objects related to Connectors that have the + address attribute set. (markt) +
fix + Remove some stale attributes from MBeans. (rjung) +
code + Move destruction of ContainerBase objects to + ContainerBase to ensure that they are destroyed. (markt) +
fix + 52443: Change the behaviour of the default Realm in the + embedded use case so it is set once on the Engine rather than on every + Context thereby avoiding the Lifecycle issues with having the same Realm + set on multiple Contexts. (markt) +
add + Provide a new Realm implementation, the NullRealm, that does not contain + any users and is used as the default Realm implementation (rather than + the JAAS Realm which was used prior to this change) if no Realm is + specified. (markt) +
fix + 52461: Don't assume file based URLs when checking last + modified times for global and host level web.xml files. Patch provided + by violetagg. (markt) +
add + Add test cases for the BASIC and NonLogin Authenticators when not using + SSO. Patch provided by Brian Burch. (markt) +
+
+
Coyote
+ + + + + +
add + 52028: Add support for automatic binding to a free port by a + connector if the special value of zero is used for the port. This is + mainly useful in embedded and testing scenarios. (markt) +
update + Remove obsolete emptySessionPath JMX attribute. (rjung) +
fix + Correct error in fix for 49683. (markt) +
fix + Ensure that the process of unlocking the acceptor thread does not + trigger processing of the connection as if it were a valid request. + (markt) +
+
+
Jasper
+ + + + + + +
fix + 52450: Add setter for entityResolver in ParserUtils. + This is mainly useful when jasper and dtds are in different + class loaders. (mturk) +
fix + 52321: Ensure that the order of multiple prelude/coda values + for JSP pages is respected. (markt) +
fix + 52335: Only handle <\% and not + \% as escaped in template text. (markt) +
fix + 52440: Ensure that when using + ValueExpression.getValueReference() if the expression is an + EL variable that the value returned is the ValueReference + for the ValueExpression associated with the EL variable. + (markt) +
fix + 52445: Don't assume that EL method expressions have + exactly three components (identifier, method name, parameters). (markt) +
+
+
Web applications
+ + + + + + + +
add + 38216: Add the ability to invoke MBean operations to the JMX + proxy servlet in the Manager application. Based on a patch by + Christopher Hlubek. (markt) +
update + Further clarify the relation between values used by + RemoteIpValve and RemoteIpFilter + and their use by AccessLogValve. (kkolinko) +
fix + 52243: Improve windows service documentation to clarify how + to include # and/or ; in the value of an + environment variable that is passed to the service. (markt) +
fix + 52366: Fix typo in VirtualWebappLoader documentation + (configuration example). (rjung) +
update + Replace Bugzilla search link on ROOT/index.jsp page with + one pointing to the bug reporting page of Tomcat site. (kkolinko) +
update + Move MBean dump code from JMXProxyServlet into a utility class. (rjung) +
+
+
Tribes
+ + + +
fix + 52208: Fix threading issue that may lead to harmless NPE + during shutdown that has occasionally been observed when running the + unit tests. (markt) +
fix + 52213, 52354, 52355 and + 52356: Fix some potential concurrency issues in + FastQueue. (markt) +
+
+
jdbc-pool
+ + +
add + r1207712: Pool cleaner should be a global thread, not spawn + one thread per connection pool. (fhanik) +
+
+
Other
+ + + + + + + + + + + + + + +
update + Update Apache Commons Daemon to 1.0.8. (mturk) +
update + Update Apache Commons Pool to 1.5.7. (kkolinko) +
fix + Fix line ends in .gitignore files contained in source + distributions. (rjung) +
fix + Run Mapper performance test twice if the first run took too long, + to ignore occasional failures. (kkolinko) +
fix + Align .gitignore and build.xml + exclude patterns with svn:ignore. (kkolinko) +
fix + Configure defaultexcludes for Ant 1.8.1/1.8.2. + The .git and .gitignore patterns are + in since Ant 1.8.2, but we include .gitignore in + src distributions. (kkolinko) +
add + 52237: Allow JUnit logs to be generated in formats other than + plain text. Patch provided by M Hasko. (markt/kkolinko) +
fix + Fix build condition for tomcat-dbcp to always rebuild when a new version + of commons-pool or commons-dbcp is downloaded. (kkolinko) +
update + Add example of configuration for SetCharacterEncodingFilter + to the default web.xml file. (kkolinko) +
update + Switch unit tests to bind Connectors to localhost rather than all + available IP addresses. (markt) +
update + Update to Eclipse JDT Compiler 3.7.1. (markt) +
update + Add Netbeans nbproject folder to svn:ignore + and .gitignore. (rjung) +
update + Align .gitignore with trunk. (rjung) +
+
+
Tomcat 7.0.23 (markt)released 2011-11-25
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
add + 46264: Add the ability to start and stop containers + (primarily Contexts) using a thread pool rather than a single thread. + This can significantly improve start and stop time. Based on patches + by Joe Kislo and Felix Schumacher. (markt) +
fix + 50570: Enable FIPS mode to be set in AprLifecycleListener. + Based upon a patch from Chris Beckey. (schultz/kkolinko) +
fix + 51744: Throw the correct exception if an application attempts + to modify the associated JNDI context. (markt) +
add + 51744: Add an option to the StandardContext that allows + exception throwing when an application attempts to modify the associated + JNDI context to be disabled. (markt) +
fix + 51910: Prevent NPE on connector stop if Comet applications + are being used without the CometConnectionManagerValve. (markt) +
fix + 51940: Do not limit saving of request bodies during FORM + authentication to POST requests since any HTTP method may include a + request body. Based on a patch by Nicholas Sushkin. (markt/kkolinko) +
fix + 51956: RemoteAddrFilter used getRemoteHost instead of + getRemoteAddr when filtering Comet events. (schultz) +
fix + 51952: Make the inclusion of a response body with a redirect + response introduced to address 41718 optional and disabled by + default due to the side-effects of including a body with the response in + this case. (markt) +
fix + 51972: Correctly handle protocol relative URLs when used with + sendRedirect(). (markt) +
code + Simplify the deployment code and use full paths in log messages to + remove any ambiguity in where a context is being deployed from. (markt) +
fix + 52009: Fix a NPE during access log entry recording when an + error occurred during the processing of a Comet request. (markt) +
fix + In OneLineFormatter log formatter in JULI always use + the US locale to format the date (esp. the month names). (rjung) +
add + Cache the results of parsing the global and host level web.xml files to + improve web application start time. (markt) +
fix + 52042: Correct threading issue in annotation caching that + could lead to an NPE if multiple threads were processing the same class + hierarchy for annotations. (markt) +
fix + Correct additional threading and premature clearance issues with the + annotation cache. (markt) +
fix + Correct a regression in the fix for 49779 that + parameters POSTed by an unauthenticated user to a page that required + FORM authentication were lost during the authentication process. + (markt) +
fix + 52055: Ensure that the input and output buffers are correctly + reset between keep-alive requests when using Servlet 3.0 asynchronous + request processing. (markt) +
fix + Ensure changes to the configuration of the RemoteHostValve and the + RemoteAddrValve via JMX are thread-safe. (markt) +
fix + Ensure that the memory leak protection for the HttpClient keep-alive + always operates even if the thread has already stopped. (markt) +
code + Remove the Java 1.2 specific error handling around the adding of the + shutdown hook. (markt) +
fix + Correct errors in i18n resources and resource usage that meant some + messages were either not used or were incorrectly formatted. (markt) +
code + Replace the use of deprecated auth method names from + authenticator.Constants with the auth method names from + HttpServletRequest. (kkolinko) +
add + Make configuration issues for security related Valves and Filters result + in the failure of the valve or filter rather than just a warning + message. (markt) +
add + Improve performance of parameter processing for GET and POST requests. + Also add an option to limit the maximum number of parameters processed + per request. This defaults to 10000. Excessive parameters are ignored. + Note that FailedRequestFilter can be used to reject the + request if some parameters were ignored. (markt/kkolinko) +
fix + 52091: Address performance issues related to lock contention + in StandardWrapper. Patch provided by Taiki Sugawara. (markt) +
code + Switch to using Collections.enumeration() rather than custom code that + does the same thing. (markt) +
fix + 52113: Don't assume presence of context.xml file with JMX + deployment. (markt) +
update + In RequestFilterValve (RemoteAddrValve, + RemoteHostValve): refactor value matching logic into + separate method and expose this new method isAllowed + through JMX. (kkolinko) +
fix + 52156: Ensure that + getServletContext().getResource(path) returns the correct + resource when path contains /../ sequences or any other + sequences that require normalization. (markt) +
add + Report existence of HTTP request parameter parsing errors via new + special ServletRequest attribute, + org.apache.catalina.parameter_parse_failed. (kkolinko) +
add + New filter FailedRequestFilter that will reject a request + if there were errors during HTTP parameter parsing. (kkolinko) +
update + Improve special attributes handling in Request object by using hash + table lookup instead of series of string comparisons. (kkolinko) +
code + Deprecate unused methods in IntrospectionUtils class. + (kkolinko) +
fix + Improve processing of errors that are wrapped in + InvocationTargetException. Rethrow fatal errors that must + be rethrown. (kkolinko) +
fix + Improve handling of failed web application deployments during automatic + deployment. Once deployment of a web application fails in one form (e.g. + WAR), no further attempt (e.g. directory) will be made to deploy that + web application. The base Lifecycle implementation has been improved to + allow failed web applications to be started once the configuration + issues have been resolved. Any changes to a context.xml file (global, + per host or web application specific) will now result in a redeploy + of the affected web application(s) that ensures that any changes are + correctly applied rather than a reload which ignores changes in + context.xml files. (markt/kkolinko) +
fix + 52173: Improve Javadoc for delegate attribute + of WebappClassLoader. Based on a patch by bmargulies. (markt) +
add + Add denyStatus attribute to RequestFilterValve + (RemoteAddrValve, RemoteHostValve valves) and + RequestFilter (RemoteAddrFilter, + RemoteHostFilter filters). It allows to use different + HTTP response code when rejecting denied request. E.g. 404 instead + of 403. (kkolinko) +
fix + Slightly improve performance of UDecoder.convert(). Align + %2f handling between implementations. (kkolinko) +
+
+
Coyote
+ + + + + + + + + + +
fix + 51881: Correctly complete Comet requests when the Comet END + event is triggered asynchronously. (markt) +
fix + 51905: Fix infinite loop in AprEndpoint shutdown if + acceptor unlock fails. Reduce timeout before forcefully closing + the socket from 30s to 10s. (kkolinko) +
fix + 51912: Fix HTTP header processing in NIO HTTP connector. + (kkolinko) +
fix + Improve MimeHeaders.toString(). (kkolinko) +
fix + Fix threading issue in NIO connectors during shutdown that meant Comet + connections were not always shut down cleanly. (markt) +
add + In HTTP connectors: self-guard against using a non-recycled input + buffer. Requests will be rejected with response status 400. (kkolinko) +
fix + 52121: Fix possible output corruption when compression is + enabled for a connector and the response is flushed. Includes a test + case provided by David Marcks. (kkolinko/markt) +
fix + Improve multi-byte character handling in Coyote output for HTTP + and AJP. (rjung) +
add + Refactor acceptor unlock code to reduce waiting time during connector + pause and stop. (markt) +
+
+
Jasper
+ + + + + +
fix + Correct possible (but very small) memory leak when using maxLoadedJsps + to limit the number of JSPs loaded at any one time. (markt) +
fix + 52051: Better handling of missing resource problems with + non-standard Servlet mappings so that a 404 response is returned to the + client rather than a 500 response. (markt) +
fix + 52091: Address performance issues related to log creation + in TagHandlerPool. Patch provided by Taiki Sugawara. (markt) +
code + Switch to using Collections.enumeration() rather than custom code that + does the same thing. (markt) +
+
+
Cluster
+ + + + + + +
fix + Avoid an unnecessary session ID change notice. + Notice of changed session ID by JvmRouteBinderValve is unnecessary to + BackupManager. In BackupManager, change of session ID is replicated by + the call of a setId() method. (kfujino) +
fix + Fix duplicate resetDeltaRequest() call in + DeltaSession.setId(String). (kkolinko) +
fix + Work around a known JVM bug that is fixed in 1.7.0_01 but still + present in 1.6.0_29 and was triggering intermittent unit test failure + for org.apache.catalina.tribes.group. + TestGroupChannelMemberArrival.testMemberArrival. + The bug affects any components that use NIO although it was more likely + to be observed in the clustering module than the HTTP or AJP NIO + connector. (markt) +
add + When Context manager does not exist, no context manager message is + replied in order to avoid timeout (default 60sec) of + GET_ALL_SESSIONS sync phase. (kfujino) +
fix + Fix setting maxInactiveInterval, sessionIdLength and + processExpiresFrequency for cluster managers. Use setter + when setting maxActiveSessions. (rjung) +
+
+
Web applications
+ + + + + + +
add + 50923: Use distinct background color for code + tag in Tomcat documentation, for better readability. (kkolinko) +
fix + 51630: Fix bug in async0 example that triggered an + IllegalStateException in the application log. (markt) +
add + 52025: Add additional information regarding DriverManager, + the service provider mechanism and memory leaks. (markt) +
fix + 52049: Improve setup instructions for running as a Windows + service: remove references to specific Windows operating systems - it + easily becomes dated; correct information on how a JRE is identified and + selected. (markt) +
update + 52172: Clarify Tomcat build instructions. Patch provided + by bmargulies. (kkolinko) +
+
+
jdbc-pool
+ + + + + +
fix + 52015: In jdbc-pool: JdbcInterceptor passes not 'this' but + 'proxy' to getNext().invoke. (kfujino) +
fix + In jdbc-pool: Improve handling of Errors that originate from methods + invoked through reflection. In TrapException interceptor: + rethrow Error as is, without wrapping it in a RuntimeException. + (kkolinko) +
fix + In jdbc-pool: Unwrap InvocationTargetException if it is caught in + ResultSetProxy, like we do it elsewhere. (kkolinko) +
fix + When building jdbc-pool from within Tomcat, use Tomcat's + output directory location. This allows to move all build + output away from the source tree. (kkolinko) +
+
+
Other
+ + + + + + + + + + + + + +
update + Update the package re-named copy of Commons BCEL (formerly Jakarta BCEL) + to the latest code from Commons BCEL trunk. (markt) +
code + Remove some unused code from the packaged renamed Commons BCEL. (markt) +
fix + 52059: In Windows uninstaller: Do not forget to remove + Tomcat keys from 32-bit registry on deinstallation. (kkolinko) +
code + Start the process of deprecating unused and unnecessary code that will + be removed in the next major release (8.0.x). (markt) +
update + Ignore .git directory when building the source + distributive. (markt) +
update + Remove trailing whitespace from the default configuration files. + (kkolinko) +
update + Improve RUNNING.txt. (kkolinko) +
update + Update optional Checkstyle library to 5.5. (kkolinko) +
add + In test suite: add LoggingBaseTest class to allow + use of Tomcat logging configuration in tests that do not start Tomcat. + (kkolinko) +
fix + In test suite: speed up TestGroupChannelSenderConnections. + Remove 48 seconds worth of waits. (kkolinko) +
fix + 52148: Add tomcat-coyote.jar to catalina-tasks.xml as this + JAR is now required by the Ant tasks. Patch provided by Volker Krebs. + (markt) +
add + Add sample Apache Commons Daemon JSVC wrapper script + bin/daemon.sh that can be used with /etc/init.d. + (mturk) +
+
+
Tomcat 7.0.22 (markt)released 2011-10-01
+
Catalina
+ + + + + + + + + + + + + + + + + + +
fix + 51550: An additional change that ensures any exceptions + thrown by an Authenticator (or any other Valve configured for the + Context) will be handled by the custom error pages for the Context if an + appropriate error page is configured. (markt) +
fix + 51580: Added a nicer error message when a WAR file contains + filenames not properly encoded in UTF-8. (schultz) +
fix + 51687: Added (optional) protection against + sun.java2d.Disposer thread pinning a WebappClassLoader into memory + in the JreMemoryLeakPreventionListener. (schultz) +
add + 51741: Fixes a problem with Eclipse WTP "Serve modules + without publishing" feature where applications failed to access + resources when using getResource() on the classloader. (slaurent) +
fix + 51744: Prevent application code from closing the associated + JNDI context while the application is running. (markt) +
fix + Correct a regression with the fix for 51653 that broke custom + error pages for 4xx responses from the Authenticators. Error handling + and request listeners are now handled in the StandardHostValve to ensure + they wrap all Context level activity. (markt) +
fix + 51758: The digester (used for processing XML files) used the + logger name org.apache.commons.digester.Digester rather + than the expected org.apache.tomcat.util.digester.Digester. + The digester has been changed to use the expected logger name. + (markt/kkolinko) +
fix + 51774: Fix incorrect cached method signature that prevented + session tracking modes from being defined in web.xml when running under + a security manager. (markt) +
add + Add an annotation cache to the DefaultInstanceManager that + improves performance for applications that make use of a lot of + non-poolable objects (e.g. tag files) that need to be scanned for + annotations when created. (markt) +
fix + Use the specification compliant request attribute of + javax.servlet.request.ssl_session_id to access the SSL + session ID and deprecated the Tomcat specific request attribute. (markt) +
add + Allow to overwrite the check for distributability + of session attributes by session implementations. (rjung) +
update + Add Java 7 sunec.jar and zipfs.jar to the list of JARs + to skip when scanning for TLDs and web fragments. (rjung) +
add + 51862: Added a classesToInitialize attribute to + JreMemoryLeakPreventionListener to allow pre-loading of configurable + classes to avoid some classloader leaks. (slaurent) +
fix + Reduce visibility of static field ManagerBase.name and + make it final. (kkolinko) +
update + Add thread name to juli OneLineFormatter. (rjung) +
fix + Ensure Servlets that implement ContainerServlet always get treated as + restricted. (markt) +
fix + 51872: Ensure that the access log always uses the correct + value for the remote IP address associated with the request and that + requests with multiple errors do not result in multiple entries in + the access log. (markt) +
+
+
Coyote
+ + + + + + + + + + + + + +
code + Remove unused and undocumented socketCloseDelay attribute from NIO + connector. (markt) +
fix + 49683: Support separate connection and keep-alive timeouts + for the APR/native connector HTTP and AJP connectors. (markt) +
code + Further re-factoring of the HTTP connectors to align the BIO, NIO and + APR implementations. (markt) +
fix + 51794: Fix race condition in NioEndpoint. (fhanik) +
fix + 51811: Correct SSL configuration property name from + sslImplemenationName to sslImplementationName. (rjung) +
fix + Fix a timing issue in NIO connector that meant that stopping a connector + did not trigger a Comet END event if the associated processor was + processing a READ event when the connector was stopped. (markt) +
fix + Replace unneeded call that iterated events queue in NioEndpoint.Poller. + (kkolinko) +
fix + 51860: Fix issues if using NIO with a custom + SSLImplementation. Based on a suggestion by Roman Tsirulnikov. (markt) +
fix + Allow the BIO HTTP connector to be used with SSL when running under Java + 7. (markt) +
update + Don't send AJP CPONG if endpoint is already paused. (rjung) +
update + Align APR AJP connector with NIO one. Send 503 if endpoint is paused. + (rjung) +
update + Accept AJP request even if endpoint is paused, if CPING was successful. + (rjung) +
+
+
Jasper
+ + + +
fix + When unloading JSPs due to configuration of the + maxLoadedJsps initialisation parameter, the unloading code + was retaining a reference to the unloaded JSP preventing the + associated class from being unloaded until the JSP that replaced it was + itself unloaded. (markt) +
fix + 51852: Correct two problems in the handling of varargs + methods with the BeanELResolver. The first meant the wrong method was + sometimes called and the second that an ArrayIndexOutOfBoundsExceptions + could be thrown. Patch (including a test case) provided by Matt Benson. + (markt) +
+
+
Cluster
+ + + +
update + Refactor cluster manager configuration: move handling of common + attributes to base class. (kfujino, rjung) +
add + New cluster manager attribute sessionAttributeFilter + allows to filter which session attributes are replicated using a + regular expression applied to the attribute name. (rjung) +
+
+
Web applications
+ + + +
fix + Correct the documentation for connectionLinger attribute + for the AJP and HTTP connectors. (markt) +
update + Document caveat of using RemoteAddrValve with IPv6 + addresses. (kkolinko) +
+
+
jdbc-pool
+ + + + + + +
fix + In jdbc-pool: Avoid IllegalArgumentException when setting maxActive + less than or equal to 0. + ArrayBlockingQueue doesn't allow capacity of 0 or less. (kfujino) +
fix + 48392 (r1169796): Fix typo in + StatementDecoratorInterceptor. (fhanik) +
fix + 51139: + In jdbc-pool: validatorClassName and suspectTimeout are ignored. + In order to support them correctly, validatorClassName and + suspectTimeout are added to a property list. (kfujino) +
fix + 51786: + In jdbc-pool: Discarded connection is not active in a pool any longer. + It removes from the active connection list. (kfujino) +
fix + 51871: Fix dependency in Maven POM file of + tomcat-jbdc. (kkolinko) +
+
+
Other
+ + + + +
update + Update the "test" target in the default build file to report a test + failure only after all available connector variants (bio, nio, apr) + have been tested. Do not stop after first connector that fails. + (kkolinko) +
update + 51887: When running the unit tests, use a fast but insecure + random number source for session ID generation to reduce the delays + caused by waiting for entropy. (kkolinko/markt) +
code + Code clean-up to further reduce the number of warnings reported by + Eclipse, FindBugs and CheckStyle. (markt/kkolinko) +
+
+
Tomcat 7.0.21 (markt)released 2011-09-01
+
Catalina
+ + + + + + + + + + + + + +
add + 41718: Include a response body when sending a redirect. + (markt) +
add + 51640: Improve the memory leak prevention for leaks triggered + by java.sql.DriverManager. (markt) +
fix + 51644: Fix annotation scanning for contexts with a + multi-level context path such as /a/b. (markt) +
fix + Unregisters MBean of DataSource when web application stops. (kfujino) +
fix + 51650: Code clean-up. Patch provided by Felix Schumacher. + (markt) +
fix + 51653: Move application level error page handling from the + Host to the Context. This ensures that application error page handling + is completed before the requestDestroyed event of any + ServletRequestListener is fired. (markt) +
fix + 51654: Improve handling of invalid appBase settings for Host + elements. (markt) +
fix + 51658: Fix possible NPE when logging a failed request. Based + on a suggestion by Felix Schumacher. (markt) +
fix + 51688: JreMemoryLeakPreventionListener now protects against + AWT thread creation. (schultz) +
fix + 51712: Ensure cache control headers are sent when appropriate + even if the request is secure. Patch provided by Michael Zampani. + (markt) +
fix + 51713: Improve message that is logged if there is an error + in the value of protocol in a Connector. + (kkolinko) +
fix + 51739: When using a landing page with FORM authentication + ensure that the request has a valid HTTP method. (markt) +
+
+
Coyote
+ + + + + + + +
fix + 51641: Use correct key when removing processor instances from + the connections map during clean-up. Patch provided by zhh. (markt) +
fix + More changes to align the code between the different HTTP connectors. + (markt) +
fix + Ensure AjpMessage headers are correct for the direction of the message. + (markt) +
code + Code clean-up and re-factoring to reduce duplicate code in the AJP + processor implementations. (markt) +
add + Detect incomplete AJP messages and reject the associated request if one + is found. (markt) +
fix + 51698: Fix CVE-2011-3190. Prevent AJP message injection. + (markt) +
+
+
Jasper
+ + +
fix + 41673: Use platform line-endings when reporting compilation + errors. (markt) +
+
+
Cluster
+ + +
add + 51736: Make rpcTimeout configurable in BackupManager. + (kfujino) +
+
+
Web applications
+ + +
fix + 51649: Update the documentation web application to include + the ThreadLocal leak prevention listener. (markt) +
+
+
jdbc-pool
+ + +
add + 51583 (r1157874, r1162102): Fix + shutdown delay in jdbc-pool. (fhanik/kkolinko) +
+
+
Other
+ + + +
fix + 51558: Don't force the use of StandardManager when using + any of the Tomcat#addWebapp() methods. (markt) +
fix + 51704: Make use of File#mkdirs() more robust. + (markt) +
+
+
Tomcat 7.0.20 (markt)released 2011-08-11
+
Catalina
+ + + + + + + + + + + + + + + + + + + + +
fix + Corrected missing comma in the value of jarsToSkip + property in conf/catalina.properties file, which + caused tomcat-jdbc.jar and commons-beanutils*.jar to be not + ignored when scanning jars for tag libraries. (kkolinko) +
fix + 41709: Provide exception messages where no message is + provided currently for IllegalStateExcpetions triggered by calling + HttpServletResponse methods when the response is committed. (markt) +
fix + 51509: Fix potential concurrency issue in CSRF prevention + filter that may lead to some requests failing that should not. (markt) +
fix + 51518: Correct error in web.xml parsing rules for the + <others/> tag when using absolute ordering. (markt) +
add + Move the SetCharacterEncoding filter from the examples web application + to the org.apache.catalina.filters package so it is + available for all web applications. (markt) +
fix + 51550: Internal errors in Tomcat components that process + requests before they are passed to a web application, such as + Authenticators, now return a 500 response rather than a 200 response. + (markt) +
fix + 51555: Allow destroy() to be called on Lifecycle components + that are in the initialized state. (markt) +
add + Add x-threadname pattern format token to ExtendedAccessLogValve to log + the current request thread name. Based on a patch from Felix Schumacher. + (timw) +
fix + 51584: Ensure file paths are encoded/decoded when translated + to/from URLs when working with resources from a Context so special + characters don't cause issues. (markt) +
fix + 51586: Expand error handling to cover anything that is + recoverable (or might be recoverable) when loading classes during + HandlesTypes processing. (markt) +
fix + 51588: Make it easier to extend the AccessLogValve to add + support for custom elements. (markt) +
fix + Ensure that calls to StandardWrapper methods() that may trigger creation + of a Servlet instance always do so in way that correctly instantiates a + Servlet instance. (markt) +
fix + In JDBCStore: Committing connection if autoCommit is false. + Make sure committed connection is returned to the pool if datasource is + enabled. (kfujino) +
add + Split condition attribute of AccessLogValve into two, + conditionIf and conditionUnless. Implement + conditional logging that logs only if a request attribute is present. + (kkolinko) +
fix + Allow to have several AccessLogValve instances in the same scope (e.g. + in the same Context). (kkolinko) +
fix + 51610: If an unchecked exception occurs during a lifecycle + transition (e.g. web application start) ensure that the component is + put into the failed state. (markt) +
fix + 51614: Avoid calling store.load() and session.expire() + twice in PersistentManager when expiring sessions. (kfujino) +
fix + Prevent spurious log warnings on container stop if a child component has + previously failed. (markt) +
fix + Add missing getter and setter for the alwaysUseSession attribute of the + authenticators. (markt) +
+
+
Coyote
+ + + + + + + + + + +
fix + 49595: Prevent JVM crash with the AJP APR connector when + flushing a closed socket. (jfclere) +
fix + 50394: Return -1 instead of throwing an exception when + encountering an EOF while processing an input stream with the HTTP APR + connector. (jfclere) +
fix + Correctly handle a connectionTimeout value of -1 (no timeout) for the + HTTP NIO and AJP NIO connectors. (markt) +
fix + 51503: Add additional validation that prevents a connector + from starting if it does not have a port > 0. (markt) +
fix + 51557: Ignore HTTP headers that do not comply with RFC 2616 + and use header names that are not tokens. (markt) +
add + Improve error handling for HTTP APR if an error occurs while using + sendfile. (markt) +
fix + Ensure that when using sendfile, HTTP APR sockets are not added to + multiple pollers. This may cause errors during shutdown. (markt) +
update + Set reuse flag of final AJP END_RESPONSE + packet to 0 if we plan to close the connection. (rjung) +
update + Correctly indicate if socket is closing when calling recycle for the AJP + NIO processor. Note since the flag is unused in this case there were no + bugs triggered by the re-factoring error. (rjung) +
+
+
Jasper
+ + + +
fix + 51532: JSP files with dependencies in JARs were recompiled on + every access leading to poor performance. (markt) +
fix + 51544: Correctly resolve bean methods in EL so accessible + methods that are overridden by inaccessible methods do not cause an + IllegalAccessException. (markt) +
+
+
Web applications
+ + + + + + + + + + + +
fix + 41498: Add the allRolesMode attribute to the Realm + configuration page in the documentation web application. (markt) +
fix + 48997: Fixed some typos and correct cross-referencing to the + HTTP Connector documentation with the SSL How-To page of the + documentation web application. (markt) +
fix + 49122: Improvements and fixes for index page for ROOT web + application. Based on a patch provided by pidster. (markt) +
fix + 51516: Correct documentation web application to show correct + system property name for changing the name of the SSO session cookie. + (markt) +
update + Configure the Manager and Host Manager web applications with the Set + Character Encoding Filter to make the default request character encoding + UTF-8 to improve i18n support. Note that best results will be obtained + if the connector is also configured with + URIEncoding="UTF-8".(markt) +
update + Update the documentation web application to be even more explicit about + the implications of setting the path attribute on a Context element in + server.xml. (markt) +
fix + 51561: Update the Realm page within the documentation web + application to recommend the use of digest.[bat|sh] to generate digests + rather than calling RealmBase directly. (markt) +
fix + 51567: Update the class loading page of the documentation + web application to include information on the search order for the + common class loader when separate values are used for $CATALINA_HOME and + $CATALINA_BASE. (markt) +
update + Improve class loading documentation and logging documentation. + (kkolinko) +
add + Add information to the security page of the documentation web + application for the ciphers attribute of the Connector element. (markt) +
+
+
Other
+ + + + + + + + + + + + + + +
fix + 51503: Add additional validation to Windows installer that + ensure that the shutdown port, HTTP port and AJP port are all specified + during the install process. (markt) +
fix + 51531: Update sample Eclipse classpath file to reflect + updated ECJ jar. Patch provided by Ian Brandt. (markt) +
update + Convert Tomcat unit tests to JUnit 4. (kkolinko) +
update + Update optional CheckStyle library to 5.4. (kkolinko) +
update + Remove resolveHosts attribute from AccessLogValve + configuration in the default server.xml. It was documented + in 7.0.19 that it has no effect. (kkolinko) +
update + Simplify mapping for jsp servlet in the default + web.xml. (kkolinko) +
fix + Correctly handle uninstall with the Windows installer if the service is + installed with a name that contains a '-' character. (markt) +
fix + 51598: Prevent direct invocation of the Windows uninstaller + without a service name from executing since the uninstall will not be + complete. (markt) +
fix + Use Tomcat icon (cat) instead of Apache Commons Daemon (feather) one + in the list of uninstallable programs on Windows. (kkolinko) +
update + Update to Apache Commons Daemon 1.0.7. (markt) +
fix + 51621: Add additional required JARs to the deployer + distribution. (markt) +
fix + Fix a small number of warnings reported by FindBugs. (markt) +
update + Update to version 1.1.22 of the native component for the AJP APR/native + and HTTP APR/native connectors. (markt) +
+
+
Tomcat 7.0.19 (markt)released 2011-07-19
+
Catalina
+ + + + + + + + + + + +
add + Add option to activate access log for unit tests. (rjung) +
fix + Fix regression in year number formatting for AccessLogValve. (rjung) +
add + 46252: Allow to specify character set to be used to write + the access log in AccessLogValve. (kkolinko) +
fix + 51494: Prevent an NPE when a long running request completes + if the associated web application was destroyed while the request was + processing. (markt) +
update + Allow choosing a locale for timestamp formatting in AccessLogValve. + (rjung) +
fix + When generating access logs for errors, log at the Context/Host level if + a Context or Host can be identified for the failed request. (markt) +
update + Create a directory for access log or error log (in AccessLogValve and + in JULI FileHandler) automatically when it is specified as a part of + the file name, e.g. in the prefix attribute. Earlier this + happened only if it was specified with the directory + attribute. (kkolinko) +
fix + Log a failure if access log file cannot be opened. (kkolinko) +
fix + Use en_US as locale for timestamps in ExtendedAccessLogValve. + (rjung) +
fix + Use en_US as locale for creationdate in WebdavServlet. (rjung) +
+
+
Coyote
+ + + + + + + + +
update + 51477: Support all SSL protocol combinations in the + APR/native connector. This only works when using the native library + version 1.1.21 or later, which is not yet released. (rjung) +
update + Various refactorings to reduce code duplication and unnecessary code in + the connectors. (markt) +
fix + Correct regression introduced in 7.0.17 that triggered 400 entries in + the AccessLog when using the AJP/BIO connector. (markt) +
fix + Fix regression producing invalid MBean names when using IPV6 + addresses for connectors. (rjung) +
fix + Add missing thread name in RequestProcessor when Servlet 3 Async + is used. Fixes null thread name in access log and JMX MBean. (rjung) +
fix + Fix CVE-2011-2526. Protect against infinite loops (HTTP NIO) and crashes + (HTTP APR) if sendfile is configured to send more data than is available + in the file. (markt) +
fix + Prevent NPEs when a socket is closed in non-error conditions after + sendfile processing when using the HTTP NIO connector. (markt) +
+
+
Cluster
+ + +
update + Remove unnecessary server.xml parsing code for old cluster + implementation that does not ship as part of Tomcat 7. (markt) +
+
+
Web applications
+ + + + + +
add + Add additional information to the documentation web application on the + benefits and remaining risks when running under a security manager. + (markt) +
fix + 51490: Correct broken HTML in JSP tag plugin examples and + improve the <c:if> example to make failures more obvious. Based on + suggestions by Charles. (markt) +
add + Document ExtendedAccessLogValve. (rjung) +
fix + Correct default value of enableLookups for connectors + and mention, that resolveHosts for the AccessLogValve + is replaced by enableLookups. (rjung) +
+
+
jdbc-pool
+ + +
add + Include jdbc-pool into Tomcat release. (fhanik) +
+
+
Other
+ + + +
update + Update to Apache Commons Daemon 1.0.6. (markt) +
update + Update to Eclipse JDT Compiler 3.7. (markt) +
+
+
Tomcat 7.0.18 (markt)not released
+
Catalina
+ + + + + + +
fix + Correct regression introduced in 7.0.17 that triggered an NPE if a + CrawlerSessionManagerValve was used without setting crawlerUserAgents. + (markt) +
fix + 51466: Correct comment typos in HostManagerServlet. Patch + provided by Felix Schumacher. (markt) +
fix + 51467: Invoke Thread.start() rather than Thread.run() so that + listeners and filters are stopped in a separate thread rather than the + current thread. Patch provided by Felix Schumacher. (markt) +
fix + 51473: Fix concatenation of values in + SecurityConfig.setSecurityProperty(). (kkolinko) +
fix + Fix response.encodeURL() for the special case of an absolute URL + with no path segment (http://name). (rjung) +
+
+
Coyote
+ + + +
fix + Correct regression caused by connector re-factoring that made AJP + APR/native connector very unstable on Windows platforms. (markt) +
fix + Correct regression caused by connector re-factoring that meant that + sendfile data was not reset between pipe-lined HTTP requests. (markt) +
+
+
Tribes
+ + + +
update + Re-factor tests to align packages for tests with the classes under test. + Start to convert non-JUnit tests to JUnit. Remove unnecessary code. + (markt) +
fix + Add synchronization to receiver socket binding to prevent test failures + on Linux. (markt) +
+
+
Other
+ + + +
fix + More code clean-up to remove unused code and reduce IDE warnings. + (markt/kkolinko) +
update + Further improvements to the Windows installer. (markt/kkolinko) +
+
+
Tomcat 7.0.17 (markt)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
add + 48956: Add regular expression support for SSI. (markt) +
add + 49165: Allow any time stamp formats supported by + SimpleDateFormat in AccessLogValve. Support logging begin and/or end of + request. (rjung) +
add + 50677: Allow system property variables to be used in the + values of "common.loader" and other "*.loader" properties in the + catalina.properties file. (kkolinko) +
fix + 51376: When adding a Servlet via + ServletContext#addServlet(String, Servlet), the Servlet was not + initialized when the web application started and a load on startup value + was set. (markt) +
fix + 51386: Correct code for processing @HandlesTypes annotations + so only types of interest are reported to a ServletContainerInitializer. + (markt) +
update + Add the Tomcat extras, ant-junit and Java Help Jars to the list of JARs + to skip when scanning for TLDs and web fragments. (rjung) +
fix + The fix for bug 51310 caused a regression that re-introduced + bug 49957 and deleted the contents of the work directory + when Tomcat was shutdown. This fix ensures that the work directory for + an application is not deleted when Tomcat is shutdown. (markt) +
fix + Correct issues with JULI's OneLineFormatter including: correctly + re-using formatted timestamps when possible; thread-safety issues in + timestamp formatting; correcting the output of any milliseconds to + include leading zeros and formatting any parameters present. + (kkolinko/markt/rjung) +
fix + 51395: Fix memory leak triggered when an application that + includes a SAXParserFactory is the first web application to be loaded. + (markt) +
fix + 51396: Correctly handle jsp-file entries in web.xml when the + JSP servlet has been configured via code when embedding Tomcat. (markt) +
fix + 51400: Avoid known bottleneck in JVM when converting between + Strings and bytes by always providing a Charset rather than an encoding + name. Based on a patch by Dave Engberg. (markt) +
fix + 51401: Correctly initialise shared WebRuleSet instance used + by the digesters that parse web.xml and prevent incorrect warnings about + multiple occurrences of elements that are only allowed to appear once in + web.xml and web-fragment.xml. (kfujino) +
add + 51403: Avoid NPE in JULI FileHandler if formatter is + misconfigured. (kkolinko) +
fix + Previous improvements in JAR scanning performance introduced a start-up + performance penalty for some use cases. This fix addresses those + performance penalties while retaining the original improvements. (markt) +
add + 51418: Provide more control over Context creation when + embedding Tomcat. Based on a patch by Benson Margulies. (markt/kkolinko) +
fix + Remove redundant copy of catalina.properties from o.a.c.startup. + Generate this copy for inclusion in bin and src jars during the + ant "compile" task. (rjung) +
fix + Use system properties loaded from catalina.properties via the class + path in unit tests. (rjung) +
update + Improve JMX unit test. (rjung) +
fix + Fix IllegalStateException for JavaScript files when switching from + Writer to OutputStream. The special handling of this case in the + DefaultServlet was broken due to a MIME type change for JavaScript. + (funkman) +
fix + Fix CVE-2011-2204. Prevent user passwords appearing in log files if a + runtime exception (e.g. OOME) occurs while creating a new user for a + MemoryUserDatabase via JMX. (markt) +
fix + Fix an issue with the CrawlerSessionManagerValve that meant sessions + were not always correctly tracked. (markt) +
fix + 51436: Send 100 (Continue) response earlier to enable + ServletRequestListener implementations to read the request body. Based + on a patch by Simon Olofsson. (markt) +
fix + Ensure an access log entry is made if an error occurs during + asynchronous request processing and the socket is immediately closed. + (markt) +
fix + Ensure that if asyncDispatch() is called during an onTimeout event and + the target Servlet does not call startAsync() or complete() that Tomcat + calls complete() once the target Servlet exits. (markt) +
fix + Improve the handling for Servlets that implement the deprecated + SingleThreadModel when embedding Tomcat. (markt) +
fix + 51445: Correctly initialise all instances of Servlets that + implement SingleThreadModel. Based on a patch by Felix Schumacher. + (markt) +
fix + 51453: Fix a regression in the preemptive authentication + support (enhancement 12428) that could trigger authentication + even if preemptive authentication was disabled. (markt) +
fix + Prevent possible NPE when serving Servlets that implement the + SingleThreadModel interface. (markt) +
fix + In launcher for embedded Tomcat: do not change catalina.home + system property if it had a value. (kkolinko) +
fix + When using Servlets that implement the SingleThreadModel interface, add + the single instance created to the pool when it is determined that a + pool of servlets is required rather than throwing it away. (markt) +
+
+
Coyote
+ + + + + + +
fix + Fix unit test for bindOnInit which was failing for APR on some + platforms. (rjung) +
fix + Remove superfluous quotes from thread names for connection pools. + (rjung) +
fix + Fix crash observed during pausing the connector when using APR. + Only add socket to poller if we are sure we don't close it later. + (rjung) +
update + Various refactorings to reduce code duplication and unnecessary code in + the connectors. (markt) +
fix + Correct a regression introduced in Apache Tomcat 7.0.11 that broke + certificate revocation list handling. (markt) +
+
+
Jasper
+ + + + + +
update + Improve the message printed by TldLocationsCache and add configuration + example to the logging.properties file. (kkolinko) +
fix + 33453: Recompile JSPs if last modified time of the source or + any of its dependencies changes either forwards or backwards. Note that + this introduces an incompatible change to the code generated for JSPs. + Tomcat will automatically re-compile any JSPs and tag files found in the + work directory when upgrading from 7.0.16 or earlier to 7.0.17 or later. + If you later downgrade from 7.0.17 or later to 7.0.16 or earlier, you + must empty the work directory as part of the downgrade process. (markt) +
fix + 36362: Handle the case where tag file attributes (which can + use any valid XML name) have a name which is not a Java identifier. + (markt/kkolinko) +
add + Broaden the exception handling in the EL Parser so that more failures to + parse an expression include the failed expression in the exception + message. Hopefully, this will help track down the cause of + 51088. (markt) +
+
+
Cluster
+ + + + +
fix + 51306: Avoid NPE when handleSESSION_EXPIRED is processed + while handleSESSION_CREATED is being processed. (kfujino) +
fix + Notifications of changes in session ID to other nodes in the cluster + should be controlled by notifySessionListenersOnReplication rather than + notifyListenersOnReplication. (markt) +
fix + The change in session ID is notified to the container event listener on + the backup node in cluster. + This notification is controlled by + notifyContainerListenersOnReplication.(kfujino) +
+
+
Web applications
+ + + + + + +
fix + Update Maven repository information in the documentation to reflect + current usage. (markt) +
add + 43538: Add host name and IP address to the HTML Manager + application. Patch by Dennis Lundberg. (markt) +
fix + Add session="false" directive to the index page of the + ROOT web application. (kkolinko) +
fix + 51443: Document the notifySessionListenersOnReplication + attribute for the DeltaManager. (markt) +
fix + 51447: Viewing a back up session in the HTML Manager web + application no longer changes the session to a primary session. Based on + a patch provided by Eiji Takahashi. (markt) +
+
+
Other
+ + + + + + + + +
fix + 33262: Install monitor to auto-start for current user only + rather than all users to be consistent with menu item creation. (markt) +
add + 40510: Provide an option to install shortcuts for the current + user or all users. Also ensure registry is correctly cleaned on + uninstall for 64-bit platforms. (markt) +
add + 50949: Provide the ability to specify the AJP port and + service name when installing Tomcat using the Windows installer. This + permits multiple instances of the same Tomcat version to be installed + side-by-side. (markt) +
update + Clean up shell and batch scripts (improve consistency, + clarify comments, add configtest command support for + Windows). (rjung) +
fix + 51206: Make CATALINA_BASE visible for setenv.sh. (rjung) +
update + Remove unnecessary variable BASEDIR from scripts. (rjung) +
fix + 51425, 51450: Update Spanish translations. Based + on patches provided by Jesus Marin. (markt) +
+
+
Tomcat 7.0.16 (markt)released 2011-06-17
+
Catalina
+ + + + + + + + + + + +
fix + 51249: Further improve system property replacement code + in ClassLoaderLogManager of Tomcat JULI to cover some corner cases. + (kkolinko) +
fix + 51264: Improve the previous fix for this issue by returning + the connection to the pool when not in use so it does not appear to be + an abandoned connection. Patch provided by Felix Schumacher. (markt) +
fix + 51324: Improve handling of exceptions when flushing the + response buffer to ensure that the doFlush flag does not get stuck in + the enabled state. Patch provided by Jeremy Norris. (markt) +
fix + Correct a regression in the fix for 51278 that prevented any + web application from being marked as distributable. (kfujino/markt) +
fix + Correct a regression in the fix for 51278 that prevented a + web application from overriding the default welcome files. (markt) +
fix + Enable remaining valves for Servlet 3 asynchronous processing support. + (markt) +
fix + Avoid possible NPE when logging requests received during embedded Tomcat + shutdown. (markt) +
fix + 51340: Fix thread-safety issue when parsing multiple web.xml + files in parallel. Apache Tomcat does not do this but products that + embed it may. (markt) +
fix + 51344: Fix problem with Lifecycle re-factoring for deprecated + embedded class that prevented events being triggered. (markt) +
fix + 51348: Prevent possible NPE when processing WebDAV locks. + (markt) +
+
+
Coyote
+ + + +
fix + When parsing the port in the HTTP host header, restrict the value to be + base 10 integer digits rather than hexadecimal ones. + (rjung/markt/kkolinko) +
update + Various refactorings to reduce code duplication and unnecessary code in + the connectors. (markt) +
+
+
Jasper
+ + +
update + Change JAR scanning log messages where no TLDs are found to DEBUG level + and replace the multiple messages with a single INFO level message that + indicates that at least one JAR was scanned needlessly and how to obtain + more info. (markt) +
+
+
Cluster
+ + +
fix + Enable Servlet 3 asynchronous processing support when using clustering. + (markt) +
+
+
Web applications
+ + +
fix + Correct the log4j configuration settings when defining conversion + patterns in the documentation web application. (markt) +
+
+
Tomcat 7.0.15 (markt)not released
+
Catalina
+ + + + + + + + + + + + +
fix + 27122: Remove a workaround for a very old and since fixed + Mozilla bug and change the default value of the securePagesWithPragma + attribute of the Authenticator Valves to false. These changes should + reduce the likelihood of issues when downloading files with IE. (markt) +
fix + 35054: Check that a file is not specified for a Host's + appBase and log an error if it is. (markt) +
fix + 51197: Fix possible dropped connection when sendError or + sendRedirect are used during async processing. (markt) +
fix + 51221: Correct Spanish translation of text used in a 302 + response. Patch provided by Paco Soberón. (markt) +
fix + 51249: Correct ClassLoaderLogManager system property + replacement code so properties of the form "}${...}" can be used + without error. (markt) +
fix + 51264: Allow the JDBC persistent session store to use a + JNDI datasource to define the database in which sessions are persisted. + Patch provided by Felix Schumacher. (markt) +
fix + 51274: Add missing i18n strings in PersistentManagerBase. + Patch provided by Eiji Takahashi. (markt) +
fix + 51276: Provide an abstraction for accessing content in JARs + so the most efficient method can be selected depending on the type of + URL used to identify the JAR. This improves startup time when JARs are + located in $CATALINA_BASE/lib. (markt) +
fix + 51277: Improve error message if an application is deployed + with an incomplete FORM authentication configuration. (markt) +
fix + 51278: Allow ServletContainerInitializers to override + settings in the global default web.xml and the host web.xml. (markt) +
fix + 51310: When stopping the Server object on shutdown call + destroy() after calling stop(). (markt) +
+
+
Coyote
+ + +
add + 51145: Add an AJP-NIO connector. (markt/rjung) +
+
+
Jasper
+ + + + +
add + 51220: Add a system property to enable tag pooling with JSPs + that use a custom base class. Based on a patch by Dan Mikusa. (markt) +
add + Include a comment header in generated java files that indicates when the + file was generated and which version of Tomcat generated it. (markt) +
fix + 51240: Ensure that maxConnections limit is enforced when + multiple acceptor threads are configured. (markt) +
+
+
Cluster
+ + +
fix + 51230: Add missing attributes to JMX for ReplicationValve and + JvmRouteBinderValve. Patch provided by Eiji Takahashi. (markt) +
+
+
Web applications
+ + + + + + + +
add + Add documentation for AJP-NIO connector. (markt/rjung) +
fix + 51182: Document JAAS supported added in 51119. + Patch provided by Neil Laurance. (markt) +
fix + 51225: Fix broken documentation links for non-English locales + in the HTML Manager application. Patch provided by Eiji Takahashi. + (markt) +
fix + 51229: Fix bugs in the Servlet 3.0 asynchronous examples. + Patch provided by Eiji Takahashi. (markt) +
fix + 51251: Add web application version support to the Ant tasks. + Based on a patch provided by Eiji Takahashi. (markt) +
fix + 51294: Clarify behaviour of unpackWAR attribute of + StandardContext components. (markt) +
+
+
Other
+ + + +
fix + 46451: Configure svn:bugtraq properties for Tomcat trunk. + Based on a patch provided by Marc Guillemot. (markt) +
fix + 51309: Correct logic in catalina.sh stop when using a PID + file to ensure the correct message is shown. Patch provided by Caio + Cezar. (markt) +
+
+
Tomcat 7.0.14 (markt)released 2011-05-12
+
Catalina
+ + + + + + + + +
update + Stylistic improvements to MIME type sync script. + Based on a patch provided by Felix Schumacher. (rjung) +
fix + Ensure that the SSLValve provides the SSL key size as an Integer rather + than a String. (markt) +
fix + Ensure that the RemoteIpValve works correctly with Servlet 3.0 + asynchronous requests. (markt) +
fix + Use safe equality test when determining event type in the + MapperListener. (markt) +
fix + Use correct class loader when loading Servlet classes in + StandardWrapper. (markt) +
add + Provide additional configuration options for the RemoteIpValve and + RemoteIpFilter to allow greater control over the values returned by + ServletRequest#getServerPort() and ServletRequest#getLocalPort() when + Tomcat is behind a reverse proxy. (markt) +
fix + Ensure session cookie paths end in / so that session + cookies created for a context with a path of /foo do not + get returned with requests mapped to a context with a path of + /foobar. (markt) +
+
+
Jasper
+ + +
fix + 51177: Ensure Tomcat's MapElResolver always returns + Object.class for getType() as required by the + EL specification. (markt) +
+
+
Tomcat 7.0.13 (markt)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + +
fix + Correct mix-up in Realm Javadoc. (markt) +
fix + Fix display of response headers in AccessLogValve. (kkolinko) +
update + Implement display of multiple request headers in AccessLogValve: + print not just the value of the first header, but of the all of them, + separated by commas. (kkolinko) +
add + 50306: New StuckThreadDetectionValve to detect requests that + take a long time to process, which might indicate that their processing + threads are stuck. Based on a patch provided by TomLu. (slaurent) +
fix + 51038: Ensure that asynchronous requests are included in + access logs. (markt) +
fix + 51042: Don't trigger session creation listeners when a + session ID is changed as part of the authentication process. (markt) +
fix + 51050: Add additional common but non-standard file extension + to MIME type mappings for MPEG 4 files. Based on a patch by Cédrik Lime. + (markt) +
add + Add some additional common JARs that do not contain TLDs or web + fragments to the list of JARs to skip when scanning for TLDs and web + fragments. (markt) +
fix + While scanning JARs for TLDs and fragments, avoid using JarFile and use + JarInputStream as in most circumstances where JARs are scanned, JarFile + will create a temporary copy of the JAR rather than using the resource + directly. This change significantly improves startup performance for + applications with lots of JARs to be scanned. (markt) +
fix + Ensure response is committed when AsyncContext#complete() + is called. (markt) +
add + Add a container event that is fired when a session's ID is changed, + e.g. on authentication. (markt) +
fix + 51099: Correctly implement non-default login configurations + (configured via the loginConfigName attribute) for the SPNEGO + authenticator. (fhanik/markt) +
add + 51119: Add JAAS authentication support to the + JMXRemoteLifecycleListener. Patch provided by Neil Laurance. (markt) +
add + 51136: Provide methods that enable the name of a Context on + Context creation when using Tomcat in an embedded scenario. Based on a + patch provided by David Calavera. (markt) +
fix + 51137: Add additional Microsoft Office MIME type mappings. + (rjung) +
add + Partial sync of MIME type mapping with mime.types from the Apache web + server. About 600 MIME types added, some changed. (rjung) +
fix + Make access logging more robust when logging requests that generate 400 + responses since the request object is unlikely to be fully/correctly + populated in that case. (markt) +
+
+
Coyote
+ + + + + + + + + + + +
fix + 50957: Fix regression in HTTP BIO connector that triggered + errors when processing pipe-lined requests. (markt) +
fix + 50158: Ensure the asynchronous requests never timeout if the + timeout is set to zero or less. Based on a patch provided by Chris. + (markt) +
fix + 51073: Throw an exception and do not start the APR connector + if it is configured for SSL and an invalid value is provided for + SSLProtocol. (markt) +
fix + Align all the connector implementations with the documented default + setting for processorCache of 200. This changes the default from -1 + (unlimited) for the AJP-BIO, AJP-APR and HTTP-APR connectors. Additional + information was also added to the documentation on how to select an + appropriate value. +
fix + Take account of time spent waiting for a processing thread when + calculating connection and keep-alive timeouts for the HTTP BIO + connector. (markt) +
fix + 51095: Don't trigger a NullPointerException when the SSL + handshake fails with the HTTP-APR connector. Patch provided by Mike + Glazer. (markt) +
fix + Improve handling in AJP connectors of the case where too large a AJP + packet is received. (markt) +
fix + Restore the automatic disabling of HTTP keep-alive with the BIO + connector once 75% of the processing threads are in use and make the + threshold configurable. (markt) +
fix + Make pollerSize and maxConnections synonyms for the APR connectors since + they perform the same function. (markt) +
fix + Use maxThreads rather than 10000 as the default maxConnections for the + BIO connectors. (markt) +
+
+
Jasper
+ + + + + + + +
fix + 47371: Correctly coerce the empty string to zero when used as + an operand in EL arithmetic. Patch provided by gbt. (markt) +
add + Label JSP/tag file line and column numbers when reporting errors since + it may not be immediately obvious what the numbers represent. (markt) +
fix + Correct a regression in the fix for 49916 that resulted in + JSPs being compiled twice rather than just once. (markt) +
add + Log JARs that are scanned for TLDs where no TLD is found so that users + can easily identify JARs that can be added to the list of JARs to skip. + (markt) +
update + Use a single TLD location cache for a web application rather than one + per JSP compilation to speed up JSP compilation. (markt) +
add + 51124: Refactor BodyContentImpl to assist in determining the + root cause of this bug. Based on a patch by Ramiro. (markt) +
+
+
Cluster
+ + +
fix + 50950: Correct possible NotSerializableException for an + authenticated session when running with a security manager. (markt) +
+
+
Web applications
+ + + + +
update + Configure Security Manager How-To to include a copy of the actual + conf/catalina.policy file when the documentation is built, rather + than maintaining a copy of its content. (kkolinko) +
fix + Fix broken stylesheet URL in XML based manager status output. (rjung) +
fix + 51156: Ensure session expiration option is available in + Manager application was running web applications that were defined in + server.xml. (markt) +
+
+
Other
+ + + + + + +
update + Clarify error messages in *.sh files to mention that if a script is + not found it might be because execute permission is needed. (kkolinko) +
update + Update Apache Commons Pool to 1.5.6. (markt) +
fix + 51135: Fix auto-detection of JAVA_HOME for 64-bit Windows + platforms that only have a 32-bit JVM installed. (markt) +
fix + 51154: Remove duplicate @deprecated tags in ServletContext + Javadoc. Patch provided by sebb. (markt) +
fix + 51155: Add comments to @deprecated tags that have none. Patch + provided by sebb. (markt) +
+
+
Tomcat 7.0.12 (markt)released 2011-04-06
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + +
add + Automatically correct invalid paths when specified for Context elements + inside server.xml and log a warning that the configuration has been + corrected. (markt) +
fix + Don't unpack WAR files if they are not located in the Host's + appBase. (markt) +
fix + Don't log to standard out in SSLValve. (markt) +
fix + Handle the case where a web crawler provides an invalid session ID in + the CrawlerSessionManagerValve. (markt) +
update + Update pattern used in CrawlerSessionManagerValve to that used by the + ASF infrastructure team. (markt) +
fix + Remove unnecessary whitespace from MIME mapping entries in global + web.xml file. (markt) +
fix + When using parallel deployment, correctly handle the scenario when the + client sends multiple JSESSIONID cookies. (markt) +
add + 12428: Add support (disabled by default) for preemptive + authentication. This can be configured per context. Based on a patch + suggested by Werner Donn. (markt) +
fix + Make the CSRF nonce cache serializable so that it can be replicated + across a cluster and/or persisted across Tomcat restarts. (markt) +
update + Resolve some refactoring TODOs in the implementation of the new Context + attribute "swallowAbortedUploads". (markt) +
fix + Include the seed time when calculating the time taken to create + SecureRandom instances for session ID generation, report excessive times + (greater than 100ms) at INFO level and provide a value for the message + key so a meaningful message appears in the logs. (markt) +
fix + Don't register Contexts that fail to start with the Mapper. (markt) +
add + 48685: Add initial support for SPNEGO/Kerberos authentication + also referred to as integrated Windows authentication. This includes + user authentication, authorisation via the directory using the + user's delegated credentials and exposing the user's delegated + credentials via a request attribute so applications can make use of them + to impersonate the current user when accessing third-party systems that + use a compatible authentication mechanism. Based on a patch provided by + Michael Osipov. (markt) +
fix + HTTP range requests cannot be reliably served when a Writer is in use so + prevent the DefaultServlet from attempting to do so. (kkolinko) +
fix + Protect the DefaultServlet from Valves, Filters and Wrappers that write + content to the response. Prevent partial responses to partial GET + requests in this case since the range cannot be reliably determined. + Also prevent the DefaultServlet from setting a content length header + since this too cannot be reliably determined. (markt) +
fix + 50929: When wrapping an exception, include the root cause. + Patch provided by sebb. (markt) +
fix + 50991: Fix regression in fix for 25060 that called + close on a JNDI resource while it was still available to the + application. (markt) +
add + Provide a configuration option that lets the close method to be used for + a JNDI Resource to be defined by the user. This change also disables + using the close method unless one is explicitly defined for the + resource and limits it to singleton resources. (markt) +
fix + Correctly track changes to context.xml files and trigger redeployment + when copyXML is set to false. (markt) +
fix + 50997: Relax the requirement that directories must have a + name ending in .jar to be treated as an expanded JAR file + by the default JarScanner. Based on patch by Rodion Zhitomirsky. (markt) +
fix + Don't append the jvmRoute to a session ID if the jvmRoute is a zero + length string. (markt) +
fix + Don't register non-singleton DataSource resources with JMX. (markt) +
add + CVE-2011-1184: Provide additional configuration options for the DIGEST + authenticator. (markt) +
fix + Provide a workaround for Tomcat hanging during shutdown when running the + unit tests. (markt) +
+
+
Coyote
+ + + + + +
add + 50887: Add support for configuring the JSSE provider used to + convert client certificates. Based on a patch by pknopp. (markt) +
fix + 50903: When a connector is stopped, ensure that requests that + are currently in a keep-alive state and waiting for client data are not + processed. Requests where processing has started will continue to + completion. (markt) +
fix + 50927: Improve error message when SSLCertificateFile is not + specified when using APR with SSL. Based on a patch provided by sebb. + (markt) +
fix + 50928: Don't ignore keyPass attribute for HTTP BIO and + NIO connectors. Based on a patch provided by sebb. (markt) +
+
+
Cluster
+ + +
fix + Securely seed the SecureRandom instance used for UUID generation and + report excessive creation time (greater than 100ms) at INFO level. + (markt) +
+
+
Web applications
+ + + + + + + + +
fix + 50924: Clean-up HTTP connector comparison table. (markt) +
add + Slightly expanded the documentation of the Host element to clarify the + relationship between host name and DNS name. (markt) +
fix + 50925: Update SSL how-to to take account of + keyPass connector attribute. (markt) +
update + Improve Tomcat Logging documentation. (kkolinko) +
fix + Align the authenticator documentation and MBean descriptors with the + implementation. (markt) +
fix + Prevent the custom error pages for the Manager and Host Manager + applications from being accessed directly. (markt) +
fix + 50984: When using the Manager application ensure that + undeployment fails if a file cannot be deleted. (markt) +
+
+
Other
+ + + + + + +
update + Update Eclipse JDT complier to 3.6.2. (markt) +
update + Update WSDL4J library to 1.6.2 (used by JSR 109 support in the extras + package). (markt) +
update + Update optional CheckStyle library to 5.3. (markt) +
fix + 50911: Reduce noise generated during the build of the Windows + installer so warnings are more obvious. Patch provided by sebb. (markt) +
fix + Further work to reduce compiler and validation warnings across the code + base. (markt) +
+
+
Tomcat 7.0.11 (markt)released 2011-03-11
+
Catalina
+ + + + + + + + + +
fix + CVE-2011-1088: Completed fix. Don't ignore @ServletSecurity + annotations. (markt) +
add + 25060: Close Apache Commons DBCP 1.x datasources when the + associated JNDI naming context is stopped (e.g. for a non-global + DataSource resource on web application reload) to close remaining + database connections immediately rather than waiting for garbage + collection. (markt) +
add + 26701: Provide a mechanism for users to register their own + URLStreamHandlerFactory objects. (markt) +
fix + 50855: Fix NPE on HttpServletRequest.logout() when debug + logging is enabled. (markt) +
add + New context attribute "swallowAbortedUploads" allows + to make request data swallowing configurable for requests + that are too large. (rjung) +
fix + 50854: Add additional permissions required by the Manager + application when running under a security Manager and support a shared + Manager installation when $CATALINA_HOME != CATALINA_BASE. (markt) +
fix + 50893: Add additional information to the download README for + the extras components. (markt) +
fix + Calling stop() and then destroy() on a + connector incorrectly triggered an exception. (markt) +
+
+
Coyote
+ + + +
add + 48208: Allow the configuration of a custom trust manager for + use in CLIENT-CERT authentication. (markt) +
fix + Fix issues that prevented asynchronous servlets from working when used + with the HTTP APR connector on platforms that support TCP_DEFER_ACCEPT. + (markt) +
+
+
Jasper
+ + + +
fix + Correct possible threading issue in JSP compilation when development + mode is used. (markt) +
fix + 50895: Don't initialize classes created during the + compilation stage. (markt) +
+
+
Tomcat 7.0.10 (markt)released 2011-03-08
+
Catalina
+ + + + + + +
fix + CVE-2011-1088: Partial fix. Don't ignore @ServletSecurity + annotations. (markt) +
fix + 27988: Improve reporting of missing files. (markt) +
fix + 28852: Add URL encoding where missing to parameters in URLs + presented by Ant tasks to the Manager application. Based on a patch by + Stephane Bailliez. (markt) +
fix + Improve handling of SSL renegotiation by failing earlier when the + request body contains more bytes than maxSavePostSize. (markt) +
fix + Improve shut down speed by not renewing threads during shut down when + the ThreadLocalLeakPreventionListener is enabled. (markt) +
+
+
Coyote
+ + +
add + 49284: Add SSL re-negotiation support to the HTTP NIO + connector and extend test cases to cover CLIENT-CERT authentication. + (fhanik/markt) +
+
+
Tomcat 7.0.9 (markt)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
add + 19444: Add an option to the JNDI realm to allow role searches + to be performed by the authenticated user. (markt) +
add + 21669: Add the ability to specify the roleBase for the JNDI + Realm as relative to the users DN. Based on a patch by Art W. (markt) +
add + 22405: Add a new Lifecycle listener, + org.apache.catalina.security.SecurityListener that prevents + Tomcat from starting insecurely. It requires that Tomcat is not started + as root and that a umask at least as restrictive as 0007 is used. This + new listener is not enabled by default. + (markt) +
fix + 48863: Better logging when specifying an invalid directory + for a class loader. Based on a patch by Ralf Hauser. (markt/kkolinko) +
fix + 48870: Refactor to remove use of parallel arrays. (markt) +
add + Enhance the RemoteIpFilter and RemoteIpValve so that the modified remote + address, remote host, protocol and server port may be used in an access + log if desired. (markt) +
fix + Restore access to Environments, Resources and ResourceLinks via JMX + which was lost in early 7.0.x re-factoring. (markt) +
update + Remove ServerLifecycleListener. This was already removed from server.xml + and with the Lifecycle re-factoring is no longer required. (markt) +
add + Add additional checks to ensure that sub-classes of + org.apache.catalina.util.LifecycleBase correctly implement + the expected state transitions. (markt) +
fix + 50189: Once the application has finished writing to the + response, prevent further reads from the request since this causes + various problems in the connectors which do not expect this. (markt) +
fix + 50700: Ensure that the override attribute of context + parameters is correctly followed. (markt) +
fix + 50721: Correctly handle URL decoding where the URL ends in + %nn. Patch provided by Christof Marti. (markt) +
add + 50737: Add additional information when an invalid WAR file is + detected. (markt) +
fix + 50748: Allow the content length header to be set up to the + point the response is committed when a writer is being used. (markt) +
fix + 50751: When authenticating with the JNDI Realm, only attempt + to read user attributes from the directory if attributes are required. + (markt) +
fix + 50752: Fix typo in debug message in deprecated Embedded + class. (markt) +
fix + 50789: Provide an option to enable ServletRequestListeners + for forwards as required by some CDI frameworks. (markt) +
fix + 50793: When processing Servlet 3.0 async requests, ensure + that the requestInitialized and requestDestroyed events are only fired + once per request at the correct times. (markt) +
fix + 50802: Ensure that + ServletContext.getResourcePaths() includes static resources + packaged in JAR files in its output. (markt) +
add + Web crawlers can trigger the creation of many thousands of sessions as + they crawl a site which may result in significant memory consumption. + The new Crawler Session Manager Valve ensures that crawlers are + associated with a single session - just like normal users - regardless + of whether or not they provide a session token with their requests. + (markt) +
fix + Don't attempt to start NamingResources for Contexts multiple times. + (markt) +
fix + 50826: Avoid IllegalArgumentException if an + embedded Tomcat instance that includes at least one Context is destroyed + without ever being started. (markt) +
fix + Ensure a web application is taken out of service if the web.xml file is + not valid. (kkolinko/markt) +
fix + Ensure Servlet 2.2 jspFile elements are correctly converted to use a + leading '/' if missing. (markt) +
fix + 50836: Better documentation of the meaning of + Lifecycle.isAvailable() and correct a couple of cases where + this could incorrectly return true. (markt) +
+
+
Coyote
+ + + +
fix + 50780: Fix memory leak in APR implementation of AJP + connector introduced by the refactoring for 49884. (markt) +
fix + If server configuration errors and/or faulty applications caused the + ulimit for open files to be reached, the acceptor threads for all + connectors could enter a tight loop. This loop consumed CPU and also + logged an error message for every iteration of the loop which lead to + large log files being generated. The acceptors have been enhanced to + better handle this situation. (markt) +
+
+
Jasper
+ + + + +
fix + 50720: Ensure that the use of non-ISO-8859-1 character sets + for web.xml does not trigger an error when Jasper parses the web.xml + file. (markt) +
fix + 50726: Ensure that the use of the genStringAsCharArray does + not result in String constants that are too long for valid Java code. + (markt) +
fix + 50790: Improve method resolution in EL expressions. (markt) +
+
+
Cluster
+ + +
fix + 50771: Ensure HttpServletRequest#getAuthType() returns the + name of the authentication scheme if request has already been + authenticated. (kfujino) +
+
+
Web applications
+ + +
fix + 50713: Remove roles command from the Manager application. + (markt) +
+
+
Tribes
+ + +
fix + 50667 (r1068549): Allow RPC callers to get + confirmation when sending a reply. (fhanik) +
+
+
Other
+ + +
fix + 50743: Cache CheckStyle results between builds to speed up + validation. Patch provided by Oliver. (markt) +
+
+
Tomcat 7.0.8 (markt)released 2011-02-05
+
Catalina
+ + + + +
fix + Fix NPE in CoyoteAdapter when postParseRequest() call fails. (kkolinko) +
fix + 50709: Make ApplicationContextFacade non-final to + enable extension. (markt) +
fix + When running under a security manager, user requests may fail with a + security exception. (markt) +
+
+
Coyote
+ + + +
fix + Reduce level of log message for invalid URL parameters from WARNING to + INFO. (markt) +
fix + Fix hanging Servlet 3 asynchronous requests when using the APR based AJP + connector. (markt) +
+
+
Other
+ + +
fix + Align server.xml installed by the Windows installer with the one + bundled in zip/tar.gz files. The differences are LockOutRealm being + used and AccessLogValve being enabled by default. (kkolinko) +
+
+
Tomcat 7.0.7 (markt)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + +
fix + 18462: Don't merge stdout and + stderr internally so users retain the option to treat them + separately. (markt) +
add + 18797: Provide protection against null or zero + length names being provided for users, roles and groups in the + MemoryRealm and UserDatabaseRealm. (markt) +
update + Improve fix for 50205 to trigger an error earlier if invalid + configuration is used. (markt) +
add + Provide additional control over component class loaders, primarily for + use when embedding. (markt) +
fix + Fix NPE in RemoteAddrFilter, RemoteHostFilter. (kkolinko) +
fix + 49711: HttpServletRequest#getParts will work in a filter + or servlet without an @MultipartConfig annotation or + MultipartConfigElement if the new "allowCasualMultipartParsing" + context attribute is set to "true". (schultz) +
fix + 49978: Correct another instance where deployment incorrectly + failed if a directory in the work area already existed. (markt) +
fix + 50582: Refactor access logging so chunked encoding is not + forced for all requests if bytes sent is logged. (markt) +
fix + 50597: Don't instantiate a new instance of a Filter if + an instance was provided via the + ServletContext.addFilter(String, Filter) method. Patch + provided by Ismael Juma. (markt) +
fix + 50598: Correct URL for Manager text interface. (markt) +
fix + 50620: Stop exceptions that occur during + Session.endAccess() from preventing the normal completion + of Request.recycle(). (markt) +
fix + 50629: Make StandardContext.bindThread() and + StandardContext.unbindThread() protected to allow use by + sub-classes. (markt) +
update + Use getName() instead of logName() in error messages in StandardContext. + (kkolinko) +
fix + 50642: Move the sun.net.www.http.HttpClient + keep-alive thread memory leak protection from the + JreMemoryLeakPreventionListener to the WebappClassLoader since the + thread that triggers the memory leak is created on demand. (markt) +
fix + 50673: Improve Catalina shutdown when running as a service. + Do not call System.exit(). (kkolinko) +
fix + 50683: Ensure annotations are scanned when + unpackWARs is set to false in the Host + where a web application is deployed. (markt) +
fix + Improve HTTP specification compliance in support of + Accept-Language header. This protects from known exploit + of the Oracle JVM bug that triggers a DoS, CVE-2010-4476. (kkolinko) +
+
+
Coyote
+ + + + + + + + + +
fix + Prevent possible thread exhaustion if a Comet timeout event takes a + while to complete. (markt) +
fix + Prevent multiple Comet END events if the CometServlet calls + event.close() during an END event. (markt) +
fix + 50325: When the JVM indicates support for RFC 5746, disable + Tomcat's allowUnsafeLegacyRenegotiation configuration + attribute and use the JVM configuration to control renegotiation. + (markt) +
fix + 50405: Fix occasional NPE when using NIO connector and + Comet. (markt) +
fix + Ensure correct recycling of NIO input filters when processing Comet + events. (markt) +
fix + 50627: Correct interaction of NIO socket and Poller when + processing Comet events. (markt) +
fix + Correct interaction of APR socket and Poller when processing Comet + events. (markt) +
fix + 50631: InternalNioInputBuffer should honor + maxHttpHeadSize. (kkolinko) +
+
+
Jasper
+ + + + + + +
fix + Improve special case handling of + javax.servlet.jsp.el.ScopedAttributeELResolver in + javax.el.CompositeELResolver to handle sub-classes. (markt) +
update + 15688: Use fully-qualified class names in generated jsp files + to avoid naming conflicts with user imports. (markt) +
fix + 46819: Remove redundant object instantiations in + JspRuntimeLibrary. Patch provided by Anthony Whitford. (markt) +
update + Improve error message when EL identifiers are not valid Java identifiers + and use i18n for the error message. (markt) +
fix + 50680: Prevent an NPE when using tag files from an exploded + JAR file, e.g. from within an IDE. Patch provided by Larry Isaacs. + (markt) +
+
+
Cluster
+ + + + + + + + +
fix + 50591: Fix NPE in ReplicationValve. (kkolinko) +
add + Internationalise the log messages for the FarmWarDeployer. (markt) +
fix + 50600: Prevent a ConcurrentModificationException + when removing a WAR file via the FarmWarDeployer. (markt) +
fix + Be consistent with locks on sessionCreationTiming, + sessionExpirationTiming in DeltaManager.resetStatistics(). (kkolinko) +
fix + 50648: Correctly set the interrupt status if a thread using + RpcChannel is interrupted waiting for a message reply. + Based on a patch by Olivier Costet. (markt) +
fix + 50646: Ensure larger Tribes messages are fully read. Patch + provided by Olivier Costet. (markt) +
fix + 50679: Update the FarmWarDeployer to support parallel + deployment. (markt) +
+
+
Web applications
+ + + + + + + + +
fix + 22278: Add a commented out RemoteAddrValve that + limits access to the Manager and Host Manager applications to localhost. + Based on a patch by Yann Cébron. (markt) +
fix + Correct a handful of Javadoc warnings. (markt) +
add + Provide additional detail about how web application version order is + determined when using parallel deployment. (markt) +
fix + Correct the documentation for the recoveryCount count attribute of the + the default cluster membership. (markt) +
fix + 50441: Clarify when it is valid to set the docBase attribute + in a Context element. (markt) +
fix + 50526: Provide additional documentation on configuring + JavaMail resources. (markt) +
fix + 50599: Use correct names of roles required to access the + Manager application. (markt) +
+
+
Other
+ + + + + + +
add + Extend the Checkstyle tests to check for license headers. (markt) +
fix + Modify the build script so a release build always rebuilds the + dependencies to ensure that the correct Tomcat version appears in the + manifest. (markt) +
fix + Code clean-up to remove unused code and reduce IDE warnings. (markt) +
fix + 50601: Code clean-up. Patch provided by sebb. (markt) +
fix + 50606: Improve CGIServlet: Provide support for specifying + empty value for the executable init-param. Provide support + for explicit additional arguments for the executable. Those were + broken when implementing fix for bug 49657. (kkolinko) +
+
+
Tomcat 7.0.6 (markt)released 2011-01-14
+
General
+ + +
update + Update to Apache Commons Daemon 1.0.5. (mturk) +
+
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 8705: org.apache.catalina.SessionListener now + extends java.util.EventListener. (markt) +
add + 10526: Add an option to the Authenticators to + force the creation of a session on authentication which may offer some + performance benefits. (markt) +
update + 10972: Improve error message if the className attribute is + missing on an element in server.xml where it is required. (markt) +
update + 48692: Provide option to parse + application/x-www-form-urlencoded PUT requests. (schultz) +
update + 48822: Include context name in case of error while stopping + or starting a context during its reload. Patch provided by Marc + Guillemot. (slaurent) +
add + 48837: Extend thread local memory leak detection to include + classes loaded by subordinate class loaders to the web + application's class loader such as the Jasper class loader. Based + on a patch by Sylvain Laurent. (markt) +
add + 48973: Avoid creating a SESSIONS.ser file when stopping an + application if there's no session. Patch provided by Marc Guillemot. + (slaurent) +
fix + 49000: No longer accept specification invalid name only + cookies by default. This behaviour can be restored using a system + property. (markt) +
add + 49159: Improve memory leak protection by renewing threads of + the pool when a web application is stopped. (slaurent) +
fix + 49372: Re-fix after connector re-factoring. If connector + initialisation fails (e.g. if a port is already in use) do not trigger + an LifecycleException for an invalid state transition. + (markt) +
fix + 49543: Allow Tomcat to use shared data sources with per + application credentials. (fhanik) +
fix + 49650: Remove unnecessary entries package.access property + defined in catalina.properties. Patch provided by Owen Farrell. (markt) +
fix + 50106: Correct several MBean descriptors. Patch provided by + Eiji Takahashi. (markt) +
update + Further performance improvements to session ID generation. Remove legacy + configuration options that are no longer required. Provide additional + options to control the SecureRandom instances used to + generate session IDs. (markt) +
fix + 50201: Update the access log reference in + StandardEngine when the ROOT web application is redeployed, + started, stopped or defaultHost is changed. (markt/kkolinko) +
add + 50282: Load + javax.security.auth.login.Configuration with + JreMemoryLeakPreventionListener to avoid memory leak when + stopping a web application that would use JAAS. (slaurent) +
fix + 50351: Fix the regression that broke BeanFactory resources + caused by the previous fix for 50159. (markt) +
fix + 50352: Ensure that AsyncListener.onComplete() is + fired when AsyncContext.complete() is called. (markt) +
fix + 50358: Set the correct LifecycleState when stopping instances + of the deprecated Embedded class. (markt) +
fix + Further Lifecycle refactoring for Connectors and associated components. + (markt) +
fix + Correct handling of versioned web applications in deployer. (markt) +
fix + Correct removal of LifeCycleListeners from + Containers via JMX. (markt) +
fix + Don't use nulls to construct log messages. (markt) +
fix + Code clean-up. Replace use of inefficient constructors with more + efficient alternatives. (markt) +
fix + 50411: Ensure sessions are removed from the + Store associated with a PersistentManager. + (markt) +
fix + 50413: Ensure 304 responses are not returned when using + static files as error pages. (markt/kkolinko) +
fix + 50448: Fix possible IllegalStateException + caused by recent session management refactoring. (markt) +
fix + Ensure aliases settings for a context are retained after a context is + reloaded. (markt) +
fix + Log a warning if context.xml files define values for properties that do + not exist (e.g. if there is a typo in a property name). (markt) +
fix + 50453: Correctly handle multiple X-Forwarded-For + headers in the RemoteIpFilter and RemoteIpValve. Patch provided by Jim + Riggs. (markt) +
add + 50541: Add support for setting the size limit and time limit + for LDAP searches when using the JNDI Realm with userSearch. + (markt) +
update + All configuration options that use regular expression now require a + single regular expression (using java.util.regex) rather + than a list of comma-separated or semi-colon-separated expressions. + (markt) +
fix + 50496: Bytes sent in the access log are now counted after + compression, chunking etc rather than before. (markt) +
fix + 50550: When a new directory is created (e.g. via WebDAV) + ensure that a subsequent request for that directory does not result in a + 404 response. (markt) +
fix + 50554: Code clean up. (markt) +
add + 50556: Improve JreMemoryLeakPreventionListener to prevent + a potential class loader leak caused by a thread spawned when the class + com.sun.jndi.ldap.LdapPoolManager is initialized and the + system property com.sun.jndi.ldap.connect.pool.timeout is + set to a value greater than 0. (slaurent) +
+
+
Coyote
+ + + + + + +
fix + 47319: Return the client's IP address rather than null + for calls to getRemoteHost() when the APR connector is + used with enableLookups="true" but the IP address + is not resolveable. (markt) +
add + 50108: Add get/set methods for Connector property + minSpareThreads. Patch provided by Eiji Takahashi. (markt) +
fix + 50360: Provide an option to control when the socket + associated with a connector is bound. By default, the socket is bound on + Connector.init() and released on + Connector.destroy() as per the current behaviour but this + can be changed so that the socket is bound on + Connector.start() and released on + Connector.stop(). This fix also includes further Lifecycle + refactoring for Connectors and associated components. (markt) +
fix + Remove a huge memory leak in the NIO connector introduced by the fix + for 49884. (markt) +
fix + 50467: Protected against NPE triggered by a race condition + that causes the NIO poller to fail, preventing the processing of further + requests. (markt) +
+
+
Jasper
+ + + + + +
add + 13731: Make variables in _jspService() method + final where possible. (markt) +
fix + 50408: Fix NoSuchMethodException when using + scoped variables with EL method invocation. (markt) +
fix + 50460: Avoid a memory leak caused by using a cached exception + instance in JspDocumentParser and + ProxyDirContext. (kkolinko) +
fix + 50500: Use correct coercions (as per the EL spec) for + arithmetic operations involving string values containing '.', + 'e' or 'E'. Based on a patch by Brian Weisleder. + (markt) +
+
+
Cluster
+ + + + + +
add + 50185: Add additional trace level logging to Tribes to assist + with fault diagnosis. Based on a patch by Ariel. (markt) +
fix + Don't try and obtain session data from the cluster if the current + node is the only node in the cluster. Log requesting session data as + INFO rather than WARNING. (markt) +
fix + 50503: When web application has a version, Engine level + Clustering works correctly. (kfujino) +
fix + 50547: Add time stamp for CHANGE_SESSION_ID message and + SESSION_EXPIRED message. (kfujino) +
+
+
Web applications
+ + + + + + + +
fix + 21157: Ensure cookies are written before the response is + committed in the Cookie example. Patch provided by Stefan Radzom. (markt) +
add + 50294: Add more information to documentation regarding format + of configuration files. Patch provided by Luke Meyer. (markt) +
fix + Correctly validate provided context path so sessions for the ROOT web + application can be viewed through the HTML Manager. (markt) +
update + Improve documentation of database connection factory. (rjung) +
fix + 50488: Update classpath required when using jsvc and add a + note regarding server VMs. (markt) +
fix + Further filtering of Manager display output. (kkolinko) +
+
+
Other
+ + + + + +
fix + Don't configure Windows installer to use PID file since it is not + removed when the service stops which prevents the service from starting. + (markt) +
fix + 14416: Make TagLibraryInfo.getTag() more robust + at handling nulls. (markt) +
fix + 50552: Avoid NPE that hides error message when using Ant + tasks. (schultz) +
add + Provide two alternative locations for the libraries downloaded from + the ASF web site at build time. Use the main distribution site as + default and the archive one as fallback. (kkolinko) +
+
+
Tomcat 7.0.5 (markt)beta, 2010-12-01
+
General
+ + +
update + Update to Apache Commons Daemon 1.0.4. (mturk) +
+
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + +
fix + 3839: Provide a mechanism to gracefully handle the case where + users book-mark the form login page or otherwise misuse the FORM + authentication process. Based on a suggestion by Mark Morris. (markt) +
fix + 49180: Add option to disable log rotation in + juli FileHandler. Patch provided by Pid (pidster at apache). (funkman) +
fix + 49991: Ensure servlet request listeners are fired for + the login and error pages during FORM authentication. (markt) +
fix + 50107: When removing a Host via JMX, do not attempt to + destroy the host's pipeline twice. Patch provided by Eiji + Takahashi. (markt) +
fix + 50138: Fix threading issues in + org.apache.catalina.security.SecurityUtil. (markt) +
fix + 50157: Ensure MapperListener is only added to a container + object once. (markt) +
fix + 50159: Add a new attribute for <Resource> + elements, singleton, that controls whether or not a new + object is created every time a JNDI lookup is performed to obtain the + resource. The default value is true, which will return the + same instance of the resource in every JNDI lookup. (markt) +
fix + 50168: Separate the Lifecycle.DESTROY_EVENT into + Lifecycle.BEFORE_DESTROY_EVENT and + Lifecycle.AFTER_DESTROY_EVENT. Use the additional state to + ensure that Context objects are only destroyed once. + (markt) +
fix + 50169: Ensure that when a Container is started that it + doesn't try and register with the mapper unless its parent has + already started. Patch provided by Eiji Takahashi. (markt) +
add + 50222: Modify memory leak prevention code so it pins the + system class loader in memory rather than the common class loader, + which is better for embedded systems. Patch provided by Christopher + Schultz. (markt) +
add + Improve debug logging for MapperListener registration. (markt) +
add + Expose names of LifecycleListeners and ContainerListeners for + StandardContext via JMX. (markt) +
add + Add a new option, resourceOnlyServlets, to Context elements + that provides a mechanism for working around the issues caused by new + requirements for welcome file mapping introduced in Servlet 3.0. By + default, the existing Tomcat 6.0.x welcome file handling is used. + (markt) +
fix + Make Tomcat more tolerant of null when generating JMX names + for Valves. (markt) +
fix + Make AccessLogValve attribute enabled changeable via JMX. + (pero) +
fix + Correct infinite loop if ServletRequest.startAsync(ServletRequest, + ServletResponse) was called. (markt) +
fix + 50232: Remove dependency between StoreBase and + PersistentManager and associated code clean-up. Patch provided by + Tiago Batista. (markt) +
fix + 50252: Prevent ClassCastException when using a + <ResourceLink>. Patch provided by Eiji Takahashi. (markt) +
add + Reduce synchronization in session managers to improve performance of + session creation. (markt) +
fix + If starting children automatically when adding them to a container (e.g. + when adding a Context to a Host) don't lock the parent's set + of children whilst the new child is being started since this can block + other threads and cause issues such as lost cluster messages. (markt) +
add + Implement support for parallel deployment. This allows multiple versions + of the same web application to be deployed to the same context path at + the same time. Users without a current session will be mapped to the + latest version of the web application. Users with a current session will + continue to use the version of the web application with which the + session is associated until the session expires. (markt) +
fix + 50308: Allow asynchronous request processing to call + AsyncContext.dispatch() once the asynchronous request has + timed out. (markt) +
add + Make memory leak prevention code that clears ThreadLocal instances more + robust against objects with toString() methods that throw exceptions. + (markt) +
+
+
Coyote
+ + + + +
fix + 49860: Complete support for handling trailing headers in + chunked HTTP requests. (markt) +
add + Impose a limit on the length of the trailing headers. The limit + is configurable with a system property and is 8192 + by default. (kkolinko) +
fix + 50207: Ensure Comet timeout events are triggered. This bug + was a regression triggered by the fix for 49884. (markt) +
+
+
Jasper
+ + + + + + + + + + +
fix + 49297: Enforce the rules in the JSP specification for parsing + the attributes of custom and standard actions that require that + the attribute names are unique within an element and that there is + whitespace before the attribute name. The whitespace test can be + disabled by setting the system property + org.apache.jasper.compiler.Parser.STRICT_WHITESPACE to + false. Attributes of the page directive have slightly + different rules. The implementation of that part of the fix is based on + a patch by genspring. (markt) +
fix + 50105: When processing composite EL expressions use + Enum.name() rather than Enum.toString() as + required by the EL specification. (markt) +
fix + Fix minor thread-safety and performance issues in the implementation + of maxLoadedJsps. (rjung) +
add + Add support for unloading JSPs that have not been requested for a + long time using the new parameter jspIdleTimeout. (rjung) +
add + Add logging and JMX support to JSP unloading. (rjung) +
fix + 50192: Improve performance for EL when running under a + security manager. Based on a patch by Robert Goff. (markt) +
fix + 50228: Improve recycling of BodyContentImpl. + This avoids keeping a cached reference to a webapp-provided Writer + used in JspFragment.invoke() calls. (kkolinko) +
add + 50273: Provide a workaround for an HP-UX issue that can + result in large numbers of SEVERE log messages appearing in the logs as + a result of normal operation. (markt) +
fix + 50293: Increase the size of internal ELResolver array from 2 + to 8 since in typical usage there are at least 5 resolvers. Based on a + patch by Robert Goff. (markt) +
+
+
Cluster
+ + + + + + +
fix + Add support for maxActiveSessions attribute to BackupManager. (kfujino) +
fix + Improve sending an access message in DeltaManager. + maxInactiveInterval of not Manager but the session is used. + If maxInactiveInterval is negative, an access message is not sending. + (kfujino) +
fix + 50183: BIO sender was not scheduling tasks to the executor + during normal operation. Patch provided by Ariel. (markt) +
fix + 50184: Add an option to the RpcChannel to enable the Channel + send options to be set for the reply message. Based on a patch by Ariel. + (markt) +
fix + Ensure that a new Context waiting for session data from other nodes in + the cluster does not block the processing of clustering messages for + other Contexts. (markt) +
+
+
Web applications
+ + + + + + + + + + + + + + + + +
fix + 49426: Localize messages in the Manager application based on + the Locale of the user rather than the default Locale of the server. + (markt) +
fix + Localize messages in the Host Manager application based on the Locale of + the user rather than the default Locale of the server. (markt) +
add + 50242: Provide a sample log4j configuration that more + closely matches the default JULI configuration. Patch provided by + Christopher Schultz. (markt) +
add + Restore the ability to edit the contents of /WEB-INF and /META-INF via + WebDAV via the provision of a new configuration option, + allowSpecialPaths. (markt) +
fix + Correct broken links for on-line JavaDocs. (markt) +
fix + 50230: Add new DistributedManager interface that is + implemented by the Backup Manager to remove circular dependency between + tomcat-catalina-ha and tomcat-catalina modules. Also allows third-party + distributed Manager implementations to report full session information + through the HTML Manager. (markt) +
update + Improve Tomcat Logging documentation. (kkolinko) +
fix + 50303: Update JNDI how-to to reflect the new JavaMail + download location and that JAF is now included in Java SE 6. (markt) +
fix + Fix ordering functionality on sessions page for the HTML Manager + application. (markt) +
fix + Fix primary sessions not always being treated as such in the HTML + Manager application. (markt) +
fix + Fix message not being displayed after session attribute removal in the + HTML Manager application. (markt) +
fix + 50310: Fix display of Servlet information in the Manager + application. (markt) +
fix + CVE-2010-4172: Multiple XSS in the Manager application. (markt/kkolinko) +
fix + 50316: Fix display of negative values in the Manager + application. (kkolinko) +
fix + 50318: Avoid NPE when trying to view session detail for an + expired session in the Manager application. (markt) +
+
+
Other
+ + + + + + + + + + + + + +
fix + Correct a handful of Javadoc warnings. (markt) +
fix + 22965: Fix some typos and formatting issues in the global + web.xml file. Based on a patch by Yann Cébron. (markt) +
add + Extend Checkstyle validation checks to check for unused imports. (markt) +
fix + General code clean-up to reduce (not eliminate) the number of warnings + reported by IDEs. (markt) +
fix + 50140: Don't ignore a user specified installation + directory when performing a silent install with the Windows installer on + 64-bit platforms. (markt) +
update + Reimplemented Windows installer dialogs, using modern libraries + (nsDialogs, MUI2). (kkolinko) +
add + When installing with the Windows installer on 64-bit platforms, allow + the user to select either a 32-bit JDK or a 64-bit JDK. If a 32-bit JDK + is selected, the 32-bit service wrapper and the 32-bit native DLL will + be installed. If a 64-bit JDK is selected, the 64-bit service wrapper + and the 64-bit native DLL will be installed. (markt/kkolinko) +
add + Create Windows shortcuts for the Manager and Host Manager webapps. + (kkolinko) +
add + Support /? command line option in the Windows Installer. (kkolinko) +
add + Display and allow to change roles for the Tomcat admin user in the + Windows installer. (kkolinko) +
fix + In the Windows installer: do not leave stale server.xml + and tomcat-users.xml fragments in the $TEMP folder. + (kkolinko) +
update + 49819: Redesign of home page by Pid (pidster at apache). + (timw) +
+
+
Tomcat 7.0.4 (markt)beta, 2010-10-21
+
Catalina
+ + + + + + + + + + + + + + + + + + + + +
fix + 49428: Re-implement the fix for bug 49428 – + namespace issues for some Microsoft WebDAV clients. (kkolinko) +
fix + 49669: Fix memory leak triggered by using the deprecated + javax.security.auth.Policy class. (markt) +
fix + 49922: Don't add filter twice to filter chain if the + filter matches more than one URL pattern and/or Servlet name. Patch + provided by heyoulin. (markt) +
fix + 49937: Use an InstanceManager when creating an AsyncListener + through the AsyncContext to ensure annotations are processed. Based on a + patch by David Jencks. (markt) +
fix + To avoid NoSuchMethodException, xmlValidation and xmlNamespaceAware are + removed from the createStandardHost definition + of mbeans-descriptors.xml. (kfujino) +
fix + 49945: Continue improvements to JMX. Fix a handful of + attributes that were showing as Unavailable in JConsole. Patch provided + by Chamith Buddhika. (markt) +
fix + 49952: Allow ServletContainerInitializers to add listeners to + a web application. Patch provided by David Jencks. (markt) +
fix + 49956: Handle case when @Resource annotation uses the full + JNDI name for a resource. Based on a patch by Gurkan Erdogdu. (markt) +
fix + 49557: Correct regression due to Lifecycle refactoring that + cleared all work directories (with compiled JSPs and persisted sessions) + when Tomcat was stopped. (markt) +
fix + 49978: Correctly handle the case when a directory expected + to be created during web application start is already present. Rather + than throwing an exception and failing to start, allow the web + application to start normally. (markt) +
fix + 49987: Fix thread safety issue with population of servlet + context initialization parameters. (markt) +
fix + 49994: As per the Java EE 6 specification, return a new + object instance for each JNDI look up of a resource reference. (markt) +
fix + 50015: Re-factor dynamic servlet security implementation to + make extensions, such as JACC implementations, simpler. Patch provided + by David Jencks. (markt) +
fix + 50016: Re-factor isUserInRole() and + login()/logout() methods to support JACC implementations + and to improve encapsulation. Patch provided by David Jencks. (markt) +
update + 50017: Code clean-up. No functional change. Patch provided by + sebb. (markt) +
fix + 50027: Avoid NPE on start when a Context is defined in + server.xml with one or more JNDI resources. (markt) +
fix + 50059: JARs should always be searched for static resources + even if the web application is marked as meta-data complete. (markt) +
fix + 50063: Correct regression in fix for 50059 that + causes applications marked as meta-data complete to return 404s for all + requests. Patch provided by heyoulin. (markt) +
fix + 50087: Catch ClassFormatErrors when scanning for annotations. + (markt) +
+
+
Coyote
+ + + + + + + +
fix + 49923: Avoid using negative timeouts during acceptor unlock + to ensure APR connector shuts down properly. (mturk) +
fix + 49972: Fix potential thread safe issue when formatting dates + for use in HTTP headers. (markt) +
fix + 50003: Set not maxThreads but minSpareThreads to + corePoolSize, if AbstractEndpoint.setMinSpareThreads is called. + (kfujino) +
fix + 50044: Fix issue when using comet where socket remained in + long poll after the comet request has ended. (markt) +
fix + 50054: Correctly handle the setting of minSpareThreads in + AJP connector. (kfujino) +
fix + 50072: Fix issues when using a non-blocking read for the + request line with the NIO connector that could result in the request + line being mis-read. (markt) +
+
+
Jasper
+ + + + + + + + +
fix + 49986: Fix thread safety issue for JSP reload. (timw) +
fix + 49998: Make jsp:root detection work with single quoted + attributes as well. (timw) +
fix + Correctly handle the setting of primitive bean values via expression + language. (markt) +
fix + Don't swallow exceptions when processing TLD files and handle the + case when there is no web.xml file. (markt) +
fix + 50066: Fix building of recursive tag files when the file + depends on a JAR file. Patch provided by Sylvain Laurent. (markt) +
fix + 50078: Fix threading problem in EL caches. Patch provided by + Takayoshi Kimura. (markt) +
add + Make EL cache sizes configurable. (markt) +
+
+
Web applications
+ + +
fix + Apply filters to default home page so copyright year is correctly + displayed. (markt) +
+
+
Other
+ + + +
update + 48716: Do not call reset if the default LogManager is in use. + (markt) +
fix + 50013: Correctly package classes from + org.apache.tomcat.util.file and add the tomcat-util.jar to + the class path for the Ant tasks. Based on a patch provided by + Sylvain Laurent. (markt) +
+
+
Tomcat 7.0.3 (markt)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + 48644: Review all instances of catching Throwable and + re-throw where appropriate. (markt) +
update + Allow glob patterns in the jarsToSkip configuration and add + some debug logging to the jar scanner. (rjung) +
fix + 48738: Workaround a couple of long standing JDK bugs to + enable GZIP compressed output streams to be flushed. Based on a patch + provided by Jiong Wang. (markt) +
update + 48967: Replace strings "catalina.base" and "catalina.home" + by globally defined constants. Patch provided by Marc Guillemot. (rjung) +
fix + 49195: Don't report an error when shutting down a Windows + service for a Tomcat instance that has a disabled shutdown port. (markt) +
fix + 49209: Prevent possible AccessControlException during + undeployment when running with a security manager. Patch provided by + Sylvain Laurent. (markt) +
fix + 49657: Handle CGI executables with spaces in the path. + (markt) +
fix + 49667: Ensure that using the JDBC driver memory leak + prevention code does not cause a one of the memory leaks it is meant to + avoid. (markt) +
fix + 49670: Restore SSO functionality that was broken by Lifecycle + refactoring. (markt) +
fix + 49698: Allow a listener to complete an asynchronous request + if it times out. (markt) +
fix + 49714: The annotation process of Jar doesn't influence + distributable element of web.xml. (kfujino) +
fix + 49721: Alls JAR in a web application should be searched for + resources, not just those with a web-fragment.xml that is going to be + processed. (markt) +
fix + 49728: Improve PID file handling when another process is + managing the PID file and Tomcat does not have write access. (markt) +
fix + 49730: Fix a race condition in StandardThreadExector that can + cause requests to experience large delays. Patch provided by Sylvain + Laurent. (markt) +
fix + 49749: Single sign on cookies should have httpOnly flag set + using same rules as session cookies. (markt) +
fix + 49750: Align WebappClassLoader.validate() + implementation with Javadoc and ensure that javax.servlet.* + classes can not be loaded by a WebappClassLoader instance. + Patch provided by pid. (markt) +
fix + 49757: Correct some generics warnings. Based on a patch + provided by Gábor. (markt) +
fix + 49779: Improve handling of POST requests and FORM + authentication, particularly when the user agent responds to the 302 + response by repeating the POST request including a request body. Any + request body provided at this point is now swallowed. (markt) +
fix + CSRF prevention filter did not correctly handle URLs that used anchors. + (markt) +
fix + Fix memory leak on web application stopped caused by failed to + de-register the web application's Servlets with the MBean server. + (markt) +
update + More tweaks to the Lifecycle refactoring to ensure that when a component + is being destroyed, the destroy method is only called once on each + child component. (markt) +
fix + Keep the MBean names for web applications consistent between Tomcat 6 + and Tomcat 7. (markt) +
fix + 49856: Add an executorName attribute to Connectors so it is + possible to trace ThreadPool to Connector to Executor via the JMX + interface. (markt) +
fix + 49865: Tomcat failed to start if catalina.properties was not + present. (markt) +
fix + 49876: Fix the generics warnings in the copied Apache Jakarta + BCEL code. Based on a patch by Gábor. (markt) +
fix + 49883: Ensure that the CombinedRealm and LockOutRealm return + a name for use in log messages rather than throwing an + UnsupportedOperationException. (markt) +
fix + 49884: Fix occasional NullPointerException on async + complete(). This resulted in a major refactoring of the async + implementation to address a number of threading issues. (markt) +
fix + Update the version numbers in ServerInfo defaults to Tomcat 7.0.x. + (markt) +
fix + 49892: Correct JNDI name for method resource injections. + Based on a patch by Gurkan Erdogdu. (markt) +
fix + Ensure that Context elements defined in server.xml use any configClass + setting specified in the parent Host element. (markt) +
fix + GSOC 2010. Enable the creation of Services, Engines, Connectors, Hosts + and Contexts via JMX from a minimal server.xml that contains only a + Server element. Based on a patch by Chamith Buddhika. (markt) +
fix + 49909: Fix a regression introduced with the fix for + 47950 that prevented JSTL classes being loaded. (markt) +
fix + 49915: Make error more obvious, particularly when accessed + via JConsole, if StandardServer.storeConfig() is called when there is + no StoreConfig implementation present. (markt) +
fix + 50018: Fix some minor Javadoc errors in Jasper source. + Based on a patch by sebb. (timw) +
fix + 50021: Correct a regression in the fix for 46844 + that may have caused additional problems during a failure at start up. + (markt) +
fix + 50026: Prevent serving of resources from WEB-INF and + META-INF directories when DefaultServlet or WebdavServlet is mapped + to a sub-path of the context. This changes DefaultServlet to always + serve resources with paths relative to the root of the context + regardless of where it is mapped, which is a breaking change for + current servlet-mappings that map the default servlet to a subpath. + (timw) +
fix + 50689: Provide 100 Continue responses at appropriate points + during FORM authentication if client indicates that they are expected. + (markt) +
+
+
Coyote
+ + + + + + + + + + + +
update + Wait for the connectors to exit before closing them down. (mturk) +
add + Follow up to 48545. Make JSSE connectors more tolerant of a + incorrect trust store password. (markt) +
fix + Fix some edge cases in the NIO connector when handling requests that are + not received all at the same time and the socket needs to be returned to + the poller. (markt) +
update + Further work to reduce the code duplication in the HTTP connectors. + (markt) +
fix + Make sure acceptor threads are stopped when the connector is stopped. + (markt) +
fix + Make sure async timeout thread is stopped when the connector is stopped. + (markt) +
fix + 49625: Ensure Vary header is set if response may be + compressed rather than only setting it if it is compressed. (markt) +
fix + 49802: Re-factor connector pause, stop and destroy methods so + that calling any of those methods has the expected results. (markt) +
update + Various refactorings to reduce code duplication and unnecessary code in + the connectors. (markt) +
fix + 49860: Add partial support for trailing headers in chunked + HTTP requests. (markt) +
+
+
Jasper
+ + + + + + +
fix + 49665: Provide better information including JSP file name and + location when a missing file is detected during TLD handling. Patch + provided by Ted Leung. (markt) +
fix + 49726: Specifying a default content type via a JSP property + group should not prevent a page from setting some other content type. + (markt) +
fix + 49799: The new omit attribute for + jsp:attribute elements now supports the use of expressions + and expression language. (markt) +
fix + 49916: Switch to using an initialisation parameter to pass + JSP file information from Catalina to Jasper. This simplifies the + Catalina code as well as making it easier for Geronimo and others to + integrate Jasper. Patch provided by David Jencks. (markt) +
fix + 49985: Fix thread safety issue in EL parser. (markt) +
+
+
Cluster
+ + + + + + + +
fix + Remove domainReplication attribute from ClusterManager. + If you send session to only same domain, use DomainFilterInterceptor. + (kfujino) +
fix + Add Null check when CHANGE_SESSION_ID message received. (kfujino) +
fix + Add support for LAST_ACCESS_AT_START system property to DeltaSession. + (kfujino) +
fix + Avoid a NPE in the DeltaManager when a parallel request invalidates the + session before the current request has a chance to send the replication + message. (markt) +
fix + 49905: Prevent memory leak when using asynchronous session + replication. (markt) +
fix + 49924: When non-primary node changes into a primary node, + make sure isPrimarySession is changed to true. (kfujino) +
+
+
Web applications
+ + + + + +
fix + Correct the class name of the default JAR scanner in the documentation + web application. (rjung) +
fix + 49585: Update JSVC documentation to reflect new packaging + of Commons Daemon. (markt) +
update + Update the Servlet, JSP and EL Javadoc links to link to the + specifications and the relevant part of the Java EE 6 Javadoc. (markt) +
fix + Update a few places in the docs where the Manager documentation referred + to the old role name of manager rather than the new manager-script. + (markt) +
+
+
Extras
+ + +
fix + 49861: Don't log RMI ports formatted with commas for the + JMX remote listener. (markt) +
+
+
Other
+ + + + + + + + +
fix + Correct the user names created by the Windows installer for the Manager + and Host Manager applications. (mturk) +
fix + Correct the Eclipse compiler dependency in the Jasper POM. (markt) +
add + Extend Checkstyle validation checks to check import order. (markt) +
fix + 49758: Fix generics warnings exposed by a fix in Eclipse 3.6. + Patch provided by sebb. (markt) +
update + Update Apache Commons Pool to 1.5.5. (markt) +
update + 49955: Improvement and correction of Building Tomcat guide. + Based on a patch from Wesley Acheson. (timw) +
update + 49993: Improve check for JAVA_HOME and add + support for JRE_HOME in service.bat. (mturk) +
+
+
Tomcat 7.0.2 (markt)beta, 2010-08-11
+
Catalina
+ + +
fix + Fix regression that prevented running with a security manager enabled. + (markt) +
+
+
Web applications
+ + + + +
fix + Correct Javadoc errors. (markt) +
add + Provide Javadoc for Servlet 3.0 API, JSP 2.2 API and EL 2.2 API. + (markt) +
fix + Remove second copy of RUNNING.txt from the full-docs distribution. Some + unpacking utilities can't handle multiple copies of a file with the same + name in a directory. (markt) +
+
+
Other
+ + + + +
add + Extend Checkstyle validation checks to check for tabs in nearly all text + files. (markt) +
update + Update Apache Commons Daemon from 1.0.2 to 1.0.3. (markt) +
update + Update Eclipse JDT Core Batch Compiler (ecj.jar) from 3.5.1 to 3.6. + (markt) +
+
+
Tomcat 7.0.1 (markt)not released
+
Catalina
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
fix + GSOC 2010. Continue work to align MBean descriptors with reality. Patch + provided by Chamith Buddhika. (markt) +
fix + When running under a security manager, enforce package access and + package definition restrictions defined in the catalina.properties file. + (markt) +
fix + When using a Loader configured with + searchExternalFirst="true" failure to find the + class in an external repository should not prevent searching of the + local repositories. (markt) +
add + Add entryPoint support to the CSRF prevention filter. (markt) +
fix + 48297: Correctly initialise handler chain for web services + resources. (markt) +
add + 48960: Add a new option to the SSI Servlet and SSI Filter to + allow the disabling of the exec command. This is now + disabled by default. Based on a patch by Yair Lenga. (markt) +
add + 48998, 49617: Add the ExpiresFilter, a port of the + httpd mod_expires module. Patch provided by Cyrille Le Clerc. (markt) +
fix + 49030: When initializing/starting/stopping connectors and + one of them fails, do not ignore the others. (markt/kkolinko) +
fix + 49128: Don't swallow exceptions unnecessarily in + WebappClassLoader.start(). (markt) +
fix + 49182: Align comments in setclasspath.[sh|bat] with + behaviour. Based on a patch provided by sebb. (markt) +
fix + 49230: Enhance JRE leak prevention listener with protection + for the keep-alive thread started by + sun.net.www.http.HttpClient. Based on a patch provided by + Rob Kooper. (markt) +
fix + 49414: When reporting threads that may have triggered a + memory leak on web application stop, attempt to differentiate between + request processing threads and threads started by the application. + (markt) +
fix + 49428: Add a work-around for the known namespace issues for + some Microsoft WebDAV clients. Patch provided by Panagiotis Astithas. + (markt) +
add + Add support for *.jar pattern in VirtualWebappLoader. + (kkolinko) +
add + Use a LockOutRealm in the default configuration to prevent attempts to + guess user passwords by brute-force. (markt) +
add + 49478: Add support for user specified character sets to the + AddDefaultCharsetFilter. Based on a patch by Felix + Schumacher. (markt) +
fix + 49503: Make sure connectors bind to their associated ports + sufficiently early to allow jsvc and the + org.apache.catalina.startup.EXIT_ON_INIT_FAILURE system property to + operate correctly. (markt) +
fix + 49525: Ensure cookies for the ROOT context have a path of / + rather than an empty string. (markt) +
fix + 49528, 49567: Ensure that + AsyncContext.isAsyncStarted() returns the correct value + after AsyncContext.start() and that if + AsyncContext.complete() is called on a separate thread that + it is handled correctly. (markt) +
fix + 49530: Contexts and Servlets not stopped when Tomcat is shut + down. (markt) +
fix + 49536: If no ROOT context is deployed, ensure a 404 rather + than a 200 is returned for requests that don't map to any other context. + (markt) +
add + Additional debug logging in StandardContext to provide information on + Manager selection. (markt) +
fix + 49550: Suppress deprecation warning where deprecated code is + required to be used. No functional change. Patch provided by Sebb. + (markt) +
fix + 49551: Allow default context.xml location to be specified + using an absolute path. (markt) +
add + Improve logging of unhandled exceptions in servlets by including the + path of the context where the error occurred. (markt) +
add + Include session ID in error message logged when trying to set an + attribute on an invalid session. (markt) +
fix + Improve the CSRF protection filter by using SecureRandom rather than + Random to generate nonces. Also make the implementation class used user + configurable. (markt) +
fix + Avoid NullPointerException, when copyXML=true and META-INF/context.xml + does not exist. (kfujino) +
fix + 49598: When session is changed and the session cookie is + replaced, ensure that the new Set-Cookie header overwrites the old + Set-Cookie header. (markt) +
fix + Create a thread to trigger asynchronous timeouts when using the BIO + connector, change the default timeout to 10s (was infinite) and make the + default timeout configurable using the asyncTimeout + attribute on the connector. (pero/markt) +
fix + 49600: Make exceptions returned by the + ProxyDirContext consistent for resources that weren't found + by checking the DirContext or the cache. Test case based on + a patch provided by Marc Guillemot. (markt) +
fix + 49613: Improve performance when using SSL for applications + that make multiple class to Request.getAttributeNames(). + Patch provided by Sampo Savolainen. (markt) +
fix + Handle the edge cases where resources packaged in JARs have names that + start with a single quote character or a double quote character. (markt) +
fix + Correct copy and paste typo in web.xml parsing rules that mixed up + local-ejb-ref and resource-env-ref. (markt) +
update + Refactor session managers to remove unused code and to reduce code + duplication. Also, all session managers used for session replication now + extend org.apache.catalina.ha.session.ClusterManagerBase. + (markt) +
+
+
Jasper
+ + + + + + + +
update + Remove references to Jikes since it does not support Java 6. (markt) +
fix + Correct over zealous type checking for EL in attributes that broke the + use of JSF converters. (markt) +
fix + Correct algorithm used to identify correct method to use when a + MethodExpressions is used in EL. (markt) +
fix + 49217: Ensure that identifiers used in EL meet the + requirements of the Java Language Specification. (markt) +
add + Improve logging of JSP exceptions by including JSP snippet (if enabled) + rather than just the root cause in the host log. (markt) +
fix + 49555: Correctly handled Tag Libraries where functions are + defined in static inner classes. (markt) +
+
+
Cluster
+ + + + +
fix + 49127: Don't swallow exceptions unnecessarily in + SimpleTcpReplicationManager.startInternal(). (markt) +
fix + 49407: Change the BackupManager so it is consistent with + DeltaManager and reports both primary and backup sessions when active + sessions are requested. (markt) +
fix + 49445: When session ID is changed after authentication, + ensure the DeltaManager replicates the change in ID to the other nodes + in the cluster. (kfujino) +
+
+
Web applications
+ + + + + + + + + + + + + +
fix + 49112: Update the ROOT web application's index page. Patch + provided by pid. (markt) +
fix + 49213: Add the permissions necessary to enable the Manager + application to operate currently when running with a security manager. + (markt) +
fix + 49436: Correct documented default for readonly attribute of + the UserDatabase component. (markt) +
fix + 49475: Use new role name for manager application access on + the ROOT web application's index page. (markt) +
fix + 49476: CSRF protection was preventing access to the session + expiration features. Also switch the manager application to the generic + CSRF protection filter. (markt) +
fix + Better handle failure to create directories required for new hosts in + the Host Manager application. (markt) +
fix + Switch the Host Manager application to the generic CSRF protection for + the HTML interface and prevent started hosts from being started and + stopped hosts from being stopped. (markt) +
fix + 49518: Fix typo in extras documentation. (markt) +
fix + 49522: Fix regression due to change of name for MBeans for + naming resources that broke the complete server status page in the + manager application. Note these MBeans now have a new name. (markt) +
fix + 49570: When using the example compression filter, set the + Vary header on compressed responses. (markt) +
add + Add redirects for the root of the manager and host-manager web + applications that redirect users to the html interface rather than + returning a 404. (markt) +
add + Provide the HTML Manager application with the ability to differentiate + between primary, backup and proxy sessions. Note that proxy sessions are + only shown if enabled in web.xml. (markt) +
+
+
Other
+ + + + + + + +
fix + 49130: Better describe the core package in the Windows + installer, making it clear that the service will be installed. Patch + provided by sebb. (markt) +
add + Re-factor unit tests to enable them to be run once with each of the HTTP + connector implementations (BIO, NIO and APR/native). (markt) +
add + 49268: Add the necessary plumbing to include CheckStyle in + the build process. Start with no checks. Additional checks will be + added as they are agreed. (markt) +
update + Updated to Ant 1.8.1. The build now requires a minimum of Ant 1.8.x. + (markt) +
update + Update the re-packaged version of commons-fileupload from 1.2.1 to + 1.2.2. The layout of re-packaged version was also restored to the + original commons-fileupload layout to make merging of future updates + easier. (markt) +
update + Update the re-packaged version of Jakarta BCEL from trunk revision + 880760 to trunk revision 978831. (markt) +
+
+
Tomcat 7.0.0 (markt)beta, 2010-06-29
+
Catalina
+ + + + + + + + + + + + + + + + + + + +
update + Update Servlet support to the Servlet 3.0 specification. (all) +
update + Improve and document VirtualWebappLoader. (rjung) +
add + 43642: Add prestartminSpareThreads attribute for Executor. + (jfclere) +
update + Switch from AnnotationProcessor to InstanceManager. Patch provided by + David Jecks with modifications by Remy. (remm/fhanik) +
update + r620845 and r669119. Make shutdown address + configurable. (jfclere) +
fix + r651977 Add some missing control checks to + ThreadWithAttributes. (markt) +
add + r677640 Add a startup class that does not require any + configuration files. (costin) +
fix + r700532 Log if temporary file operations within the CGI + servlet fail. Make sure header Reader is closed on failure. (markt) +
fix + r708541 Delete references to DefaultContext which was removed + in 6.0.x. (markt) +
add + r709018 Initial implementation of an asynchronous file handler + for JULI. (fhanik) +
fix + Give session thisAccessedTime and lastAccessedTime clear semantics. + (rjung) +
add + Expose thisAccessedTime via Session interface. (rjung) +
add + Provide a log format for JULI that provides the same information as the + default but on a single line. (markt) +
add + r723889 Provide the ability to configure the Executor job + queue size and a timeout for adding jobs to the queue. (fhanik) +
add + Add support for aliases to StandardContext. This allows content from + other directories and/or WAR files to be mapped to paths within the + context. (markt) +
update + Provide clearer definition of Lifecycle interface, particularly start + and stop, and align components that implement Lifecycle with this + definition. (markt) +
add + 48662: Provide a new option to control the copying of context + XML descriptors from web applications to the host's xmlBase. Copying of + XML descriptors is now disabled by default. (markt) +
fix + Move comet classes from the org.apache.catalina package to the + org.apache.catalina.comet package to allow comet to work under a + security manager. (markt) +
+
+
Coyote
+ + + + + + + + + +
update + Port SSLInsecureRenegotiation from mod_ssl. This requires + to use tomcat-native 1.2.21 that have option to detect this + support from OpenSSL library. (mturk) +
update + Allow bigger AJP packets also for request bodies and responses + using the packetSize attribute of the Connector. (rjung) +
updater703017 Make Java socket options consistent between NIO + and JIO connector. Expose all the socket options available on + java.net.Socket (fhanik) +
fix + 46051: The writer returned by getWriter() now + conforms to the PrintWriter specification and uses platform + dependent line endings rather than always using \r\n. + (markt) +
update + Use tc-native 1.2.x which is based on APR 1.3.3+ (mturk) +
update + r724239 NIO connector now always uses an Executor. (fhanik) +
update + r724393 Implement keepAliveCount for NIO connector in a thread + safe manner. (fhanik) +
update + r724849 Implement keep alive timeout for NIO connector. + (fhanik) +
+
+
Jasper
+ + + + + + +
update + Update JSP support to the JSP 2.2 specification. (markt) +
update + Update EL support to the EL 2.2 specification. (markt) +
update + r787978 Use "1.6" as the default value for compilerSourceVM + and compilerTargetVM options of Jasper. (kkolinko) +
add + 48358: Add support for limiting the number of JSPs that are + loaded at any one time. Based on a patch by Isabel Drost. (markt) +
add + 48689: Access TLD files through a new JarResource interface + to make extending Jasper simpler, particularly in OSGi environments. + Patch provided by Jarek Gawor. (markt) +
+
+
High Availability
+ + + + + + + + +
add + Add support for UDP and secure communication to tribes. (fhanik) +
add + Add versioning to the tribes communication protocol to support future + developments. (fhanik) +
add + Add a demo on how to use the payload. (fhanik) +
add + Started to add JMX support to the cluster implementation. (markt) +
fix + r609778 Minor fixes to the throughput interceptor and the + NIO receiver. (fhanik) +
fix + r630234 Additional checks for the NIO receiver. (fhanik) +
update + r671650 Improve error message when multicast is not enabled. + (fhanik) +
+
+
Web applications
+ + + + + +
update + r631321 Update changelog to support the <rev> element + in the documentation. (fhanik) +
add + A number of additional roles were added to the Manager and Host Manager + applications to separate out permissions for the HTML interface, the + text interface and the JMX proxy. (markt) +
add + CSRF protection was added to the Manager and Host Manager applications. + (markt) +
add + List array elements in the JMX proxy output of the Manager application. + (rjung) +
+
+
Extras
+ + +
add + A new JmxRemoteLifecycleListener that can be used to fix the ports used + for remote JMX connections, e.g. when using JConsole. (markt) +
+
+
Other
+ + + + + +
fix + Numerous code clean-up changes including the use of generics and + removing unused imports, fields, parameters and methods. (markt) +
fix + All deprecated internal code has been removed. Warning: If you + have custom components for a previous Tomcat version that extend + internal Tomcat classes and override deprecated methods it is highly + likely that they will no longer work. (markt) +
update + Parameterize version number throughout build scripts and source. (rjung) +
add + r766526 Add support for setting up an additional PropertySource + that is used to lookup parameters referenced as ${..} in + XML files parsed by Tomcat. It is configured via + org.apache.tomcat.util.digester.PROPERTY_SOURCE + system property. (fhanik) +
+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/class-loader-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/class-loader-howto.html new file mode 100644 index 0000000..35cd16f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/class-loader-howto.html @@ -0,0 +1,322 @@ +Apache Tomcat 7 (7.0.108) - Class Loader HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Class Loader HOW-TO

Table of Contents
+ +
Overview
+ +

Like many server applications, Tomcat installs a variety of class loaders +(that is, classes that implement java.lang.ClassLoader) to allow +different portions of the container, and the web applications running on the +container, to have access to different repositories of available classes and +resources. This mechanism is used to provide the functionality defined in the +Servlet Specification, version 2.4 — in particular, Sections 9.4 +and 9.6.

+ +

In a Java environment, class loaders are +arranged in a parent-child tree. Normally, when a class loader is asked to +load a particular class or resource, it delegates the request to a parent +class loader first, and then looks in its own repositories only if the parent +class loader(s) cannot find the requested class or resource. Note, that the +model for web application class loaders differs slightly from this, +as discussed below, but the main principles are the same.

+ +

When Tomcat is started, it creates a set of class loaders that are +organized into the following parent-child relationships, where the parent +class loader is above the child class loader:

+ +
      Bootstrap
+          |
+       System
+          |
+       Common
+       /     \
+  Webapp1   Webapp2 ...
+ +

The characteristics of each of these class loaders, including the source +of classes and resources that they make visible, are discussed in detail in +the following section.

+ +
Class Loader Definitions
+ +

As indicated in the diagram above, Tomcat creates the following class +loaders as it is initialized:

+
    +
  • Bootstrap — This class loader contains the basic + runtime classes provided by the Java Virtual Machine, plus any classes from + JAR files present in the System Extensions directory + ($JAVA_HOME/jre/lib/ext). Note: some JVMs may + implement this as more than one class loader, or it may not be visible + (as a class loader) at all.

  • +
  • System — This class loader is normally initialized + from the contents of the CLASSPATH environment variable. All + such classes are visible to both Tomcat internal classes, and to web + applications. However, the standard Tomcat startup scripts + ($CATALINA_HOME/bin/catalina.sh or + %CATALINA_HOME%\bin\catalina.bat) totally ignore the contents + of the CLASSPATH environment variable itself, and instead + build the System class loader from the following repositories: +

    +
      +
    • $CATALINA_HOME/bin/bootstrap.jar — Contains the + main() method that is used to initialize the Tomcat server, and the + class loader implementation classes it depends on.

    • +
    • $CATALINA_BASE/bin/tomcat-juli.jar or + $CATALINA_HOME/bin/tomcat-juli.jar — Logging + implementation classes. These include enhancement classes to + java.util.logging API, known as Tomcat JULI, + and a package-renamed copy of Apache Commons Logging library + used internally by Tomcat. + See logging documentation for more + details.

      +

      If tomcat-juli.jar is present in + $CATALINA_BASE/bin, it is used instead of the one in + $CATALINA_HOME/bin. It is useful in certain logging + configurations

    • +
    • $CATALINA_HOME/bin/commons-daemon.jar — The classes + from Apache Commons + Daemon project. + This JAR file is not present in the CLASSPATH built by + catalina.bat|.sh scripts, but is referenced + from the manifest file of bootstrap.jar.

    • +
    +
  • +
  • Common — This class loader contains additional + classes that are made visible to both Tomcat internal classes and to all + web applications.

    +

    Normally, application classes should NOT + be placed here. The locations searched by this class loader are defined by + the common.loader property in + $CATALINA_BASE/conf/catalina.properties. The default setting will search the + following locations in the order they are listed:

    +
      +
    • unpacked classes and resources in $CATALINA_BASE/lib
    • +
    • JAR files in $CATALINA_BASE/lib
    • +
    • unpacked classes and resources in $CATALINA_HOME/lib
    • +
    • JAR files in $CATALINA_HOME/lib
    • +
    +

    By default, this includes the following:

    +
      +
    • annotations-api.jar — JavaEE annotations classes.
    • +
    • catalina.jar — Implementation of the Catalina servlet + container portion of Tomcat.
    • +
    • catalina-ant.jar — Tomcat Catalina Ant tasks.
    • +
    • catalina-ha.jar — High availability package.
    • +
    • catalina-tribes.jar — Group communication package.
    • +
    • ecj-*.jar — Eclipse JDT Java compiler.
    • +
    • el-api.jar — EL 2.2 API.
    • +
    • jasper.jar — Tomcat Jasper JSP Compiler and Runtime.
    • +
    • jasper-el.jar — Tomcat Jasper EL implementation.
    • +
    • jsp-api.jar — JSP 2.2 API.
    • +
    • servlet-api.jar — Servlet 3.0 API.
    • +
    • tomcat-api.jar — Several interfaces defined by Tomcat.
    • +
    • tomcat-coyote.jar — Tomcat connectors and utility classes.
    • +
    • tomcat-dbcp.jar — Database connection pool + implementation based on package-renamed copy of Apache Commons Pool + and Apache Commons DBCP 1.x.
    • +
    • tomcat-i18n-**.jar — Optional JARs containing resource bundles + for other languages. As default bundles are also included in each + individual JAR, they can be safely removed if no internationalization + of messages is needed.
    • +
    • tomcat-jdbc.jar — An alternative database connection pool + implementation, known as Tomcat JDBC pool. See + documentation for more details.
    • +
    • tomcat-util.jar — Common classes used by various components of + Apache Tomcat.
    • +
    • tomcat7-websocket.jar — WebSocket 1.1 implementation
    • +
    • websocket-api.jar — WebSocket 1.1 API
    • +
  • +
  • WebappX — A class loader is created for each web + application that is deployed in a single Tomcat instance. All unpacked + classes and resources in the /WEB-INF/classes directory of + your web application, plus classes and resources in JAR files + under the /WEB-INF/lib directory of your web application, + are made visible to this web application, but not to other ones.

  • +
+ +

As mentioned above, the web application class loader diverges from the +default Java delegation model (in accordance with the recommendations in the +Servlet Specification, version 2.4, section 9.7.2 Web Application Classloader). +When a request to load a +class from the web application's WebappX class loader is processed, +this class loader will look in the local repositories first, +instead of delegating before looking. There are exceptions. Classes which are +part of the JRE base classes cannot be overridden. For some classes (such as +the XML parser components in J2SE 1.4+), the Java endorsed feature can be +used up to Java 8. +Last, any JAR file that contains Servlet API classes will be explicitly +ignored by the classloader — Do not include such JARs in your web +application. +All other class loaders in Tomcat follow the usual delegation pattern.

+ +

Therefore, from the perspective of a web application, class or resource +loading looks in the following repositories, in this order:

+
    +
  • Bootstrap classes of your JVM
  • +
  • /WEB-INF/classes of your web application
  • +
  • /WEB-INF/lib/*.jar of your web application
  • +
  • System class loader classes (described above)
  • +
  • Common class loader classes (described above)
  • +
+ +

If the web application class loader is +configured with +<Loader delegate="true"/> +then the order becomes:

+
    +
  • Bootstrap classes of your JVM
  • +
  • System class loader classes (described above)
  • +
  • Common class loader classes (described above)
  • +
  • /WEB-INF/classes of your web application
  • +
  • /WEB-INF/lib/*.jar of your web application
  • +
+ +
XML Parsers and Java
+ +

Starting with Java 1.4 a copy of JAXP APIs and an XML parser are packed +inside the JRE. This has impacts on applications that wish to use their own +XML parser.

+ +

In old versions of Tomcat, you could simply replace the XML parser +in the Tomcat libraries directory to change the parser +used by all web applications. However, this technique will not be effective +when you are running modern versions of Java, because the usual class loader +delegation process will always choose the implementation inside the JDK in +preference to this one.

+ +

Java supports a mechanism called the "Endorsed Standards Override +Mechanism" to allow replacement of APIs created outside of the JCP +(i.e. DOM and SAX from W3C). It can also be used to update the XML parser +implementation. For more information, see: + +http://docs.oracle.com/javase/1.5.0/docs/guide/standards/index.html.

+ +

Tomcat utilizes this mechanism by including the system property setting +-Djava.endorsed.dirs=$JAVA_ENDORSED_DIRS in the +command line that starts the container. The default value of this option is +$CATALINA_HOME/endorsed. This endorsed directory is not +created by default. Note that the endorsed feature is no longer supported +with Java 9 and the above system property will only be set if either the +directory $CATALINA_HOME/endorsed exists, or the variable +JAVA_ENDORSED_DIRS has been set. +

+ +

Note that overriding any JRE component carries risk. If the overriding +component does not provide a 100% compatible API (e.g. the API provided by +Xerces is not 100% compatible with the XML API provided by the JRE) then there +is a risk that Tomcat and/or the deployed application will experience errors.

+ +
Running under a security manager
+ +

When running under a security manager the locations from which classes +are permitted to be loaded will also depend on the contents of your policy +file. See Security Manager HOW-TO +for further information.

+ +
Advanced configuration
+ +

A more complex class loader hierarchy may also be configured. See the diagram +below. By default, the Server and Shared +class loaders are not defined and the simplified hierarchy shown above is used. +This more complex hierarchy may be use by defining values for the +server.loader and/or shared.loader properties in +conf/catalina.properties.

+ +

+  Bootstrap
+      |
+    System
+      |
+    Common
+     /  \
+Server  Shared
+         /  \
+   Webapp1  Webapp2 ...
+ +

The Server class loader is only visible to Tomcat internals +and is completely invisible to web applications.

+ +

The Shared class loader is visible to all web applications +and may be used to shared code across all web applications. However, any updates +to this shared code will require a Tomcat restart.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/cluster-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/cluster-howto.html new file mode 100644 index 0000000..11b1f77 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/cluster-howto.html @@ -0,0 +1,707 @@ +Apache Tomcat 7 (7.0.108) - Clustering/Session Replication HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Clustering/Session Replication HOW-TO

Important Note
+

You can also check the configuration reference documentation. +

+
Table of Contents
+ +
For the impatient
+

+ Simply add +

+
<Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"/>
+

+ to your <Engine> or your <Host> element to enable clustering. +

+

+ Using the above configuration will enable all-to-all session replication + using the DeltaManager to replicate session deltas. By all-to-all we mean that the session gets replicated to all the other + nodes in the cluster. This works great for smaller cluster but we don't recommend it for larger clusters(a lot of Tomcat nodes). + Also when using the delta manager it will replicate to all nodes, even nodes that don't have the application deployed.
+ To get around this problem, you'll want to use the BackupManager. This manager only replicates the session data to one backup + node, and only to nodes that have the application deployed. Downside of the BackupManager: not quite as battle tested as the delta manager. +

+

+ Here are some of the important default values: +

+
    +
  1. Multicast address is 228.0.0.4
  2. +
  3. Multicast port is 45564 (the port and the address together determine cluster membership.
  4. +
  5. The IP broadcasted is java.net.InetAddress.getLocalHost().getHostAddress() (make sure you don't broadcast 127.0.0.1, this is a common error)
  6. +
  7. The TCP port listening for replication messages is the first available server socket in range 4000-4100
  8. +
  9. Listener is configured ClusterSessionListener
  10. +
  11. Two interceptors are configured TcpFailureDetector and MessageDispatch15Interceptor
  12. +
+

+ The following is the default cluster configuration: +

+
        <Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"
+                 channelSendOptions="8">
+
+          <Manager className="org.apache.catalina.ha.session.DeltaManager"
+                   expireSessionsOnShutdown="false"
+                   notifyListenersOnReplication="true"/>
+
+          <Channel className="org.apache.catalina.tribes.group.GroupChannel">
+            <Membership className="org.apache.catalina.tribes.membership.McastService"
+                        address="228.0.0.4"
+                        port="45564"
+                        frequency="500"
+                        dropTime="3000"/>
+            <Receiver className="org.apache.catalina.tribes.transport.nio.NioReceiver"
+                      address="auto"
+                      port="4000"
+                      autoBind="100"
+                      selectorTimeout="5000"
+                      maxThreads="6"/>
+
+            <Sender className="org.apache.catalina.tribes.transport.ReplicationTransmitter">
+              <Transport className="org.apache.catalina.tribes.transport.nio.PooledParallelSender"/>
+            </Sender>
+            <Interceptor className="org.apache.catalina.tribes.group.interceptors.TcpFailureDetector"/>
+            <Interceptor className="org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor"/>
+          </Channel>
+
+          <Valve className="org.apache.catalina.ha.tcp.ReplicationValve"
+                 filter=""/>
+          <Valve className="org.apache.catalina.ha.session.JvmRouteBinderValve"/>
+
+          <Deployer className="org.apache.catalina.ha.deploy.FarmWarDeployer"
+                    tempDir="/tmp/war-temp/"
+                    deployDir="/tmp/war-deploy/"
+                    watchDir="/tmp/war-listen/"
+                    watchEnabled="false"/>
+
+          <ClusterListener className="org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener">
+          <ClusterListener className="org.apache.catalina.ha.session.ClusterSessionListener">
+        </Cluster>
+

Will cover this section in more detail later in this document.

+
Security
+ +

The cluster implementation is written on the basis that a secure, trusted +network is used for all of the cluster related network traffic. It is not safe +to run a cluster on a insecure, untrusted network.

+ +

There are many options for providing a secure, trusted network for use by a +Tomcat cluster. These include:

+
    +
  • private LAN
  • +
  • a Virtual Private Network (VPN)
  • +
  • IPSEC
  • +
+ +
Cluster Basics
+ +

To run session replication in your Tomcat 7.0 container, the following steps +should be completed:

+
    +
  • All your session attributes must implement java.io.Serializable
  • +
  • Uncomment the Cluster element in server.xml
  • +
  • If you have defined custom cluster valves, make sure you have the ReplicationValve defined as well under the Cluster element in server.xml
  • +
  • If your Tomcat instances are running on the same machine, make sure the Receiver.port + attribute is unique for each instance, in most cases Tomcat is smart enough to resolve this on it's own by autodetecting available ports in the range 4000-4100
  • +
  • Make sure your web.xml has the + <distributable/> element
  • +
  • If you are using mod_jk, make sure that jvmRoute attribute is set at your Engine <Engine name="Catalina" jvmRoute="node01" > + and that the jvmRoute attribute value matches your worker name in workers.properties
  • +
  • Make sure that all nodes have the same time and sync with NTP service!
  • +
  • Make sure that your loadbalancer is configured for sticky session mode.
  • +
+

Load balancing can be achieved through many techniques, as seen in the +Load Balancing chapter.

+

Note: Remember that your session state is tracked by a cookie, so your URL must look the same from the out + side otherwise, a new session will be created.

+

The Cluster module uses the Tomcat JULI logging framework, so you can configure logging + through the regular logging.properties file. To track messages, you can enable logging on the key: org.apache.catalina.tribes.MESSAGES

+
Overview
+ +

To enable session replication in Tomcat, three different paths can be followed to achieve the exact same thing:

+
    +
  1. Using session persistence, and saving the session to a shared file system (PersistenceManager + FileStore)
  2. +
  3. Using session persistence, and saving the session to a shared database (PersistenceManager + JDBCStore)
  4. +
  5. Using in-memory-replication, using the SimpleTcpCluster that ships with Tomcat (lib/catalina-tribes.jar + lib/catalina-ha.jar)
  6. +
+ +

In this release of session replication, Tomcat can perform an all-to-all replication of session state using the DeltaManager or + perform backup replication to only one node using the BackupManager. + The all-to-all replication is an algorithm that is only efficient when the clusters are small. For larger clusters, to use + a primary-secondary session replication where the session will only be stored at one backup server simply setup the BackupManager.
+ Currently you can use the domain worker attribute (mod_jk > 1.2.8) to build cluster partitions + with the potential of having a more scalable cluster solution with the DeltaManager(you'll need to configure the domain interceptor for this). + In order to keep the network traffic down in an all-to-all environment, you can split your cluster + into smaller groups. This can be easily achieved by using different multicast addresses for the different groups. + A very simple setup would look like this: +

+ +
        DNS Round Robin
+               |
+         Load Balancer
+          /           \
+      Cluster1      Cluster2
+      /     \        /     \
+  Tomcat1 Tomcat2  Tomcat3 Tomcat4
+ +

What is important to mention here, is that session replication is only the beginning of clustering. + Another popular concept used to implement clusters is farming, i.e., you deploy your apps only to one + server, and the cluster will distribute the deployments across the entire cluster. + This is all capabilities that can go into with the FarmWarDeployer (s. cluster example at server.xml)

+

In the next section will go deeper into how session replication works and how to configure it.

+ +
Cluster Information
+

Membership is established using multicast heartbeats. + Hence, if you wish to subdivide your clusters, you can do this by + changing the multicast IP address or port in the <Membership> element. +

+

+ The heartbeat contains the IP address of the Tomcat node and the TCP port that + Tomcat listens to for replication traffic. All data communication happens over TCP. +

+

+ The ReplicationValve is used to find out when the request has been completed and initiate the + replication, if any. Data is only replicated if the session has changed (by calling setAttribute or removeAttribute + on the session). +

+

+ One of the most important performance considerations is the synchronous versus asynchronous replication. + In a synchronous replication mode the request doesn't return until the replicated session has been + sent over the wire and reinstantiated on all the other cluster nodes. + Synchronous vs. asynchronous is configured using the channelSendOptions + flag and is an integer value. The default value for the SimpleTcpCluster/DeltaManager combo is + 8, which is asynchronous. You can read more on the send flag(overview) or the + send flag(javadoc). + During async replication, the request is returned before the data has been replicated. async replication yields shorter + request times, and synchronous replication guarantees the session to be replicated before the request returns. +

+
Bind session after crash to failover node
+

+ If you are using mod_jk and not using sticky sessions or for some reasons sticky session don't + work, or you are simply failing over, the session id will need to be modified as it previously contained + the worker id of the previous tomcat (as defined by jvmRoute in the Engine element). + To solve this, we will use the JvmRouteBinderValve. +

+

+ The JvmRouteBinderValve rewrites the session id to ensure that the next request will remain sticky + (and not fall back to go to random nodes since the worker is no longer available) after a fail over. + The valve rewrites the JSESSIONID value in the cookie with the same name. + Not having this valve in place, will make it harder to ensure stickiness in case of a failure for the mod_jk module. +

+

+ By default, if no valves are configured, the JvmRouteBinderValve is added on. + The cluster message listener called JvmRouteSessionIDBinderListener is also defined by default and is used to actually rewrite the + session id on the other nodes in the cluster once a fail over has occurred. + Remember, if you are adding your own valves or cluster listeners in server.xml then the defaults are no longer valid, + make sure that you add in all the appropriate valves and listeners as defined by the default. +

+

+ Hint:
+ With attribute sessionIdAttribute you can change the request attribute name that included the old session id. + Default attribute name is org.apache.catalina.ha.session.JvmRouteOriginalSessionID. +

+

+ Trick:
+ You can enable this mod_jk turnover mode via JMX before you drop a node to all backup nodes! + Set enable true on all JvmRouteBinderValve backups, disable worker at mod_jk + and then drop node and restart it! Then enable mod_jk Worker and disable JvmRouteBinderValves again. + This use case means that only requested session are migrated. +

+ + +
Configuration Example
+
        <Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"
+                 channelSendOptions="6">
+
+          <Manager className="org.apache.catalina.ha.session.BackupManager"
+                   expireSessionsOnShutdown="false"
+                   notifyListenersOnReplication="true"
+                   mapSendOptions="6"/>
+          <!--
+          <Manager className="org.apache.catalina.ha.session.DeltaManager"
+                   expireSessionsOnShutdown="false"
+                   notifyListenersOnReplication="true"/>
+          -->
+          <Channel className="org.apache.catalina.tribes.group.GroupChannel">
+            <Membership className="org.apache.catalina.tribes.membership.McastService"
+                        address="228.0.0.4"
+                        port="45564"
+                        frequency="500"
+                        dropTime="3000"/>
+            <Receiver className="org.apache.catalina.tribes.transport.nio.NioReceiver"
+                      address="auto"
+                      port="5000"
+                      selectorTimeout="100"
+                      maxThreads="6"/>
+
+            <Sender className="org.apache.catalina.tribes.transport.ReplicationTransmitter">
+              <Transport className="org.apache.catalina.tribes.transport.nio.PooledParallelSender"/>
+            </Sender>
+            <Interceptor className="org.apache.catalina.tribes.group.interceptors.TcpFailureDetector"/>
+            <Interceptor className="org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor"/>
+            <Interceptor className="org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor"/>
+          </Channel>
+
+          <Valve className="org.apache.catalina.ha.tcp.ReplicationValve"
+                 filter=".*\.gif|.*\.js|.*\.jpeg|.*\.jpg|.*\.png|.*\.htm|.*\.html|.*\.css|.*\.txt"/>
+
+          <Deployer className="org.apache.catalina.ha.deploy.FarmWarDeployer"
+                    tempDir="/tmp/war-temp/"
+                    deployDir="/tmp/war-deploy/"
+                    watchDir="/tmp/war-listen/"
+                    watchEnabled="false"/>
+
+          <ClusterListener className="org.apache.catalina.ha.session.ClusterSessionListener"/>
+        </Cluster>
+

+ Break it down!! +

+
        <Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"
+                 channelSendOptions="6">
+

+ The main element, inside this element all cluster details can be configured. + The channelSendOptions is the flag that is attached to each message sent by the + SimpleTcpCluster class or any objects that are invoking the SimpleTcpCluster.send method. + The description of the send flags is available at + our javadoc site + The DeltaManager sends information using the SimpleTcpCluster.send method, while the backup manager + sends it itself directly through the channel. +
For more info, Please visit the reference documentation +

+
          <Manager className="org.apache.catalina.ha.session.BackupManager"
+                   expireSessionsOnShutdown="false"
+                   notifyListenersOnReplication="true"
+                   mapSendOptions="6"/>
+          <!--
+          <Manager className="org.apache.catalina.ha.session.DeltaManager"
+                   expireSessionsOnShutdown="false"
+                   notifyListenersOnReplication="true"/>
+          -->
+

+ This is a template for the manager configuration that will be used if no manager is defined in the <Context> + element. In Tomcat 5.x each webapp marked distributable had to use the same manager, this is no longer the case + since Tomcat you can define a manager class for each webapp, so that you can mix managers in your cluster. + Obviously the managers on one node's application has to correspond with the same manager on the same application on the other node. + If no manager has been specified for the webapp, and the webapp is marked <distributable/> Tomcat will take this manager configuration + and create a manager instance cloning this configuration. +
For more info, Please visit the reference documentation +

+
          <Channel className="org.apache.catalina.tribes.group.GroupChannel">
+

+ The channel element is Tribes, the group communication framework + used inside Tomcat. This element encapsulates everything that has to do with communication and membership logic. +
For more info, Please visit the reference documentation +

+
            <Membership className="org.apache.catalina.tribes.membership.McastService"
+                        address="228.0.0.4"
+                        port="45564"
+                        frequency="500"
+                        dropTime="3000"/>
+

+ Membership is done using multicasting. Please note that Tribes also supports static memberships using the + StaticMembershipInterceptor if you want to extend your membership to points beyond multicasting. + The address attribute is the multicast address used and the port is the multicast port. These two together + create the cluster separation. If you want a QA cluster and a production cluster, the easiest config is to + have the QA cluster be on a separate multicast address/port combination than the production cluster.
+ The membership component broadcasts TCP address/port of itself to the other nodes so that communication between + nodes can be done over TCP. Please note that the address being broadcasted is the one of the + Receiver.address attribute. +
For more info, Please visit the reference documentation +

+
            <Receiver className="org.apache.catalina.tribes.transport.nio.NioReceiver"
+                      address="auto"
+                      port="5000"
+                      selectorTimeout="100"
+                      maxThreads="6"/>
+

+ In tribes the logic of sending and receiving data has been broken into two functional components. The Receiver, as the name suggests + is responsible for receiving messages. Since the Tribes stack is thread less, (a popular improvement now adopted by other frameworks as well), + there is a thread pool in this component that has a maxThreads and minThreads setting.
+ The address attribute is the host address that will be broadcasted by the membership component to the other nodes. +
For more info, Please visit the reference documentation +

+
            <Sender className="org.apache.catalina.tribes.transport.ReplicationTransmitter">
+              <Transport className="org.apache.catalina.tribes.transport.nio.PooledParallelSender"/>
+            </Sender>
+

+ The sender component, as the name indicates is responsible for sending messages to other nodes. + The sender has a shell component, the ReplicationTransmitter but the real stuff done is done in the + sub component, Transport. + Tribes support having a pool of senders, so that messages can be sent in parallel and if using the NIO sender, + you can send messages concurrently as well.
+ Concurrently means one message to multiple senders at the same time and Parallel means multiple messages to multiple senders + at the same time. +
For more info, Please visit the reference documentation +

+
            <Interceptor className="org.apache.catalina.tribes.group.interceptors.TcpFailureDetector"/>
+            <Interceptor className="org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor"/>
+            <Interceptor className="org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor"/>
+          </Channel>
+

+ Tribes uses a stack to send messages through. Each element in the stack is called an interceptor, and works much like the valves do + in the Tomcat servlet container. + Using interceptors, logic can be broken into more manageable pieces of code. The interceptors configured above are:
+ TcpFailureDetector - verifies crashed members through TCP, if multicast packets get dropped, this interceptor protects against false positives, + ie the node marked as crashed even though it still is alive and running.
+ MessageDispatch15Interceptor - dispatches messages to a thread (thread pool) to send message asynchronously.
+ ThroughputInterceptor - prints out simple stats on message traffic.
+ Please note that the order of interceptors is important. The way they are defined in server.xml is the way they are represented in the + channel stack. Think of it as a linked list, with the head being the first most interceptor and the tail the last. +
For more info, Please visit the reference documentation +

+
          <Valve className="org.apache.catalina.ha.tcp.ReplicationValve"
+                 filter=".*\.gif|.*\.js|.*\.jpeg|.*\.jpg|.*\.png|.*\.htm|.*\.html|.*\.css|.*\.txt"/>
+

+ The cluster uses valves to track requests to web applications, we've mentioned the ReplicationValve and the JvmRouteBinderValve above. + The <Cluster> element itself is not part of the pipeline in Tomcat, instead the cluster adds the valve to its parent container. + If the <Cluster> elements is configured in the <Engine> element, the valves get added to the engine and so on. +
For more info, Please visit the reference documentation +

+
          <Deployer className="org.apache.catalina.ha.deploy.FarmWarDeployer"
+                    tempDir="/tmp/war-temp/"
+                    deployDir="/tmp/war-deploy/"
+                    watchDir="/tmp/war-listen/"
+                    watchEnabled="false"/>
+

+ The default tomcat cluster supports farmed deployment, ie, the cluster can deploy and undeploy applications on the other nodes. + The state of this component is currently in flux but will be addressed soon. There was a change in the deployment algorithm + between Tomcat 5.0 and 5.5 and at that point, the logic of this component changed to where the deploy dir has to match the + webapps directory. +
For more info, Please visit the reference documentation +

+
          <ClusterListener className="org.apache.catalina.ha.session.ClusterSessionListener"/>
+        </Cluster>
+

+ Since the SimpleTcpCluster itself is a sender and receiver of the Channel object, components can register themselves as listeners to + the SimpleTcpCluster. The listener above ClusterSessionListener listens for DeltaManager replication messages + and applies the deltas to the manager that in turn applies it to the session. +
For more info, Please visit the reference documentation +

+ +
Cluster Architecture
+ +

Component Levels:

+
         Server
+           |
+         Service
+           |
+         Engine
+           |  \
+           |  --- Cluster --*
+           |
+         Host
+           |
+         ------
+        /      \
+     Cluster    Context(1-N)
+        |             \
+        |             -- Manager
+        |                   \
+        |                   -- DeltaManager
+        |                   -- BackupManager
+        |
+     ---------------------------
+        |                       \
+      Channel                    \
+    ----------------------------- \
+        |                          \
+     Interceptor_1 ..               \
+        |                            \
+     Interceptor_N                    \
+    -----------------------------      \
+     |          |         |             \
+   Receiver    Sender   Membership       \
+                                         -- Valve
+                                         |      \
+                                         |       -- ReplicationValve
+                                         |       -- JvmRouteBinderValve
+                                         |
+                                         -- LifecycleListener
+                                         |
+                                         -- ClusterListener
+                                         |      \
+                                         |       -- ClusterSessionListener
+                                         |       -- JvmRouteSessionIDBinderListener
+                                         |
+                                         -- Deployer
+                                                \
+                                                 -- FarmWarDeployer
+
+
+ + +
How it Works
+

To make it easy to understand how clustering works, we are gonna to take you through a series of scenarios. + In this scenario we only plan to use two tomcat instances TomcatA and TomcatB. + We will cover the following sequence of events:

+ +
    +
  1. TomcatA starts up
  2. +
  3. TomcatB starts up (Wait the TomcatA start is complete)
  4. +
  5. TomcatA receives a request, a session S1 is created.
  6. +
  7. TomcatA crashes
  8. +
  9. TomcatB receives a request for session S1
  10. +
  11. TomcatA starts up
  12. +
  13. TomcatA receives a request, invalidate is called on the session (S1)
  14. +
  15. TomcatB receives a request, for a new session (S2)
  16. +
  17. TomcatA The session S2 expires due to inactivity.
  18. +
+ +

Ok, now that we have a good sequence, we will take you through exactly what happens in the session replication code

+ +
    +
  1. TomcatA starts up +

    + Tomcat starts up using the standard start up sequence. When the Host object is created, a cluster object is associated with it. + When the contexts are parsed, if the distributable element is in place in the web.xml file, + Tomcat asks the Cluster class (in this case SimpleTcpCluster) to create a manager + for the replicated context. So with clustering enabled, distributable set in web.xml + Tomcat will create a DeltaManager for that context instead of a StandardManager. + The cluster class will start up a membership service (multicast) and a replication service (tcp unicast). + More on the architecture further down in this document. +

    +
  2. +
  3. TomcatB starts up +

    + When TomcatB starts up, it follows the same sequence as TomcatA did with one exception. + The cluster is started and will establish a membership (TomcatA, TomcatB). + TomcatB will now request the session state from a server that already exists in the cluster, + in this case TomcatA. TomcatA responds to the request, and before TomcatB starts listening + for HTTP requests, the state has been transferred from TomcatA to TomcatB. + In case TomcatA doesn't respond, TomcatB will time out after 60 seconds, issue a log + entry, and continue starting. The session state gets transferred for each web + application that has distributable in its web.xml. (Note: To use session replication + efficiently, all your tomcat instances should be configured the same.) +

    +
  4. +
  5. TomcatA receives a request, a session S1 is created. +

    + The request coming in to TomcatA is handled exactly the same way as without session + replication, until the request is completed, at which time the + ReplicationValve will intercept the request before the response is + returned to the user. At this point it finds that the session has been modified, + and it uses TCP to replicate the session to TomcatB. Once the serialized data has + been handed off to the operating system's TCP logic, the request returns to the user, + back through the valve pipeline. For each request the entire session is replicated, + this allows code that modifies attributes in the session without calling setAttribute + or removeAttribute to be replicated. A useDirtyFlag configuration parameter can + be used to optimize the number of times a session is replicated. +

    + +
  6. +
  7. TomcatA crashes +

    + When TomcatA crashes, TomcatB receives a notification that TomcatA has dropped out + of the cluster. TomcatB removes TomcatA from its membership list, and TomcatA will + no longer be notified of any changes that occurs in TomcatB. The load balancer + will redirect the requests from TomcatA to TomcatB and all the sessions are current. +

    +
  8. +
  9. TomcatB receives a request for session S1 +

    Nothing exciting, TomcatB will process the request as any other request. +

    +
  10. +
  11. TomcatA starts up +

    Upon start up, before TomcatA starts taking new request and making itself + available to it will follow the start up sequence described above 1) 2). + It will join the cluster, contact TomcatB for the current state of all the sessions. + And once it receives the session state, it finishes loading and opens its HTTP/mod_jk ports. + So no requests will make it to TomcatA until it has received the session state from TomcatB. +

    +
  12. +
  13. TomcatA receives a request, invalidate is called on the session (S1) +

    The invalidate call is intercepted, and the session is queued with invalidated sessions. + When the request is complete, instead of sending out the session that has changed, it sends out + an "expire" message to TomcatB and TomcatB will invalidate the session as well. +

    + +
  14. +
  15. TomcatB receives a request, for a new session (S2) +

    Same scenario as in step 3) +

    + + +
  16. +
  17. TomcatA The session S2 expires due to inactivity. +

    The invalidate call is intercepted the same way as when a session is invalidated by the user, + and the session is queued with invalidated sessions. + At this point, the invalidated session will not be replicated across until + another request comes through the system and checks the invalid queue. +

    +
  18. +
+ +

Phuuuhh! :)

+ +

Membership + Clustering membership is established using very simple multicast pings. + Each Tomcat instance will periodically send out a multicast ping, + in the ping message the instance will broadcast its IP and TCP listen port + for replication. + If an instance has not received such a ping within a given timeframe, the + member is considered dead. Very simple, and very effective! + Of course, you need to enable multicasting on your system. +

+ +

TCP Replication + Once a multicast ping has been received, the member is added to the cluster + Upon the next replication request, the sending instance will use the host and + port info and establish a TCP socket. Using this socket it sends over the serialized data. + The reason I chose TCP sockets is because it has built in flow control and guaranteed delivery. + So I know, when I send some data, it will make it there :) +

+ +

Distributed locking and pages using frames + Tomcat does not keep session instances in sync across the cluster. + The implementation of such logic would be to much overhead and cause all + kinds of problems. If your client accesses the same session + simultaneously using multiple requests, then the last request + will override the other sessions in the cluster. +

+ +
Monitoring your Cluster with JMX
+

Monitoring is a very important question when you use a cluster. Some of the cluster objects are JMX MBeans

+

Add the following parameter to your startup script:

+
set CATALINA_OPTS=\
+-Dcom.sun.management.jmxremote \
+-Dcom.sun.management.jmxremote.port=%my.jmx.port% \
+-Dcom.sun.management.jmxremote.ssl=false \
+-Dcom.sun.management.jmxremote.authenticate=false
+ +

+ List of Cluster Mbeans +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameDescriptionMBean ObjectName - EngineMBean ObjectName - Host
ClusterThe complete cluster elementtype=Clustertype=Cluster,host=${HOST}
DeltaManagerThis manager control the sessions and handle session replication type=Manager,context=${APP.CONTEXT.PATH}, host=${HOST}type=Manager,context=${APP.CONTEXT.PATH}, host=${HOST}
FarmWarDeployerManages the process of deploying an application to all nodes in the clusterNot supportedtype=Cluster, host=${HOST}, component=deployer
MemberRepresents a node in the clustertype=Cluster, component=member, name=${NODE_NAME}type=Cluster, host=${HOST}, component=member, name=${NODE_NAME}
ReplicationValveThis valve control the replication to the backup nodestype=Valve,name=ReplicationValvetype=Valve,name=ReplicationValve,host=${HOST}
JvmRouteBinderValveThis is a cluster fallback valve to change the Session ID to the current tomcat jvmroute.type=Valve,name=JvmRouteBinderValve, + context=${APP.CONTEXT.PATH}type=Valve,name=JvmRouteBinderValve,host=${HOST}, + context=${APP.CONTEXT.PATH}
+
FAQ
+

Please see the clustering section of the FAQ.

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/comments.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/comments.html new file mode 100644 index 0000000..97b9f6c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/comments.html @@ -0,0 +1,157 @@ +Apache Tomcat 7 (7.0.108) - Documentation User Comments

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Documentation User Comments

Introduction
+ +

The Tomcat documentation integrates the +Apache Comments System. +It allows users to add comments to most documentation pages. The comments +section can be found at the end of each page.

+ +
Allowed Content
+ +

Please use the Apache Comments System responsibly. We can only provide +this service to the community as long as it isn't misused.

+ +

The comments are not for general Q&A. +Comments should be pointed towards suggestions on improving the documentation +or server. Questions on how to use Apache Tomcat should be directed +to our mailing lists.

+ +

Comments may be removed by moderators if they are either +implemented or considered invalid/off-topic.

+ +

HTML is not allowed in comments, and will just display as raw source code +if attempted. Links that do not point to an Apache site (*.apache.org) will +need approval by a moderator before the comment is visible to regular visitors.

+ +
License
+ +

Any submitted comments must be contributed under the terms of the +Apache License, Version 2.0.

+ +
Verified Users
+ +

Verified users gain the Apache feather next to their name, +and may post comments with links in them without requiring approval +by a moderator before the comments are shown. Being a verified user +in itself does not give you moderating rights. If you are interested +in becoming a verified user, please contact us on the +users mailing list.

+ +

All ASF committers are automatically verified users.

+ +
Moderators
+ +

Moderators are allowed to mark comments as "Resolved", "Invalid" +or "Sticky", remove marks, approve comments e.g. if they contain +a link, and delete comments. Moderators can also subscribe to new +comments and comment updates and use the dashboard to gain some +overview over all comments of a site.

+ +

To use the moderation features, you need to login to the comments +system. Furthermore you will need to allow cookies to be set for +comments.apache.org (this is done using a secure https cookie). Once +logged in as a moderator you will see additional moderation +options attached to each comment.

+ +

If you are a long time follower of the Apache Tomcat projects +and you are interested in becoming a moderator, please contact us on the +users mailing list.

+ +
Privacy Policy
+ +

No data except what you personally submit is kept on record. +A cookie is used to keep track of moderators and other people +who wish to create an account to avoid having to enter their +credentials whenever they wish to post a comment.

+ +

To prevent spam and unsolicited comments, we use a digest of +visitors' IPs to keep track of comments posted by them.

+ +

Entering an email address when you post a comment is completely +optional, and will not be shared with anyone. If you enter an +email address, it will be used to notify you when someone posts +a reply to one of your comments, provided you have registered +an account and validated your email address.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/ajp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/ajp.html new file mode 100644 index 0000000..97e53f9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/ajp.html @@ -0,0 +1,709 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The AJP Connector

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The AJP Connector

Table of Contents
+ +
Introduction
+ +

The AJP Connector element represents a + Connector component that communicates with a web + connector via the AJP protocol. This is used for cases + where you wish to invisibly integrate Tomcat into an existing (or new) + Apache installation, and you want Apache to handle the static content + contained in the web application, and/or utilize Apache's SSL + processing.

+ +

This connector supports load balancing when used in conjunction with + the jvmRoute attribute of the + Engine.

+ +

The native connectors supported with this Tomcat release are:

+
    +
  • JK 1.2.x with any of the supported servers. See + the JK docs + for details.
  • +
  • mod_proxy on Apache httpd 2.x (included by default in Apache HTTP + Server 2.2), with AJP enabled: see + the + httpd docs for details.
  • +
+ +

Other native connectors supporting AJP may work, but are no longer + supported.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Connector + support the following attributes:

+ +
AttributeDescription
ajpFlush +

A boolean value which can be used to enable or disable sending + AJP flush messages to the fronting proxy whenever an explicit + flush happens. The default value is true.
+ An AJP flush message is a SEND_BODY_CHUNK packet with no body content. + Proxy implementations like mod_jk or mod_proxy_ajp will flush the + data buffered in the web server to the client when they receive + such a packet. Setting this to false can reduce + AJP packet traffic but might delay sending packets to the client. + At the end of the response, AJP does always flush to the client.

+
allowTrace +

A boolean value which can be used to enable or disable the TRACE + HTTP method. If not specified, this attribute is set to false.

+
asyncTimeout +

The default timeout for asynchronous requests in milliseconds. If not + specified, this attribute is set to 10000 (10 seconds).

+
enableLookups +

Set to true if you want calls to + request.getRemoteHost() to perform DNS lookups in + order to return the actual host name of the remote client. Set + to false to skip the DNS lookup and return the IP + address in String form instead (thereby improving performance). + By default, DNS lookups are disabled.

+
encodedSolidusHandling +

When set to reject request paths containing a + %2f sequence will be rejected with a 400 response. When set + to decode request paths containing a %2f + sequence will have that sequence decoded to / at the same + time other %nn sequences are decoded. When set to + passthrough request paths containing a %2f + sequence will be processed with the %2f sequence unchanged. + If not specified the default value is reject. This default + may be modified if the deprecated system + property + org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH is + set.

+
maxHeaderCount +

The maximum number of headers in a request that are allowed by the + container. A request that contains more headers than the specified limit + will be rejected. A value of less than 0 means no limit. + If not specified, a default of 100 is used.

+
maxParameterCount +

The maximum number of parameter and value pairs (GET plus POST) which + will be automatically parsed by the container. Parameter and value pairs + beyond this limit will be ignored. A value of less than 0 means no limit. + If not specified, a default of 10000 is used. Note that + FailedRequestFilter filter can be + used to reject requests that hit the limit.

+
maxPostSize +

The maximum size in bytes of the POST which will be handled by + the container FORM URL parameter parsing. The limit can be disabled by + setting this attribute to a value less than zero. If not specified, this + attribute is set to 2097152 (2 megabytes). Note that the + FailedRequestFilter + can be used to reject requests that exceed this limit.

+
maxSavePostSize +

The maximum size in bytes of the POST which will be saved/buffered by + the container during FORM or CLIENT-CERT authentication. For both types + of authentication, the POST will be saved/buffered before the user is + authenticated. For CLIENT-CERT authentication, the POST is buffered for + the duration of the SSL handshake and the buffer emptied when the request + is processed. For FORM authentication the POST is saved whilst the user + is re-directed to the login form and is retained until the user + successfully authenticates or the session associated with the + authentication request expires. The limit can be disabled by setting this + attribute to -1. Setting the attribute to zero will disable the saving of + POST data during authentication. If not specified, this attribute is set + to 4096 (4 kilobytes).

+
parseBodyMethods +

A comma-separated list of HTTP methods for which request + bodies using application/x-www-form-urlencoded will be parsed + for request parameters identically to POST. This is useful in RESTful + applications that want to support POST-style semantics for PUT requests. + Note that any setting other than POST causes Tomcat + to behave in a way that goes against the intent of the servlet + specification. + The HTTP method TRACE is specifically forbidden here in accordance + with the HTTP specification. + The default is POST

+
port +

The TCP port number on which this Connector + will create a server socket and await incoming connections. Your + operating system will allow only one server application to listen + to a particular port number on a particular IP address. If the special + value of 0 (zero) is used, then Tomcat will select a free port at random + to use for this connector. This is typically only useful in embedded and + testing applications.

+
protocol +

Sets the protocol to handle incoming traffic. To configure an AJP + connector this must be specified. If no value for protocol is provided, + an HTTP connector rather than an AJP connector + will be configured.
+ The standard protocol value for an AJP connector is AJP/1.3 + which uses an auto-switching mechanism to select either a Java based + connector or an APR/native based connector. If the + PATH (Windows) or LD_LIBRARY_PATH (on most unix + systems) environment variables contain the Tomcat native library, the + native/APR connector will be used. If the native library cannot be + found, the Java BIO based connector will be used.
+ To use an explicit protocol rather than rely on the auto-switching + mechanism described above, the following values may be used:
+ org.apache.coyote.ajp.AjpProtocol + - blocking Java connector
+ org.apache.coyote.ajp.AjpNioProtocol + - non blocking Java connector.
+ org.apache.coyote.ajp.AjpAprProtocol + - the APR/native connector.
+ Custom implementations may also be used.
+ Take a look at our Connector + Comparison chart. +

+
proxyName +

If this Connector is being used in a proxy + configuration, configure this attribute to specify the server name + to be returned for calls to request.getServerName(). + See Proxy Support for more + information.

+
proxyPort +

If this Connector is being used in a proxy + configuration, configure this attribute to specify the server port + to be returned for calls to request.getServerPort(). + See Proxy Support for more + information.

+
redirectPort +

If this Connector is supporting non-SSL + requests, and a request is received for which a matching + <security-constraint> requires SSL transport, + Catalina will automatically redirect the request to the port + number specified here.

+
scheme +

Set this attribute to the name of the protocol you wish to have + returned by calls to request.getScheme(). For + example, you would set this attribute to "https" + for an SSL Connector. The default value is "http". +

+
secure +

Set this attribute to true if you wish to have + calls to request.isSecure() to return true + for requests received by this Connector. You would want this on an + SSL Connector or a non SSL connector that is receiving data from a + SSL accelerator, like a crypto card, an SSL appliance or even a webserver. + The default value is false.

+
URIEncoding +

This specifies the character encoding used to decode the URI bytes, + after %xx decoding the URL. If not specified, ISO-8859-1 will be used. +

+
useBodyEncodingForURI +

This specifies if the encoding specified in contentType should be used + for URI query parameters, instead of using the URIEncoding. This + setting is present for compatibility with Tomcat 4.1.x, where the + encoding specified in the contentType, or explicitly set using + Request.setCharacterEncoding method was also used for the parameters from + the URL. The default value is false. +

+

Notes: See notes on this attribute in + HTTP Connector documentation.

+
useIPVHosts +

Set this attribute to true to cause Tomcat to use + the IP address passed by the native web server to determine the Host + to send the request to. The default value is false.

+
xpoweredBy +

Set this attribute to true to cause Tomcat to advertise + support for the Servlet specification using the header recommended in the + specification. The default value is false.

+
+ +
+ +
Standard Implementations
+ +

To use AJP, you must specify the protocol attribute (see above).

+ +

The standard AJP connectors (BIO, NIO and APR/native) all support the + following attributes in addition to the common Connector attributes listed + above.

+ +
AttributeDescription
acceptCount +

The maximum queue length for incoming connection requests when + all possible request processing threads are in use. Any requests + received when the queue is full will be refused. The default + value is 100.

+
acceptorThreadCount +

The number of threads to be used to accept connections. Increase this + value on a multi CPU machine, although you would never really need more + than 2. Also, with a lot of non keep alive connections, you + might want to increase this value as well. Default value is + 1.

+
acceptorThreadPriority +

The priority of the acceptor threads. The threads used to accept + new connections. The default value is 5 (the value of the + java.lang.Thread.NORM_PRIORITY constant). See the JavaDoc + for the java.lang.Thread class for more details on what + this priority means.

+
address +

For servers with more than one IP address, this attribute specifies + which address will be used for listening on the specified port. By + default, the connector will listen on the loopback address. Unless the JVM + is configured otherwise using system properties, the Java based connectors + (BIO, NIO) will listen on both IPv4 and IPv6 addresses when configured + with either 0.0.0.0 or ::. The APR/native + connector will only listen on IPv4 addresses if configured with + 0.0.0.0 and will listen on IPv6 addresses and the equivalent + IPv4 address if present when configured with ::.

+
allowedRequestAttributesPattern +

The AJP protocol passes some information from the reverse proxy to the + AJP connector using request attributes. These attributes are:

+
    +
  • javax.servlet.request.cipher_suite
  • +
  • javax.servlet.request.key_size
  • +
  • javax.servlet.request.ssl_session
  • +
  • javax.servlet.request.X509Certificate
  • +
  • AJP_LOCAL_ADDR
  • +
  • AJP_REMOTE_PORT
  • +
  • AJP_SSL_PROTOCOL
  • +
  • JK_LB_ACTIVATION
  • +
  • CERT_ISSUER (IIS only)
  • +
  • CERT_SUBJECT (IIS only)
  • +
  • CERT_COOKIE (IIS only)
  • +
  • HTTPS_SERVER_SUBJECT (IIS only)
  • +
  • CERT_FLAGS (IIS only)
  • +
  • HTTPS_SECRETKEYSIZE (IIS only)
  • +
  • CERT_SERIALNUMBER (IIS only)
  • +
  • HTTPS_SERVER_ISSUER (IIS only)
  • +
  • HTTPS_KEYSIZE (IIS only)
  • +
+

The AJP protocol supports the passing of arbitrary request attributes. + Requests containing arbitrary request attributes will be rejected with a + 403 response unless the entire attribute name matches this regular + expression. If not specified, the default value is null.

+
bindOnInit +

Controls when the socket used by the connector is bound. By default it + is bound when the connector is initiated and unbound when the connector is + destroyed. If set to false, the socket will be bound when the + connector is started and unbound when it is stopped.

+
clientCertProvider +

When client certificate information is presented in a form other than + instances of java.security.cert.X509Certificate it needs to + be converted before it can be used and this property controls which JSSE + provider is used to perform the conversion. For example it is used with + the AJP connectors, the HTTP APR connector and + with the + org.apache.catalina.valves.SSLValve.If not specified, the default + provider will be used.

+
connectionLinger +

The number of seconds during which the sockets used by this + Connector will linger when they are closed. The default + value is -1 which disables socket linger.

+
connectionTimeout +

The number of milliseconds this Connector will wait, + after accepting a connection, for the request URI line to be + presented. The default value for AJP protocol connectors + is -1 (i.e. infinite).

+
executor +

A reference to the name in an Executor + element. If this attribute is set, and the named executor exists, the + connector will use the executor, and all the other thread attributes will + be ignored. Note that if a shared executor is not specified for a + connector then the connector will use a private, internal executor to + provide the thread pool.

+
executorTerminationTimeoutMillis +

The time that the private internal executor will wait for request + processing threads to terminate before continuing with the process of + stopping the connector. If not set, the default is 0 (zero) + for the BIO connector and 5000 (5 seconds) for the NIO and + APR/native connectors.

+
keepAliveTimeout +

The number of milliseconds this Connector will wait for + another AJP request before closing the connection. + The default value is to use the value that has been set for the + connectionTimeout attribute.

+
maxConnections +

The maximum number of connections that the server will accept and + process at any given time. When this number has been reached, the server + will accept, but not process, one further connection. This additional + connection be blocked until the number of connections being processed + falls below maxConnections at which point the server will + start accepting and processing new connections again. Note that once the + limit has been reached, the operating system may still accept connections + based on the acceptCount setting. The default value varies by + connector type. For BIO the default is the value of + maxThreads unless an Executor + is used in which case the default will be the value of maxThreads from the + executor. For NIO the default is 10000. + For APR/native, the default is 8192.

+

For NIO only, setting the value to -1, will disable the + maxConnections feature and connections will not be counted.

+
maxCookieCount +

The maximum number of cookies that are permitted for a request. A value + of less than zero means no limit. If not specified, a default value of 200 + will be used.

+
maxThreads +

The maximum number of request processing threads to be created + by this Connector, which therefore determines the + maximum number of simultaneous requests that can be handled. If + not specified, this attribute is set to 200. If an executor is associated + with this connector, this attribute is ignored as the connector will + execute tasks using the executor rather than an internal thread pool. Note + that if an executor is configured any value set for this attribute will be + recorded correctly but it will be reported (e.g. via JMX) as + -1 to make clear that it is not used.

+
minSpareThreads +

The minimum number of threads always kept running. This includes both + active and idle threads. If not specified, the default of 10 + is used. If an executor is associated with this connector, this attribute + is ignored as the connector will execute tasks using the executor rather + than an internal thread pool. Note that if an executor is configured any + value set for this attribute will be recorded correctly but it will be + reported (e.g. via JMX) as -1 to make clear that it is not + used.

+
packetSize +

This attribute sets the maximum AJP packet size in Bytes. The maximum + value is 65536. It should be the same as the max_packet_size + directive configured for mod_jk. Normally it is not necessary to change + the maximum packet size. Problems with the default value have been + reported when sending certificates or certificate chains. The default + value is 8192. If set to less than 8192 then the setting will ignored and + the default value of 8192 used.

+
processorCache +

The protocol handler caches Processor objects to speed up performance. + This setting dictates how many of these objects get cached. + -1 means unlimited, default is 200. If not using + Servlet 3.0 asynchronous processing, a good default is to use the same as + the maxThreads setting. If using Servlet 3.0 asynchronous processing, a + good default is to use the larger of maxThreads and the maximum number of + expected concurrent requests (synchronous and asynchronous).

+
secret +

Only requests from workers with this secret keyword will be accepted. + The default value is null. This attribute must be specified + with a non-null, non-zero length value unless + secretRequired is explicitly configured to be + false. If this attribute is configured with a non-null, + non-zero length value then the workers must provide a + matching value else the request will be rejected irrespective of the + setting of secretRequired.

+
secretRequired +

If this attribute is true, the AJP Connector will only + start if the secret attribute is configured with a + non-null, non-zero length value. This attribute only controls whether + the secret attribute is required to be specified for the + AJP Connector to start. It does not control whether + workers are required to provide the secret. The default value is + true. This attribute should only be set to false + when the Connector is used on a trusted network.

+
tcpNoDelay +

If set to true, the TCP_NO_DELAY option will be + set on the server socket, which improves performance under most + circumstances. This is set to true by default.

+
threadPriority +

The priority of the request processing threads within the JVM. + The default value is 5 (the value of the + java.lang.Thread.NORM_PRIORITY constant). See the JavaDoc + for the java.lang.Thread class for more details on what + this priority means.If an executor is associated + with this connector, this attribute is ignored as the connector will + execute tasks using the executor rather than an internal thread pool. Note + that if an executor is configured any value set for this attribute will be + recorded correctly but it will be reported (e.g. via JMX) as + -1 to make clear that it is not used.

+
tomcatAuthentication +

If set to true, the authentication will be done in Tomcat. + Otherwise, the authenticated principal will be propagated from the native + webserver and used for authorization in Tomcat.

+

The web server must send the user principal (username) as a request + attribute named REMOTE_USER.

+

Note that this principal will have no roles associated with it.

+

The default value is true. If + tomcatAuthorization is set to true this + attribute has no effect.

+
tomcatAuthorization +

If set to true, the authenticated principal will be + propagated from the native webserver and considered already authenticated + in Tomcat. If the web application has one or more security constraints, + authorization will then be performed by Tomcat and roles assigned to the + authenticated principal. If the appropriate Tomcat Realm for the request + does not recognise the provided user name, a Principal will be still be + created but it will have no roles. The default value is + false.

+
+ +
+ +
Java TCP socket attributes
+ +

The BIO and NIO implementation support the following Java TCP socket + attributes in addition to the common Connector and HTTP attributes listed + above.

+ +
AttributeDescription
socket.rxBufSize +

(int)The socket receive buffer (SO_RCVBUF) size in bytes. JVM default + used if not set.

+
socket.txBufSize +

(int)The socket send buffer (SO_SNDBUF) size in bytes. JVM default + used if not set. Care should be taken if explicitly setting this value. + Very poor performance has been observed on some JVMs with values less + than ~8k.

+
socket.tcpNoDelay +

(bool)This is equivalent to standard attribute + tcpNoDelay.

+
socket.soKeepAlive +

(bool)Boolean value for the socket's keep alive setting + (SO_KEEPALIVE). JVM default used if not set.

+
socket.ooBInline +

(bool)Boolean value for the socket OOBINLINE setting. JVM default + used if not set.

+
socket.soReuseAddress +

(bool)Boolean value for the sockets reuse address option + (SO_REUSEADDR). JVM default used if not set.

+
socket.soLingerOn +

(bool)Boolean value for the sockets so linger option (SO_LINGER). + A value for the standard attribute connectionLinger + that is >=0 is equivalent to setting this to true. + A value for the standard attribute connectionLinger + that is <0 is equivalent to setting this to false. + Both this attribute and soLingerTime must be set else the + JVM defaults will be used for both.

+
socket.soLingerTime +

(int)Value in seconds for the sockets so linger option (SO_LINGER). + This is equivalent to standard attribute + connectionLinger. + Both this attribute and soLingerOn must be set else the + JVM defaults will be used for both.

+
socket.soTimeout +

This is equivalent to standard attribute + connectionTimeout.

+
socket.performanceConnectionTime +

(int)The first value for the performance settings. See + Socket Performance Options + All three performance attributes must be set else the JVM defaults will + be used for all three.

+
socket.performanceLatency +

(int)The second value for the performance settings. See + Socket Performance Options + All three performance attributes must be set else the JVM defaults will + be used for all three.

+
socket.performanceBandwidth +

(int)The third value for the performance settings. See + Socket Performance Options + All three performance attributes must be set else the JVM defaults will + be used for all three.

+
socket.unlockTimeout +

(int) The timeout for a socket unlock. When a connector is stopped, it will try to release the acceptor thread by opening a connector to itself. + The default value is 250 and the value is in milliseconds

+
+
+ +
NIO specific configuration
+ +

The following attributes are specific to the NIO connector.

+ +
AttributeDescription
socket.directBuffer +

(bool)Boolean value, whether to use direct ByteBuffers or java mapped + ByteBuffers. Default is false.
+ When you are using direct buffers, make sure you allocate the + appropriate amount of memory for the direct memory space. On Sun's JDK + that would be something like -XX:MaxDirectMemorySize=256m. +

+
socket.appReadBufSize +

(int)Each connection that is opened up in Tomcat get associated with + a read ByteBuffer. This attribute controls the size of this buffer. By + default this read buffer is sized at 8192 bytes. For lower + concurrency, you can increase this to buffer more data. For an extreme + amount of keep alive connections, decrease this number or increase your + heap size.

+
socket.appWriteBufSize +

(int)Each connection that is opened up in Tomcat get associated with + a write ByteBuffer. This attribute controls the size of this buffer. By + default this write buffer is sized at 8192 bytes. For low + concurrency you can increase this to buffer more response data. For an + extreme amount of keep alive connections, decrease this number or + increase your heap size.
+ The default value here is pretty low, you should up it if you are not + dealing with tens of thousands concurrent connections.

+
socket.bufferPool +

(int)The NIO connector uses a class called NioChannel that holds + elements linked to a socket. To reduce garbage collection, the NIO + connector caches these channel objects. This value specifies the size of + this cache. The default value is 500, and represents that + the cache will hold 500 NioChannel objects. Other values are + -1 for unlimited cache and 0 for no cache.

+
socket.bufferPoolSize +

(int)The NioChannel pool can also be size based, not used object + based. The size is calculated as follows:
+ NioChannel + buffer size = read buffer size + write buffer size
+ SecureNioChannel buffer size = application read buffer size + + application write buffer size + network read buffer size + + network write buffer size
+ The value is in bytes, the default value is 1024*1024*100 + (100MB).

+
socket.processorCache +

(int)Tomcat will cache SocketProcessor objects to reduce garbage + collection. The integer value specifies how many objects to keep in the + cache at most. The default is 500. Other values are + -1 for unlimited cache and 0 for no cache.

+
socket.keyCache +

(int)Tomcat will cache KeyAttachment objects to reduce garbage + collection. The integer value specifies how many objects to keep in the + cache at most. The default is 500. Other values are + -1 for unlimited cache and 0 for no cache.

+
socket.eventCache +

(int)Tomcat will cache PollerEvent objects to reduce garbage + collection. The integer value specifies how many objects to keep in the + cache at most. The default is 500. Other values are + -1 for unlimited cache and 0 for no cache.

+
selectorPool.maxSelectors +

(int)The max selectors to be used in the pool, to reduce selector + contention. Use this option when the command line + org.apache.tomcat.util.net.NioSelectorShared value is set + to false. Default value is 200.

+
selectorPool.maxSpareSelectors +

(int)The max spare selectors to be used in the pool, to reduce + selector contention. When a selector is returned to the pool, the system + can decide to keep it or let it be GC'd. Use this option when the + command line org.apache.tomcat.util.net.NioSelectorShared + value is set to false. Default value is -1 (unlimited).

+
command-line-options +

The following command line options are available for the NIO + connector:
+ -Dorg.apache.tomcat.util.net.NioSelectorShared=true|false + - default is true. Set this value to false if you wish to + use a selector for each thread. When you set it to false, you can + control the size of the pool of selectors by using the + selectorPool.maxSelectors attribute.

+
+
+ +
APR/native specific configuration
+ +

The APR/native implementation supports the following attributes in + addition to the common Connector and AJP attributes listed above.

+ +
AttributeDescription
pollTime +

Duration of a poll call in microseconds. Lowering this value will + slightly decrease latency of connections being kept alive in some cases + , but will use more CPU as more poll calls are being made. The default + value is 2000 (2ms). +

+
pollerSize +

Amount of sockets that the poller responsible for polling kept alive + connections can hold at a given time. Extra connections will be closed + right away. The default value is 8192, corresponding to 8192 keep-alive + connections.

+
+ +
+ +
Nested Components
+ +

None at this time.

+ +
Special Features
+ +
Proxy Support
+ +

The proxyName and proxyPort attributes can + be used when Tomcat is run behind a proxy server. These attributes + modify the values returned to web applications that call the + request.getServerName() and request.getServerPort() + methods, which are often used to construct absolute URLs for redirects. + Without configuring these attributes, the values returned would reflect + the server name and port on which the connection from the proxy server + was received, rather than the server name and port to whom the client + directed the original request.

+ +

For more information, see the + Proxy Support HOW-TO.

+ +
+ +
Connector Comparison
+ +

Below is a small chart that shows how the connectors differ.

+

+                       Java Blocking Connector   Java Nio Blocking Connector   APR/native Connector
+                                 BIO                         NIO                       APR
+    Classname                AjpProtocol               AjpNioProtocol           AjpAprProtocol
+    Tomcat Version           3.x onwards                 7.x onwards              5.5.x onwards
+    Support Polling              NO                          YES                       YES
+    Polling Size                 N/A                   maxConnections             maxConnections
+    Read Request Headers      Blocking                    Blocking                   Blocking
+    Read Request Body         Blocking                    Blocking                   Blocking
+    Write Response            Blocking                    Blocking                   Blocking
+    Wait for next Request     Blocking                  Non Blocking               Non Blocking
+    Max Connections        maxConnections              maxConnections             maxConnections
+
+    
+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/automatic-deployment.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/automatic-deployment.html new file mode 100644 index 0000000..67c5ac6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/automatic-deployment.html @@ -0,0 +1,575 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - Automatic Deployment - Use cases

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

Automatic Deployment - Use cases

Table of Contents
+ +
Introduction
+ +

This page defines the expected behaviour of the automatic deployer in many + typical use cases. This is a complex area of Tomcat's functionality. + While any difference between this document and Tomcat's behaviour is a + bug, the fix may be to change this document, Tomcat's behaviour or + both.

+ +
Key
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TermDescription
XMLAn XML configuration file located in the Host's + configBase. It must contain a single <Context> element + and may contain optional nested elements. It does not define an + explicit docBase attribute. It represents a single web + application. It is often referred to as a context.xml file.
XML+EWAn XML configuration file located in the Host's + configBase. It must contain a single <Context> element + and may contain optional nested elements. It includes an explicit + docBase attribute that points to an external WAR. It + represents a single web application. It is often referred to as a + context.xml file.
XML+EDAn XML configuration file located in the Host's + configBase. It must contain a single <Context> element + and may contain optional nested elements. It includes an explicit + docBase attribute that points to an external directory. It + represents a single web application. It is often referred to as a + context.xml file.
WARA WAR file located in the Host's appBase. The WAR does + not include an embedded context.xml file.
WAR+XMLA WAR file located in the Host's appBase. The WAR does + include an embedded context.xml file.
DIRA directory located in the Host's appBase. The directory + does not include an embedded context.xml file.
DIR+XMLA directory located in the Host's appBase. The directory + does include an embedded context.xml file.
redeployThe Context object that represents the web application is destroyed + and a new Context object is created. If present and permitted by the + configuration, this new Context object is created by parsing the + context.xml file. The web.xml file is parsed during the application + start process. Any sessions stored in the standard Manager in the + default configuration will not be persisted. Any requests to the web + application during the redeploy will be handled as if the web + application is not deployed.
reloadThe Context object that represents the web application is stopped and + then started. The web.xml file is parsed during the application start + process. Any sessions stored in the standard Manager in the default + configuration will not be persisted. Any requests to the web + application during the reload will be held until the reload completes + at which point they will continue using the reloaded web application. +
+ +
New files
+ +

This section describes Tomcat's behaviour when the automatic + deployment process discovers a new web application.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Starting artifact(s)Configuration SettingsResult
deployXMLcopyXMLunpackWARsXMLWARDIRNotes
XMLeithereithereitherYNN1, 2, 3
XML+EWeithereitherfalseYNN1
XML+EWeithereithertrueYNY1
XML+EDeithereithereitherYNN1, 2
WAR+XMLfalseeitherfalseNYN4
WAR+XMLfalseeithertrueNYY4
WAR+XMLtruefalsefalseNYN
WAR+XMLtruefalsetrueNYY
WAR+XMLtruetruefalseYYN
WAR+XMLtruetruetrueYYY
WAReithereitherfalseNYN
WAReithereithertrueNYY
DIR+XMLfalseeithereitherNNY4
DIR+XMLtruefalseeitherNNY
DIR+XMLtruetrueeitherYNY
DIRfalseeithereitherNNY
+ +
Deleted files
+ +

This section describes Tomcat's behaviour when the automatic + deployment process detects that a web application file has been deleted.

+ +

When a file is deleted or modified any redeploy resources that are listed + after the modified/deleted resource are themselves deleted (and possibly + re-created). The order of redeploy resources is:

+ +
    +
  1. WAR
  2. +
  3. DIR
  4. +
  5. XML
  6. +
  7. global resources
  8. +
+ +

There are some exceptions to the deletion rule above:

+ +
    +
  • global resources are never deleted
  • +
  • external resources are never deleted
  • +
  • if the WAR or DIR has been modified then the XML file is only deleted if + copyXML is true and deployXML is + true
  • +
+ +

In the following table:

+ +
    +
  • '-' means "unchanged from not present". i.e. the artifact wasn't present + before the change and isn't present after it either. '-' rather than 'N' + is used to focus attention on what changes.
  • +
  • 'R' means that the directory is re-created by expanding the WAR file. + This will only happen if unpackWARs is true.
  • +
  • 'XW' means that the if the WAR contains a META-INF/context.xml file it + will be extracted and placed in the Host's configBase. + This only happens if copyXML is true and + deployXML is true.
  • +
  • 'XD' means that the if the directory contains a META-INF/context.xml + file it will be copied to the Host's configBase. This only + happens if copyXML is true and deployXML + is true.
  • +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Artifacts presentArtifact removedArtifacts remaining
XMLWARDIRXMLWARDIRNotes
NNYDIR--N
NYNWAR-N-
NYYDIR-YR
NYYWAR-NN
YNNXMLN--
YNYDIRN-N5
YNYXMLXD-Y
YYNWARNN-5
YYNXMLXWY-
YYYDIRXWYR
YYYWARNNN
YYYXMLXWYY
YY (external)NWARYN-3
YY (external)NXMLNY (external)-6
YNY (external)DIRY-N3
YNY (external)XMLN-Y (external)6
YY (external)YDIRYY (external)R
YY (external)YWARYNN3
YY (external)YXMLNY (external)N6
+ +
Modified files
+ +

This section describes Tomcat's behaviour when the automatic + deployment process detects that a web application file has been modified.

+ +

In the following table:

+ +
    +
  • '-' means "unchanged from not present". i.e. the artifact wasn't present + before the change and isn't present after it either. '-' rather than 'N' + is used to focus attention on what changes.
  • +
  • 'M' means that the artifact has been modified.
  • +
  • 'R' means that the directory is deleted and re-created by expanding the + WAR file. This will only happen if unpackWARs is + true.
  • +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Artifacts presentArtifact modifiedArtifacts remaining
XMLWARDIRXMLWARDIRAction
NNYDIR--MNone
NYNWAR-M-Redeploy
NYYDIR-YMNone
NYYWAR-MRRedeploy
YNNXMLM--Redeploy
YNYDIRY-MNone
YNYXMLM-YRedeploy
YYNWARYM-Reload
YYNXMLMY-Redeploy
YYYDIRYYMNone
YYYWARYMRReload
YYYXMLMYYRedeploy
YY(external)NWARYM(external)-Reload
YY(external)NXMLMY(external)-Redeploy
YNY(external)DIRY-M(external)None
YNY(external)XMLM-Y(external)Redeploy
YY(external)YDIRYY(external)MNone
YY(external)YWARYM(external)RReload
YY(external)YXMLMY(external)YRedeploy
+ +
Added files
+ +

This is treated as if the added file has been modified with the following + additional actions:

+ +
    +
  • If a WAR is added, any DIR is removed and may be recreated depending on + unpackWARs.
  • +
  • If an XML file is added that refers to an external docBase any + WAR or DIR in the appBase will be removed. The DIR may be recreated if + the external resource is a WAR and unpackWARs is true.
  • +
  • If a DIR is added when a WAR already exists and unpackWARs is + false, the DIR will be ignored but a warning will be + logged when the DIR is first detected. If the WAR is removed, the DIR + will be left and may be deployed via automatic deployment.
  • +
  • If a WAR is added to the appBase when an external WAR already + exists, the WAR in the appBase will be ignored but a warning + will be logged when the WAR in the appBase is first detected. + If the external WAR is removed, the WAR in the appBase will be + left and may be deployed via automatic deployment.
  • +
  • If an XML file is added to the META-INF directory of an application + deployed from that DIR, the application will always be redeployed. The + result will be the same as for a new deployment.
  • +
+ +
Notes
+ +
    +
  1. deployXML and copyXML are ignored since an XML file + was discovered in the configBase.
  2. +
  3. unpackWARs is ignored since there is no WAR file.
  4. +
  5. The context will fail to start because there is no content in the + expected docBase.
  6. +
  7. The web application fails to deploy because it contains an embedded + META-INF/context.xml, deployXML is false and an + XML has not been provided in the configBase.
  8. +
  9. The XML file is only deleted if copyXML is true + and deployXML is true.
  10. +
  11. Although the external resource is still present, the web application is + fully undeployed as Tomcat has no knowledge of the external resource. +
  12. +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-channel.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-channel.html new file mode 100644 index 0000000..035b205 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-channel.html @@ -0,0 +1,157 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Cluster Channel object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Cluster Channel object

Table of Contents
+ +
Introduction
+ The cluster channel is the main component of a small framework we've nicknamed Apache Tribes.
+ The channel manages a set of sub components and together they create a group communication framework.
+ This framework is then used internally by the components that need to send messages between different Tomcat instances. +
+ A few examples of these components would be the SimpleTcpCluster that does the messaging for the DeltaManager, + or the BackupManager that uses a different replication strategy. The ReplicatedContext object does also + use the channel object to communicate context attribute changes. +
Nested Components
+

Channel/Membership:
+ The Membership component is responsible for auto discovering new nodes in the cluster + and also to provide for notifications for any nodes that have not responded with a heartbeat. + The default implementation uses multicast.
+ In the membership component you configure how your nodes, aka. members, are to be discovered and/or + divided up. + You can always find out more about Apache Tribes +

+

Channel/Sender:
+ The Sender component manages all outbound connections and data messages that are sent + over the network from one node to another. + This component allows messages to be sent in parallel. + The default implementation uses TCP client sockets, and socket tuning for outgoing messages are + configured here.
+ You can always find out more about Apache Tribes +

+

Channel/Sender/Transport:
+ The Transport component is the bottom IO layer for the sender component. + The default implementation uses non-blocking TCP client sockets.
+ You can always find out more about Apache Tribes +

+

Channel/Receiver:
+ The receiver component listens for messages from other nodes. + Here you will configure the cluster thread pool, as it will dispatch incoming + messages to a thread pool for faster processing. + The default implementation uses non-blocking TCP server sockets.
+ You can always find out more about Apache Tribes +

+

Channel/Interceptor:
+ The channel will send messages through an interceptor stack. Because of this, you have the ability to + customize the way messages are sent and received, and even how membership is handled.
+ You can always find out more about Apache Tribes +

+
Attributes
+ +
Common Attributes
+ +
AttributeDescription
className + The default value here is org.apache.catalina.tribes.group.GroupChannel and is + currently the only implementation available. +
+ + +
+ +
org.apache.catalina.tribes.group.GroupChannel Attributes
+ +
AttributeDescription
heartbeat + Flag whether the channel manages its own heartbeat. + If set to true, the channel start a local thread for the heart beat. + If set this flag to false, you must set SimpleTcpCluster#heartbeatBackgroundEnabled + to true. default value is true. +
heartbeatSleeptime + If heartbeat == true, specifies the interval of heartbeat thread in milliseconds. + The default is 5000 (5 seconds). +
optionCheck + If set to true, the GroupChannel will check the option flags that each + interceptor is using. Reports an error if two interceptor share the same + flag. The default is false. +
+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-deployer.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-deployer.html new file mode 100644 index 0000000..6da23ab --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-deployer.html @@ -0,0 +1,138 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Cluster Deployer object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Cluster Deployer object

Table of Contents
+ +
Introduction
+

The Farm War Deployer can deploy and undeploy web applications on the other + nodes in the cluster.

+

Note: FarmWarDeployer can be configured at host level + cluster only. +

+
org.apache.catalina.ha.deploy.FarmWarDeployer
+ +
Attributes
+ +
AttributeDescription
className + The cluster deployer class, currently only one is available, + org.apache.catalina.ha.deploy.FarmWarDeployer. +
deployDir + Deployment directory. This is the pathname of a directory where deploy + the web applications. You may specify an absolute pathname, or a + pathname that is relative to the $CATALINA_BASE directory. In the + current implementation, this attribute must be the same value as the + Host's appBase. +
tempDir + The temporaryDirectory to store binary data when downloading a war from + the cluster. You may specify an absolute pathname, or a pathname that is + relative to the $CATALINA_BASE directory. +
watchDir + This is the pathname of a directory where watch for changes(add/modify/remove) + of web applications. You may specify an absolute pathname, or a pathname + that is relative to the $CATALINA_BASE directory. + Note: if watchEnabled is false, this + attribute will have no effect. +
watchEnabled + Set to true if you want to watch for changes of web applications. + Only when this attribute set to true, you can trigger a deploy/undeploy + of web applications. The flag's value defaults to false. +
processDeployFrequency + Frequency of the Farm watchDir check. Cluster wide deployment will be + done once for the specified amount of backgroundProcess calls (ie, the + lower the amount, the most often the checks will occur). The minimum + value is 1, and the default value is 2. + Note: if watchEnabled is false, this + attribute will have no effect. +
maxValidTime + The maximum valid time(in seconds) of FileMessageFactory. + FileMessageFactory will be removed immediately after receiving the + complete WAR file but when failing to receive a FileMessage which was + sent dividing, FileMessageFactory will leak without being removed. + FileMessageFactory that is leaking will be automatically removed after + maxValidTime. If a negative value specified, FileMessageFactory will + never be removed. If the attribute is not provided, a default of 300 + seconds (5 minutes) is used. +
+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-interceptor.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-interceptor.html new file mode 100644 index 0000000..23ecc45 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-interceptor.html @@ -0,0 +1,322 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Channel Interceptor object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Channel Interceptor object

Table of Contents
+ +
Introduction
+

+ Apache Tribes supports an interceptor architecture to intercept both messages and membership notifications. + This architecture allows decoupling of logic and opens the way for some very useful feature add ons. +

+
Available Interceptors
+
    +
  • org.apache.catalina.tribes.group.interceptors.TcpFailureDetector
  • +
  • org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.MessageDispatchInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.NonBlockingCoordinator
  • +
  • org.apache.catalina.tribes.group.interceptors.OrderInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.SimpleCoordinator
  • +
  • org.apache.catalina.tribes.group.interceptors.StaticMembershipInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.TwoPhaseCommitInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.DomainFilterInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.FragmentationInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.GzipInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.TcpPingInterceptor
  • +
  • org.apache.catalina.tribes.group.interceptors.EncryptInterceptor
  • +
+
Static Membership
+

+ In addition to dynamic discovery, Apache Tribes also supports static membership, with membership verification. + To achieve this add the org.apache.catalina.tribes.group.interceptors.StaticMembershipInterceptor + after the org.apache.catalina.tribes.group.interceptors.TcpFailureDetector interceptor. + Inside the StaticMembershipInterceptor you can add the static members you wish to have. + The TcpFailureDetector will do a health check on the static members,and also monitor them for crashes + so they will have the same level of notification mechanism as the members that are automatically discovered.

+
     <Interceptor className="org.apache.catalina.tribes.group.interceptors.StaticMembershipInterceptor">
+       <LocalMember className="org.apache.catalina.tribes.membership.StaticMember"
+                  domain="staging-cluster"
+                  uniqueId="{1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,1}"/>
+       <Member className="org.apache.catalina.tribes.membership.StaticMember"
+                  port="5678"
+                  securePort="-1"
+                  host="tomcat01.mydomain.com"
+                  domain="staging-cluster"
+                  uniqueId="{0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15}"/>
+     </Interceptor>
+
Attributes
+ +
Common Attributes
+
AttributeDescription
className + Required, as there is no default +
optionFlag + If you want the interceptor to trigger on certain message depending on the message's option flag, + you can setup the interceptors flag here. + The default value is 0, meaning this interceptor will trigger on all messages. +
+
+ +
org.apache.catalina.tribes.group.interceptors.DomainFilterInterceptor Attributes
+
AttributeDescription
domain + The logical cluster domain that this Interceptor accepts. + Two different type of values are possible:
+ 1. Regular string values like "staging-domain" or "tomcat-cluster" will be converted into bytes + using ISO-8859-1 encoding.
+ 2. byte array in string form, for example {216,123,12,3}
+
logInterval + This value indicates the interval for logging for messages from different domains. + The default is 100, which means that to log per 100 messages. +
+
+
org.apache.catalina.tribes.group.interceptors.FragmentationInterceptor Attributes
+
AttributeDescription
expire + How long do we keep the fragments in memory and wait for the rest to arrive. + The default is 60000 ms. +
maxSize + The maximum message size in bytes. If the message size exceeds this value, this interceptor fragments the message and sends them. + If it is less than this value, this interceptor does not fragment the message and sent in as one message. The default is 1024*100. +
+
+
org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor Attributes
+
AttributeDescription
className + Required, This dispatcher uses JDK 1.5 java.util.concurrent package +
optionFlag + The default and hard coded value is 8 (org.apache.catalina.tribes.Channel.SEND_OPTIONS_ASYNCHRONOUS). + The dispatcher will trigger on this value only, as it is predefined by Tribes. + The other attributes are inherited from its base class org.apache.catalina.tribes.group.interceptors.MessageDispatchInterceptor. +
maxThreads + The maximum number of threads in this pool, default is 10. +
maxSpareThreads + The number of threads to keep in the pool, default is 2. +
keepAliveTime + Maximum number of milliseconds of until Idle thread terminates. Default value is 5000(5 seconds). +
+
+
org.apache.catalina.tribes.group.interceptors.MessageDispatchInterceptor Attributes
+
AttributeDescription
className + Required, Same implementation as MessageDispatch15Interceptor, but with JDK 1.4 compliance. +
optionFlag + The default and hard coded value is 8 (org.apache.catalina.tribes.Channel.SEND_OPTIONS_ASYNCHRONOUS). + The dispatcher will trigger on this value only, as it is predefined by Tribes. +
alwaysSend + What behavior should be executed when the dispatch queue is full. If true (default), then the message is + is sent synchronously, if false an error is thrown. +
maxQueueSize + Size in bytes of the dispatch queue, the default value is 1024*1024*64 (64MB) sets the maximum queue size for the dispatch queue + if the queue fills up, one can trigger the behavior, if alwaysSend is set to true, the message will be sent synchronously + if the flag is false, an error is thrown +
+
+
org.apache.catalina.tribes.group.interceptors.TcpFailureDetector Attributes
+
AttributeDescription
connectTimeout + Specifies the timeout, in milliseconds, to use when attempting a TCP connection + to the suspect node. Default is 1000. +
performSendTest + If true is set, send a test message to the suspect node. Default is true. +
performReadTest + If true is set, read the response of the test message that sent. Default is false. + Note: if performSendTest is false, this attribute will have no effect. +
readTestTimeout + Specifies the timeout, in milliseconds, to use when performing a read test + to the suspicious node. Default is 5000. +
removeSuspectsTimeout + The maximum time(in seconds) for remove from removeSuspects. Member of + removeSuspects will be automatically removed after removeSuspectsTimeout. + If a negative value specified, the removeSuspects members never be + removed until disappeared really. If the attribute is not provided, + a default of 300 seconds (5 minutes) is used. +
+
+
org.apache.catalina.tribes.group.interceptors.TcpPingInterceptor Attributes
+
AttributeDescription
interval + If useThread == true, defines the interval of sending a ping message. + default is 1000 ms. +
useThread + Flag of whether to start a thread for sending a ping message. + If set to true, this interceptor will start a local thread for sending a ping message. + if set to false, channel heartbeat will send a ping message. + default is false. +
+
+
org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor Attributes
+
AttributeDescription
interval + Defines the interval in number of messages when we are to report the throughput statistics. + The report is logged to the org.apache.juli.logging.LogFactory.getLog(ThroughputInterceptor.class) + logger under the INFO level. + Default value is to report every 10000 messages. +
+
+
org.apache.catalina.tribes.group.interceptors.EncryptInterceptor Attributes
+

+ The EncryptInterceptor adds encryption to the channel messages carrying + session data between nodes. Added in Tomcat 7.0.100. +

+

+ If using the TcpFailureDetector, the EncryptInterceptor + must be inserted into the interceptor chain before the + TcpFailureDetector. This is because when validating cluster + members, TcpFailureDetector writes channel data directly + to the other members without using the remainder of the interceptor chain, + but on the receiving side, the message still goes through the chain (in reverse). + Because of this asymmetry, the EncryptInterceptor must execute + before the TcpFailureDetector on the sender and after + it on the receiver, otherwise message corruption will occur. +

+
AttributeDescription
encryptionAlgorithm + The encryption algorithm to be used, including the mode and padding. Please see + https://docs.oracle.com/javase/8/docs/technotes/guides/security/StandardNames.html + for the standard JCA names that can be used. + + The mode is currently required to be CBC. + + The length of the key will specify the flavor of the encryption algorithm + to be used, if applicable (e.g. AES-128 versus AES-256). + + The default algorithm is AES/CBC/PKCS5Padding. +
encryptionKey + The key to be used with the encryption algorithm. + + The key should be specified as hex-encoded bytes of the appropriate + length for the algorithm (e.g. 16 bytes / 32 characters / 128 bits for + AES-128, 32 bytes / 64 characters / 256 bits for AES-256, etc.). +
+
+
Nested Components
+ +
StaticMember Attributes
+

LocalMember:
+ Static member that is the local member of the static cluster group. +

+
AttributeDescription
className + Only one implementation available:org.apache.catalina.tribes.membership.StaticMember +
port + There is no need to set. + The value of this attribute inherits from the cluster receiver setting. +
securePort + There is no need to set. + The value of this attribute inherits from the cluster receiver setting. +
host + There is no need to set. + The value of this attribute inherits from the cluster receiver setting. +
domain + The logical cluster domain for that this static member listens for cluster messages. + Two different type of values are possible:
+ 1. Regular string values like "staging-domain" or "tomcat-cluster" will be converted into bytes + using ISO-8859-1 encoding. + 2. byte array in string form, for example {216,123,12,3}
+
uniqueId + A universally uniqueId for this static member. + The values must be 16 bytes in the following form:
+ 1. byte array in string form, for example {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15}
+
+ +

Member:
+ Static member that add to the static cluster group. +

+
AttributeDescription
className + Only one implementation available:org.apache.catalina.tribes.membership.StaticMember +
port + The port that this static member listens to for cluster messages +
securePort + The secure port this static member listens to for encrypted cluster messages + default value is -1, this value means the member is not listening on a secure port +
host + The host (or network interface) that this static member listens for cluster messages. + Three different type of values are possible:
+ 1. IP address in the form of "216.123.1.23"
+ 2. Hostnames like "tomcat01.mydomain.com" or "tomcat01" as long as they resolve correctly
+ 3. byte array in string form, for example {216,123,12,3}
+
domain + The logical cluster domain for that this static member listens for cluster messages. + Two different type of values are possible:
+ 1. Regular string values like "staging-domain" or "tomcat-cluster" will be converted into bytes + using ISO-8859-1 encoding.
+ 2. byte array in string form, for example {216,123,12,3}
+
uniqueId + A universally uniqueId for this static member. + The values must be 16 bytes in the following form:
+ 1. byte array in string form, for example {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15}
+
+
+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-listener.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-listener.html new file mode 100644 index 0000000..428207c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-listener.html @@ -0,0 +1,115 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The ClusterListener object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The ClusterListener object

Table of Contents
+ +
Introduction
+

+ The org.apache.catalina.ha.ClusterListener base class + lets you listen in on messages that are received by the Cluster component. +

+ +
org.apache.catalina.ha.session.ClusterSessionListener
+

+ When using the DeltaManager, the messages are received by the Cluster object and are propagated to the + to the manager through this listener. +

+
org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener
+

+ Listens for session Id changes. This listener is only used if you are using mod_jk + along with the jvmRoute attribute where the session Id can change. + In the event of a change, the JvmRouteBinderValve will broadcast the + session change and it will get picked up by this listener. +

+
Attributes
+ +
Common Attributes
+ +
AttributeDescription
className + +
+ + +
+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-manager.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-manager.html new file mode 100644 index 0000000..079de85 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-manager.html @@ -0,0 +1,324 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The ClusterManager object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The ClusterManager object

Table of Contents
+ +
Introduction
+

A cluster manager is an extension to Tomcat's session manager interface, + org.apache.catalina.Manager. + A cluster manager must implement the + org.apache.catalina.ha.ClusterManager and is solely responsible + for how the session is replicated.
+ There are currently two different managers, the + org.apache.catalina.ha.session.DeltaManager replicates deltas of + session data to all members in the cluster. This implementation is proven and + works very well, but has a limitation as it requires the cluster members to be + homogeneous, all nodes must deploy the same applications and be exact + replicas. The org.apache.catalina.ha.session.BackupManager also + replicates deltas but only to one backup node. The location of the backup node + is known to all nodes in the cluster. It also supports heterogeneous + deployments, so the manager knows at what locations the web application is + deployed.

+
The <Manager>
+

The <Manager> element defined inside the + <Cluster> element is the template defined for all web + applications that are marked <distributable/> in their + web.xml file. However, you can still override the manager + implementation on a per web application basis, by putting the + <Manager> inside the <Context> element + either in the context.xml file or the + server.xml file.

+
Attributes
+
Common Attributes
+
AttributeDescription
className +
name + The name of this cluster manager, the name is used to identify a + session manager on a node. The name might get modified by the + Cluster element to make it unique in the container. +
notifyListenersOnReplication + Set to true if you wish to have session listeners notified + when session attributes are being replicated or removed across Tomcat + nodes in the cluster. +
expireSessionsOnShutdown + When a web application is being shutdown, Tomcat issues an expire call + to each session to notify all the listeners. If you wish for all + sessions to expire on all nodes when a shutdown occurs on one node, set + this value to true. Default value is false. +
maxInactiveInterval +

Deprecated: This should be configured via the + Context.

+

The initial maximum time interval, in seconds, + between client requests before a session is invalidated. A negative value + will result in sessions never timing out. If the attribute is not provided, + a default of 1800 seconds (30 minutes) is used.

+

This attribute provides the initial value whenever a + new session is created, but the interval may be dynamically + varied by a servlet via the + setMaxInactiveInterval method of the HttpSession object.

+
sessionIdLength +

The length of session ids created by this Manager, measured in bytes, + excluding subsequent conversion to a hexadecimal string and + excluding any JVM route information used for load balancing. + The default is 16. You should set the length on a nested + SessionIdGenerator element instead.

+
processExpiresFrequency +

Frequency of the session expiration, and related manager operations. + Manager operations will be done once for the specified amount of + backgroundProcess calls (i.e., the lower the amount, the more often the + checks will occur). The minimum value is 1, and the default value is 6. +

+
secureRandomClass +

Name of the Java class that extends + java.security.SecureRandom to use to generate session IDs. + If not specified, the default value is + java.security.SecureRandom.

+
secureRandomProvider +

Name of the provider to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the Manager + will use the platform default provider and the default algorithm. If not + specified, the platform default provider will be used.

+
secureRandomAlgorithm +

Name of the algorithm to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the Manager + will use the platform default provider and the default algorithm. If not + specified, the default algorithm of SHA1PRNG will be used. If the + default algorithm is not supported, the platform default will be used. + To specify that the platform default should be used, do not set the + secureRandomProvider attribute and set this attribute to the empty + string.

+
recordAllActions +

Flag whether send all actions for session across Tomcat cluster + nodes. If set to false, if already done something to the same attribute, + make sure don't send multiple actions across Tomcat cluster nodes. + In that case, sends only the actions that have been added at last. + Default is false.

+
+
+
org.apache.catalina.ha.session.DeltaManager Attributes
+
AttributeDescription
expireSessionsOnShutdown + When a web application is being shutdown, Tomcat issues an expire call + to each session to notify all the listeners. If you wish for all + sessions to expire on all nodes when a shutdown occurs on one node, set + this value to true. + Default value is false. +
maxActiveSessions + The maximum number of active sessions that will be created by this + Manager, or -1 (the default) for no limit. For this manager, all + sessions are counted as active sessions irrespective if whether or not + the current node is the primary node for the session. +
notifySessionListenersOnReplication + Set to true if you wish to have session listeners notified + when sessions are created and expired across Tomcat nodes in the + cluster. +
notifyContainerListenersOnReplication + Set to true if you wish to have container listeners notified + across Tomcat nodes in the cluster. +
stateTransferTimeout + The time in seconds to wait for a session state transfer to complete + from another node when a node is starting up. + Default value is 60 seconds. +
sendAllSessions + Flag whether send sessions as split blocks. + If set to true, send all sessions as one big block. + If set to false, send sessions as split blocks. + Default value is true. +
sendAllSessionsSize + The number of sessions in a session block message. This value is + effective only when sendAllSessions is false. + Default is 1000. +
sendAllSessionsWaitTime + Wait time between sending of session block messages. This value is + effective only when sendAllSessions is false. + Default is 2000 milliseconds. +
sessionAttributeNameFilter +

A regular expression used to filter which session attributes will be + replicated. An attribute will only be replicated if its name matches + this pattern. If the pattern is zero length or null, all + attributes are eligible for replication. The pattern is anchored so the + session attribute name must fully match the pattern. As an example, the + value (userName|sessionHistory) will only replicate the + two session attributes named userName and + sessionHistory. If not specified, the default value of + null will be used.

+
sessionAttributeValueClassNameFilter +

A regular expression used to filter which session attributes will be + replicated. An attribute will only be replicated if the implementation + class name of the value matches this pattern. If the pattern is zero + length or null, all attributes are eligible for + replication. The pattern is anchored so the fully qualified class name + must fully match the pattern. If not specified, the default value of + null will be used unless a SecurityManager is + enabled in which case the default will be + java\\.lang\\.(?:Boolean|Integer|Long|Number|String).

+
stateTimestampDrop + When this node sends a GET_ALL_SESSIONS message to other + node, all session messages that are received as a response are queued. + If this attribute is set to true, the received session + messages (except any GET_ALL_SESSIONS sent by other nodes) + are filtered by their timestamp. A message is dropped if it is not a + GET_ALL_SESSIONS message and its timestamp is earlier than + the timestamp of our GET_ALL_SESSIONS message. + If set to false, all queued session messages are handled. + Default is true. +
warnOnSessionAttributeFilterFailure +

If sessionAttributeNameFilter or + sessionAttributeValueClassNameFilter blocks an + attribute, should this be logged at WARN level? If + WARN level logging is disabled then it will be logged at + DEBUG. The default value of this attribute is + false unless a SecurityManager is enabled in + which case the default will be true.

+
+
+
org.apache.catalina.ha.session.BackupManager Attributes
+
AttributeDescription
mapSendOptions + The backup manager uses a replicated map, this map is sending and + receiving messages. You can setup the flag for how this map is sending + messages, the default value is 6(synchronous).
+ Note that if you use asynchronous messaging it is possible for update + messages for a session to be processed by the receiving node in a + different order to the order in which they were sent. +
maxActiveSessions + The maximum number of active sessions that will be created by this + Manager, or -1 (the default) for no limit. For this manager, only + sessions where the current node is the primary node for the session are + considered active sessions. +
rpcTimeout + Timeout for RPC message used for broadcast and transfer state from + another map. + Default value is 15000 milliseconds. +
sessionAttributeNameFilter +

A regular expression used to filter which session attributes will be + replicated. An attribute will only be replicated if its name matches + this pattern. If the pattern is zero length or null, all + attributes are eligible for replication. The pattern is anchored so the + session attribute name must fully match the pattern. As an example, the + value (userName|sessionHistory) will only replicate the + two session attributes named userName and + sessionHistory. If not specified, the default value of + null will be used.

+
sessionAttributeValueClassNameFilter +

A regular expression used to filter which session attributes will be + replicated. An attribute will only be replicated if the implementation + class name of the value matches this pattern. If the pattern is zero + length or null, all attributes are eligible for + replication. The pattern is anchored so the fully qualified class name + must fully match the pattern. If not specified, the default value of + null will be used unless a SecurityManager is + enabled in which case the default will be + java\\.lang\\.(?:Boolean|Integer|Long|Number|String).

+
terminateOnStartFailure + Set to true if you wish to terminate replication map when replication + map fails to start. If replication map is terminated, associated context + will fail to start. If you set this attribute to false, replication map + does not end. It will try to join the map membership in the heartbeat. + Default value is false . +
warnOnSessionAttributeFilterFailure +

If sessionAttributeNameFilter or + sessionAttributeValueClassNameFilter blocks an + attribute, should this be logged at WARN level? If + WARN level logging is disabled then it will be logged at + DEBUG. The default value of this attribute is + false unless a SecurityManager is enabled in + which case the default will be true.

+
accessTimeout + The timeout for a ping message. If a remote map does not respond within + this timeout period, its regarded as disappeared. + Default value is 5000 milliseconds. +
+
+
Nested Components
+

All Manager Implementations

+

All Manager implementations allow nesting of a + <SessionIdGenerator> element. It defines + the behavior of session id generation. All implementations + of the SessionIdGenerator allow the + following attributes: +

+
AttributeDescription
sessionIdLength +

The length of the session ID may be changed with the + sessionIdLength attribute. +

+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-membership.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-membership.html new file mode 100644 index 0000000..52f6933 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-membership.html @@ -0,0 +1,194 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Cluster Membership object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Cluster Membership object

Table of Contents
+ +
Introduction
+

+ The membership component in the Apache Tribes Channel is responsible + for dynamic discovery of other members(nodes) in the cluster. +

+
Default Implementation
+

+ The default implementation of the cluster group notification is built on top of multicast heartbeats + sent using UDP packets to a multicast IP address. + Cluster members are grouped together by using the same multicast address/port combination. + Each member sends out a heartbeat with a given interval (frequency), and this + heartbeat is used for dynamic discovery. + In a similar fashion, if a heartbeat has not been received in a timeframe specified by dropTime + ms. a member is considered suspect and the channel and any membership listener will be notified. +

+
Attributes
+ +
Multicast Attributes
+ +
AttributeDescription
className +

+ The default value is org.apache.catalina.tribes.membership.McastService + and is currently the only implementation. + This implementation uses multicast heartbeats for member discovery. +

+
address +

+ The multicast address that the membership will broadcast its presence and listen + for other heartbeats on. The default value is 228.0.0.4 + Make sure your network is enabled for multicast traffic.
+ The multicast address, in conjunction with the port is what + creates a cluster group. To divide up your farm into several different group, or to + split up QA from production, change the port or the address +
Previously known as mcastAddr. +

+
port +

+ The multicast port, the default value is 45564
+ The multicast port, in conjunction with the address is what + creates a cluster group. To divide up your farm into several different group, or to + split up QA from production, change the port or the address +

+
frequency +

+ The frequency in milliseconds in which heartbeats are sent out. The default value is 500 ms.
+ In most cases the default value is sufficient. Changing this value, simply changes the interval in between heartbeats. +

+
dropTime +

+ The membership component will time out members and notify the Channel if a member fails to send a heartbeat within + a give time. The default value is 3000 ms. This means, that if a heartbeat is not received from a + member in that timeframe, the membership component will notify the cluster of this.
+ On a high latency network you may wish to increase this value, to protect against false positives.
+ Apache Tribes also provides a TcpFailureDetector that will + verify a timeout using a TCP connection when a heartbeat timeout has occurred. This protects against false positives. +

+
bind +

+ Use this attribute if you wish to bind your multicast traffic to a specific network interface. + By default, or when this attribute is unset, it tries to bind to 0.0.0.0 and sometimes on multihomed hosts + this becomes a problem. +

+
ttl +

+ The time-to-live setting for the multicast heartbeats. + This setting should be a value between 0 and 255. The default value is VM implementation specific. +

+
domain +

+ Apache Tribes has the ability to logically group members into domains, by using this domain attribute. + The org.apache.catalina.tribes.Member.getDomain() method returns the value specified here. +

+
soTimeout +

+ The sending and receiving of heartbeats is done on a single thread, hence to avoid blocking this thread forever, + you can control the SO_TIMEOUT value on this socket.
+ If a value smaller or equal to 0 is presented, the code will default this value to frequency +

+
recoveryEnabled +

+ In case of a network failure, Java multicast socket don't transparently fail over, instead the socket will continuously + throw IOException upon each receive request. When recoveryEnabled is set to true, this will close the multicast socket + and open a new socket with the same properties as defined above.
+ The default is true.
+

+
recoveryCounter +

+ When recoveryEnabled==true this value indicates how many + times an error has to occur before recovery is attempted. The default is + 10.
+

+
recoverySleepTime +

+ When recoveryEnabled==true this value indicates how long time (in milliseconds) + the system will sleep in between recovery attempts, until it recovers successfully. + The default is 5000 (5 seconds).
+

+
localLoopbackDisabled +

+ Membership uses multicast, it will call java.net.MulticastSocket.setLoopbackMode(localLoopbackDisabled). + When localLoopbackDisabled==true multicast messages will not reach other nodes on the same local machine. + The default is false.
+

+
+ + +
+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-receiver.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-receiver.html new file mode 100644 index 0000000..ccbd98f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-receiver.html @@ -0,0 +1,190 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Cluster Receiver object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Cluster Receiver object

Table of Contents
+ +
Introduction
+

+ The receiver component is responsible for receiving cluster messages. + As you might notice through the configuration, is that the receiving of messages + and sending of messages are two different components, this is different from many other + frameworks, but there is a good reason for it, to decouple the logic for how messages are sent from + how messages are received.
+ The receiver is very much like the Tomcat Connector, its the base of the thread pool + for incoming cluster messages. The receiver is straight forward, but all the socket settings + for incoming traffic are managed here. +

+
Blocking vs Non-Blocking Receiver
+

+ The receiver supports both a non blocking, org.apache.catalina.tribes.transport.nio.NioReceiver, and a + blocking, org.apache.catalina.tribes.transport.bio.BioReceiver. It is preferred to use the non blocking receiver + to be able to grow your cluster without running into thread starvation.
+ Using the non blocking receiver allows you to with a very limited thread count to serve a large number of messages. + Usually the rule is to use 1 thread per node in the cluster for small clusters, and then depending on your message frequency + and your hardware, you'll find an optimal number of threads peak out at a certain number. +

+
Attributes
+
Common Attributes
+
AttributeDescription
className + The implementation of the receiver component. Two implementations available, + org.apache.catalina.tribes.transport.nio.NioReceiver and + org.apache.catalina.tribes.transport.bio.BioReceiver.
+ The org.apache.catalina.tribes.transport.nio.NioReceiver is the + preferred implementation +
address + The address (network interface) to listen for incoming traffic. + Same as the bind address. The default value is auto and translates to + java.net.InetAddress.getLocalHost().getHostAddress(). +
direct + Possible values are true or false. + Set to true if you want the receiver to use direct bytebuffers when reading data + from the sockets. +
port + The listen port for incoming data. The default value is 4000. + To avoid port conflicts the receiver will automatically bind to a free port within the range of + port <= bindPort < port+autoBind + So for example, if port is 4000, and autoBind is set to 10, then the receiver will open up + a server socket on the first available port in the range 4000-4009. +
autoBind + Default value is 100. + Use this value if you wish to automatically avoid port conflicts the cluster receiver will try to open a + server socket on the port attribute port, and then work up autoBind number of times. +
securePort + The secure listen port. This port is SSL enabled. If this attribute is omitted no SSL port is opened up. + There default value is unset, meaning there is no SSL socket available. +
udpPort + The UDP listen port. If this attribute is omitted no UDP port is opened up. + There default value is unset, meaning there is no UDP listener available. +
selectorTimeout + The value in milliseconds for the polling timeout in the NioReceiver. On older versions of the JDK + there have been bugs, that should all now be cleared out where the selector never woke up. + The default value is a very high 5000 milliseconds. +
maxThreads + The maximum number of threads in the receiver thread pool. The default value is 15 + Adjust this value relative to the number of nodes in the cluster, the number of messages being exchanged and + the hardware you are running on. A higher value doesn't mean more efficiency, tune this value according to your + own test results. +
minThreads + Minimum number of threads to be created when the receiver is started up. Default value is 6 +
maxIdleTime + Maximum number of milliseconds of until Idle thread terminates. Default value is 60000 milliseconds. +
ooBInline + Boolean value for the socket OOBINLINE option. Possible values are true or false. +
rxBufSize + The receiver buffer size on the receiving sockets. Value is in bytes, the default value is 43800 bytes. +
txBufSize + The sending buffer size on the receiving sockets. Value is in bytes, the default value is 25188 bytes. +
udpRxBufSize + The receive buffer size on the datagram socket. + Default value is 25188 bytes. +
udpTxBufSize + The send buffer size on the datagram socket. + Default value is 43800 bytes. +
soKeepAlive + Boolean value for the socket SO_KEEPALIVE option. Possible values are true or false. +
soLingerOn + Boolean value to determine whether to use the SO_LINGER socket option. + Possible values are true or false. Default value is true. +
soLingerTime + Sets the SO_LINGER socket option time value. The value is in seconds. + The default value is 3 seconds. +
soReuseAddress + Boolean value for the socket SO_REUSEADDR option. Possible values are true or false. +
tcpNoDelay + Boolean value for the socket TCP_NODELAY option. Possible values are true or false. + The default value is true +
timeout + Sets the SO_TIMEOUT option on the socket. The value is in milliseconds and the default value is 3000 + milliseconds. +
useBufferPool + Boolean value whether to use a shared buffer pool of cached org.apache.catalina.tribes.io.XByteBuffer + objects. If set to true, the XByteBuffer that is used to pass a message up the channel, will be recycled at the end + of the requests. This means that interceptors in the channel must not maintain a reference to the object + after the org.apache.catalina.tribes.ChannelInterceptor#messageReceived method has exited. +
+
+
NioReceiver
+
+
BioReceiver
+
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-sender.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-sender.html new file mode 100644 index 0000000..e793c24 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-sender.html @@ -0,0 +1,198 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Cluster Sender object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Cluster Sender object

Table of Contents
+ +
Introduction
+

+ The channel sender component is responsible for delivering outgoing cluster messages over the network. + In the default implementation, org.apache.catalina.tribes.transport.ReplicationTransmitter, + the sender is a fairly empty shell with not much logic around a fairly complex <Transport> + component the implements the actual delivery mechanism. +

+
Concurrent Parallel Delivery
+

+ In the default transport implementation, org.apache.catalina.tribes.transport.nio.PooledParallelSender, + Apache Tribes implements what we like to call "Concurrent Parallel Delivery". + This means that we can send a message to more than one destination at the same time(parallel), and + deliver two messages to the same destination at the same time(concurrent). Combine these two and we have + "Concurrent Parallel Delivery". +

+

+ When is this useful? The simplest example we can think of is when part of your code is sending a 10MB message, + like a war file being deployed, and you need to push through a small 10KB message, say a session being replicated, + you don't have to wait for the 10MB message to finish, as a separate thread will push in the small message + transmission at the same time. Currently there is no interrupt, pause or priority mechanism available, but check back soon. +

+
Nested Elements
+

+ The nested element <Transport> is not required, but encouraged, as this is where + you would set all the socket options for the outgoing messages. Please see its attributes below. + There are two implementations, in a similar manner to the receiver, one is non-blocking + based and the other is built using blocking IO.
+ org.apache.catalina.tribes.transport.bio.PooledMultiSender is the blocking implementation and + org.apache.catalina.tribes.transport.nio.PooledParallelSender. + Parallel delivery is not available for the blocking implementation due to the fact that it is blocking a thread on sending data. +

+
Attributes
+
Common Sender Attributes
+
AttributeDescription
className + Required, only available implementation is org.apache.catalina.tribes.transport.ReplicationTransmitter +
+
+
Common Transport Attributes
+
AttributeDescription
className + Required, an implementation of the org.apache.catalina.tribes.transport.MultiPointSender.
+ Non-blocking implementation is org.apache.catalina.tribes.transport.nio.PooledParallelSender
+ Blocking implementation is org.apache.catalina.tribes.transport.bio.PooledMultiSender +
rxBufSize + The receive buffer size on the socket. + Default value is 25188 bytes. +
txBufSize + The send buffer size on the socket. + Default value is 43800 bytes. +
udpRxBufSize + The receive buffer size on the datagram socket. + Default value is 25188 bytes. +
udpTxBufSize + The send buffer size on the datagram socket. + Default value is 43800 bytes. +
directBuffer + Possible values are true or false. + Set to true if you want the receiver to use direct bytebuffers when writing data + to the sockets. Default value is false +
keepAliveCount + The number of requests that can go through the socket before the socket is closed, and reopened + for the next request. The default value is -1, which is unlimited. +
keepAliveTime + The number of milliseconds a connection is kept open after its been opened. + The default value is -1, which is unlimited. +
timeout + Sets the SO_TIMEOUT option on the socket. The value is in milliseconds and the default value is 3000 + milliseconds.(3 seconds) This timeout starts when a message send attempt is starting, until the transfer has been completed. + For the NIO sockets, this will mean, that the caller can guarantee that we will not attempt sending the message + longer than this timeout value. For the blocking IO implementation, this translated directly to the soTimeout.
+ A timeout will not spawn a retry attempt, in order to guarantee the return of the application thread. +
maxRetryAttempts + How many times do we retry a failed message, that received a IOException at the socket level. + The default value is 1, meaning we will retry a message that has failed once. + In other words, we will attempt a message send no more than twice. One is the original send, and one is the + maxRetryAttempts. +
ooBInline + Boolean value for the socket OOBINLINE option. Possible values are true or false. +
soKeepAlive + Boolean value for the socket SO_KEEPALIVE option. Possible values are true or false. +
soLingerOn + Boolean value to determine whether to use the SO_LINGER socket option. + Possible values are true or false. Default value is true. +
soLingerTime + Sets the SO_LINGER socket option time value. The value is in seconds. + The default value is 3 seconds. +
soReuseAddress + Boolean value for the socket SO_REUSEADDR option. Possible values are true or false. +
soTrafficClass + Sets the traffic class level for the socket, the value is between 0 and 255. + Default value is int soTrafficClass = 0x04 | 0x08 | 0x010; + Different values are defined in + java.net.Socket#setTrafficClass(int). +
tcpNoDelay + Boolean value for the socket TCP_NODELAY option. Possible values are true or false. + The default value is true +
throwOnFailedAck + Boolean value, default value is true. + If set to true, the sender will throw a org.apache.catalina.tribes.RemoteProcessException + when we receive a negative ack from the remote member. + Set to false, and Tribes will treat a positive ack the same way as a negative ack, that the message was received. +
+
+
Common PooledSender Attributes
+
AttributeDescription
poolSize + The maximum number of concurrent connections from A to B. + The value is based on a per-destination count. + The default value is 25 +
maxWait + The maximum number of milliseconds that the senderPool will wait when + there are no available senders. The default value is 3000 + milliseconds.(3 seconds). +
+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-valve.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-valve.html new file mode 100644 index 0000000..1a533ad --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster-valve.html @@ -0,0 +1,191 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Cluster Valve object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Cluster Valve object

Table of Contents
+ +
Introduction
+

+ A cluster valve is no different from any other Tomcat Valve. + The cluster valves are interceptors in the invocation chain for HTTP requests, and the clustering implementation + uses these valves to make intelligent decision around data and when data should be replicated. +

+

+ A cluster valve must implement the org.apache.catalina.ha.ClusterValve interface. + This is a simple interface that extends the org.apache.catalina.Valve interface. +

+
org.apache.catalina.ha.tcp.ReplicationValve
+ The ReplicationValve will notify the cluster at the end of an HTTP request + so that the cluster can make a decision whether there is data to be replicated or not. +
Attributes
+
AttributeDescription
className + Set value to org.apache.catalina.ha.tcp.ReplicationValve +
filter + For known file extensions or urls, you can use this Valve to notify the + cluster that the session has not been modified during this request and + the cluster doesn't have to probe the session managers for changes. If + the request matches this filter pattern, the cluster assumes there has + been no session change. An example filter would look like + filter=".*\.gif|.*\.js|.*\.jpeg|.*\.jpg|.*\.png|.*\.htm|.*\.html|.*\.css|.*\.txt" + . The filter is a regular expression using + java.util.regex. +
primaryIndicator + Boolean value, so to true, and the replication valve will insert a request attribute with the name + defined by the primaryIndicatorName attribute. + The value inserted into the request attribute is either Boolean.TRUE or + Boolean.FALSE +
primaryIndicatorName + Default value is org.apache.catalina.ha.tcp.isPrimarySession + The value defined here is the name of the request attribute that contains the boolean value + if the session is primary on this server or not. +
statistics + Boolean value. Set to true if you want the valve to collect request statistics. + Default value is false +
+
+
org.apache.catalina.ha.session.JvmRouteBinderValve
+ In case of a mod_jk failover, the JvmRouteBinderValve will replace the + jvmWorker attribute in the session Id, to make future requests stick to this + node. If you want fallback capability, don't enable this valve, but if you want your failover to stick, + and for mod_jk not to have to keep probing the node that went down, you use this valve. +
Attributes
+
AttributeDescription
className + org.apache.catalina.ha.session.JvmRouteBinderValve +
enabled + Default value is true + Runtime attribute to turn on and off turn over of the session's jvmRoute value. +
sessionIdAttribute + Old sessionid before failover is registered in request attributes with this attribute. + Default attribute name is org.apache.catalina.ha.session.JvmRouteOriginalSessionID. +
+
+
org.apache.catalina.ha.authenticator.ClusterSingleSignOn
+ The ClusterSingleSignOn supports feature of single sign on in cluster. + By using ClusterSingleSignOn, the security identity authenticated + by one web application is recognized by other web applications on the same virtual host, + and it is propagated to other nodes in the cluster. + +

See the Single Sign On special + feature on the Host element for more information.

+ +

Note: ClusterSingleSignOn can be configured at host level cluster only. +

+ +
Attributes
+
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.ha.authenticator.ClusterSingleSignOn.

+
cookieDomain +

Sets the host domain to be used for sso cookies.

+
mapSendOptions +

The Valve uses a replicated map. You can setup the flag for how this + map sends messages. The default value is 6 (synchronous). + Note that if you use asynchronous messaging it is possible for update + messages to be processed by the receiving node in a different order to + the order in which they were sent.

+
requireReauthentication +

Default false. Flag to determine whether each request needs to be + reauthenticated to the security Realm. If "true", this + Valve uses cached security credentials (username and password) to + reauthenticate to the Realm each request associated + with an SSO session. If "false", the Valve can itself authenticate + requests based on the presence of a valid SSO cookie, without + rechecking with the Realm.

+
rpcTimeout +

The Valve uses a replicated map. This is the timeout for messages + that transfer state to/from the other nodes in the cluster. If not + specified, a default value of 15000 milliseconds is used. +

+
terminateOnStartFailure +

Set to true if you wish this Valve to fail if the + underlying replication fails to start. If the Valve fails, then the + associated container will fail to start. If you set this attribute to + false, and the underlying replications fails to start, the Valve will + start and it will attempt to join the cluster and start replication as + part of the heartbeat process. If not specified, the default value of + false is used.

+
accessTimeout + The timeout for a ping message. If a remote map does not respond within + this timeout period, its regarded as disappeared. + Default value is 5000 milliseconds. +
+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster.html new file mode 100644 index 0000000..68add5e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/cluster.html @@ -0,0 +1,208 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Cluster object

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Cluster object

Table of Contents
+ +
Introduction
+

+ The tomcat cluster implementation provides session replication, context attribute replication and + cluster wide WAR file deployment. + While the Cluster configuration is fairly complex, the default configuration will work + for most people out of the box.

+ The Tomcat Cluster implementation is very extensible, and hence we have exposed a myriad of options, + making the configuration seem like a lot, but don't lose faith, instead you have a tremendous control + over what is going on.

+
Security
+ +

The cluster implementation is written on the basis that a secure, trusted +network is used for all of the cluster related network traffic. It is not safe +to run a cluster on a insecure, untrusted network.

+ +

There are many options for providing a secure, trusted network for use by a +Tomcat cluster. These include:

+ + +
Engine vs Host placement
+

+ You can place the <Cluster> element inside either the <Engine> + container or the <Host> container.
+ Placing it in the engine, means that you will support clustering in all virtual hosts of Tomcat, + and share the messaging component. When you place the <Cluster> inside the <Engine> + element, the cluster will append the host name of each session manager to the managers name so that two contexts with + the same name but sitting inside two different hosts will be distinguishable. +

+
Context Attribute Replication
+

To configure context attribute replication, simply do this by swapping out the context implementation + used for your application context.

+
<Context className="org.apache.catalina.ha.context.ReplicatedContext"/>
+

+ This context extends the Tomcat StandardContext + so all the options from the base implementation are valid. +

+
Nested Components
+

Manager:
+ The session manager element identifies what kind of session manager is used in this cluster implementation. + This manager configuration is identical to the one you would use in a regular <Context> configuration. +
The default value is the org.apache.catalina.ha.session.DeltaManager that is closely coupled with + the SimpleTcpCluster implementation. Other managers like the org.apache.catalina.ha.session.BackupManager + are/could be loosely coupled and don't rely on the SimpleTcpCluster for its data replication. +

+

Channel:
+ The Channel and its sub components are all part of the IO layer + for the cluster group, and is a module in it's own that we have nick named "Tribes" +
+ Any configuring and tuning of the network layer, the messaging and the membership logic + will be done in the channel and its nested components. + You can always find out more about Apache Tribes +

+

Valve:
+ The Tomcat Cluster implementation uses Tomcat Valves to + track when requests enter and exit the servlet container. It uses these valves to be able to make + intelligent decisions on when to replicate data, which is always at the end of a request. +

+

Deployer:
+ The Deployer component is the Tomcat Farm Deployer. It allows you to deploy and undeploy applications + cluster wide. +

+

ClusterListener:
+ ClusterListener's are used to track messages sent and received using the SimpleTcpCluster. + If you wish to track messages, you can add a listener here, or you can add a valve to the channel object. +

+
Deprecated configuration options
+

+ Deprecated settings: In the previous version of Tomcat you were able to control session + manager settings using manager.<property>=value. + This has been discontinued, as the way it was written interferes with + the ability to support multiple different manager classes under one cluster implementation, + as the same properties might have the different effect on different managers. +

+
Attributes
+
SimpleTcpCluster Attributes
+
AttributeDescription
className +

The main cluster class, currently only one is available, + org.apache.catalina.ha.tcp.SimpleTcpCluster +

+
channelSendOptions +

The Tribes channel send options, default is 8.
+ This option is used to set the flag that all messages sent through the + SimpleTcpCluster uses. The flag decides how the messages are sent, and is a simple logical OR.

+ +
int options = Channel.SEND_OPTIONS_ASYNCHRONOUS |
+              Channel.SEND_OPTIONS_SYNCHRONIZED_ACK |
+              Channel.SEND_OPTIONS_USE_ACK;
+

Some of the values are:
+ Channel.SEND_OPTIONS_SYNCHRONIZED_ACK = 0x0004
+ Channel.SEND_OPTIONS_ASYNCHRONOUS = 0x0008
+ Channel.SEND_OPTIONS_USE_ACK = 0x0002
+ So to use ACK and ASYNC messaging, the flag would be 10 (8+2) +
+ Note that if you use ASYNC messaging it is possible for update messages + for a session to be processed by the receiving nodes in a different order + to the order in which they were sent.

+
channelStartOptions +

Sets the start and stop flags for the <Channel> object used by the cluster. + The default is Channel.DEFAULT which starts all the channel services, such as + sender, receiver, multicast sender and multicast receiver. + The following flags are available today:

+
Channel.DEFAULT = Channel.SND_RX_SEQ (1) |
+                  Channel.SND_TX_SEQ (2) |
+                  Channel.MBR_RX_SEQ (4) |
+                  Channel.MBR_TX_SEQ (8);
+

To start a channel without multicasting, you would want to use the value Channel.SND_RX_SEQ | Channel.SND_TX_SEQ + that equals to 3. +

+
heartbeatBackgroundEnabled +

Flag whether invoke channel heartbeat at container background thread. Default value is false. + Enable this flag don't forget to disable the channel heartbeat thread. +

+
notifyLifecycleListenerOnFailure +

Flag whether notify LifecycleListeners if all ClusterListener couldn't accept channel message. + Default value is false. +

+
+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/context.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/context.html new file mode 100644 index 0000000..3449edb --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/context.html @@ -0,0 +1,1418 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Context Container

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Context Container

Table of Contents
+ +
Introduction
+ +

+ The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat. +

+ +

The Context element represents a web + application, which is run within a particular virtual host. + Each web application is based on a Web Application Archive + (WAR) file, or a corresponding directory containing the corresponding + unpacked contents, as described in the Servlet Specification (version + 2.2 or later). For more information about web application archives, + you can download the + Servlet + Specification, and review the Tomcat + Application Developer's Guide.

+ +

The web application used to process each HTTP request is selected + by Catalina based on matching the longest possible prefix of the + Request URI against the context path of each defined Context. + Once selected, that Context will select an appropriate servlet to + process the incoming request, according to the servlet mappings defined + by the web application deployment.

+ +

You may define as many Context elements as you + wish. Each such Context MUST have a unique context name within a virtual + host. The context path does not need to be unique (see parallel + deployment below). In addition, a Context must be present with a + context path equal to + a zero-length string. This Context becomes the default + web application for this virtual host, and is used to process all + requests that do not match any other Context's context path.

+ +
Parallel deployment
+

You may deploy multiple versions of a web application with the same + context path at the same time. The rules used to match requests to a + context version are as follows: +

+
    +
  • If no session information is present in the request, use the latest + version.
  • +
  • If session information is present in the request, check the session + manager of each version for a matching session and if one is found, use that + version.
  • +
  • If session information is present in the request but no matching session + can be found, use the latest version.
  • +
+

The Host may be configured (via the + undeployOldVersions) to remove old versions deployed in this way + once they are no longer in use.

+
+ +
Naming
+

When autoDeploy or deployOnStartup operations + are performed by a Host, the name and context path of the web application are + derived from the name(s) of the file(s) that define(s) the web application. + Consequently, the context path may not be defined in a + META-INF/context.xml embedded in the application and there is a + close relationship between the context name, context path, + context version and the base file name (the name minus any + .war or .xml extension) of the file.

+ +

If no version is specified then the context name is always the + same as the context path. If the context path is the empty + string then the base name will be ROOT (always in upper case) + otherwise the base name will be the context path with the + leading '/' removed and any remaining '/' characters replaced with '#'.

+ +

If a version is specified then the context path remains unchanged + and both the context name and the base name have the string + '##' appended to them followed by the version identifier.

+ +

Some examples of these naming conventions are given below.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Context PathContext VersionContext NameBase File NameExample File Names (.xml, .war & directory)
/fooNone/foofoofoo.xml, foo.war, foo
/foo/barNone/foo/barfoo#barfoo#bar.xml, foo#bar.war, foo#bar
Empty StringNoneEmpty StringROOTROOT.xml, ROOT.war, ROOT
/foo42/foo##42foo##42foo##42.xml, foo##42.war, foo##42
/foo/bar42/foo/bar##42foo#bar##42foo#bar##42.xml, foo#bar##42.war, foo#bar##42
Empty String42##42ROOT##42ROOT##42.xml, ROOT##42.war, ROOT##42
+ +

The version component is treated as a String both for + performance reasons and to allow flexibility in versioning schemes. String + comparisons are used to determine version order. If version is not specified, + it is treated as the empty string. + Therefore, + foo.war will be treated as an earlier version than + foo##11.war and + foo##11.war will be treated as an earlier version than + foo##2.war. If using a purely numerical versioning scheme it is + recommended that zero padding is used so that foo##002.war is + treated as an earlier version than foo##011.war. +

+ +

If you want to deploy a WAR file or a directory using a context path that + is not related to the base file name then one of the following options must + be used to prevent double-deployment: +

+
    +
  • Disable autoDeploy and deployOnStartup and define all + Contexts in server.xml
  • +
  • Locate the WAR and/or directory outside of the Host's appBase and use + a context.xml file with a docBase attribute to define it.
  • +
+
+ +
Defining a context
+

It is NOT recommended to place <Context> elements directly in the + server.xml file. This is because it makes modifying the + Context configuration more invasive since the main + conf/server.xml file cannot be reloaded without restarting + Tomcat. Default Context elements (see below) will also + overwrite the configuration of any <Context> elements + placed directly in server.xml. To prevent this, the override + attribute of the <Context> element defined in server.xml should be set + to true.

+ +

Individual Context elements may be explicitly defined: +

+
    +
  • In an individual file at /META-INF/context.xml inside the + application files. Optionally (based on the Host's copyXML attribute) + this may be copied to + $CATALINA_BASE/conf/[enginename]/[hostname]/ and renamed to + application's base file name plus a ".xml" extension.
  • +
  • In individual files (with a ".xml" extension) in the + $CATALINA_BASE/conf/[enginename]/[hostname]/ directory. + The context path and version will be derived from the base name of the file + (the file name less the .xml extension). This file will always take precedence + over any context.xml file packaged in the web application's META-INF + directory.
  • +
  • Inside a Host element in the main + conf/server.xml.
  • +
+ +

Default Context elements may be defined that apply to + multiple web applications. Configuration for an individual web application + will override anything configured in one of these defaults. Any nested + elements, e.g. <Resource> elements, that are defined in a default + Context will be created once for each + Context to which the default applies. They will not be + shared between Context elements. +

+
    +
  • In the $CATALINA_BASE/conf/context.xml file: + the Context element information will be loaded by all web applications.
  • +
  • In the + $CATALINA_BASE/conf/[enginename]/[hostname]/context.xml.default + file: the Context element information will be loaded by all web applications + of that host.
  • +
+ +

With the exception of server.xml, files that define Context + elements may only define a single Context element. +

+ +

In addition to explicitly specified Context elements, there are + several techniques by which Context elements can be created automatically + for you. See + Automatic Application Deployment and + User Web Applications + for more information.

+ +

To define multiple contexts that use a single WAR file or directory, + use one of the options described in the Naming + section above for creating a Context that has a path + that is not related to the base file name.

+
+
Attributes
+ +
Common Attributes
+ +

All implementations of Context + support the following attributes:

+ +
AttributeDescription
allowCasualMultipartParsing +

Set to true if Tomcat should automatically parse + multipart/form-data request bodies when HttpServletRequest.getPart* + or HttpServletRequest.getParameter* is called, even when the + target servlet isn't marked with the @MultipartConfig annotation + (See Servlet Specification 3.0, Section 3.2 for details). + Note that any setting other than false causes Tomcat + to behave in a way that is not technically spec-compliant. + The default is false

+
allowMultipleLeadingForwardSlashInPath +

Tomcat normalises sequences of multiple / characters in + a URI to a single /. This is for consistency with the + behaviour of file systems as URIs are often translated to file system + paths. As a result, the return value of + HttpServletRequest#getContextPath() is expected to start + with multiple / characters for some URIs. This will cause + problems if this value is used directly with + HttpServletResponse#sendRedirect() as redirect paths that + start with // are treated as protocol relative redirects. + To avoid potential issues, Tomcat will collapse multiple leading + / characters at the start of the return value for + HttpServletRequest#getContextPath() to a single + /. This attribute has a default value of false + which enables the collapsing of multiple / characters. To + disable this behaviour, set this attribute to true.

+
altDDName +

The absolute path to the alternative deployment descriptor for this + context. This overrides the default deployment descriptor located at + /WEB-INF/web.xml.

+
backgroundProcessorDelay +

This value represents the delay in seconds between the + invocation of the backgroundProcess method on this context and + its child containers, including all wrappers. + Child containers will not be invoked if their delay value is not + negative (which would mean they are using their own processing + thread). Setting this to a positive value will cause + a thread to be spawn. After waiting the specified amount of time, + the thread will invoke the backgroundProcess method on this host + and all its child containers. A context will use background + processing to perform session expiration and class monitoring for + reloading. If not specified, the default value for this attribute is + -1, which means the context will rely on the background processing + thread of its parent host.

+
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Context interface. + If not specified, the standard value (defined below) will be used.

+
containerSciFilter +

The regular expression that specifies which container provided SCIs + should be filtered out and not used for this context. Matching uses + java.util.regex.Matcher.find() so the regular expression + only has to match a sub-string of the fully qualified class name of the + container provided SCI for it to be filtered out. If not specified, + no filtering will be applied.

+
cookies +

Set to true if you want cookies to be used for + session identifier communication if supported by the client (this + is the default). Set to false if you want to disable + the use of cookies for session identifier communication, and rely + only on URL rewriting by the application.

+
createUploadTargets +

Set to true if Tomcat should attempt to create the + temporary upload location specified in the MultipartConfig + for a Servlet if the location does not already exist. If not specified, + the default value of false will be used.

+
crossContext +

Set to true if you want calls within this application + to ServletContext.getContext() to successfully return a + request dispatcher for other web applications running on this virtual + host. Set to false (the default) in security + conscious environments, to make getContext() always + return null.

+
docBase +

The Document Base (also known as the Context + Root) directory for this web application, or the pathname + to the web application archive file (if this web application is + being executed directly from the WAR file). You may specify + an absolute pathname for this directory or WAR file, or a pathname + that is relative to the appBase directory of the + owning Host.

+

The value of this field must not be set unless the Context element is + defined in server.xml or the docBase is not located under + the Host's appBase.

+

If a symbolic link is used for docBase then changes to the + symbolic link will only be effective after a Tomcat restart or + by undeploying and redeploying the context. A context reload is not + sufficient.

+
dispatchersUseEncodedPaths +

Controls whether paths used in calls to obtain a request dispatcher + ares expected to be encoded. This affects both how Tomcat handles calls + to obtain a request dispatcher as well as how Tomcat generates paths + used to obtain request dispatchers internally. If not specified, the + default value of true is used. When encoding/decoding paths + for a request dispatcher, UTF-8 is always used.

+
failCtxIfServletStartFails +

Set to true to have the context fail its startup if any + servlet that has load-on-startup >=0 fails its own startup.

+

If not specified, the attribute of the same name in the parent Host + configuration is used if specified. Otherwise the default value of + false is used.

+
fireRequestListenersOnForwards +

Set to true to fire any configured + ServletRequestListeners when Tomcat forwards a request. This is + primarily of use to users of CDI frameworks that use + ServletRequestListeners to configure the necessary environment for a + request. If not specified, the default value of false is + used.

+
logEffectiveWebXml +

Set to true if you want the effective web.xml used for a + web application to be logged (at INFO level) when the application + starts. The effective web.xml is the result of combining the + application's web.xml with any defaults configured by Tomcat and any + web-fragment.xml files and annotations discovered. If not specified, the + default value of false is used.

+
mapperContextRootRedirectEnabled +

If enabled, requests for a web application context root will be + redirected (adding a trailing slash) if necessary by the Mapper rather + than the default Servlet. This is more efficient but has the side effect + of confirming that the context path exists. If not specified, the + default value of true is used.

+
mapperDirectoryRedirectEnabled +

If enabled, requests for a web application directory will be + redirected (adding a trailing slash) if necessary by the Mapper rather + than the default Servlet. This is more efficient but has the side effect + of confirming that the directory is exists. If not specified, the + default value of false is used.

+
override +

Set to true to ignore any settings in both the global + or Host default contexts. By default, settings + from a default context will be used but may be overridden by a setting + the same attribute explicitly for the Context.

+
path +

The context path of this web application, which is + matched against the beginning of each request URI to select the + appropriate web application for processing. All of the context paths + within a particular Host must be unique. + If you specify a context path of an empty string (""), you are + defining the default web application for this Host, which + will process all requests not assigned to other Contexts.

+

This attribute must only be used when statically defining a Context + in server.xml. In all other circumstances, the path will be inferred + from the filenames used for either the .xml context file or the docBase. +

+

Even when statically defining a Context in server.xml, this attribute + must not be set unless either the docBase is not located under the + Host's appBase or both + deployOnStartup and autoDeploy are false. If + this rule is not followed, double deployment is likely to result.

+
preemptiveAuthentication +

When set to true and the user presents credentials for a + resource that is not protected by a security constraint, if the + authenticator supports preemptive authentication (the standard + authenticators provided with Tomcat do) then the user' credentials + will be processed. If not specified, the default of false is + used. +

+
privileged +

Set to true to allow this context to use container + servlets, like the manager servlet. Use of the privileged + attribute will change the context's parent class loader to be the + Server class loader rather than the Shared class + loader. Note that in a default installation, the Common class + loader is used for both the Server and the Shared + class loaders.

+
reloadable +

Set to true if you want Catalina to monitor classes in + /WEB-INF/classes/ and /WEB-INF/lib for + changes, and automatically reload the web application if a change + is detected. This feature is very useful during application + development, but it requires significant runtime overhead and is + not recommended for use on deployed production applications. That's + why the default setting for this attribute is false. You + can use the Manager web + application, however, to trigger reloads of deployed applications + on demand.

+
resourceOnlyServlets +

Comma separated list of Servlet names (as used in + /WEB-INF/web.xml) that expect a resource to be present. + Ensures that welcome files associated with Servlets that expect a + resource to be present (such as the JSP Servlet) are not used when there + is no resource present. This prevents issues caused by the clarification + of welcome file mapping in section 10.10 of the Servlet 3.0 + specification. If the + org.apache.catalina.STRICT_SERVLET_COMPLIANCE + system property is set to + true, the default value of this attribute will be the empty + string, else the default value will be jsp.

+
sendRedirectBody +

If true, redirect responses will include a short + response body that includes details of the redirect as recommended by + RFC 2616. This is disabled by default since including a response body + may cause problems for some application component such as compression + filters.

+
sessionCookieDomain +

The domain to be used for all session cookies created for this + context. If set, this overrides any domain set by the web application. + If not set, the value specified by the web application, if any, will be + used.

+
sessionCookieName +

The name to be used for all session cookies created for this + context. If set, this overrides any name set by the web application. + If not set, the value specified by the web application, if any, will be + used, or the name JSESSIONID if the web application does + not explicitly set one.

+
sessionCookiePath +

The path to be used for all session cookies created for this + context. If set, this overrides any path set by the web application. + If not set, the value specified by the web application will be used, or + the context path used if the web application does not explicitly set + one. To configure all web application to use an empty path (this can be + useful for portlet specification implementations) set this attribute to + / in the global CATALINA_BASE/conf/context.xml + file.

+

Note: Once one web application using + sessionCookiePath="/" obtains a session, all + subsequent sessions for any other web application in the same host also + configured with sessionCookiePath="/" will always + use the same session ID. This holds even if the session is invalidated + and a new one created. This makes session fixation protection more + difficult and requires custom, Tomcat specific code to change the + session ID shared by the multiple applications.

+
sessionCookiePathUsesTrailingSlash +

Some browsers, such as Internet Explorer, Safari and Edge, will send + a session cookie for a context with a path of /foo with a + request to /foobar in violation of RFC6265. This could + expose a session ID from an application deployed at /foo to + an application deployed at /foobar. If the application + deployed at /foobar is untrusted, this could create a + security risk. However, it should be noted that RFC 6265, section 8.5 + makes clear that path alone should not be view as sufficient to prevent + untrusted applications accessing cookies from other applications. To + mitigate this risk, this attribute may be set to true and + Tomcat will add a trailing slash to the path associated with the session + cookie so, in the above example, the cookie path becomes /foo/. However, + with a cookie path of /foo/, browsers will no longer send the cookie + with a request to /foo. This should not be a problem unless there is a + servlet mapped to /*. In this case this attribute will need to be set to + false to disable this feature. The default value for this + attribute is false.

+
swallowAbortedUploads +

Set to false if Tomcat should not read any additional request + body data for aborted uploads and instead abort the client connection. + This setting is used in the following situations: +

+
    +
  • the size of the request body is larger than the + maxPostSize configured in the connector
  • +
  • the size limit of a MultiPart upload is reached
  • +
  • the servlet sets the response status to 413 (Request Entity Too + Large)
  • +
+

+ Not reading the additional data will free the request processing thread + more quickly. Unfortunately most HTTP clients will not read the response + if they can not write the full request.

+

The default is true, so additional data will be + read.

+

Note if an error occurs during the request processing that triggers + a 5xx response, any unread request data will always be ignored and the + client connection will be closed once the error response has been + written.

+
swallowOutput +

If the value of this flag is true, the bytes output to + System.out and System.err by the web application will be redirected to + the web application logger. If not specified, the default value + of the flag is false.

+
tldValidation +

If the value of this flag is true, the TLD files + will be XML validated on context startup. If the + org.apache.catalina.STRICT_SERVLET_COMPLIANCE + system property is set to + true, the default value of this attribute will be + true, else the default value will be false. + Setting this attribute to true will incur a performance + penalty.

+
useHttpOnly +

Should the HttpOnly flag be set on session cookies to prevent client + side script from accessing the session ID? Defaults to + true.

+
useRelativeRedirects +

Controls whether HTTP 1.1 and later location headers generated by a + call to + javax.servlet.http.HttpServletResponse#sendRedirect(String) + will use relative or absolute redirects. Relative redirects are more + efficient but may not work with reverse proxies that change the context + path. It should be noted that it is not recommended to use a reverse + proxy to change the context path because of the multiple issues it + creates. Absolute redirects should work with reverse proxies that change + the context path but may cause issues with the + org.apache.catalina.filters.RemoteIpFilter if the filter is + changing the scheme and/or port. If the + org.apache.catalina.STRICT_SERVLET_COMPLIANCE + system property is set to + true, the default value of this attribute will be + false, else the default value will be true. +

+
validateClientProvidedNewSessionId +

When a client provides the ID for a new session, this attribute + controls whether that ID is validated. The only use case for using a + client provided session ID is to have a common session ID across + multiple web applications. Therefore, any client provided session ID + should already exist in another web application. If this check is + enabled, the client provided session ID will only be used if the session + ID exists in at least one other web application for the current host. + Note that the following additional tests are always applied, + irrespective of this setting:

+
    +
  • The session ID is provided by a cookie
  • +
  • The session cookie has a path of {@code /}
  • +
+

If not specified, the default value of true will be + used.

+
wrapperClass +

Java class name of the org.apache.catalina.Wrapper + implementation class that will be used for servlets managed by this + Context. If not specified, a standard default value will be used.

+
xmlBlockExternal +

If the value of this flag is true, the parsing of + web.xml, web-fragment.xml, *.tld, + *.jspx, *.tagx and tagPlugins.xml + files for this web application will not permit external entities to be + loaded. If not specified, the default value of true will + be used.

+
xmlNamespaceAware +

If the value of this flag is true, the parsing of + web.xml and web-fragment.xml files for this + web application will be namespace-aware. Note that *.tld, + *.jspx and *.tagx files are always parsed + using a namespace-aware parser and that the tagPlugins.xml + file (if any) is never parsed using a namespace-aware parser. Note also + that if you turn this flag on, you should probably also turn + xmlValidation on. If the + org.apache.catalina.STRICT_SERVLET_COMPLIANCE + system property is set to + true, the default value of this attribute will be + true, else the default value will be false. + Setting this attribute to true will incur a performance + penalty.

+
xmlValidation +

If the value of this flag is true, the parsing of + web.xml and web-fragment.xml files for this + web application will use a validating parser. If the + org.apache.catalina.STRICT_SERVLET_COMPLIANCE + system property is set to + true, the default value of this attribute will be + true, else the default value will be false. + Setting this attribute to true will incur a performance + penalty.

+
+ +
+ + +
Standard Implementation
+ +

The standard implementation of Context is + org.apache.catalina.core.StandardContext. + It supports the following additional attributes (in addition to the + common attributes listed above):

+ +
AttributeDescription
addWebinfClassesResources +

This attribute controls if, in addition to static resources being + served from META-INF/resources inside web application JAR + files, static resources are also served from + WEB-INF/classes/META-INF/resources. This only applies to + web applications with a major version of 3 or higher. Since this is a + proprietary extension to the Servlet 3 specification, it is disabled by + default. To enable this feature, set the attribute to true. +

+
aliases +

This attribute provides a list of external locations from which to + load resources for this context. The list of aliases should be of + the form "/aliasPath1=docBase1,/aliasPath2=docBase2" where + aliasPathN must include a leading '/' and + docBaseN must be an absolute path to either a .war file or + a directory.

+

Whitespace is permitted around both the , and + = delimiters, and will be trimmed. Therefore, an aliases + attribute with the value "/aliasPath1 = docBase1,
+ /aliasPath2= docBase2"
is equivalent to + "/aliasPath1=docBase1,/aliasPath2=docBase2"

+

A resource will be searched for in the first docBaseN + for which aliasPathN is a leading path segment of the + resource. If there is no such alias, then the resource will be searched + in the usual way.

+

Using '/' as an aliasPath is not allowed. Consider using + docBase instead.

+

These external locations will not be emptied if the context + is un-deployed.

+

A more powerful feature (for development only) is + Virtual webapp.

+
allowLinking +

If the value of this flag is true, symlinks will be + allowed inside the web application, pointing to resources inside or + outside the web application base path. If not specified, the default + value of the flag is false.

+

NOTE: This flag MUST NOT be set to true on the Windows platform + (or any other OS which does not have a case sensitive filesystem), + as it will disable case sensitivity checks, allowing JSP source code + disclosure, among other security problems.

+
antiJARLocking +

If true, the Tomcat classloader will take extra measures to avoid + JAR file locking when resources are accessed inside JARs through URLs. + This will impact startup time of applications, but could prove to be + useful on platforms or configurations where file locking can occur. + If not specified, the default value is false.

+ +

antiJARLocking is a subset of + antiResourceLocking and therefore, to prevent duplicate + work and possible issues, only one of these attributes should be set + to true at any one time.

+
antiResourceLocking +

If true, Tomcat will prevent any file locking. + This will significantly impact startup time of applications, + but allows full webapp hot deploy and undeploy on platforms + or configurations where file locking can occur. + If not specified, the default value is false.

+ +

antiJARLocking is a subset of + antiResourceLocking and therefore, to prevent duplicate + work and possible issues, only one of these attributes should be set + to true at any one time.

+ +

Please note that setting this to true has some side + effects, including the disabling of JSP reloading in a running server: + see + Bugzilla 37668.

+ +

Please note that setting this flag to true in applications that are + outside the appBase for the Host (the webapps directory + by default) will cause the application to be deleted on + Tomcat shutdown. You probably don't want to do this, so think twice + before setting antiResourceLocking=true on a webapp that's outside the + appBase for its Host.

+
cacheMaxSize +

Maximum size of the static resource cache in kilobytes. + If not specified, the default value is 10240 + (10 megabytes).

+
cacheObjectMaxSize +

Maximum size of the static resource that will be placed in the cache. + If not specified, the default value is 512 + (512 kilobytes). If this value is greater than + cacheMaxSize/20 it will be reduced to + cacheMaxSize/20.

+
cacheTTL +

Amount of time in milliseconds between cache entries revalidation. + If not specified, the default value is 5000 + (5 seconds).

+
cachingAllowed +

If the value of this flag is true, the cache for static + resources will be used. If not specified, the default value + of the flag is true.

+
clearReferencesHttpClientKeepAliveThread +

If true and an sun.net.www.http.HttpClient + keep-alive timer thread has been started by this web application and is + still running, Tomcat will change the context class loader for that + thread from the current WebappClassLoader to + WebappClassLoader#parent to prevent a memory leak. Note + that the keep-alive timer thread will stop on its own once the + keep-alives all expire however, on a busy system that might not happen + for some time. If not specified, the default value of + true will be used.

+
clearReferencesObjectStreamClassCaches +

If true, when the web application is stopped Tomcat + looks for SoftReferences to classes loaded by the web + application in the ObjectStreamClass class used for + serialization and clears any SoftReferences it finds. This + feature uses reflection to identify the SoftReferences and + therefore requires that the command line option + -XaddExports:java.base/java.io=ALL-UNNAMED is set + when running on Java 9 and above. If not specified, the default value of + true will be used.

+
clearReferencesRmiTargets +

If true, Tomcat looks for memory leaks associated with + RMI Targets and clears any it finds. This feature uses reflection to + identify the leaks and therefore requires that the command line option + -XaddExports:java.rmi/sun.rmi.transport=ALL-UNNAMED is set + when running on Java 9 and above. Applications without memory leaks + should operate correctly with this attribute set to false. + If not specified, the default value of true will be used.

+
clearReferencesStatic +

If true, Tomcat attempts to null out any static or final + fields from loaded classes when a web application is stopped as a work + around for apparent garbage collection bugs and application coding + errors. There have been some issues reported with log4j when this + is true. Applications without memory leaks using recent + JVMs should operate correctly with this attribute set to + false. If not specified, the default value of + false will be used.

+

This attribute has been deprecated and will be removed in Tomcat + 8.5.

+
clearReferencesStopThreads +

If true, Tomcat attempts to terminate threads that have + been started by the web application. Stopping threads is performed via + the deprecated (for good reason) Thread.stop() method and + is likely to result in instability. As such, enabling this should be + viewed as an option of last resort in a development environment and is + not recommended in a production environment. If not specified, the + default value of false will be used. If this feature is + enabled, web applications may take up to two seconds longer to stop as + executor threads are given up to two seconds to stop gracefully before + Thread.stop() is called on any remaining threads.

+
clearReferencesStopTimerThreads +

If true, Tomcat attempts to terminate + java.util.Timer threads that have been started by the web + application. Unlike standard threads, timer threads can be stopped + safely although there may still be side-effects for the application. If + not specified, the default value of false will be used.

+
clearReferencesThreadLocals +

If true, Tomcat attempts to clear + java.lang.ThreadLocal variables that have been populated + with classes loaded by the web application. If not specified, the + default value of true will be used.

+
copyXML +

Set to true if you want a context XML descriptor + embedded inside the application (located at + /META-INF/context.xml) to be copied to the owning + Host's xmlBase when the application + is deployed. On subsequent starts, the copied context XML descriptor + will be used in preference to any context XML descriptor embedded inside + the application even if the descriptor embedded inside the application + is more recent. The flag's value defaults to false. Note if + the deployXML attribute of the owning + Host is false or if the + copyXML attribute of the owning + Host is true, this attribute will + have no effect.

+
jndiExceptionOnFailedWrite +

If true, any attempt by an application to modify the + provided JNDI context with a call to bind(), unbind(), + createSubContext(), destroySubContext() or close() will trigger a + javax.naming.OperationNotSupportedException as required by + section EE.5.3.4 of the Java EE specification. This exception can be + disabled by setting this attribute to false in which case any calls to + modify the JNDI context will return without making any changes + and methods that return values will return null. If not + specified, the specification compliant default of true will + be used.

+
processTlds +

Whether the context should process TLDs on startup. The default + is true. The false setting is intended for special cases + that know in advance TLDs are not part of the webapp.

+
renewThreadsWhenStoppingContext +

If true, when this context is stopped, Tomcat renews all + the threads from the thread pool that was used to serve this context. + This also requires that the + ThreadLocalLeakPreventionListener be configured in + server.xml and that the threadRenewalDelay + property of the Executor be >=0. If not specified, the + default value of true will be used.

+
unloadDelay +

Number of ms that the container will wait for servlets to unload. + If not specified, the default value is 2000 ms.

+
unpackWAR +

If false, the unpackWARs attribute of + the owning Host will be overridden and the WAR + file will not be unpacked. If true, the value of the owning + Host's unpackWARs + attribute will determine if the WAR is unpacked. If not specified, the + default value is true.

+
useNaming +

Set to true (the default) to have Catalina enable a + JNDI InitialContext for this web application that is + compatible with Java2 Enterprise Edition (J2EE) platform + conventions.

+
workDir +

Pathname to a scratch directory to be provided by this Context + for temporary read-write use by servlets within the associated web + application. This directory will be made visible to servlets in the + web application by a servlet context attribute (of type + java.io.File) named + javax.servlet.context.tempdir as described in the + Servlet Specification. If not specified, a suitable directory + underneath $CATALINA_BASE/work will be provided.

+
+ +
+ + +
Nested Components
+ +

You can nest at most one instance of the following utility components + by nesting a corresponding element inside your Context + element:

+
    +
  • Loader - + Configure the web application class loader that will be used to load + servlet and bean classes for this web application. Normally, the + default configuration of the class loader will be sufficient.
  • +
  • Manager - + Configure the session manager that will be used to create, destroy, + and persist HTTP sessions for this web application. Normally, the + default configuration of the session manager will be sufficient.
  • +
  • Realm - + Configure a realm that will allow its + database of users, and their associated roles, to be utilized solely + for this particular web application. If not specified, this web + application will utilize the Realm associated with the owning + Host or Engine.
  • +
  • Resources - + Configure the resource manager that will be used to access the static + resources associated with this web application. Normally, the + default configuration of the resource manager will be sufficient.
  • +
  • WatchedResource - The auto deployer will monitor the + specified static resource of the web application for updates, and will + reload the web application if it is updated. The content of this element + must be a string.
  • +
+ +
Special Features
+ + +
Logging
+ +

A context is associated with the + org.apache.catalina.core.ContainerBase.[enginename].[hostname].[path] + log category. Note that the brackets are actually part of the name, don't omit them.

+ +
+ + +
Access Logs
+ +

When you run a web server, one of the output files normally generated + is an access log, which generates one line of information for + each request processed by the server, in a standard format. Catalina + includes an optional Valve implementation that + can create access logs in the same standard format created by web servers, + or in any number of custom formats.

+ +

You can ask Catalina to create an access log for all requests + processed by an Engine, + Host, or Context + by nesting a Valve element like this:

+ +
<Context>
+  ...
+  <Valve className="org.apache.catalina.valves.AccessLogValve"
+         prefix="localhost_access_log." suffix=".txt"
+         pattern="common"/>
+  ...
+</Context>
+ +

See Access Logging Valves + for more information on the configuration attributes that are + supported.

+ +
+ + +
Automatic Context Configuration
+ +

If you use the standard Context implementation, + the following configuration steps occur automatically when Catalina + is started, or whenever this web application is reloaded. No special + configuration is required to enable this feature.

+ +
    +
  • If you have not declared your own Loader + element, a standard web application class loader will be configured. +
  • +
  • If you have not declared your own Manager + element, a standard session manager will be configured.
  • +
  • If you have not declared your own Resources + element, a standard resources manager will be configured.
  • +
  • The web application properties listed in conf/web.xml + will be processed as defaults for this web application. This is used + to establish default mappings (such as mapping the *.jsp + extension to the corresponding JSP servlet), and other standard + features that apply to all web applications.
  • +
  • The web application properties listed in the + /WEB-INF/web.xml resource for this web application + will be processed (if this resource exists).
  • +
  • If your web application has specified security constraints that might + require user authentication, an appropriate Authenticator that + implements the login method you have selected will be configured.
  • +
+ +
+ + +
Context Parameters
+ +

You can configure named values that will be made visible to the + web application as servlet context initialization parameters by nesting + <Parameter> elements inside this element. For + example, you can create an initialization parameter like this:

+
<Context>
+  ...
+  <Parameter name="companyName" value="My Company, Incorporated"
+         override="false"/>
+  ...
+</Context>
+ +

This is equivalent to the inclusion of the following element in the + web application deployment descriptor (/WEB-INF/web.xml): +

+
<context-param>
+  <param-name>companyName</param-name>
+  <param-value>My Company, Incorporated</param-value>
+</context-param>
+

but does not require modification of the deployment descriptor + to customize this value.

+ +

The valid attributes for a <Parameter> element + are as follows:

+ +
AttributeDescription
description +

Optional, human-readable description of this context + initialization parameter.

+
name +

The name of the context initialization parameter to be created.

+
override +

Set this to false if you do not want + a <context-param> for the same parameter name, + found in the web application deployment descriptor, to override the + value specified here. By default, overrides are allowed.

+
value +

The parameter value that will be presented to the application + when requested by calling + ServletContext.getInitParameter().

+
+ +
+ + +
Environment Entries
+ +

You can configure named values that will be made visible to the + web application as environment entry resources, by nesting + <Environment> entries inside this element. For + example, you can create an environment entry like this:

+
<Context>
+  ...
+  <Environment name="maxExemptions" value="10"
+         type="java.lang.Integer" override="false"/>
+  ...
+</Context>
+ +

This is equivalent to the inclusion of the following element in the + web application deployment descriptor (/WEB-INF/web.xml): +

+
<env-entry>
+  <env-entry-name>maxExemptions</env-entry-name>
+  <env-entry-value>10</env-entry-value>
+  <env-entry-type>java.lang.Integer</env-entry-type>
+</env-entry>
+

but does not require modification of the deployment descriptor + to customize this value.

+ +

The valid attributes for an <Environment> element + are as follows:

+ +
AttributeDescription
description +

Optional, human-readable description of this environment entry.

+
name +

The name of the environment entry to be created, relative to the + java:comp/env context.

+
override +

Set this to false if you do not want + an <env-entry> for the same environment entry name, + found in the web application deployment descriptor, to override the + value specified here. By default, overrides are allowed.

+
type +

The fully qualified Java class name expected by the web application + for this environment entry. Must be a legal value for + <env-entry-type> in the web application deployment + descriptor.

+
value +

The parameter value that will be presented to the application + when requested from the JNDI context. This value must be convertable + to the Java type defined by the type attribute.

+
+ +
+ + +
Lifecycle Listeners
+ +

If you have implemented a Java object that needs to know when this + Context is started or stopped, you can declare it by + nesting a Listener element inside this element. The + class name you specify must implement the + org.apache.catalina.LifecycleListener interface, and + the class must be packaged in a jar and placed in the + $CATALINA_HOME/lib directory. + It will be notified about the occurrence of the corresponding + lifecycle events. Configuration of such a listener looks like this:

+ +
<Context>
+  ...
+  <Listener className="com.mycompany.mypackage.MyListener" ... >
+  ...
+</Context>
+ +

Note that a Listener can have any number of additional properties + that may be configured from this element. Attribute names are matched + to corresponding JavaBean property names using the standard property + method naming patterns.

+ +
+ + +
Request Filters
+ +

You can ask Catalina to check the IP address, or host name, on every + incoming request directed to the surrounding + Engine, Host, or + Context element. The remote address or name + will be checked against configured "accept" and/or "deny" + filters, which are defined using java.util.regex Regular + Expression syntax. Requests that come from locations that are + not accepted will be rejected with an HTTP "Forbidden" error. + Example filter declarations:

+ +
<Context>
+  ...
+  <Valve className="org.apache.catalina.valves.RemoteHostValve"
+         allow=".*\.mycompany\.com|www\.yourcompany\.com"/>
+  <Valve className="org.apache.catalina.valves.RemoteAddrValve"
+         deny="192\.168\.1\.\d+"/>
+  ...
+</Context>
+ +

See Remote Address Filter + and Remote Host Filter for + more information about the configuration options that are supported.

+ +
+ + +
Resource Definitions
+ +

You can declare the characteristics of the resource + to be returned for JNDI lookups of <resource-ref> and + <resource-env-ref> elements in the web application + deployment descriptor. You MUST also define + the needed resource parameters as attributes of the Resource + element, to configure the object factory to be used (if not known to Tomcat + already), and the properties used to configure that object factory.

+ +

For example, you can create a resource definition like this:

+
<Context>
+  ...
+  <Resource name="jdbc/EmployeeDB" auth="Container"
+            type="javax.sql.DataSource"
+     description="Employees Database for HR Applications"/>
+  ...
+</Context>
+ +

This is equivalent to the inclusion of the following element in the + web application deployment descriptor (/WEB-INF/web.xml):

+
<resource-ref>
+  <description>Employees Database for HR Applications</description>
+  <res-ref-name>jdbc/EmployeeDB</res-ref-name>
+  <res-ref-type>javax.sql.DataSource</res-ref-type>
+  <res-auth>Container</res-auth>
+</resource-ref>
+ +

but does not require modification of the deployment + descriptor to customize this value.

+ +

The valid attributes for a <Resource> element + are as follows:

+ +
AttributeDescription
auth +

Specify whether the web Application code signs on to the + corresponding resource manager programmatically, or whether the + Container will sign on to the resource manager on behalf of the + application. The value of this attribute must be + Application or Container. This + attribute is required if the web application + will use a <resource-ref> element in the web + application deployment descriptor, but is optional if the + application uses a <resource-env-ref> instead.

+
closeMethod +

Name of the zero-argument method to call on a singleton resource when + it is no longer required. This is intended to speed up clean-up of + resources that would otherwise happen as part of garbage collection. + This attribute is ignored if the singleton attribute is + false. If not specified, no default is defined and no close method will + be called.

+

For Apache Commons DBCP 1.x and Apache Tomcat JDBC connection pools + you can use closeMethod="close".

+
description +

Optional, human-readable description of this resource.

+
name +

The name of the resource to be created, relative to the + java:comp/env context.

+
scope +

Specify whether connections obtained through this resource + manager can be shared. The value of this attribute must be + Shareable or Unshareable. By default, + connections are assumed to be shareable.

+
singleton +

Specify whether this resource definition is for a singleton resource, + i.e. one where there is only a single instance of the resource. If this + attribute is true, multiple JNDI lookups for this resource + will return the same object. If this attribute is false, + multiple JNDI lookups for this resource will return different objects. + This attribute must be true for + javax.sql.DataSource resources to enable JMX registration + of the DataSource. The value of this attribute must be true + or false. By default, this attribute is true. +

+
type +

The fully qualified Java class name expected by the web + application when it performs a lookup for this resource.

+
+ + +
+ + +
Resource Links
+ +

This element is used to create a link to a global JNDI resource. Doing + a JNDI lookup on the link name will then return the linked global + resource.

+ +

For example, you can create a resource link like this:

+
<Context>
+  ...
+  <ResourceLink name="linkToGlobalResource"
+            global="simpleValue"
+            type="java.lang.Integer"
+  ...
+</Context>
+ +

The valid attributes for a <ResourceLink> element + are as follows:

+ +
AttributeDescription
global +

The name of the linked global resource in the + global JNDI context.

+
name +

The name of the resource link to be created, relative to the + java:comp/env context.

+
type +

The fully qualified Java class name expected by the web + application when it performs a lookup for this resource link.

+
factory +

The fully qualified Java class name for the class creating these objects. + This class should implement the javax.naming.spi.ObjectFactory interface.

+
+ +

When the attribute factory="org.apache.naming.factory.DataSourceLinkFactory" the resource link can be used with + two additional attributes to allow a shared data source to be used with different credentials. + When these two additional attributes are used in combination with the javax.sql.DataSource + type, different contexts can share a global data source with different credentials. + Under the hood, what happens is that a call to getConnection() + is simply translated to a call + getConnection(username, password) on the global data source. This is an easy way to get code to be transparent to what schemas are being used, + yet be able to control connections (or pools) in the global configuration. +

+
AttributeDescription
username +

username value for the getConnection(username, password) + call on the linked global DataSource. +

+
password +

password value for the getConnection(username, password) + call on the linked global DataSource. +

+
+

Shared Data Source Example:

+

Warning: This feature works only if the global DataSource +supports getConnection(username, password) method. +Apache Commons DBCP pool that +Tomcat uses by default does not support it. See its Javadoc for +BasicDataSource class. +Apache Tomcat JDBC pool does support it, +but by default this support is disabled and can be enabled by +alternateUsernameAllowed attribute. See its documentation +for details.

+
<GlobalNamingResources>
+  ...
+  <Resource name="sharedDataSource"
+            global="sharedDataSource"
+            type="javax.sql.DataSource"
+            factory="org.apache.tomcat.jdbc.pool.DataSourceFactory"
+            alternateUsernameAllowed="true"
+            username="bar"
+            password="barpass"
+            ...
+  ...
+</GlobalNamingResources>
+
+<Context path="/foo"...>
+  ...
+  <ResourceLink
+            name="appDataSource"
+            global="sharedDataSource"
+            type="javax.sql.DataSource"
+            factory="org.apache.naming.factory.DataSourceLinkFactory"
+            username="foo"
+            password="foopass"
+  ...
+</Context>
+<Context path="/bar"...>
+  ...
+  <ResourceLink
+            name="appDataSource"
+            global="sharedDataSource"
+            type="javax.sql.DataSource"
+  ...
+</Context>
+

When a request for getConnection() is made in the + /foo context, the request is translated into + getConnection("foo","foopass"), + while a request in the /bar gets passed straight through.

+
+ +
Transaction
+ +

You can declare the characteristics of the UserTransaction + to be returned for JNDI lookup for java:comp/UserTransaction. + You MUST define an object factory class to instantiate + this object as well as the needed resource parameters as attributes of the + Transaction + element, and the properties used to configure that object factory.

+ +

The valid attributes for the <Transaction> element + are as follows:

+ +
AttributeDescription
factory +

The class name for the JNDI object factory.

+
+ +
+ +
Virtual webapp
+

During development it may be more productive to avoid copying files (static + resources, JSPs, classes, jars...) and configure tomcat to use files from their + source locations. To do that, several customisations of the context configuration are + required:

+
    +
  • The VirtualDirContext implementation of + Resources
  • +
  • The VirtualWebappLoader implementation of + Loader
  • +
  • scanAllDirectories="true" on the JarScanner
  • +
+

To illustrate this feature, here is an example of a standard maven webapp source tree:

+ +
mywebapp/
+         src/
+             main/
+                  java/
+                  resources/
+                  webapp/
+                         WEB-INF/
+                                 classes/
+         target/
+                classes/
+
+ +

To deploy such an application (assuming it also uses the log4j maven artefact), + the context configuration looks like:

+ +
<Context path="/mywebapp" docBase="/Users/theuser/mywebapp/src/main/webapp">
+  <Resources className="org.apache.naming.resources.VirtualDirContext"
+    extraResourcePaths="/WEB-INF/classes=/Users/theuser/mywebapp/target/classes" />
+  <Loader className="org.apache.catalina.loader.VirtualWebappLoader"
+    virtualClasspath="/Users/theuser/mywebapp/target/classes;/Users/theuser/.m2/repository/log4j/log4j/1.2.15/log4j-1.2.15.jar" />
+  <JarScanner scanAllDirectories="true" />
+</Context>
+
+ +

Here is another example where the webapp serves pictures under /pictures and movies + under /movies and also depends on another maven project mylib that would normally + produce a jar to be packaged in WEB-INF/lib:

+ +
mylib/
+      src/
+          main/
+               java/
+               resources/
+                         META-INF/
+                                  resources/
+      target/
+             classes/
+mymovies/
+mypictures/
+mywebapp/
+         src/
+             main/
+                  java/
+                  resources/
+                  webapp/
+                         WEB-INF/
+                                 classes/
+         target/
+                classes/
+
+ +

The configuration is:

+ +
<Context path="/mywebapp" docBase="/Users/theuser/mywebapp/src/main/webapp">
+  <Resources className="org.apache.naming.resources.VirtualDirContext"
+    extraResourcePaths="/WEB-INF/classes=/Users/theuser/mywebapp/target/classes,/pictures=/Users/theuser/mypictures,/movies=/Users/theuser/mymovies" />
+  <Loader className="org.apache.catalina.loader.VirtualWebappLoader"
+   virtualClasspath="/Users/theuser/mywebapp/target/classes;/Users/theuser/mylib/target/classes;/Users/theuser/.m2/repository/log4j/log4j/1.2.15/log4j-1.2.15.jar" />
+  <JarScanner scanAllDirectories="true" />
+</Context>
+
+ +

Note that resources in mylib/target/classes/META-INF/resources/ are mapped to / as + required by servlet 3 specification.

+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/engine.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/engine.html new file mode 100644 index 0000000..51acca1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/engine.html @@ -0,0 +1,286 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Engine Container

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Engine Container

Table of Contents
+ +
Introduction
+ +

The Engine element represents the entire request + processing machinery associated with a particular Catalina + Service. It receives and processes + all requests from one or more Connectors, + and returns the completed response to the Connector for ultimate + transmission back to the client.

+ +

Exactly one Engine element MUST be nested inside + a Service element, following all of the + corresponding Connector elements associated with this Service.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Engine + support the following attributes:

+ +
AttributeDescription
backgroundProcessorDelay +

This value represents the delay in seconds between the + invocation of the backgroundProcess method on this engine and + its child containers, including all hosts and contexts. + Child containers will not be invoked if their delay value is not + negative (which would mean they are using their own processing + thread). Setting this to a positive value will cause + a thread to be spawn. After waiting the specified amount of time, + the thread will invoke the backgroundProcess method on this engine + and all its child containers. If not specified, the default value for + this attribute is 10, which represent a 10 seconds delay.

+
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Engine interface. + If not specified, the standard value (defined below) will be used.

+
defaultHost +

The default host name, which identifies the + Host that will process requests directed + to host names on this server, but which are not configured in + this configuration file. This name MUST match the name + attributes of one of the Host elements + nested immediately inside.

+
jvmRoute +

Identifier which must be used in load balancing scenarios to enable + session affinity. The identifier, which must be unique across all + Tomcat servers which participate in the cluster, will be appended to + the generated session identifier, therefore allowing the front end + proxy to always forward a particular session to the same Tomcat + instance.

+

+ Note that the jvmRoute can also be set using the + jvmRoute system property. The jvmRoute + set in an <Engine> attribute will override + any jvmRoute system property. +

+
name +

Logical name of this Engine, used in log and error messages. When + using multiple Service elements in the same + Server, each Engine MUST be assigned a unique + name.

+
startStopThreads +

The number of threads this Engine will use to start + child Host elements in parallel. The special + value of 0 will result in the value of + Runtime.getRuntime().availableProcessors() being used. + Negative values will result in + Runtime.getRuntime().availableProcessors() + value being + used unless this is less than 1 in which case 1 thread will be used. If + not specified, the default value of 1 will be used.

+
+ +
+ + +
Standard Implementation
+ +

The standard implementation of Engine is + org.apache.catalina.core.StandardEngine. + It supports the following additional attributes (in addition to the + common attributes listed above):

+ +
AttributeDescription
+ +
+ + +
Nested Components
+ +

You can nest one or more Host elements inside + this Engine element, each representing a different virtual + host associated with this server. At least one Host + is required, and one of the nested Hosts MUST + have a name that matches the name specified for the + defaultHost attribute, listed above.

+ +

You can nest at most one instance of the following utility components + by nesting a corresponding element inside your Engine + element:

+
    +
  • Realm - + Configure a realm that will allow its + database of users, and their associated roles, to be shared across all + Hosts and Contexts + nested inside this Engine, unless overridden by a + Realm configuration at a lower level.
  • +
+ +
Special Features
+ + +
Logging
+ +

An engine is associated with the + org.apache.catalina.core.ContainerBase.[enginename] + log category. Note that the brackets are actually part of the name, + don't omit them.

+ +
+ + +
Access Logs
+ +

When you run a web server, one of the output files normally generated + is an access log, which generates one line of information for + each request processed by the server, in a standard format. Catalina + includes an optional Valve implementation that + can create access logs in the same standard format created by web servers, + or in any number of custom formats.

+ +

You can ask Catalina to create an access log for all requests + processed by an Engine, + Host, or Context + by nesting a Valve element like this:

+ +
<Engine name="Standalone" ...>
+  ...
+  <Valve className="org.apache.catalina.valves.AccessLogValve"
+         prefix="catalina_access_log." suffix=".txt"
+         pattern="common"/>
+  ...
+</Engine>
+ +

See Access Logging Valves + for more information on the configuration attributes that are + supported.

+ +
+ + +
Lifecycle Listeners
+ +

If you have implemented a Java object that needs to know when this + Engine is started or stopped, you can declare it by + nesting a Listener element inside this element. The + class name you specify must implement the + org.apache.catalina.LifecycleListener interface, and + it will be notified about the occurrence of the corresponding + lifecycle events. Configuration of such a listener looks like this:

+ +
<Engine name="Standalone" ...>
+  ...
+  <Listener className="com.mycompany.mypackage.MyListener" ... >
+  ...
+</Engine>
+ +

Note that a Listener can have any number of additional properties + that may be configured from this element. Attribute names are matched + to corresponding JavaBean property names using the standard property + method naming patterns.

+ +
+ + +
Request Filters
+ +

You can ask Catalina to check the IP address, or host name, on every + incoming request directed to the surrounding + Engine, Host, or + Context element. The remote address or name + will be checked against configured "accept" and/or "deny" + filters, which are defined using java.util.regex Regular + Expression syntax. Requests that come from locations that are + not accepted will be rejected with an HTTP "Forbidden" error. + Example filter declarations:

+ +
<Engine name="Standalone" ...>
+  ...
+  <Valve className="org.apache.catalina.valves.RemoteHostValve"
+         allow=".*\.mycompany\.com|www\.yourcompany\.com"/>
+  <Valve className="org.apache.catalina.valves.RemoteAddrValve"
+         deny="192\.168\.1\.\d+"/>
+  ...
+</Engine>
+ +

See Remote Address Filter + and Remote Host Filter for + more information about the configuration options that are supported.

+ +
+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/executor.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/executor.html new file mode 100644 index 0000000..11f4edd --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/executor.html @@ -0,0 +1,154 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Executor (thread pool)

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Executor (thread pool)

Table of Contents
+ +
Introduction
+ +

The Executor represents a thread pool that can be shared + between components in Tomcat. Historically there has been a thread pool per + connector created but this allows you to share a thread pool, between (primarily) connector + but also other components when those get configured to support executors

+ + +

The executor has to implement the org.apache.catalina.Executor interface.

+ +

The executor is a nested element to the Service element. + And in order for it to be picked up by the connectors, the Executor element has to appear + prior to the Connector element in server.xml

+
Attributes
+ +
Common Attributes
+ +

All implementations of Executor + support the following attributes:

+ +
AttributeDescription
className +

The class of the implementation. The implementation has to implement the + org.apache.catalina.Executor interface. + This interface ensures that the object can be referenced through its name attribute + and that implements Lifecycle, so that it can be started and stopped with the container. + The default value for the className is org.apache.catalina.core.StandardThreadExecutor

+
name +

The name used to reference this pool in other places in server.xml. + The name is required and must be unique.

+
+ +
+ +
Standard Implementation
+ +

+ The default implementation supports the following attributes:

+ +
AttributeDescription
threadPriority +

(int) The thread priority for threads in the executor, the default is + 5 (the value of the Thread.NORM_PRIORITY constant)

+
daemon +

(boolean) Whether the threads should be daemon threads or not, the default is true

+
namePrefix +

(String) The name prefix for each thread created by the executor. + The thread name for an individual thread will be namePrefix+threadNumber

+
maxThreads +

(int) The max number of active threads in this pool, default is 200

+
minSpareThreads +

(int) The minimum number of threads (idle and active) always kept alive, default is 25

+
maxIdleTime +

(int) The number of milliseconds before an idle thread shutsdown, unless the number of active threads are less + or equal to minSpareThreads. Default value is 60000(1 minute)

+
maxQueueSize +

(int) The maximum number of runnable tasks that can queue up awaiting + execution before we reject them. Default value is Integer.MAX_VALUE

+
prestartminSpareThreads +

(boolean) Whether minSpareThreads should be started when starting the Executor or not, + the default is false

+
threadRenewalDelay +

(long) If a ThreadLocalLeakPreventionListener is configured, + it will notify this executor about stopped contexts. + After a context is stopped, threads in the pool are renewed. To avoid renewing all threads at the same time, + this option sets a delay between renewal of any 2 threads. The value is in ms, + default value is 1000 ms. If value is negative, threads are not renewed.

+
+ + +
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/filter.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/filter.html new file mode 100644 index 0000000..13dda14 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/filter.html @@ -0,0 +1,1746 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - Container Provided Filters

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

Container Provided Filters

Table of Contents
+ +
Introduction
+ +

Tomcat provides a number of Filters which may be + configured for use with all web applications using + $CATALINA_BASE/conf/web.xml or may be configured for individual + web applications by configuring them in the application's + WEB-INF/web.xml. Each filter is described below.

+ +

This description uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+ +
Add Default Character Set Filter
+ +
Introduction
+ +

The HTTP specification is clear that if no character set is specified for + media sub-types of the "text" media type, the ISO-8859-1 character set must + be used. However, browsers may attempt to auto-detect the character set. + This may be exploited by an attacker to perform an XSS attack. Internet + Explorer has this behaviour by default. Other browsers have an option to + enable it.

+ +

This filter prevents the attack by explicitly setting a character set. + Unless the provided character set is explicitly overridden by the user the + browser will adhere to the explicitly set character set, thus preventing the + XSS attack.

+ +
+ +
Filter Class Name
+ +

The filter class name for the Add Default Character Set Filter is + org.apache.catalina.filters.AddDefaultCharsetFilter + .

+ +
+ +
Initialisation parameters
+ +

The Add Default Character Set Filter supports the following initialization + parameters:

+ +
AttributeDescription
encoding +

Name of the character set which should be set, if no other character set + was set explicitly by a Servlet. This parameter has two special values + default and system. A value of system + uses the JVM wide default character set, which is usually set by locale. + A value of default will use ISO-8859-1.

+
+ +
+ +
CORS Filter
+
Introduction
+

This filter is an implementation of W3C's CORS (Cross-Origin Resource + Sharing) specification, which is a + mechanism that enables cross-origin requests.

+

The filter works by adding required Access-Control-* headers + to HttpServletResponse object. The filter also protects against HTTP + response splitting. If request is invalid, or is not permitted, then request + is rejected with HTTP status code 403 (Forbidden). A + flowchart that + demonstrates request processing by this filter is available.

+

The minimal configuration required to use this filter is:

+
<filter>
+  <filter-name>CorsFilter</filter-name>
+  <filter-class>org.apache.catalina.filters.CorsFilter</filter-class>
+</filter>
+<filter-mapping>
+  <filter-name>CorsFilter</filter-name>
+  <url-pattern>/*</url-pattern>
+</filter-mapping>
+

The above configuration enables the filter but does not relax the + cross-origin policy. As a minimum, you will need to add a + cors.allowed.origins initialisation parameter as described + below to enable cross-origin requests. Depending on your requirements, you + may need to provide additional configuration.

+

An instance of this filter can only implement one policy. If you want to + apply different policies (e.g. different allowed origins) to different URLs + or sets of URLs within your web application you will need to configure a + separate instance of this filter for each policy you wish to configure.

+
+
Filter Class Name
+

The filter class name for the CORS Filter is + org.apache.catalina.filters.CorsFilter.

+
+
Initialisation parameters
+

The CORS Filter supports following initialisation parameters:

+
AttributeDescription
cors.allowed.origins +

A list of origins + that are allowed to access the resource. A * can be + specified to enable access to resource from any origin. Otherwise, an + allow list of comma separated origins can be provided. Eg: + https://www.w3.org, https://www.apache.org. + Defaults: The empty String. (No origin is allowed to + access the resource).

+
cors.allowed.methods +

A comma separated list of HTTP methods that can be used to access the + resource, using cross-origin requests. These are the methods which will + also be included as part of Access-Control-Allow-Methods + header in pre-flight response. Eg: GET, POST. + Defaults: GET, POST, HEAD, OPTIONS

+
cors.allowed.headers +

A comma separated list of request headers that can be used when + making an actual request. These headers will also be returned as part + of Access-Control-Allow-Headers header in a pre-flight + response. Eg: Origin,Accept. Defaults: + Origin, Accept, X-Requested-With, Content-Type, + Access-Control-Request-Method, Access-Control-Request-Headers

+
cors.exposed.headers +

A comma separated list of headers other than simple response headers + that browsers are allowed to access. These are the headers which will + also be included as part of Access-Control-Expose-Headers + header in the pre-flight response. Eg: + X-CUSTOM-HEADER-PING,X-CUSTOM-HEADER-PONG. + Default: None. Non-simple headers are not exposed by + default.

+
cors.preflight.maxage +

The amount of seconds, browser is allowed to cache the result of the + pre-flight request. This will be included as part of + Access-Control-Max-Age header in the pre-flight response. + A negative value will prevent CORS Filter from adding this response + header to pre-flight response. Defaults: + 1800

+
cors.support.credentials +

A flag that indicates whether the resource supports user credentials. + This flag is exposed as part of + Access-Control-Allow-Credentials header in a pre-flight + response. It helps browser determine whether or not an actual request + can be made using credentials. Defaults: + false

+
cors.request.decorate +

A flag to control if CORS specific attributes should be added to + HttpServletRequest object or not. Defaults: + true

+
+

Here's an example of a more advanced configuration, that overrides + defaults:

+
<filter>
+  <filter-name>CorsFilter</filter-name>
+  <filter-class>org.apache.catalina.filters.CorsFilter</filter-class>
+  <init-param>
+    <param-name>cors.allowed.origins</param-name>
+    <param-value>https://www.apache.org</param-value>
+  </init-param>
+  <init-param>
+    <param-name>cors.allowed.methods</param-name>
+    <param-value>GET,POST,HEAD,OPTIONS,PUT</param-value>
+  </init-param>
+  <init-param>
+    <param-name>cors.allowed.headers</param-name>
+    <param-value>Content-Type,X-Requested-With,accept,Origin,Access-Control-Request-Method,Access-Control-Request-Headers</param-value>
+  </init-param>
+  <init-param>
+    <param-name>cors.exposed.headers</param-name>
+    <param-value>Access-Control-Allow-Origin,Access-Control-Allow-Credentials</param-value>
+  </init-param>
+  <init-param>
+    <param-name>cors.support.credentials</param-name>
+    <param-value>true</param-value>
+  </init-param>
+  <init-param>
+    <param-name>cors.preflight.maxage</param-name>
+    <param-value>10</param-value>
+  </init-param>
+</filter>
+<filter-mapping>
+  <filter-name>CorsFilter</filter-name>
+  <url-pattern>/*</url-pattern>
+</filter-mapping>
+
+
CORS Filter and HttpServletRequest attributes
+

CORS Filter adds information about the request, in HttpServletRequest + object, for consumption downstream. Following attributes are set, if + cors.request.decorate initialisation parameter is + true:

+
    +
  • cors.isCorsRequest: Flag to determine if request is + a CORS request.
  • +
  • cors.request.origin: The Origin URL, i.e. the URL of + the page from where the request originated.
  • +
  • cors.request.type: Type of CORS request. Possible + values: +
      +
    • SIMPLE: A request which is not preceded by a + pre-flight request.
    • +
    • ACTUAL: A request which is preceded by a pre-flight + request.
    • +
    • PRE_FLIGHT: A pre-flight request.
    • +
    • NOT_CORS: A normal same-origin request.
    • +
    • INVALID_CORS: A cross-origin request, which is + invalid.
    • +
    +
  • +
  • cors.request.headers: Request headers sent as + Access-Control-Request-Headers header, for a pre-flight + request. +
  • +
+
+
CSRF Prevention Filter
+ +
Introduction
+ +

This filter provides basic CSRF protection for a web application. The + filter assumes that it is mapped to /* and that all URLs + returned to the client are encoded via a call to + HttpServletResponse#encodeRedirectURL(String) or + HttpServletResponse#encodeURL(String).

+ +

This filter prevents CSRF by generating a nonce and storing it in the + session. URLs are also encoded with the same nonce. When the next request is + received the nonce in the request is compared to the nonce in the session + and only if they are the same is the request allowed to continue.

+ +
+ +
Filter Class Name
+ +

The filter class name for the CSRF Prevention Filter is + org.apache.catalina.filters.CsrfPreventionFilter + .

+ +
+ +
Initialisation parameters
+ +

The CSRF Prevention Filter supports the following initialisation + parameters:

+ +
AttributeDescription
denyStatus +

HTTP response status code that is used when rejecting denied + request. The default value is 403.

+
entryPoints +

A comma separated list of URLs that will not be tested for the + presence of a valid nonce. They are used to provide a way to navigate + back to a protected application after having navigated away from it. + Entry points will be limited to HTTP GET requests and should not trigger + any security sensitive actions.

+
nonceCacheSize +

The number of previously issued nonces that will be cached on a LRU + basis to support parallel requests, limited use of the refresh and back + in the browser and similar behaviors that may result in the submission + of a previous nonce rather than the current one. If not set, the default + value of 5 will be used.

+
randomClass +

The name of the class to use to generate nonces. The class must be an + instance of java.util.Random. If not set, the default value + of java.security.SecureRandom will be used.

+
+ +
+ +
CSRF Prevention Filter for REST APIs
+ +
Introduction
+ +

This filter provides basic CSRF protection for REST APIs. The CSRF + protection is applied only for modifying HTTP requests (different from GET, + HEAD, OPTIONS) to protected resources. It is based on a custom header + X-CSRF-Token that provides a valid nonce.

+ +

CSRF protection mechanism for REST APIs consists of the following steps: +

    +
  • Client asks for a valid nonce. This is performed with a + non-modifying "Fetch" request to protected resource.
  • +
  • Server responds with a valid nonce mapped to the current user + session.
  • +
  • Client provides this nonce in the subsequent modifying requests in + the frame of the same user session.
  • +
  • Server rejects all modifying requests to protected resources that + do not contain a valid nonce.
  • +
+

+ +
+ +
Basic configuration sample
+ +

On the server side

+ +
    +
  • All CSRF protected REST APIs should be protected with an authentication + mechanism.
  • +
  • Protect modifying REST APIs with this filter.
  • +
  • Provide at least one non-modifying operation.
  • +
+
<filter>
+  <filter-name>RestCSRF</filter-name>
+  <filter-class>org.apache.catalina.filters.RestCsrfPreventionFilter</filter-class>
+</filter>
+<filter-mapping>
+  <filter-name>RestCSRF</filter-name>
+  <!-- Modifying operations -->
+  <url-pattern>/resources/removeResource</url-pattern>
+  <url-pattern>/resources/addResource</url-pattern>
+  <!-- Non-modifying operations -->
+  <url-pattern>/resources/listResources</url-pattern>
+</filter-mapping>
+ +

On the client side

+ +
    +
  • Make a non-modifying "Fetch" request in order to obtain a valid nonce. + This can be done with sending additional header + X-CSRF-Token: Fetch
  • +
  • Cache the returned session id and nonce in order to provide them in + the subsequent modifying requests to protected resources.
  • +
  • Modifying requests can be denied and header + X-CSRF-Token: Required will be returned in case of + invalid or missing nonce, expired session or in case the session + id is changed by the server.
  • +
+
Client Request:
+GET /rest/resources/listResources HTTP/1.1
+X-CSRF-Token: Fetch
+Authorization: Basic ...
+Host: localhost:8080
+...
+
+Server Response:
+HTTP/1.1 200 OK
+Set-Cookie: JSESSIONID=...; Path=/rest; HttpOnly
+X-CSRF-Token: ...
+...
+
+Client Request:
+POST /rest/resources/addResource HTTP/1.1
+Cookie: JSESSIONID=...
+X-CSRF-Token: ...
+Authorization: Basic ...
+Host: localhost:8080
+...
+
+Server Response:
+HTTP/1.1 200 OK
+...
+ +
+ +
RestCsrfPreventionFilter and HttpServletRequest parameters
+ +

When the client is not able to insert custom headers in its calls to + REST APIs there is additional capability to configure URLs for which a + valid nonce will be accepted as a request parameter.

+ +

Note: If there is a X-CSRF-Token header, it will be taken + with preference over any parameter with the same name in the request. + Request parameters cannot be used to fetch new nonce, only header can be + used to request a new nonce.

+ +
<filter>
+  <filter-name>RestCSRF</filter-name>
+  <filter-class>org.apache.catalina.filters.RestCsrfPreventionFilter</filter-class>
+  <init-param>
+    <param-name>pathsAcceptingParams</param-name>
+    <param-value>/resources/removeResource,/resources/addResource</param-value>
+  </init-param>
+</filter>
+<filter-mapping>
+  <filter-name>RestCSRF</filter-name>
+  <url-pattern>/resources/*</url-pattern>
+</filter-mapping>
+ +
+ +
Filter Class Name
+ +

The filter class name for the CSRF Prevention Filter for REST APIs is + org.apache.catalina.filters.RestCsrfPreventionFilter + .

+ +
+ +
Initialisation parameters
+ +

The CSRF Prevention Filter for REST APIs supports the following + initialisation parameters:

+ +
AttributeDescription
denyStatus +

HTTP response status code that is used when rejecting denied + request. The default value is 403.

+
pathsAcceptingParams +

A comma separated list of URLs that can accept nonces via request + parameter X-CSRF-Token. For use cases when a nonce information cannot + be provided via header, one can provide it via request parameters. If + there is a X-CSRF-Token header, it will be taken with preference over + any parameter with the same name in the request. Request parameters + cannot be used to fetch new nonce, only header can be used to request a + new nonce.

+
randomClass +

The name of the class to use to generate nonces. The class must be an + instance of java.util.Random. If not set, the default value + of java.security.SecureRandom will be used.

+
+ +
+ +
Expires Filter
+ +
Introduction
+ +

+ ExpiresFilter is a Java Servlet API port of Apache + mod_expires. + This filter controls the setting of the Expires HTTP header and the + max-age directive of the Cache-Control HTTP header in + server responses. The expiration date can set to be relative to either the + time the source file was last modified, or to the time of the client access. +

+ +

+ These HTTP headers are an instruction to the client about the document's + validity and persistence. If cached, the document may be fetched from the + cache rather than from the source until this time has passed. After that, the + cache copy is considered "expired" and invalid, and a new copy must + be obtained from the source. +

+

+ To modify Cache-Control directives other than max-age (see + RFC + 2616 section 14.9), you can use other servlet filters or Apache Httpd + mod_headers module. +

+ +
+ +
Basic configuration sample
+

+ Basic configuration to add 'Expires' and 'Cache-Control: max-age=' + headers to images, css and javascript. +

+ +
<filter>
+ <filter-name>ExpiresFilter</filter-name>
+ <filter-class>org.apache.catalina.filters.ExpiresFilter</filter-class>
+ <init-param>
+    <param-name>ExpiresByType image</param-name>
+    <param-value>access plus 10 minutes</param-value>
+ </init-param>
+ <init-param>
+    <param-name>ExpiresByType text/css</param-name>
+    <param-value>access plus 10 minutes</param-value>
+ </init-param>
+ <init-param>
+    <param-name>ExpiresByType application/javascript</param-name>
+    <param-value>access plus 10 minutes</param-value>
+ </init-param>
+</filter>
+...
+<filter-mapping>
+ <filter-name>ExpiresFilter</filter-name>
+ <url-pattern>/*</url-pattern>
+ <dispatcher>REQUEST</dispatcher>
+</filter-mapping>
+ +
+ +
Alternate Syntax
+

+ The ExpiresDefault and ExpiresByType directives can also be + defined in a more readable syntax of the form: +

+ +
<init-param>
+ <param-name>ExpiresDefault</param-name>
+ <param-value><base> [plus] {<num> <type>}*</param-value>
+</init-param>
+
+<init-param>
+ <param-name>ExpiresByType type</param-name>
+ <param-value><base> [plus] {<num> <type>}*</param-value>
+</init-param>
+
+<init-param>
+ <param-name>ExpiresByType type;encoding</param-name>
+ <param-value><base> [plus] {<num> <type>}*</param-value>
+</init-param>
+

+ where <base> is one of: +

+
    +
  • access
  • +
  • now (equivalent to 'access')
  • +
  • modification
  • +
+ +

+ The plus keyword is optional. <num> should be an + integer value (acceptable to Integer.parseInt()), and + <type> is one of: +

+
    +
  • year, years
  • +
  • month, months
  • +
  • week, weeks
  • +
  • day, days
  • +
  • hour, hours
  • +
  • minute, minutes
  • +
  • second, seconds
  • +
+

+ For example, any of the following directives can be used to make documents + expire 1 month after being accessed, by default: +

+ +
<init-param>
+ <param-name>ExpiresDefault</param-name>
+ <param-value>access plus 1 month</param-value>
+</init-param>
+
+<init-param>
+ <param-name>ExpiresDefault</param-name>
+ <param-value>access plus 4 weeks</param-value>
+</init-param>
+
+<init-param>
+ <param-name>ExpiresDefault</param-name>
+ <param-value>access plus 30 days</param-value>
+</init-param>
+

+The expiry time can be fine-tuned by adding several +'<num> <type>' clauses: +

+ +
<init-param>
+ <param-name>ExpiresByType text/html</param-name>
+ <param-value>access plus 1 month 15 days 2 hours</param-value>
+</init-param>
+
+<init-param>
+ <param-name>ExpiresByType image/gif</param-name>
+ <param-value>modification plus 5 hours 3 minutes</param-value>
+</init-param>
+

+ Note that if you use a modification date based setting, the Expires + header will not be added to content that does not come from + a file on disk. This is due to the fact that there is no modification time + for such content. +

+
+ +
Expiration headers generation eligibility
+

+ A response is eligible to be enriched by ExpiresFilter if : +

+
    +
  1. no expiration header is defined (Expires header or the + max-age directive of the Cache-Control header),
  2. +
  3. the response status code is not excluded by the directive + ExpiresExcludedResponseStatusCodes,
  4. +
  5. the Content-Type of the response matches one of the types + defined the in ExpiresByType directives or the + ExpiresDefault directive is defined.
  6. +
+ +

+ Note : If Cache-Control header contains other directives than + max-age, they are concatenated with the max-age directive + that is added by the ExpiresFilter. +

+ +
+ +
Expiration configuration selection
+

+ The expiration configuration if elected according to the following algorithm: +

+
    +
  1. ExpiresByType matching the exact content-type returned by + HttpServletResponse.getContentType() possibly including the charset + (e.g. 'text/xml;charset=UTF-8'),
  2. +
  3. ExpiresByType matching the content-type without the charset if + HttpServletResponse.getContentType() contains a charset (e.g. + 'text/xml;charset=UTF-8' -> 'text/xml'),
  4. +
  5. ExpiresByType matching the major type (e.g. substring before + '/') of HttpServletResponse.getContentType() + (e.g. 'text/xml;charset=UTF-8' -> 'text'),
  6. +
  7. ExpiresDefault
  8. +
+ +
+ +
Filter Class Name
+ +

The filter class name for the Expires Filter is + org.apache.catalina.filters.ExpiresFilter + .

+ +
+ +
Initialisation parameters
+ +

The Expires Filter supports the following + initialisation parameters:

+ +
AttributeDescription
ExpiresExcludedResponseStatusCodes +

+ This directive defines the http response status codes for which the + ExpiresFilter will not generate expiration headers. By default, the + 304 status code ("Not modified") is skipped. The + value is a comma separated list of http status codes. +

+

+ This directive is useful to ease usage of ExpiresDefault directive. + Indeed, the behavior of 304 Not modified (which does specify a + Content-Type header) combined with Expires and + Cache-Control:max-age= headers can be unnecessarily tricky to + understand. +

+

See sample below the table

+
ExpiresByType <content-type> +

+ This directive defines the value of the Expires header and the + max-age directive of the Cache-Control header generated for + documents of the specified type (e.g., text/html). The second + argument sets the number of seconds that will be added to a base time to + construct the expiration date. The Cache-Control: max-age is + calculated by subtracting the request time from the expiration date and + expressing the result in seconds. +

+

+ The base time is either the last modification time of the file, or the time + of the client's access to the document. Which should be used is + specified by the <code> field; M means that the + file's last modification time should be used as the base time, and + A means the client's access time should be used. The duration + is expressed in seconds. A2592000 stands for + access plus 30 days in alternate syntax. +

+

+ The difference in effect is subtle. If M (modification in + alternate syntax) is used, all current copies of the document in all caches + will expire at the same time, which can be good for something like a weekly + notice that's always found at the same URL. If A ( + access or now in alternate syntax) is used, the date of + expiration is different for each client; this can be good for image files + that don't change very often, particularly for a set of related + documents that all refer to the same images (i.e., the images will be + accessed repeatedly within a relatively short timespan). +

+

+ Note: When the content type includes a charset (e.g. + 'ExpiresByType text/xml;charset=utf-8'), Tomcat removes blank chars + between the ';' and the 'charset' keyword. Due to this, + configuration of an expiration with a charset must not include + such a space character. +

+

See sample below the table

+

+ It overrides, for the specified MIME type only, any + expiration date set by the ExpiresDefault directive. +

+

+ You can also specify the expiration time calculation using an alternate + syntax, described earlier in this document. +

+
ExpiresDefault +

+ This directive sets the default algorithm for calculating the + expiration time for all documents in the affected realm. It can be + overridden on a type-by-type basis by the ExpiresByType directive. See the + description of that directive for details about the syntax of the + argument, and the "alternate syntax" + description as well. +

+
+ +

Sample: exclude response status codes 302, 500 and 503

+ +
<init-param>
+ <param-name>ExpiresExcludedResponseStatusCodes</param-name>
+ <param-value>302, 500, 503</param-value>
+</init-param>
+ +

Sample for ExpiresByType initialization parameter

+ +
<init-param>
+   <param-name>ExpiresByType text/html</param-name>
+   <param-value>access plus 1 month 15   days 2 hours</param-value>
+</init-param>
+
+<init-param>
+   <!-- 2592000 seconds = 30 days -->
+   <param-name>ExpiresByType image/gif</param-name>
+   <param-value>A2592000</param-value>
+</init-param>
+ +
+ +
Troubleshooting
+

+ To troubleshoot, enable logging on the + org.apache.catalina.filters.ExpiresFilter. +

+

+ Extract of logging.properties +

+ +
org.apache.catalina.filters.ExpiresFilter.level = FINE    
+

+ Sample of initialization log message: +

+ +
Mar 26, 2010 2:01:41 PM org.apache.catalina.filters.ExpiresFilter init
+FINE: Filter initialized with configuration ExpiresFilter[
+ excludedResponseStatusCode=[304],
+ default=null,
+ byType={
+    image=ExpiresConfiguration[startingPoint=ACCESS_TIME, duration=[10 MINUTE]],
+    text/css=ExpiresConfiguration[startingPoint=ACCESS_TIME, duration=[10 MINUTE]],
+    text/javascript=ExpiresConfiguration[startingPoint=ACCESS_TIME, duration=[10 MINUTE]]}]
+

+ Sample of per-request log message where ExpiresFilter adds an + expiration date is below. The message is on one line and is wrapped here + for better readability. +

+ +
Mar 26, 2010 2:09:47 PM org.apache.catalina.filters.ExpiresFilter onBeforeWriteResponseBody
+FINE: Request "/tomcat.gif" with response status "200"
+ content-type "image/gif", set expiration date 3/26/10 2:19 PM
+

+ Sample of per-request log message where ExpiresFilter does not add + an expiration date: +

+ +
Mar 26, 2010 2:10:27 PM org.apache.catalina.filters.ExpiresFilter onBeforeWriteResponseBody
+FINE: Request "/docs/config/manager.html" with response status "200"
+ content-type "text/html", no expiration configured
+
+ +
Failed Request Filter
+ +
Introduction
+ +

This filter triggers parameters parsing in a request and rejects the + request if some parameters were skipped during parameter parsing because + of parsing errors or request size limitations (such as + maxParameterCount attribute in a + Connector). + This filter can be used to ensure that none parameter values submitted by + client are lost.

+ +

Note that parameter parsing may consume the body of an HTTP request, so + caution is needed if the servlet protected by this filter uses + request.getInputStream() or request.getReader() + calls. In general the risk of breaking a web application by adding this + filter is not so high, because parameter parsing does check content type + of the request before consuming the request body.

+ +

Note, that for the POST requests to be parsed correctly, a + SetCharacterEncodingFilter filter must be configured above + this one. See CharacterEncoding page in the FAQ for details.

+ +

The request is rejected with HTTP status code 400 (Bad Request).

+ +
+ +
Filter Class Name
+ +

The filter class name for the Failed Request Filter is + org.apache.catalina.filters.FailedRequestFilter + .

+ +
+ +
Initialisation parameters
+ +

The Failed Request Filter does not support any initialization parameters.

+ +
+ +
HTTP Header Security Filter
+ +
Introduction
+ +

There are a number of HTTP headers that can be added to the response to + improve the security of the connection. This filter provides a mechanism for + adding those headers. Note that security related headers with more complex + requirements, like CORS, are implemented as separate Filters.

+ +
+ +
Filter Class Name
+ +

The filter class name for the HTTP Header Security Filter is + org.apache.catalina.filters.HttpHeaderSecurityFilter + .

+ +
+ +
Initialisation parameters
+ +

The HTTP Header Security Filter supports the following initialization + parameters:

+ +
AttributeDescription
hstsEnabled +

Will an HTTP Strict Transport Security (HSTS) header + (Strict-Transport-Security) be set on the response for + secure requests. Any HSTS header already present will be replaced. See + RFC 6797 for further + details of HSTS. If not specified, the default value of + true will be used.

+
hstsMaxAgeSeconds +

The max age value that should be used in the HSTS header. Negative + values will be treated as zero. If not specified, the default value of + 0 will be used.

+
hstsIncludeSubDomains +

Should the includeSubDomains parameter be included in the HSTS + header. If not specified, the default value of false will + be used.

+
hstsPreload +

Should the preload parameter be included in the HSTS header. If not + specified, the default value of false will be used. See + https://hstspreload.org for + important information about this parameter.

+
antiClickJackingEnabled +

Should the anti click-jacking header (X-Frame-Options) + be set on the response. Any anti click-jacking header already present + will be replaced. If not specified, the default value of + true will be used.

+
antiClickJackingOption +

What value should be used for the anticlick-jacking header? Must be + one of DENY, SAMEORIGIN, + ALLOW-FROM (case-insensitive). If not specified, the + default value of DENY will be used.

+
antiClickJackingUri +

If ALLOW-FROM is used for antiClickJackingOption, + what URI should be allowed? If not specified, the default value of an + empty string will be used.

+
blockContentTypeSniffingEnabled +

Should the header that blocks content type sniffing + (X-Content-Type-Options) be set on every response. If + already present, the header will be replaced. If not specified, the + default value of true will be used.

+
xssProtectionEnabled +

Should the header that enables the browser's cross-site scripting + filter protection (X-XSS-Protection: 1; mode=block) + be set on every response. If already present, the header + will be replaced. If not specified, the default value of + true will be used.

+
+ +
+ +
Remote Address Filter
+ +
Introduction
+ +

The Remote Address Filter allows you to compare the + IP address of the client that submitted this request against one or more + regular expressions, and either allow the request to continue + or refuse to process the request from this client.

+ +

The syntax for regular expressions is different than that for + 'standard' wildcard matching. Tomcat uses the java.util.regex + package. Please consult the Java documentation for details of the + expressions supported.

+ +

Note: There is a caveat when using this filter with + IPv6 addresses. Format of the IP address that this valve is processing + depends on the API that was used to obtain it. If the address was obtained + from Java socket using Inet6Address class, its format will be + x:x:x:x:x:x:x:x. That is, the IP address for localhost + will be 0:0:0:0:0:0:0:1 instead of the more widely used + ::1. Consult your access logs for the actual value.

+ +

See also: Remote Host Filter.

+
+ +
Filter Class Name
+ +

The filter class name for the Remote Address Filter is + org.apache.catalina.filters.RemoteAddrFilter + .

+ +
+ +
Initialisation parameters
+ +

The Remote Address Filter supports the following + initialisation parameters:

+ +
AttributeDescription
allow +

A regular expression (using java.util.regex) that the + remote client's IP address is compared to. If this attribute + is specified, the remote address MUST match for this request to be + accepted. If this attribute is not specified, all requests will be + accepted UNLESS the remote address matches a deny + pattern.

+
deny +

A regular expression (using java.util.regex) that the + remote client's IP address is compared to. If this attribute + is specified, the remote address MUST NOT match for this request to be + accepted. If this attribute is not specified, request acceptance is + governed solely by the accept attribute.

+
denyStatus +

HTTP response status code that is used when rejecting denied + request. The default value is 403. For example, + it can be set to the value 404.

+
+ +
+ +
Example
+

To allow access only for the clients connecting from localhost:

+
    <filter>
+      <filter-name>Remote Address Filter</filter-name>
+      <filter-class>org.apache.catalina.filters.RemoteAddrFilter</filter-class>
+      <init-param>
+        <param-name>allow</param-name>
+        <param-value>127\.\d+\.\d+\.\d+|::1|0:0:0:0:0:0:0:1</param-value>
+      </init-param>
+    </filter>
+    <filter-mapping>
+      <filter-name>Remote Address Filter</filter-name>
+      <url-pattern>/*</url-pattern>
+    </filter-mapping>
+
+ +
Remote Host Filter
+ +
Introduction
+ +

The Remote Host Filter allows you to compare the + hostname of the client that submitted this request against one or more + regular expressions, and either allow the request to continue + or refuse to process the request from this client.

+ +

The syntax for regular expressions is different than that for + 'standard' wildcard matching. Tomcat uses the java.util.regex + package. Please consult the Java documentation for details of the + expressions supported.

+ +

Note: This filter processes the value returned by + method ServletRequest.getRemoteHost(). To allow the method + to return proper host names, you have to enable "DNS lookups" feature on + a Connector.

+ +

See also: Remote Address Filter, + HTTP Connector configuration.

+
+ +
Filter Class Name
+ +

The filter class name for the Remote Address Filter is + org.apache.catalina.filters.RemoteHostFilter + .

+ +
+ +
Initialisation parameters
+ +

The Remote Host Filter supports the following + initialisation parameters:

+ +
AttributeDescription
allow +

A regular expression (using java.util.regex) that the + remote client's hostname is compared to. If this attribute + is specified, the remote hostname MUST match for this request to be + accepted. If this attribute is not specified, all requests will be + accepted UNLESS the remote hostname matches a deny + pattern.

+
deny +

A regular expression (using java.util.regex) that the + remote client's hostname is compared to. If this attribute + is specified, the remote hostname MUST NOT match for this request to be + accepted. If this attribute is not specified, request acceptance is + governed solely by the accept attribute.

+
denyStatus +

HTTP response status code that is used when rejecting denied + request. The default value is 403. For example, + it can be set to the value 404.

+
+ +
+ +
Remote CIDR Filter
+ +
Introduction
+ +

The Remote CIDR Filter allows you to compare the + IP address of the client that submitted this request against one or more + netmasks following the CIDR notation, and either allow the request to + continue or refuse to process the request from this client. IPv4 and + IPv6 are both fully supported. +

+ +

This filter mimicks Apache httpd's Order, + Allow from and Deny from directives, + with the following limitations: +

+ +
    +
  • Order will always be allow, deny;
  • +
  • dotted quad notations for netmasks are not supported (that is, you + cannot write 192.168.1.0/255.255.255.0, you must write + 192.168.1.0/24; +
  • +
  • shortcuts, like 10.10., which is equivalent to + 10.10.0.0/16, are not supported; +
  • +
  • as the filter name says, this is a CIDR only filter, + therefore subdomain notations like .mydomain.com are not + supported either. +
  • +
+ +

Some more features of this filter are: +

+ +
    +
  • if you omit the CIDR prefix, this filter becomes a single IP + filter;
  • +
  • unlike the Remote Host Filter, + it can handle IPv6 addresses in condensed form (::1, + fe80::/71, etc).
  • +
+ +
+ +
Filter Class Name
+ +

The filter class name for the Remote Address Filter is + org.apache.catalina.filters.RemoteCIDRFilter + .

+ +
+ +
Initialisation parameters
+ +

The Remote CIDR Filter supports the following + initialisation parameters:

+ +
AttributeDescription
allow +

A comma-separated list of IPv4 or IPv6 netmasks or addresses + that the remote client's IP address is matched against. + If this attribute is specified, the remote address MUST match + for this request to be accepted. If this attribute is not specified, + all requests will be accepted UNLESS the remote IP is matched by a + netmask in the deny attribute. +

+
deny +

A comma-separated list of IPv4 or IPv6 netmasks or addresses + that the remote client's IP address is matched against. + If this attribute is specified, the remote address MUST NOT match + for this request to be accepted. If this attribute is not specified, + request acceptance is governed solely by the accept + attribute. +

+
+ +
+ +
Example
+

To allow access only for the clients connecting from localhost:

+
+      <filter>
+      <filter-name>Remote CIDR Filter</filter-name>
+      <filter-class>org.apache.catalina.filters.RemoteCIDRFilter</filter-class>
+      <init-param>
+      <param-name>allow</param-name>
+      <param-value>127.0.0.0/8, ::1</param-value>
+      </init-param>
+      </filter>
+      <filter-mapping>
+      <filter-name>Remote CIDR Filter</filter-name>
+      <url-pattern>/*</url-pattern>
+      </filter-mapping>
+    
+
+ +
Remote IP Filter
+ +
Introduction
+ +

Tomcat port of + mod_remoteip, + this filter replaces the apparent client remote IP address and hostname for + the request with the IP address list presented by a proxy or a load balancer + via a request headers (e.g. "X-Forwarded-For").

+ +

Another feature of this filter is to replace the apparent scheme + (http/https), server port and request.secure with the scheme presented + by a proxy or a load balancer via a request header + (e.g. "X-Forwarded-Proto").

+ +

If used in conjunction with Remote Address/Host filters then this filter + should be defined first to ensure that the correct client IP address is + presented to the Remote Address/Host filters.

+ +

Note: By default this filter has no effect on the + values that are written into access log. The original values are restored + when request processing leaves the filter and that always happens earlier + than access logging. To pass the remote address, remote host, server port + and protocol values set by this filter to the access log, + they are put into request attributes. Publishing these values here + is enabled by default, but AccessLogValve should be explicitly + configured to use them. See documentation for + requestAttributesEnabled attribute of + AccessLogValve.

+ +

The names of request attributes that are set by this filter + and can be used by access logging are the following:

+ +
    +
  • org.apache.catalina.AccessLog.RemoteAddr
  • +
  • org.apache.catalina.AccessLog.RemoteHost
  • +
  • org.apache.catalina.AccessLog.Protocol
  • +
  • org.apache.catalina.AccessLog.ServerPort
  • +
  • org.apache.tomcat.remoteAddr
  • +
+ +
+ +
Filter Class Name
+ +

The filter class name for the Remote IP Filter is + org.apache.catalina.filters.RemoteIpFilter + .

+ +
+ +
Basic configuration to handle 'x-forwarded-for'
+

+ The filter will process the x-forwarded-for http header. +

+
      <filter>
+        <filter-name>RemoteIpFilter</filter-name>
+        <filter-class>org.apache.catalina.filters.RemoteIpFilter</filter-class>
+      </filter>
+
+      <filter-mapping>
+        <filter-name>RemoteIpFilter</filter-name>
+        <url-pattern>/*</url-pattern>
+        <dispatcher>REQUEST</dispatcher>
+      </filter-mapping>
+
+ +
Basic configuration to handle 'x-forwarded-for' and 'x-forwarded-proto'
+ +

+ The filter will process x-forwarded-for and + x-forwarded-proto http headers. Expected value for the + x-forwarded-proto header in case of SSL connections is + https (case insensitive).

+
      <filter>
+        <filter-name>RemoteIpFilter</filter-name>
+        <filter-class>org.apache.catalina.filters.RemoteIpFilter</filter-class>
+        <init-param>
+          <param-name>protocolHeader</param-name>
+          <param-value>x-forwarded-proto</param-value>
+        </init-param>
+      </filter>
+
+      <filter-mapping>
+        <filter-name>RemoteIpFilter</filter-name>
+        <url-pattern>/*</url-pattern>
+        <dispatcher>REQUEST</dispatcher>
+      </filter-mapping>
+
+ +
Advanced configuration with internal proxies
+

RemoteIpFilter configuration:

+
     <filter>
+       <filter-name>RemoteIpFilter</filter-name>
+       <filter-class>org.apache.catalina.filters.RemoteIpFilter</filter-class>
+       <init-param>
+         <param-name>allowedInternalProxies</param-name>
+         <param-value>192\.168\.0\.10|192\.168\.0\.11</param-value>
+       </init-param>
+       <init-param>
+         <param-name>remoteIpHeader</param-name>
+         <param-value>x-forwarded-for</param-value>
+       </init-param>
+       <init-param>
+         <param-name>remoteIpProxiesHeader</param-name>
+         <param-value>x-forwarded-by</param-value>
+       </init-param>
+       <init-param>
+         <param-name>protocolHeader</param-name>
+         <param-value>x-forwarded-proto</param-value>
+       </init-param>
+     </filter>
+

Request values:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
PropertyValue Before RemoteIpFilterValue After RemoteIpFilter
request.remoteAddr 192.168.0.10 140.211.11.130
request.header['x-forwarded-for'] 140.211.11.130, 192.168.0.10 null
request.header['x-forwarded-by'] null null
request.header['x-forwarded-proto'] https https
request.scheme http https
request.secure false true
request.serverPort 80 443
+ +

+ Note : x-forwarded-by header is null because only + internal proxies has been traversed by the request. + x-forwarded-for is null because all the proxies are + trusted or internal. +

+
+ + +
Advanced configuration with trusted proxies
+

RemoteIpFilter configuration:

+
     <filter>
+       <filter-name>RemoteIpFilter</filter-name>
+       <filter-class>org.apache.catalina.filters.RemoteIpFilter</filter-class>
+       <init-param>
+         <param-name>allowedInternalProxies</param-name>
+         <param-value>192\.168\.0\.10|192\.168\.0\.11</param-value>
+       </init-param>
+       <init-param>
+         <param-name>remoteIpHeader</param-name>
+         <param-value>x-forwarded-for</param-value>
+       </init-param>
+       <init-param>
+         <param-name>remoteIpProxiesHeader</param-name>
+         <param-value>x-forwarded-by</param-value>
+       </init-param>
+       <init-param>
+         <param-name>trustedProxies</param-name>
+         <param-value>proxy1|proxy2</param-value>
+       </init-param>
+     </filter>
+

Request values:

+ + + + + + + + + + + + + + + + + + + + + +
PropertyValue Before RemoteIpFilterValue After RemoteIpFilter
request.remoteAddr 192.168.0.10 140.211.11.130
request.header['x-forwarded-for'] 140.211.11.130, proxy1, proxy2 null
request.header['x-forwarded-by'] null proxy1, proxy2
+ +

+ Note : proxy1 and proxy2 are both trusted proxies that + come in x-forwarded-for header, they both are migrated in + x-forwarded-by header. x-forwarded-for is null + because all the proxies are trusted or internal. +

+
+ +
Advanced configuration with internal and trusted proxies
+

RemoteIpFilter configuration:

+
     <filter>
+       <filter-name>RemoteIpFilter</filter-name>
+       <filter-class>org.apache.catalina.filters.RemoteIpFilter</filter-class>
+       <init-param>
+         <param-name>allowedInternalProxies</param-name>
+         <param-value>192\.168\.0\.10|192\.168\.0\.11</param-value>
+       </init-param>
+       <init-param>
+         <param-name>remoteIpHeader</param-name>
+         <param-value>x-forwarded-for</param-value>
+       </init-param>
+       <init-param>
+         <param-name>remoteIpProxiesHeader</param-name>
+         <param-value>x-forwarded-by</param-value>
+       </init-param>
+       <init-param>
+         <param-name>trustedProxies</param-name>
+         <param-value>proxy1|proxy2</param-value>
+       </init-param>
+     </filter>
+

Request values:

+ + + + + + + + + + + + + + + + + + + + + +
PropertyValue Before RemoteIpFilterValue After RemoteIpFilter
request.remoteAddr 192.168.0.10 140.211.11.130
request.header['x-forwarded-for'] 140.211.11.130, proxy1, proxy2, 192.168.0.10 null
request.header['x-forwarded-by'] null proxy1, proxy2
+ +

+ Note : proxy1 and proxy2 are both trusted proxies that + come in x-forwarded-for header, they both are migrated in + x-forwarded-by header. As 192.168.0.10 is an internal + proxy, it does not appear in x-forwarded-by. + x-forwarded-for is null because all the proxies are + trusted or internal. +

+
+ +
Advanced configuration with an untrusted proxy
+ +

RemoteIpFilter configuration:

+
     <filter>
+       <filter-name>RemoteIpFilter</filter-name>
+       <filter-class>org.apache.catalina.filters.RemoteIpFilter</filter-class>
+       <init-param>
+         <param-name>allowedInternalProxies</param-name>
+         <param-value>192\.168\.0\.10|192\.168\.0\.11</param-value>
+       </init-param>
+       <init-param>
+         <param-name>remoteIpHeader</param-name>
+         <param-value>x-forwarded-for</param-value>
+       </init-param>
+       <init-param>
+         <param-name>remoteIpProxiesHeader</param-name>
+         <param-value>x-forwarded-by</param-value>
+       </init-param>
+       <init-param>
+         <param-name>trustedProxies</param-name>
+         <param-value>proxy1|proxy2</param-value>
+       </init-param>
+     </filter>
+

Request values:

+ + + + + + + + + + + + + + + + + + + + + +
PropertyValue Before RemoteIpFilterValue After RemoteIpFilter
request.remoteAddr 192.168.0.10 untrusted-proxy
request.header['x-forwarded-for'] 140.211.11.130, untrusted-proxy, proxy1 140.211.11.130
request.header['x-forwarded-by'] null proxy1
+ +

+ Note : x-forwarded-by holds the trusted proxy proxy1. + x-forwarded-by holds 140.211.11.130 because + untrusted-proxy is not trusted and thus, we cannot trust that + untrusted-proxy is the actual remote ip. + request.remoteAddr is untrusted-proxy that is an IP + verified by proxy1. +

+
+ +
Initialisation parameters
+ +

The Remote IP Filter supports the + following initialisation parameters:

+ +
AttributeDescription
enableLookups +

Should a DNS lookup be performed to provide a host name when calling + ServletRequest#getRemoteHost(). If not specified, the + default of false is used.

+
remoteIpHeader +

Name of the HTTP Header read by this valve that holds the list of + traversed IP addresses starting from the requesting client. If not + specified, the default of x-forwarded-for is used.

+
internalProxies +

Regular expression (using java.util.regex) that a + proxy's IP address must match to be considered an internal proxy. + Internal proxies that appear in the remoteIpHeader will + be trusted and will not appear in the proxiesHeader + value. If not specified the default value of + 10\.\d{1,3}\.\d{1,3}\.\d{1,3}|192\.168\.\d{1,3}\.\d{1,3}|169\.254\.\d{1,3}\.\d{1,3}|127\.\d{1,3}\.\d{1,3}\.\d{1,3}|0:0:0:0:0:0:0:1 + will be used.

+
proxiesHeader +

Name of the HTTP header created by this valve to hold the list of + proxies that have been processed in the incoming + remoteIpHeader. If not specified, the default of + x-forwarded-by is used.

+
requestAttributesEnabled +

Set to true to set the request attributes used by + AccessLog implementations to override the values returned by the + request for remote address, remote host, server port and protocol. + Request attributes are also used to enable the forwarded remote address + to be displayed on the status page of the Manager web application. + If not set, the default value of true will be used.

+
trustedProxies +

Regular expression (using java.util.regex) that a + proxy's IP address must match to be considered an trusted proxy. + Trusted proxies that appear in the remoteIpHeader will + be trusted and will appear in the proxiesHeader value. + If not specified, no proxies will be trusted.

+
protocolHeader +

Name of the HTTP Header read by this valve that holds the protocol + used by the client to connect to the proxy. If not specified, the + default of X-Forwarded-Proto is used.

+
hostHeader +

Name of the HTTP Header read by this valve that holds the host + used by the client to connect to the proxy. If not specified, the + default of null is used.

+
portHeader +

Name of the HTTP Header read by this valve that holds the port + used by the client to connect to the proxy. If not specified, the + default of null is used.

+
protocolHeaderHttpsValue +

Value of the protocolHeader to indicate that it is + an HTTPS request. If not specified, the default of https is + used.

+
httpServerPort +

Value returned by ServletRequest.getServerPort() + when the protocolHeader indicates http + protocol and no portHeader is present. If not + specified, the default of 80 is used.

+
httpsServerPort +

Value returned by ServletRequest.getServerPort() + when the protocolHeader indicates https + protocol and no portHeader is present. If not + specified, the default of 443 is used.

+
changeLocalName +

If true, the value returned by + ServletRequest.getLocalName() and + ServletRequest.getServerName() is modified by the this + filter. If not specified, the default of false is used.

+
changeLocalPort +

If true, the value returned by + ServletRequest.getLocalPort() and + ServletRequest.getServerPort() is modified by the this + filter. If not specified, the default of false is used.

+
+ + +
+ +
Request Dumper Filter
+ +
Introduction
+ +

The Request Dumper Filter logs information from the request and response + objects and is intended to be used for debugging purposes. When using this + Filter, it is recommended that the + org.apache.catalina.filter.RequestDumperFilter logger is + directed to a dedicated file and that the + org.apache.juli.VerbatimFormatter is used.

+ +

WARNING: Using this filter has side-effects. The + output from this filter includes any parameters included with the request. + The parameters will be decoded using the default platform encoding. Any + subsequent calls to request.setCharacterEncoding() within + the web application will have no effect.

+ +
+ +
Filter Class Name
+ +

The filter class name for the Request Dumper Filter is + org.apache.catalina.filters.RequestDumperFilter + .

+ +
+ +
Initialisation parameters
+ +

The Request Dumper Filter does not support any initialization + parameters.

+ +
+ +
Sample Configuration
+ +

The following entries in a web application's web.xml would enable the + Request Dumper filter for all requests for that web application. If the + entries were added to CATALINA_BASE/conf/web.xml, the Request + Dumper Filter would be enabled for all web applications.

+
<filter>
+    <filter-name>requestdumper</filter-name>
+    <filter-class>
+        org.apache.catalina.filters.RequestDumperFilter
+    </filter-class>
+</filter>
+<filter-mapping>
+    <filter-name>requestdumper</filter-name>
+    <url-pattern>*</url-pattern>
+</filter-mapping>
+ +

The following entries in CATALINA_BASE/conf/logging.properties would + create a separate log file for the Request Dumper Filter output.

+
# To this configuration below, 1request-dumper.org.apache.juli.FileHandler
+# also needs to be added to the handlers property near the top of the file
+1request-dumper.org.apache.juli.FileHandler.level = INFO
+1request-dumper.org.apache.juli.FileHandler.directory = ${catalina.base}/logs
+1request-dumper.org.apache.juli.FileHandler.prefix = request-dumper.
+1request-dumper.org.apache.juli.FileHandler.encoding = UTF-8
+1request-dumper.org.apache.juli.FileHandler.formatter = org.apache.juli.VerbatimFormatter
+org.apache.catalina.filters.RequestDumperFilter.level = INFO
+org.apache.catalina.filters.RequestDumperFilter.handlers = \
+  1request-dumper.org.apache.juli.FileHandler
+
+
Session Initializer Filter
+ +
Introduction
+

The Session Initializer Filter initializes the javax.servlet.http.HttpSession + before the Request is processed. This is required for JSR-356 compliant WebSocket implementations, + if the HttpSession is needed during the HandShake phase.

+ +

The Java API for WebSocket does not mandate that an HttpSession would + be initialized upon request, and thus javax.servlet.http.HttpServletRequest's + getSession() returns null if the HttpSession was not + initialized in advance.

+ +

This filter solves that problem by initializing the HttpSession for any HttpServletRequest + that matches its url-pattern.

+
+ +
Filter Class Name
+

The filter class name for the Session Initializer Filter is + org.apache.catalina.filters.SessionInitializerFilter.

+
+ +
Initialisation parameters
+

The Session Initializer Filter does not support any initialization parameters.

+
+ +
Sample Configuration
+

The following entries in the Web Application Deployment Descriptor, web.xml, + would enable the Session Initializer Filter for requests that match the given URL pattern + (in this example, "/ws/*").

+ +
<filter>
+    <filter-name>SessionInitializer</filter-name>
+    <filter-class>org.apache.catalina.filters.SessionInitializerFilter</filter-class>
+</filter>
+<filter-mapping>
+    <filter-name>SessionInitializer</filter-name>
+    <url-pattern>/ws/*</url-pattern>
+</filter-mapping>
+
+
Set Character Encoding Filter
+ +
Introduction
+ +

User agents don't always include character encoding information in + requests. Depending on the how the request is processed, usually the + default encoding of ISO-8859-1 is used. This is not always + desirable. This filter provides options for setting that encoding or + forcing it to a particular value. Essentially this filter calls + ServletRequest.setCharacterEncoding() method.

+ +

Effectively the value set by this filter is used when parsing parameters + in a POST request, if parameter parsing occurs later than this filter. Thus + the order of filter mappings is important. Note that the encoding for GET + requests is not set here, but on a Connector. See + CharacterEncoding page in the FAQ for details.

+ +
+ +
Filter Class Name
+ +

The filter class name for the Set Character Encoding Filter is + org.apache.catalina.filters.SetCharacterEncodingFilter + .

+ +
+ +
Initialisation parameters
+ +

The Set Character Encoding Filter supports the following initialization + parameters:

+ +
AttributeDescription
encoding +

Name of the character encoding which should be set.

+
ignore +

Determines if any character encoding specified by the user agent is + ignored. If this attribute is true, any value provided by + the user agent is ignored. If false, the encoding is only + set if the user agent did not specify an encoding. The default value + is false.

+
+ +
+ +
WebDAV Fix Filter
+ +
Introduction
+ +

Microsoft operating systems have two WebDAV clients. One is used with + port 80, the other is used for all other ports. The implementation used with + port 80 does not adhere to the WebDAV specification and fails when trying to + communicate with the Tomcat WebDAV Servlet. This Filter provides a fix for + this by forcing the use of the WebDAV implementation that works, even when + connecting via port 80.

+ +
+ +
Filter Class Name
+ +

The filter class name for the WebDAV Fix Filter is + org.apache.catalina.filters.WebdavFixFilter + .

+ +
+ +
Initialisation parameters
+ +

The WebDAV Fix Filter does not support any initialization parameters.

+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/globalresources.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/globalresources.html new file mode 100644 index 0000000..b3c5008 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/globalresources.html @@ -0,0 +1,281 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The GlobalNamingResources Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The GlobalNamingResources Component

Table of Contents
+ +
Introduction
+ +

The GlobalNamingResources element defines the global + JNDI resources for the Server.

+ +

These resources are listed in the server's global JNDI resource context. + This context is distinct from the per-web-application JNDI contexts + described in + the JNDI Resources HOW-TO. + The resources defined in this element are not visible in + the per-web-application contexts unless you explicitly link them with + <ResourceLink> elements. +

+ +
Attributes
+ +
Nested Components
+ +
Special Features
+ + +
Environment Entries
+ +

You can configure named values that will be made visible to all + web applications as environment entry resources by nesting + <Environment> entries inside this element. For + example, you can create an environment entry like this:

+
<GlobalNamingResources ...>
+  ...
+  <Environment name="maxExemptions" value="10"
+         type="java.lang.Integer" override="false"/>
+  ...
+</GlobalNamingResources>
+ +

This is equivalent to the inclusion of the following element in the + web application deployment descriptor (/WEB-INF/web.xml): +

+
<env-entry>
+  <env-entry-name>maxExemptions</env-entry-name>
+  <env-entry-value>10</env-entry-value>
+  <env-entry-type>java.lang.Integer</env-entry-type>
+</env-entry>
+

but does not require modification of the deployment descriptor + to customize this value.

+ +

The valid attributes for an <Environment> element + are as follows:

+ +
AttributeDescription
description +

Optional, human-readable description of this environment entry.

+
name +

The name of the environment entry to be created, relative to the + java:comp/env context.

+
override +

Set this to false if you do not want + an <env-entry> for the same environment entry name, + found in the web application deployment descriptor, to override the + value specified here. By default, overrides are allowed.

+
type +

The fully qualified Java class name expected by the web application + for this environment entry. Must be a legal value for + <env-entry-type> in the web application deployment + descriptor.

+
value +

The parameter value that will be presented to the application + when requested from the JNDI context. This value must be convertable + to the Java type defined by the type attribute.

+
+ +
+ + +
Resource Definitions
+ +

You can declare the characteristics of resources + to be returned for JNDI lookups of <resource-ref> and + <resource-env-ref> elements in the web application + deployment descriptor by defining them in this element and then linking + them with <ResourceLink> + elements + in the <Context> element. + + You MUST also define any other needed parameters using + attributes on the Resource element, to configure + the object factory to be used (if not known to Tomcat already), and + the properties used to configure that object factory.

+ +

For example, you can create a resource definition like this:

+
<GlobalNamingResources ...>
+  ...
+  <Resource name="jdbc/EmployeeDB" auth="Container"
+            type="javax.sql.DataSource"
+     description="Employees Database for HR Applications"/>
+  ...
+</GlobalNamingResources>
+ +

This is equivalent to the inclusion of the following element in the + web application deployment descriptor (/WEB-INF/web.xml):

+
<resource-ref>
+  <description>Employees Database for HR Applications</description>
+  <res-ref-name>jdbc/EmployeeDB</res-ref-name>
+  <res-ref-type>javax.sql.DataSource</res-ref-type>
+  <res-auth>Container</res-auth>
+</resource-ref>
+ +

but does not require modification of the deployment + descriptor to customize this value.

+ +

The valid attributes for a <Resource> element + are as follows:

+ +
AttributeDescription
auth +

Specify whether the web Application code signs on to the + corresponding resource manager programmatically, or whether the + Container will sign on to the resource manager on behalf of the + application. The value of this attribute must be + Application or Container. This + attribute is required if the web application + will use a <resource-ref> element in the web + application deployment descriptor, but is optional if the + application uses a <resource-env-ref> instead.

+
closeMethod +

Name of the zero-argument method to call on a singleton resource when + it is no longer required. This is intended to speed up clean-up of + resources that would otherwise happen as part of garbage collection. + This attribute is ignored if the singleton attribute is + false. If not specified, no default is defined and no close method will + be called.

+

For Apache Commons DBCP 1.x and Apache Tomcat JDBC connection pools + you can use closeMethod="close".

+
description +

Optional, human-readable description of this resource.

+
name +

The name of the resource to be created, relative to the + java:comp/env context.

+
scope +

Specify whether connections obtained through this resource + manager can be shared. The value of this attribute must be + Shareable or Unshareable. By default, + connections are assumed to be shareable.

+
singleton +

Specify whether this resource definition is for a singleton resource, + i.e. one where there is only a single instance of the resource. If this + attribute is true, multiple JNDI lookups for this resource + will return the same object. If this attribute is false, + multiple JNDI lookups for this resource will return different objects. + This attribute must be true for + javax.sql.DataSource resources to enable JMX registration + of the DataSource. The value of this attribute must be true + or false. By default, this attribute is true. +

+
type +

The fully qualified Java class name expected by the web + application when it performs a lookup for this resource.

+
+ + +
+ +
Resource Links
+

Use <ResourceLink> + elements to link resources from the global context into + per-web-application contexts. Here is an example of making a custom + factory available to an application, based on the example definition in the + + JNDI Resource HOW-TO: +

+ +
<Context>
+  <ResourceLink
+    name="bean/MyBeanFactory"
+    global="bean/MyBeanFactory"
+    type="com.mycompany.MyBean"
+  />
+</Context>
+ +
+ +
Transaction
+ +

You can declare the characteristics of the UserTransaction + to be returned for JNDI lookup for java:comp/UserTransaction. + You MUST define an object factory class to instantiate + this object as well as the needed resource parameters as attributes of the + Transaction + element, and the properties used to configure that object factory.

+ +

The valid attributes for the <Transaction> element + are as follows:

+ +
AttributeDescription
factory +

The class name for the JNDI object factory.

+
+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/host.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/host.html new file mode 100644 index 0000000..5a285c5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/host.html @@ -0,0 +1,644 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Host Container

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Host Container

Table of Contents
+ +
Introduction
+ +

The Host element represents a virtual host, + which is an association of a network name for a server (such as + "www.mycompany.com") with the particular server on which Tomcat is running. + For clients to be able to connect to a Tomcat server using its network name, + this name must be registered in the Domain Name Service (DNS) server + that manages the Internet domain you belong to - contact your Network + Administrator for more information.

+ +

In many cases, System Administrators wish to associate more than + one network name (such as www.mycompany.com and + company.com) with the same virtual host and applications. + This can be accomplished using the Host + Name Aliases feature discussed below.

+ +

One or more Host elements are nested inside an + Engine element. Inside the Host element, you + can nest Context elements for the web + applications associated with this virtual host. Exactly one of the Hosts + associated with each Engine MUST have a name matching the + defaultHost attribute of that Engine.

+ +

Clients normally use host names to identify the server they wish to connect + to. This host name is also included in the HTTP request headers. Tomcat + extracts the host name from the HTTP headers and looks for a + Host with a matching name. If no match is found, the request + is routed to the default host. The name of the default host does not have to + match a DNS name (although it can) since any request where the DNS name does + not match the name of a Host element will be routed to the + default host.

+ +

The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Host + support the following attributes:

+ +
AttributeDescription
appBase +

The Application Base directory for this virtual host. + This is the pathname of a directory that may contain web applications + to be deployed on this virtual host. You may specify an + absolute pathname, or a pathname that is relative to the + $CATALINA_BASE directory. See + Automatic Application + Deployment for more information on automatic recognition and + deployment of web applications. If not specified, the default of + webapps will be used.

+
xmlBase +

The XML Base directory for this virtual host. + This is the pathname of a directory that may contain context XML + descriptors to be deployed on this virtual host. You may specify an + absolute pathname for this directory, or a pathname that is relative + to the $CATALINA_BASE directory. See + Automatic Application + Deployment for more information on automatic recognition and + deployment of web applications. If not specified the default of + conf/<engine_name>/<host_name> will be used.

+
createDirs +

If set to true, Tomcat will attempt to create the directories defined + by the attributes appBase and xmlBase during + the startup phase. The default value is true. If set to + true, and directory creation fails, an error message will be printed out + but will not halt the startup sequence.

+
autoDeploy +

This flag value indicates if Tomcat should check periodically for new + or updated web applications while Tomcat is running. If true, Tomcat + periodically checks the appBase and xmlBase + directories and deploys any new web applications or context XML + descriptors found. Updated web applications or context XML descriptors + will trigger a reload of the web application. The flag's value defaults + to true. See + Automatic Application + Deployment for more information.

+
backgroundProcessorDelay +

This value represents the delay in seconds between the + invocation of the backgroundProcess method on this host and + its child containers, including all contexts. + Child containers will not be invoked if their delay value is not + negative (which would mean they are using their own processing + thread). Setting this to a positive value will cause + a thread to be spawn. After waiting the specified amount of time, + the thread will invoke the backgroundProcess method on this host + and all its child containers. A host will use background processing to + perform live web application deployment related tasks. If not + specified, the default value for this attribute is -1, which means + the host will rely on the background processing thread of its parent + engine.

+
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Host interface. + If not specified, the standard value (defined below) will be used.

+
deployIgnore +

A regular expression defining paths to ignore when + autoDeploy and deployOnStartup are set. This + allows you to keep your configuration in a version control system, for + example, and not deploy a .svn or CVS folder that happens to be in the + appBase.

+

This regular expression is relative to appBase. It is + also anchored, meaning the match is performed against the + entire file/directory name. So, foo matches only a file or + directory named foo but not foo.war, + foobar, or myfooapp. To match anything with + "foo", you could use .*foo.*.

+

See Automatic Application + Deployment for more information.

+
deployOnStartup +

This flag value indicates if web applications from this host should + be automatically deployed when Tomcat starts. The flag's value defaults + to true. See + Automatic Application + Deployment for more information.

+
failCtxIfServletStartFails +

Set to true to have each child contexts fail its startup + if any of its servlet that has load-on-startup >=0 fails its own + startup.

+

Each child context may override this attribute.

+

If not specified, the default value of false is + used.

+
name +

Usually the network name of this virtual host, as registered in your + Domain Name Service server. Regardless of the case used to + specify the host name, Tomcat will convert it to lower case internally. + One of the Hosts nested within an Engine MUST + have a name that matches the defaultHost setting for that + Engine. See Host Name Aliases for + information on how to assign more than one network name to the same + virtual host.

+
startStopThreads +

The number of threads this Host will use to start + child Context elements in parallel. The same + thread pool will be used to deploy new + Contexts if automatic deployment is being + used. The special value of 0 will result in the value of + Runtime.getRuntime().availableProcessors() being used. + Negative values will result in + Runtime.getRuntime().availableProcessors() + value being + used unless this is less than 1 in which case 1 thread will be used. If + not specified, the default value of 1 will be used.

+
undeployOldVersions +

This flag determines if Tomcat, as part of the auto deployment + process, will check for old, unused versions of web applications + deployed using parallel deployment and, if any are found, remove them. + This flag only applies if autoDeploy is true. If not + specified the default value of false will be used.

+
+ +
+ + +
Standard Implementation
+ +

The standard implementation of Host is + org.apache.catalina.core.StandardHost. + It supports the following additional attributes (in addition to the + common attributes listed above):

+ +
AttributeDescription
copyXML +

Set to true if you want a context XML descriptor + embedded inside the application (located at + /META-INF/context.xml) to be copied to xmlBase + when the application is deployed. On subsequent starts, the copied + context XML descriptor will be used in preference to any context XML + descriptor embedded inside the application even if the descriptor + embedded inside the application is more recent. The flag's value + defaults to false. Note if deployXML + is false, this attribute will have no effect.

+
deployXML +

Set to false if you want to disable parsing the context + XML descriptor embedded inside the application (located at + /META-INF/context.xml). Security conscious environments + should set this to false to prevent applications from + interacting with the container's configuration. The administrator will + then be responsible for providing an external context configuration + file, and putting it in the location defined by the + xmlBase attribute. If this flag is false, + a descriptor is located at /META-INF/context.xml and no + descriptor is present in xmlBase then the context will + fail to start in case the descriptor contains necessary configuration + for secure deployment (such as a RemoteAddrValve) which should not be + ignored. The flag's value defaults to true unless a + security manager is enabled when the default is false. + When running under a security manager this may be enabled on a per web + application basis by granting the + org.apache.catalina.security.DeployXmlPermission to the web + application. The Manager and Host Manager applications are granted this + permission by default so that they continue to work when running under a + security manager.

+
errorReportValveClass +

Java class name of the error reporting valve which will be used + by this Host. The responsibility of this valve is to output error + reports. Setting this property allows to customize the look of the + error pages which will be generated by Tomcat. This class must + implement the + org.apache.catalina.Valve interface. If none is specified, + the value org.apache.catalina.valves.ErrorReportValve + will be used by default.

+
unpackWARs +

Set to true if you want web applications that are + placed in the appBase directory as web application + archive (WAR) files to be unpacked into a corresponding disk directory + structure, false to run such web applications directly + from a WAR file. WAR files located outside of the Host's + appBase will not be expanded. See + Automatic Application + Deployment for more information.

+
workDir +

Pathname to a scratch directory to be used by applications for + this Host. Each application will have its own sub directory with + temporary read-write use. Configuring a Context workDir will override + use of the Host workDir configuration. This directory will be made + visible to servlets in the web application by a servlet context + attribute (of type java.io.File) named + javax.servlet.context.tempdir as described in the + Servlet Specification. If not specified, a suitable directory + underneath $CATALINA_BASE/work will be provided.

+
+ +
+ + +
Nested Components
+ +

You can nest one or more Context elements + inside this Host element, each representing a different web + application associated with this virtual host.

+ +

You can nest at most one instance of the following utility components + by nesting a corresponding element inside your Host + element:

+
    +
  • Realm - + Configure a realm that will allow its + database of users, and their associated roles, to be shared across all + Contexts nested inside this Host (unless + overridden by a Realm configuration + at a lower level).
  • +
+ +
Special Features
+ + +
Logging
+ +

A host is associated with the + org.apache.catalina.core.ContainerBase.[engine_name].[host_name] + log category. Note that the brackets are part of the name, + don't omit them.

+ +
+ + +
Access Logs
+ +

When you run a web server, one of the output files normally generated + is an access log, which generates one line of information for + each request processed by the server, in a standard format. Catalina + includes an optional Valve implementation that + can create access logs in the same standard format created by web servers, + or in any number of custom formats.

+ +

You can ask Catalina to create an access log for all requests + processed by an Engine, + Host, or Context + by nesting a Valve element like this:

+ +
<Host name="localhost" ...>
+  ...
+  <Valve className="org.apache.catalina.valves.AccessLogValve"
+         prefix="localhost_access_log." suffix=".txt"
+         pattern="common"/>
+  ...
+</Host>
+ +

See Access Logging Valves + for more information on the configuration attributes that are + supported.

+ +
+ + +
Automatic Application Deployment
+ +

If you are using the standard Host implementation with + default settings then applications in the appBase or with context + files in the configBase are automatically deployed when Tomcat + starts (the deployOnStartup property defaults to + true) and reloaded or redeployed (as appropriate) when a change + is detected while Tomcat is running (the autoDeploy attribute + also defaults to true).

+ +

deployOnStartup and autoDeploy trigger + execution of exactly the same code so the behaviour is very similar. + However, there is one key difference. When Tomcat starts it has no knowledge + of which files are the same, which have been changed and which are new. It + therefore treats all files as new. While Tomcat is running, it can + differentiate between unchanged, modified and new files. This leads to some + differences in behaviour between files being modified while Tomcat is + running and files being modified while Tomcat is stopped.

+ +

When you use automatic deployment, related files (a web application may + have a context.xml file, a WAR and a directory) that exist in the + Host's appBase and/or configBase + must conform to the expected naming + convention. In short, this means files for the same web application must + share the same base name.

+ +

The automatic deployment process identifies new and/or modified web + applications using the following search order:

+ +
    +
  1. Web applications with a context.xml file located in the Host's + configBase.
  2. +
  3. Web applications with a WAR file located in the Host's + appBase that have not already been identified during the scan for + context.xml files.
  4. +
  5. Web applications with a directory located in the Host's + appBase that have not already been identified during the scans + for context.xml and/or WAR files.
  6. +
+ +

When autoDeploy is true, the automatic + deployment process will monitor the deployed web applications for changes. + Depending on exactly what changes, the web application will either be + re-deployed or reloaded. Re-deployment involves the creation of a new web + application and, if using the standard session manager, user sessions will + not be retained. Reloading uses the existing web application but re-parses + the web.xml and reloads any classes. If using the standard session manager, + user sessions will be persisted.

+ +

Users may add to the files that the automatic deployment process monitors + for reloading (i.e. any change to one of these files triggers a reload of + the web application) by adding a WatchedResources element to the + context.xml file. See the + Context documentation for + further details.

+ +

When using automatic deployment, the docBase defined by + an XML Context file should be outside of the + appBase directory. If this is not the case, difficulties + may be experienced deploying the web application or the application may + be deployed twice. The deployIgnore attribute can be used + to avoid this situation.

+ +

Note that if you are defining contexts explicitly in server.xml, you + should probably turn off automatic application deployment or specify + deployIgnore carefully. Otherwise, the web applications + will each be deployed twice, and that may cause problems for the + applications.

+ +

There are many possible combinations of settings, new files, changed + files and deleted files. A separate page describes the + expected behaviour of the automatic + deployment process in many of these scenarios.

+ +
+ + +
Host Name Aliases
+ +

In many server environments, Network Administrators have configured + more than one network name (in the Domain Name Service (DNS) + server), that resolve to the IP address of the same server. Normally, + each such network name would be configured as a separate + Host element in conf/server.xml, each + with its own set of web applications.

+ +

However, in some circumstances, it is desirable that two or more + network names should resolve to the same virtual host, + running the same set of applications. A common use case for this + scenario is a corporate web site, where it is desirable that users + be able to utilize either www.mycompany.com or + company.com to access exactly the same content and + applications.

+ +

This is accomplished by utilizing one or more Alias + elements nested inside your Host element. For + example:

+
<Host name="www.mycompany.com" ...>
+  ...
+  <Alias>mycompany.com</Alias>
+  ...
+</Host>
+ +

In order for this strategy to be effective, all of the network names + involved must be registered in your DNS server to resolve to the + same computer that is running this instance of Catalina.

+ +
+ + +
Lifecycle Listeners
+ +

If you have implemented a Java object that needs to know when this + Host is started or stopped, you can declare it by + nesting a Listener element inside this element. The + class name you specify must implement the + org.apache.catalina.LifecycleListener interface, and + it will be notified about the occurrence of the corresponding + lifecycle events. Configuration of such a listener looks like this:

+ +
<Host name="localhost" ...>
+  ...
+  <Listener className="com.mycompany.mypackage.MyListener" ... >
+  ...
+</Host>
+ +

Note that a Listener can have any number of additional properties + that may be configured from this element. Attribute names are matched + to corresponding JavaBean property names using the standard property + method naming patterns.

+ +
+ + +
Request Filters
+ +

You can ask Catalina to check the IP address, or host name, on every + incoming request directed to the surrounding + Engine, Host, or + Context element. The remote address or name + will be checked against configured "accept" and/or "deny" + filters, which are defined using java.util.regex Regular + Expression syntax. Requests that come from locations that are + not accepted will be rejected with an HTTP "Forbidden" error. + Example filter declarations:

+ +
<Host name="localhost" ...>
+  ...
+  <Valve className="org.apache.catalina.valves.RemoteHostValve"
+         allow=".*\.mycompany\.com|www\.yourcompany\.com"/>
+  <Valve className="org.apache.catalina.valves.RemoteAddrValve"
+         deny="192\.168\.1\.\d+"/>
+  ...
+</Host>
+ +

See Remote Address Filter + and Remote Host Filter for + more information about the configuration options that are supported.

+ +
+ + +
Single Sign On
+ +

In many environments, but particularly in portal environments, it + is desirable to have a user challenged to authenticate themselves only + once over a set of web applications deployed on a particular virtual + host. This can be accomplished by nesting an element like this inside + the Host element for this virtual host:

+ +
<Host name="localhost" ...>
+  ...
+  <Valve className="org.apache.catalina.authenticator.SingleSignOn"/>
+  ...
+</Host>
+ +

The Single Sign On facility operates according to the following rules: +

+
    +
  • All web applications configured for this virtual host must share the + same Realm. In practice, that means you can + nest the Realm element inside this Host element (or the surrounding + Engine element), but not inside a + Context element for one of the involved + web applications.
  • +
  • As long as the user accesses only unprotected resources in any of the + web applications on this virtual host, they will not be challenged + to authenticate themselves.
  • +
  • As soon as the user accesses a protected resource in + any web application associated with this virtual + host, the user will be challenged to authenticate himself or herself, + using the login method defined for the web application currently + being accessed.
  • +
  • Once authenticated, the roles associated with this user will be + utilized for access control decisions across all + of the associated web applications, without challenging the user + to authenticate themselves to each application individually.
  • +
  • As soon as the user logs out of one web application (for example, + by invalidating the corresponding session if form + based login is used), the user's sessions in all + web applications will be invalidated. Any subsequent attempt to + access a protected resource in any application will require the + user to authenticate himself or herself again.
  • +
  • The Single Sign On feature utilizes HTTP cookies to transmit a token + that associates each request with the saved user identity, so it can + only be utilized in client environments that support cookies.
  • +
+ +
+ + +
User Web Applications
+ +

Many web servers can automatically map a request URI starting with + a tilde character ("~") and a username to a directory (commonly named + public_html) in that user's home directory on the server. + You can accomplish the same thing in Catalina by using a special + Listener element like this (on a Unix system that + uses the /etc/passwd file to identify valid users):

+ +
<Host name="localhost" ...>
+  ...
+  <Listener className="org.apache.catalina.startup.UserConfig"
+            directoryName="public_html"
+            userClass="org.apache.catalina.startup.PasswdUserDatabase"/>
+  ...
+</Host>
+ +

On a server where /etc/passwd is not in use, you can + request Catalina to consider all directories found in a specified base + directory (such as c:\Homes in this example) to be + considered "user home" directories for the purposes of this directive:

+ +
<Host name="localhost" ...>
+  ...
+  <Listener className="org.apache.catalina.startup.UserConfig"
+            directoryName="public_html"
+            homeBase="c:\Homes"
+            userClass="org.apache.catalina.startup.HomesUserDatabase"/>
+  ...
+</Host>
+ +

If a user home directory has been set up for a user named + craigmcc, then its contents will be visible from a + client browser by making a request to a URL like:

+ +
http://www.mycompany.com:8080/~craigmcc
+ +

Successful use of this feature requires recognition of the following + considerations:

+
    +
  • Each user web application will be deployed with characteristics + established by the global and host level default context settings.
  • +
  • It is legal to include more than one instance of this Listener + element. This would only be useful, however, in circumstances + where you wanted to configure more than one "homeBase" directory.
  • +
  • The operating system username under which Catalina is executed + MUST have read access to each user's web application directory, + and all of its contents.
  • +
+ +
+ +
Custom context.xml and web.xml
+

You can override the default values found in conf/context.xml and + conf/web.xml files from $CATALINA_BASE for each virtual host. + Tomcat will look for files named context.xml.default and web.xml.default + in the directory specified by xmlBase and merge the files into + those found in the default ones.

+
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/http.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/http.html new file mode 100644 index 0000000..bd536aa --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/http.html @@ -0,0 +1,1254 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The HTTP Connector

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The HTTP Connector

Table of Contents
+ +
Introduction
+ +

The HTTP Connector element represents a + Connector component that supports the HTTP/1.1 protocol. + It enables Catalina to function as a stand-alone web server, in addition + to its ability to execute servlets and JSP pages. A particular instance + of this component listens for connections on a specific TCP port number + on the server. One or more such Connectors can be + configured as part of a single Service, each + forwarding to the associated Engine to perform + request processing and create the response.

+ +

If you wish to configure the Connector that is used + for connections to web servers using the AJP protocol (such as the + mod_jk 1.2.x connector for Apache 1.3), please refer to the + AJP Connector documentation.

+ +

Each incoming request requires + a thread for the duration of that request. If more simultaneous requests + are received than can be handled by the currently available request + processing threads, additional threads will be created up to the + configured maximum (the value of the maxThreads attribute). + If still more simultaneous requests are received, they are stacked up + inside the server socket created by the Connector, up to + the configured maximum (the value of the acceptCount + attribute). Any further simultaneous requests will receive "connection + refused" errors, until resources are available to process them.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Connector + support the following attributes:

+ +
AttributeDescription
allowTrace +

A boolean value which can be used to enable or disable the TRACE + HTTP method. If not specified, this attribute is set to false.

+
asyncTimeout +

The default timeout for asynchronous requests in milliseconds. If not + specified, this attribute is set to 10000 (10 seconds).

+
discardFacades +

A boolean value which can be used to enable or disable the recycling + of the facade objects that isolate the container internal request + processing objects. If set to true the facades will be + set for garbage collection after every request, otherwise they will be + reused. This setting has no effect when the security manager is enabled. + If not specified, this attribute is set to the value of the + org.apache.catalina.connector.RECYCLE_FACADES system + property, or false if not set.

+
enableLookups +

Set to true if you want calls to + request.getRemoteHost() to perform DNS lookups in + order to return the actual host name of the remote client. Set + to false to skip the DNS lookup and return the IP + address in String form instead (thereby improving performance). + By default, DNS lookups are disabled.

+
encodedSolidusHandling +

When set to reject request paths containing a + %2f sequence will be rejected with a 400 response. When set + to decode request paths containing a %2f + sequence will have that sequence decoded to / at the same + time other %nn sequences are decoded. When set to + passthrough request paths containing a %2f + sequence will be processed with the %2f sequence unchanged. + If not specified the default value is reject. This default + may be modified if the deprecated system + property + org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH is + set.

+
maxHeaderCount +

The maximum number of headers in a request that are allowed by the + container. A request that contains more headers than the specified limit + will be rejected. A value of less than 0 means no limit. + If not specified, a default of 100 is used.

+
maxParameterCount +

The maximum number of parameter and value pairs (GET plus POST) which + will be automatically parsed by the container. Parameter and value pairs + beyond this limit will be ignored. A value of less than 0 means no limit. + If not specified, a default of 10000 is used. Note that + FailedRequestFilter filter can be + used to reject requests that hit the limit.

+
maxPostSize +

The maximum size in bytes of the POST which will be handled by + the container FORM URL parameter parsing. The limit can be disabled by + setting this attribute to a value less than zero. If not specified, this + attribute is set to 2097152 (2 megabytes). Note that the + FailedRequestFilter + can be used to reject requests that exceed this limit.

+
maxSavePostSize +

The maximum size in bytes of the POST which will be saved/buffered by + the container during FORM or CLIENT-CERT authentication. For both types + of authentication, the POST will be saved/buffered before the user is + authenticated. For CLIENT-CERT authentication, the POST is buffered for + the duration of the SSL handshake and the buffer emptied when the request + is processed. For FORM authentication the POST is saved whilst the user + is re-directed to the login form and is retained until the user + successfully authenticates or the session associated with the + authentication request expires. The limit can be disabled by setting this + attribute to -1. Setting the attribute to zero will disable the saving of + POST data during authentication. If not specified, this attribute is set + to 4096 (4 kilobytes).

+
parseBodyMethods +

A comma-separated list of HTTP methods for which request + bodies using application/x-www-form-urlencoded will be parsed + for request parameters identically to POST. This is useful in RESTful + applications that want to support POST-style semantics for PUT requests. + Note that any setting other than POST causes Tomcat + to behave in a way that goes against the intent of the servlet + specification. + The HTTP method TRACE is specifically forbidden here in accordance + with the HTTP specification. + The default is POST

+
port +

The TCP port number on which this Connector + will create a server socket and await incoming connections. Your + operating system will allow only one server application to listen + to a particular port number on a particular IP address. If the special + value of 0 (zero) is used, then Tomcat will select a free port at random + to use for this connector. This is typically only useful in embedded and + testing applications.

+
protocol +

Sets the protocol to handle incoming traffic. The default value is + HTTP/1.1 which uses an auto-switching mechanism to select + either a blocking Java based connector or an APR/native based connector. + If the PATH (Windows) or LD_LIBRARY_PATH (on + most unix systems) environment variables contain the Tomcat native + library, the APR/native connector will be used. If the native library + cannot be found, the blocking Java based connector will be used. Note + that the APR/native connector has different settings for HTTPS than the + Java connectors.
+ To use an explicit protocol rather than rely on the auto-switching + mechanism described above, the following values may be used:
+ org.apache.coyote.http11.Http11Protocol - + blocking Java connector
+ org.apache.coyote.http11.Http11NioProtocol - + non blocking Java connector
+ org.apache.coyote.http11.Http11AprProtocol - + the APR/native connector.
+ Custom implementations may also be used.
+ Take a look at our Connector + Comparison chart. The configuration for both Java connectors is + identical, for http and https.
+ For more information on the APR connector and APR specific SSL settings + please visit the APR documentation +

+
proxyName +

If this Connector is being used in a proxy + configuration, configure this attribute to specify the server name + to be returned for calls to request.getServerName(). + See Proxy Support for more + information.

+
proxyPort +

If this Connector is being used in a proxy + configuration, configure this attribute to specify the server port + to be returned for calls to request.getServerPort(). + See Proxy Support for more + information.

+
redirectPort +

If this Connector is supporting non-SSL + requests, and a request is received for which a matching + <security-constraint> requires SSL transport, + Catalina will automatically redirect the request to the port + number specified here.

+
scheme +

Set this attribute to the name of the protocol you wish to have + returned by calls to request.getScheme(). For + example, you would set this attribute to "https" + for an SSL Connector. The default value is "http". +

+
secure +

Set this attribute to true if you wish to have + calls to request.isSecure() to return true + for requests received by this Connector. You would want this on an + SSL Connector or a non SSL connector that is receiving data from a + SSL accelerator, like a crypto card, an SSL appliance or even a webserver. + The default value is false.

+
URIEncoding +

This specifies the character encoding used to decode the URI bytes, + after %xx decoding the URL. If not specified, ISO-8859-1 will be used. +

+
useBodyEncodingForURI +

This specifies if the encoding specified in contentType should be used + for URI query parameters, instead of using the URIEncoding. This + setting is present for compatibility with Tomcat 4.1.x, where the + encoding specified in the contentType, or explicitly set using + Request.setCharacterEncoding method was also used for the parameters from + the URL. The default value is false. +

+

Notes: 1) This setting is applied only to the + query string of a request. Unlike URIEncoding it does not + affect the path portion of a request URI. 2) If request character + encoding is not known (is not provided by a browser and is not set by + SetCharacterEncodingFilter or a similar filter using + Request.setCharacterEncoding method), the default encoding is always + "ISO-8859-1". The URIEncoding setting has no effect on + this default. +

+
useIPVHosts +

Set this attribute to true to cause Tomcat to use + the IP address that the request was received on to determine the Host + to send the request to. The default value is false.

+
xpoweredBy +

Set this attribute to true to cause Tomcat to advertise + support for the Servlet specification using the header recommended in the + specification. The default value is false.

+
+ +
+ +
Standard Implementation
+ +

The standard HTTP connectors (BIO, NIO and APR/native) all support the + following attributes in addition to the common Connector attributes listed + above.

+ +
AttributeDescription
acceptCount +

The maximum queue length for incoming connection requests when + all possible request processing threads are in use. Any requests + received when the queue is full will be refused. The default + value is 100.

+
acceptorThreadCount +

The number of threads to be used to accept connections. Increase this + value on a multi CPU machine, although you would never really need more + than 2. Also, with a lot of non keep alive connections, you + might want to increase this value as well. Default value is + 1.

+
acceptorThreadPriority +

The priority of the acceptor threads. The threads used to accept + new connections. The default value is 5 (the value of the + java.lang.Thread.NORM_PRIORITY constant). See the JavaDoc + for the java.lang.Thread class for more details on what + this priority means.

+
address +

For servers with more than one IP address, this attribute specifies + which address will be used for listening on the specified port. By + default, the connector will listen all local addresses. Unless the JVM is + configured otherwise using system properties, the Java based connectors + (BIO, NIO) will listen on both IPv4 and IPv6 addresses when configured + with either 0.0.0.0 or ::. The APR/native + connector will only listen on IPv4 addresses if configured with + 0.0.0.0 and will listen on IPv6 addresses and the equivalent + IPv4 address if present when configured with ::.

+
allowHostHeaderMismatch +

By default Tomcat will allow requests that specify a host in the + request line but specify a different host in the host header. This + check can be enabled by setting this attribute to false. If + not specified, the default is true.

+
allowedTrailerHeaders +

By default Tomcat will ignore all trailer headers when processing + chunked input. For a header to be processed, it must be added to this + comma-separated list of header names.

+
bindOnInit +

Controls when the socket used by the connector is bound. By default it + is bound when the connector is initiated and unbound when the connector is + destroyed. If set to false, the socket will be bound when the + connector is started and unbound when it is stopped.

+
compressibleMimeType +

The value is a comma separated list of MIME types for which HTTP + compression may be used. + The default value is + + text/html,text/xml,text/plain,text/css,text/javascript,application/javascript + . +

+
compression +

The Connector may use HTTP/1.1 GZIP compression in + an attempt to save server bandwidth. The acceptable values for the + parameter is "off" (disable compression), "on" (allow compression, which + causes text data to be compressed), "force" (forces compression in all + cases), or a numerical integer value (which is equivalent to "on", but + specifies the minimum amount of data before the output is compressed). If + the content-length is not known and compression is set to "on" or more + aggressive, the output will also be compressed. If not specified, this + attribute is set to "off".

+

Note: There is a tradeoff between using compression (saving + your bandwidth) and using the sendfile feature (saving your CPU cycles). + If the connector supports the sendfile feature, e.g. the NIO connector, + using sendfile will take precedence over compression. The symptoms will + be that static files greater that 48 Kb will be sent uncompressed. + You can turn off sendfile by setting useSendfile attribute + of the connector, as documented below, or change the sendfile usage + threshold in the configuration of the + DefaultServlet in the default + conf/web.xml or in the web.xml of your web + application. +

+
compressionMinSize +

If compression is set to "on" then this attribute + may be used to specify the minimum amount of data before the output is + compressed. If not specified, this attribute is defaults to "2048".

+
connectionLinger +

The number of seconds during which the sockets used by this + Connector will linger when they are closed. The default + value is -1 which disables socket linger.

+
connectionTimeout +

The number of milliseconds this Connector will wait, + after accepting a connection, for the request URI line to be + presented. Use a value of -1 to indicate no (i.e. infinite) timeout. + The default value is 60000 (i.e. 60 seconds) but note that the standard + server.xml that ships with Tomcat sets this to 20000 (i.e. 20 seconds). + Unless disableUploadTimeout is set to false, + this timeout will also be used when reading the request body (if any).

+
connectionUploadTimeout +

Specifies the timeout, in milliseconds, to use while a data upload is + in progress. This only takes effect if + disableUploadTimeout is set to false. +

+
disableUploadTimeout +

This flag allows the servlet container to use a different, usually + longer connection timeout during data upload. If not specified, this + attribute is set to true which disables this longer timeout. +

+
executor +

A reference to the name in an Executor + element. If this attribute is set, and the named executor exists, the + connector will use the executor, and all the other thread attributes will + be ignored. Note that if a shared executor is not specified for a + connector then the connector will use a private, internal executor to + provide the thread pool.

+
executorTerminationTimeoutMillis +

The time that the private internal executor will wait for request + processing threads to terminate before continuing with the process of + stopping the connector. If not set, the default is 0 (zero) + for the BIO connector and 5000 (5 seconds) for the NIO and + APR/native connectors.

+
keepAliveTimeout +

The number of milliseconds this Connector will wait + for another HTTP request before closing the connection. The default value + is to use the value that has been set for the + connectionTimeout attribute. + Use a value of -1 to indicate no (i.e. infinite) timeout.

+
maxConnections +

The maximum number of connections that the server will accept and + process at any given time. When this number has been reached, the server + will accept, but not process, one further connection. This additional + connection be blocked until the number of connections being processed + falls below maxConnections at which point the server will + start accepting and processing new connections again. Note that once the + limit has been reached, the operating system may still accept connections + based on the acceptCount setting. The default value varies by + connector type. For BIO the default is the value of + maxThreads unless an Executor + is used in which case the default will be the value of maxThreads from the + executor. For NIO the default is 10000. + For APR/native, the default is 8192.

+

For NIO only, setting the value to -1, will disable the + maxConnections feature and connections will not be counted.

+
maxCookieCount +

The maximum number of cookies that are permitted for a request. A value + of less than zero means no limit. If not specified, a default value of 200 + will be used.

+
maxExtensionSize +

Limits the total length of chunk extensions in chunked HTTP requests. + If the value is -1, no limit will be imposed. If not + specified, the default value of 8192 will be used.

+
maxHttpHeaderSize +

The maximum size of the request and response HTTP header, specified + in bytes. If not specified, this attribute is set to 8192 (8 KB).

+
maxKeepAliveRequests +

The maximum number of HTTP requests which can be pipelined until + the connection is closed by the server. Setting this attribute to 1 will + disable HTTP/1.0 keep-alive, as well as HTTP/1.1 keep-alive and + pipelining. Setting this to -1 will allow an unlimited amount of + pipelined or keep-alive HTTP requests. + If not specified, this attribute is set to 100.

+
maxSwallowSize +

The maximum number of request body bytes (excluding transfer encoding + overhead) that will be swallowed by Tomcat for an aborted upload. An + aborted upload is when Tomcat knows that the request body is going to be + ignored but the client still sends it. If Tomcat does not swallow the body + the client is unlikely to see the response. If not specified the default + of 2097152 (2 megabytes) will be used. A value of less than zero indicates + that no limit should be enforced.

+
maxThreads +

The maximum number of request processing threads to be created + by this Connector, which therefore determines the + maximum number of simultaneous requests that can be handled. If + not specified, this attribute is set to 200. If an executor is associated + with this connector, this attribute is ignored as the connector will + execute tasks using the executor rather than an internal thread pool. Note + that if an executor is configured any value set for this attribute will be + recorded correctly but it will be reported (e.g. via JMX) as + -1 to make clear that it is not used.

+
maxTrailerSize +

Limits the total length of trailing headers in the last chunk of + a chunked HTTP request. If the value is -1, no limit will be + imposed. If not specified, the default value of 8192 will be + used.

+
minSpareThreads +

The minimum number of threads always kept running. This includes both + active and idle threads. If not specified, the default of 10 + is used. If an executor is associated with this connector, this attribute + is ignored as the connector will execute tasks using the executor rather + than an internal thread pool. Note that if an executor is configured any + value set for this attribute will be recorded correctly but it will be + reported (e.g. via JMX) as -1 to make clear that it is not + used.

+
noCompressionStrongETag +

This flag configures whether resources with a strong ETag will be + considered for compression. If true, resources with a strong + ETag will not be compressed. The default value is true.

+

This attribute is deprecated. It will be removed in Tomcat 10 onwards + where it will be hard-coded to true.

+
noCompressionUserAgents +

The value is a regular expression (using java.util.regex) + matching the user-agent header of HTTP clients for which + compression should not be used, + because these clients, although they do advertise support for the + feature, have a broken implementation. + The default value is an empty String (regexp matching disabled).

+
processorCache +

The protocol handler caches Processor objects to speed up performance. + This setting dictates how many of these objects get cached. + -1 means unlimited, default is 200. If not using + Servlet 3.0 asynchronous processing, a good default is to use the same as + the maxThreads setting. If using Servlet 3.0 asynchronous processing, a + good default is to use the larger of maxThreads and the maximum number of + expected concurrent requests (synchronous and asynchronous).

+
rejectIllegalHeader +

If an HTTP request is received that contains an illegal header name or + value (e.g. the header name is not a token) this setting determines if the + request will be rejected with a 400 response (true) or if the + illegal header be ignored (false). The default value is + false which will cause the request to be processed but the + illegal header will be ignored.

+
rejectIllegalHeaderName +

This attribute is deprecated. It will be removed in Tomcat 10 onwards. + It is now an alias for rejectIllegalHeader.

+
relaxedPathChars +

The HTTP/1.1 + specification requires that certain characters are %nn encoded when + used in URI paths. Unfortunately, many user agents including all the major + browsers are not compliant with this specification and use these + characters in unencoded form. To prevent Tomcat rejecting such requests, + this attribute may be used to specify the additional characters to allow. + If not specified, no additional characters will be allowed. The value may + be any combination of the following characters: + " < > [ \ ] ^ ` { | } . Any other characters + present in the value will be ignored.

+
relaxedQueryChars +

The HTTP/1.1 + specification requires that certain characters are %nn encoded when + used in URI query strings. Unfortunately, many user agents including all + the major browsers are not compliant with this specification and use these + characters in unencoded form. To prevent Tomcat rejecting such requests, + this attribute may be used to specify the additional characters to allow. + If not specified, no additional characters will be allowed. The value may + be any combination of the following characters: + " < > [ \ ] ^ ` { | } . Any other characters + present in the value will be ignored.

+
restrictedUserAgents +

The value is a regular expression (using java.util.regex) + matching the user-agent header of HTTP clients for which + HTTP/1.1 or HTTP/1.0 keep alive should not be used, even if the clients + advertise support for these features. + The default value is an empty String (regexp matching disabled).

+
server +

Overrides the Server header for the http response. If set, the value + for this attribute overrides the Tomcat default and any Server header set + by a web application. If not set, any value specified by the application + is used. If the application does not specify a value then + Apache-Coyote/1.1 is used. Unless you are paranoid, you won't + need this feature. +

+
socketBuffer +

The size (in bytes) of the buffer to be provided for socket + output buffering. -1 can be specified to disable the use of a buffer. + By default, a buffers of 9000 bytes will be used.

+
SSLEnabled +

Use this attribute to enable SSL traffic on a connector. + To turn on SSL handshake/encryption/decryption on a connector + set this value to true. + The default value is false. + When turning this value true you will want to set the + scheme and the secure attributes as well + to pass the correct request.getScheme() and + request.isSecure() values to the servlets + See SSL Support for more information. +

+
tcpNoDelay +

If set to true, the TCP_NO_DELAY option will be + set on the server socket, which improves performance under most + circumstances. This is set to true by default.

+
threadPriority +

The priority of the request processing threads within the JVM. + The default value is 5 (the value of the + java.lang.Thread.NORM_PRIORITY constant). See the JavaDoc + for the java.lang.Thread class for more details on what + this priority means. If an executor is associated + with this connector, this attribute is ignored as the connector will + execute tasks using the executor rather than an internal thread pool. Note + that if an executor is configured any value set for this attribute will be + recorded correctly but it will be reported (e.g. via JMX) as + -1 to make clear that it is not used.

+
upgradeAsyncWriteBufferSize +

The default size of the buffer to allocate to for asynchronous writes + that can not be completed in a single operation, specified in bytes. Data that can't be + written immediately will be stored in this buffer until it can be written. + If more data needs to be stored than space is available in the buffer than + the size of the buffer will be increased for the duration of the write. If + not specified the default value of 8192 will be used.

+
+ +
+ +
Java TCP socket attributes
+ +

The BIO and NIO implementation support the following Java TCP socket + attributes in addition to the common Connector and HTTP attributes listed + above.

+ +
AttributeDescription
socket.rxBufSize +

(int)The socket receive buffer (SO_RCVBUF) size in bytes. JVM default + used if not set.

+
socket.txBufSize +

(int)The socket send buffer (SO_SNDBUF) size in bytes. JVM default + used if not set. Care should be taken if explicitly setting this value. + Very poor performance has been observed on some JVMs with values less + than ~8k.

+
socket.tcpNoDelay +

(bool)This is equivalent to standard attribute + tcpNoDelay.

+
socket.soKeepAlive +

(bool)Boolean value for the socket's keep alive setting + (SO_KEEPALIVE). JVM default used if not set.

+
socket.ooBInline +

(bool)Boolean value for the socket OOBINLINE setting. JVM default + used if not set.

+
socket.soReuseAddress +

(bool)Boolean value for the sockets reuse address option + (SO_REUSEADDR). JVM default used if not set.

+
socket.soLingerOn +

(bool)Boolean value for the sockets so linger option (SO_LINGER). + A value for the standard attribute connectionLinger + that is >=0 is equivalent to setting this to true. + A value for the standard attribute connectionLinger + that is <0 is equivalent to setting this to false. + Both this attribute and soLingerTime must be set else the + JVM defaults will be used for both.

+
socket.soLingerTime +

(int)Value in seconds for the sockets so linger option (SO_LINGER). + This is equivalent to standard attribute + connectionLinger. + Both this attribute and soLingerOn must be set else the + JVM defaults will be used for both.

+
socket.soTimeout +

This is equivalent to standard attribute + connectionTimeout.

+
socket.performanceConnectionTime +

(int)The first value for the performance settings. See + Socket Performance Options. + All three performance attributes must be set else the JVM defaults will + be used for all three.

+
socket.performanceLatency +

(int)The second value for the performance settings. See + Socket Performance Options. + All three performance attributes must be set else the JVM defaults will + be used for all three.

+
socket.performanceBandwidth +

(int)The third value for the performance settings. See + Socket Performance Options. + All three performance attributes must be set else the JVM defaults will + be used for all three.

+
socket.unlockTimeout +

(int) The timeout for a socket unlock. When a connector is stopped, it will try to release the acceptor thread by opening a connector to itself. + The default value is 250 and the value is in milliseconds

+
+
+ +
BIO specific configuration
+ +

The following attributes are specific to the BIO connector.

+ +
AttributeDescription
disableKeepAlivePercentage +

The percentage of processing threads that have to be in use before + HTTP keep-alives are disabled to improve scalability. Values less than + 0 will be changed to 0 and values greater than + 100 will be changed to 100. If not specified, + the default value is 75.

+
+ +
+ +
NIO specific configuration
+ +

The following attributes are specific to the NIO connector.

+ +
AttributeDescription
pollerThreadCount +

(int)The number of threads to be used to run for the polling events. + Default value is 1 per processor up to and including version 7.0.27. + Default value as of version 7.0.28 is 1 per processor but not more than 2.
+ When accepting a socket, the operating system holds a global lock. So the benefit of + going above 2 threads diminishes rapidly. Having more than one thread is for + system that need to accept connections very rapidly. However usually just + increasing acceptCount will solve that problem. + Increasing this value may also be beneficial when a large amount of send file + operations are going on. +

+
pollerThreadPriority +

(int)The priority of the poller threads. + The default value is 5 (the value of the + java.lang.Thread.NORM_PRIORITY constant). See the JavaDoc + for the java.lang.Thread class for more details on what + this priority means.

+
selectorTimeout +

(int)The time in milliseconds to timeout on a select() for the + poller. This value is important, since connection clean up is done on + the same thread, so do not set this value to an extremely high one. The + default value is 1000 milliseconds.

+
useComet +

(bool)Whether to allow comet servlets or not. Default value is + true.

+
useSendfile +

(bool)Use this attribute to enable or disable sendfile capability. + The default value is true.

+
socket.directBuffer +

(bool)Boolean value, whether to use direct ByteBuffers or java mapped + ByteBuffers. If true then + java.nio.ByteBuffer.allocateDirect() is used to allocate + the buffers, if false then + java.nio.ByteBuffer.allocate() is used. The default value + is false.
+ When you are using direct buffers, make sure you allocate the + appropriate amount of memory for the direct memory space. On Sun's JDK + that would be something like -XX:MaxDirectMemorySize=256m. +

+
socket.appReadBufSize +

(int)Each connection that is opened up in Tomcat get associated with + a read ByteBuffer. This attribute controls the size of this buffer. By + default this read buffer is sized at 8192 bytes. For lower + concurrency, you can increase this to buffer more data. For an extreme + amount of keep alive connections, decrease this number or increase your + heap size.

+
socket.appWriteBufSize +

(int)Each connection that is opened up in Tomcat get associated with + a write ByteBuffer. This attribute controls the size of this buffer. By + default this write buffer is sized at 8192 bytes. For low + concurrency you can increase this to buffer more response data. For an + extreme amount of keep alive connections, decrease this number or + increase your heap size.
+ The default value here is pretty low, you should up it if you are not + dealing with tens of thousands concurrent connections.

+
socket.bufferPool +

(int)The NIO connector uses a class called NioChannel that holds + elements linked to a socket. To reduce garbage collection, the NIO + connector caches these channel objects. This value specifies the size of + this cache. The default value is 500, and represents that + the cache will hold 500 NioChannel objects. Other values are + -1 for unlimited cache and 0 for no cache.

+
socket.bufferPoolSize +

(int)The NioChannel pool can also be size based, not used object + based. The size is calculated as follows:
+ NioChannel + buffer size = read buffer size + write buffer size
+ SecureNioChannel buffer size = application read buffer size + + application write buffer size + network read buffer size + + network write buffer size
+ The value is in bytes, the default value is 1024*1024*100 + (100MB).

+
socket.processorCache +

(int)Tomcat will cache SocketProcessor objects to reduce garbage + collection. The integer value specifies how many objects to keep in the + cache at most. The default is 500. Other values are + -1 for unlimited cache and 0 for no cache.

+
socket.keyCache +

(int)Tomcat will cache KeyAttachment objects to reduce garbage + collection. The integer value specifies how many objects to keep in the + cache at most. The default is 500. Other values are + -1 for unlimited cache and 0 for no cache.

+
socket.eventCache +

(int)Tomcat will cache PollerEvent objects to reduce garbage + collection. The integer value specifies how many objects to keep in the + cache at most. The default is 500. Other values are + -1 for unlimited cache and 0 for no cache.

+
selectorPool.maxSelectors +

(int)The max selectors to be used in the pool, to reduce selector + contention. Use this option when the command line + org.apache.tomcat.util.net.NioSelectorShared value is set + to false. Default value is 200.

+
selectorPool.maxSpareSelectors +

(int)The max spare selectors to be used in the pool, to reduce + selector contention. When a selector is returned to the pool, the system + can decide to keep it or let it be GC'd. Use this option when the + command line org.apache.tomcat.util.net.NioSelectorShared + value is set to false. Default value is -1 (unlimited).

+
command-line-options +

The following command line options are available for the NIO + connector:
+ -Dorg.apache.tomcat.util.net.NioSelectorShared=true|false + - default is true. Set this value to false if you wish to + use a selector for each thread. When you set it to false, you can + control the size of the pool of selectors by using the + selectorPool.maxSelectors attribute.

+
oomParachute +

(int)The NIO connector implements an OutOfMemoryError strategy called + parachute. It holds a chunk of data as a byte array. In case of an OOM, + this chunk of data is released and the error is reported. This will give + the VM enough room to clean up. The oomParachute represents + the size in bytes of the parachute(the byte array). The default value is + 1024*1024(1MB). Please note, this only works for OOM errors + regarding the Java Heap space, and there is absolutely no guarantee + that you will be able to recover at all. If you have an OOM outside of + the Java Heap, then this parachute trick will not help. +

+
+
+ +
APR/native specific configuration
+ +

The following attributes are specific to the APR/native connector.

+ +
AttributeDescription
deferAccept +

Sets the TCP_DEFER_ACCEPT flag on the listening socket + for this connector. The default value is true where + TCP_DEFER_ACCEPT is supported by the operating system, + otherwise it is false.

+
pollerSize +

Amount of sockets that the poller responsible for polling kept alive + connections can hold at a given time. Extra connections will be closed + right away. The default value is 8192, corresponding to 8192 keep-alive + connections. This is a synonym for maxConnections.

+
pollTime +

Duration of a poll call in microseconds. Lowering this value will + slightly decrease latency of connections being kept alive in some cases, + but will use more CPU as more poll calls are being made. The default + value is 2000 (2ms).

+
sendfileSize +

Amount of sockets that the poller responsible for sending static + files asynchronously can hold at a given time. Extra connections will be + closed right away without any data being sent (resulting in a zero + length file on the client side). Note that in most cases, sendfile is a + call that will return right away (being taken care of "synchronously" by + the kernel), and the sendfile poller will not be used, so the amount of + static files which can be sent concurrently is much larger than the + specified amount. The default value is 1024.

+
threadPriority +

(int)The priority of the acceptor and poller threads. + The default value is 5 (the value of the + java.lang.Thread.NORM_PRIORITY constant). See the JavaDoc + for the java.lang.Thread class for more details on what + this priority means.

+
useComet +

(bool)Whether to allow comet servlets or not. Default value is + true.

+
useSendfile +

(bool)Use this attribute to enable or disable sendfile capability. + The default value is true. Note that the use of sendfile + will disable any compression that Tomcat may otherwise have performed on + the response.

+
+ +
+ +
Nested Components
+ +

None at this time.

+ +
Special Features
+ + +
HTTP/1.1 and HTTP/1.0 Support
+ +

This Connector supports all of the required features + of the HTTP/1.1 protocol, as described in RFCs 7230-7235, including persistent + connections, pipelining, expectations and chunked encoding. If the client + supports only HTTP/1.0 or HTTP/0.9, the + Connector will gracefully fall back to supporting this + protocol as well. No special configuration is required to enable this + support. The Connector also supports HTTP/1.0 + keep-alive.

+ +

RFC 7230 requires that HTTP servers always begin their responses with + the highest HTTP version that they claim to support. Therefore, this + Connector will always return HTTP/1.1 at + the beginning of its responses.

+ +
+ + +
Proxy Support
+ +

The proxyName and proxyPort attributes can + be used when Tomcat is run behind a proxy server. These attributes + modify the values returned to web applications that call the + request.getServerName() and request.getServerPort() + methods, which are often used to construct absolute URLs for redirects. + Without configuring these attributes, the values returned would reflect + the server name and port on which the connection from the proxy server + was received, rather than the server name and port to whom the client + directed the original request.

+ +

For more information, see the + Proxy Support HOW-TO.

+ +
+ + +
SSL Support
+ +

You can enable SSL support for a particular instance of this + Connector by setting the SSLEnabled attribute to + true.

+ +

You will also need to set the scheme and secure + attributes to the values https and true + respectively, to pass correct information to the servlets.

+ +

The BIO and NIO connectors use the JSSE SSL whereas the APR/native + connector uses OpenSSL. Therefore, in addition to using different attributes + to configure SSL, the APR/native connector also requires keys and certificates + to be provided in a different format.

+ +

For more information, see the + SSL Configuration HOW-TO.

+ +
SSL Support - BIO and NIO
+ +

The BIO and NIO connectors use the following attributes to configure SSL: +

+ +
AttributeDescription
algorithm +

The certificate encoding algorithm to be used. This defaults to + KeyManagerFactory.getDefaultAlgorithm() which returns + SunX509 for Sun JVMs. IBM JVMs return + IbmX509. For other vendors, consult the JVM + documentation for the default value.

+
allowUnsafeLegacyRenegotiation +

Is unsafe legacy TLS renegotiation allowed which is likely to expose + users to CVE-2009-3555, a man-in-the-middle vulnerability in the TLS + protocol that allows an attacker to inject arbitrary data into the user's + request. If not specified, a default of false is used. This + attribute only has an effect if the JVM does not support RFC 5746 as + indicated by the presence of the pseudo-ciphersuite + TLS_EMPTY_RENEGOTIATION_INFO_SCSV. This is available JRE/JDK 6 update 22 + onwards. Where RFC 5746 is supported the renegotiation - including support + for unsafe legacy renegotiation - is controlled by the JVM configuration. +

+
useServerCipherSuitesOrder +

+ Set to true to enforce the server's cipher order + (from the ciphers setting). Set to false + to choose the first acceptable cipher suite presented by the client. + Use of this feature requires Java 8 or later. + Default is undefined, leaving the choice up to the JSSE + implementation. +

+
ciphers +

The comma separated list of encryption ciphers to support for HTTPS + connections. If specified, only the ciphers that are listed and supported + by the SSL implementation will be used. By default, the default ciphers + for the JVM will be used less those considered to be insecure. Note that + with older JVMs this will result in a very limited set of ciphers being + available by default. The ciphers are specified using the JSSE cipher + naming convention. The special value of ALL will enable all + supported ciphers. This will include many that are not secure. + ALL is intended for testing purposes only.

+
clientAuth +

Set to true if you want the SSL stack to require a + valid certificate chain from the client before accepting a connection. + Set to want if you want the SSL stack to request a client + Certificate, but not fail if one isn't presented. A false + value (which is the default) will not require a certificate chain + unless the client requests a resource protected by a security + constraint that uses CLIENT-CERT authentication.

+
clientCertProvider +

When client certificate information is presented in a form other than + instances of java.security.cert.X509Certificate it needs to + be converted before it can be used and this property controls which JSSE + provider is used to perform the conversion. For example it is used with + the AJP connectors, the HTTP APR connector and + with the + org.apache.catalina.valves.SSLValve. If not specified, the default + provider will be used.

+
crlFile +

The certificate revocation list to be used to verify client + certificates. If not defined, client certificates will not be checked + against a certificate revocation list. The file may be specified using a + URL, an absolute path or a relative (to CATALINA_BASE) path.

+
keyAlias +

The alias used for the server key and certificate in the keystore. If + not specified, the first key read from the keystore will be used. The + order in which keys are read from the keystore is implementation + dependent. It may not be the case that keys are read from the keystore in + the same order as they were added. If more than one key is present in the + keystore it is strongly recommended that a keyAlias is configured to + ensure that the correct key is used.

+
keyPass +

The password used to access the server certificate from the + specified keystore file. The default value is "changeit". +

+
keystoreFile +

The pathname of the keystore file where you have stored the + server certificate to be loaded. By default, the pathname is + the file ".keystore" in the operating system home + directory of the user that is running Tomcat. If your + keystoreType doesn't need a file use "" + (empty string) for this parameter. The file may be specified using a + URL, an absolute path or a relative (to CATALINA_BASE) path.

+
keystorePass +

The password used to access the specified keystore file. The default + value is the value of the keyPass attribute. +

+
keystoreProvider +

The name of the keystore provider to be used for the server + certificate. If not specified, the list of registered providers is + traversed in preference order and the first provider that supports the + keystoreType is used. +

+
keystoreType +

The type of keystore file to be used for the server certificate. + If not specified, the default value is "JKS". See the notes + on key store types below.

+
sessionCacheSize +

The number of SSL sessions to maintain in the session cache. Specify + -1 to use the implementation default. Values of zero and + above are passed to the implementation. Zero is used to specify an + unlimited cache size and is not recommended. If not specified, a default + of -1 is used.

+
sessionTimeout +

The time, in seconds, after the creation of an SSL session that it will + timeout. Specify -1 to use the implementation default. Values + of zero and above are passed to the implementation. Zero is used to + specify an unlimited timeout and is not recommended. If not specified, a + default of 86400 (24 hours) is used.

+
sslEnabledProtocols +

The comma separated list of SSL protocols to support for HTTPS + connections. If specified, only the protocols that are listed and + supported by the SSL implementation will be enabled. If not specified, + the JVM default (excluding SSLv2 and SSLv3 if the JVM enables either or + both of them by default) is used. The permitted values may be obtained from the + JVM documentation for the allowed values for + SSLSocket.setEnabledProtocols() e.g. + + Oracle Java 6 and + + Oracle Java 7. Note: There is overlap between this attribute and + sslProtocol.

+
sslImplementationName +

The class name of the SSL implementation to use. If not specified, the + default of org.apache.tomcat.util.net.jsse.JSSEImplementation + will be used which wraps JVM's default JSSE provider. Note that the + JVM can be configured to use a different JSSE provider as the default.

+
sslProtocol +

The SSL protocol(s) to use (a single value may enable multiple + protocols - see the JVM documentation for details). If not specified, the + default is TLS. The permitted values may be obtained from the + JVM documentation for the allowed values for algorithm when creating an + SSLContext instance e.g. + + Oracle Java 6 and + + Oracle Java 7. Note: There is overlap between this attribute and + sslEnabledProtocols.

+
trustManagerClassName +

The name of a custom trust manager class to use to validate client + certificates. The class must have a zero argument constructor and must + also implement javax.net.ssl.X509TrustManager. If this + attribute is set, the trust store attributes may be ignored. +

+
trustMaxCertLength +

The maximum number of intermediate certificates that will be allowed + when validating client certificates. If not specified, the default value + of 5 will be used.

+
truststoreAlgorithm +

The algorithm to use for truststore. If not specified, the default + value returned by + javax.net.ssl.TrustManagerFactory.getDefaultAlgorithm() is + used.

+
truststoreFile +

The trust store file to use to validate client certificates. The + default is the value of the javax.net.ssl.trustStore system + property. If neither this attribute nor the default system property is + set, no trust store will be configured. The file may be specified using a + URL, an absolute path or a relative (to CATALINA_BASE) path.

+
truststorePass +

The password to access the trust store. The default is the value of the + javax.net.ssl.trustStorePassword system property. If that + property is null, no trust store password will be configured. If an + invalid trust store password is specified, a warning will be logged and an + attempt will be made to access the trust store without a password which + will skip validation of the trust store contents.

+
truststoreProvider +

The name of the truststore provider to be used for the server + certificate. The default is the value of the + javax.net.ssl.trustStoreProvider system property. If + that property is null, the value of keystoreProvider is used + as the default. If neither this attribute, the default system property nor + keystoreProvider is set, the list of registered providers is + traversed in preference order and the first provider that supports the + truststoreType is used. +

+
truststoreType +

The type of key store used for the trust store. The default is the + value of the javax.net.ssl.trustStoreType system property. If + that property is null, the value of keystoreType is used as + the default. See the notes on key store + types below.

+
+ +
+ +
SSL Support - APR/Native
+ +

When APR/native is enabled, the HTTPS connector will use a socket poller + for keep-alive, increasing scalability of the server. It also uses OpenSSL, + which may be more optimized than JSSE depending on the processor being used, + and can be complemented with many commercial accelerator components. Unlike + the HTTP connector, the HTTPS connector cannot use sendfile to optimize static + file processing.

+ +

The HTTPS APR/native connector has the same attributes than the HTTP + APR/native connector, but adds OpenSSL specific ones. For the full details on + using OpenSSL, please refer to OpenSSL documentations and the many books + available for it (see the Official OpenSSL + website). The SSL specific attributes for the APR/native connector are: +

+ +
AttributeDescription
SSLCACertificateFile +

See + the mod_ssl documentation.

+
SSLCACertificatePath +

See + the mod_ssl documentation.

+
SSLCARevocationFile +

See + the mod_ssl documentation.

+
SSLCARevocationPath +

See + the mod_ssl documentation.

+
SSLCertificateChainFile +

See + the mod_ssl documentation.

+
SSLCACertificateFile +

Name of the file that contains the concatenated certificates for the + trusted certificate authorities. The format is PEM-encoded.

+
SSLCACertificatePath +

Name of the directory that contains the certificates for the trusted + certificate authorities. The format is PEM-encoded.

+
SSLCARevocationFile +

Name of the file that contains the concatenated certificate revocation + lists for the certificate authorities. The format is PEM-encoded.

+
SSLCARevocationPath +

Name of the directory that contains the certificate revocation lists + for the certificate authorities. The format is PEM-encoded.

+
SSLCertificateChainFile +

Name of the file that contains concatenated certifcates for the + certificate authorities which form the certifcate chain for the server + certificate. The format is PEM-encoded.

+
SSLCertificateFile +

Name of the file that contains the server certificate. The format is + PEM-encoded.

+

In addition to the certificate, the file can also contain as optional + elements DH parameters and/or an EC curve name for ephemeral keys, as + generated by openssl dhparam and openssl ecparam, + respectively. The output of the respective OpenSSL command can simply + be concatenated to the certificate file. This feature needs APR/native + version 1.1.34 or later.

+
SSLCertificateKeyFile +

Name of the file that contains the server private key. The format is + PEM-encoded. The default value is the value of "SSLCertificateFile" and in + this case both certificate and private key have to be in this file (NOT + RECOMMENDED).

+
SSLCipherSuite +

Ciphers which may be used for communicating with clients. The default + is "HIGH:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!kRSA". See the OpenSSL + documentation for details of the cipher configuration options.

+
SSLDisableCompression +

Disables compression if set to true and OpenSSL supports + disabling compression. Default is false which inherits the + default compression setting in OpenSSL.

+
SSLHonorCipherOrder +

Set to true to enforce the server's cipher order + (from the SSLCipherSuite setting) instead of allowing + the client to choose the cipher (which is the default).

+
SSLPassword +

Pass phrase for the encrypted private key. If "SSLPassword" is not + provided, the callback function should prompt for the pass phrase.

+
SSLProtocol +

The names of the protocols to support when communicating with clients. + This should be a list of any combination of the following: +

+
  • SSLv2
  • SSLv3
  • TLSv1
  • +
  • TLSv1.1
  • TLSv1.2
  • TLSv1.3
  • all
+

Each token in the list can be prefixed with a plus sign ("+") + or a minus sign ("-"). A plus sign adds the protocol, a minus sign + removes it form the current list. The list is built starting from + an empty list.

+

The token all is an alias for + TLSv1+TLSv1.1+TLSv1.2+TLSv1.3.

+

If more than one protocol is specified for an OpenSSL + based secure connector it will always support SSLv2Hello. If a + single protocol is specified it will not support + SSLv2Hello.

+

Note that SSLv2 and SSLv3 are inherently + unsafe.

+

If not specified, the default value of all will be + used.

+
SSLVerifyClient +

Ask client for certificate. The default is "none", meaning the client + will not have the opportunity to submit a certificate. Other acceptable + values include "optional", "require" and "optionalNoCA".

+
SSLVerifyDepth +

Maximum verification depth for client certificates. The default is + "10".

+
+ +
+ +
+ +
Key store types
+ +

In addition to the standard key store types (JKS and PKCS12), most Java + runtimes support additional key store types such as Windows-ROOT, + Windows-My, DKS as well as hardware security modules. Generally, to use + these additional keystore types with a TLS Connector in Tomcat:

+ +
    +
  • Set the certificateKeystoreType and/or truststoreType Connector + attribute (as appropriate) to the necessary type
  • +
  • If a configuration file is required, set the certificateKeystoreFile + and/or truststoreFile Connector attribute (as appropriate) to point to + the file
  • +
  • If no configuration file is required then you will almost certainly + need to explicitly set the certificateKeystoreFile and/or + truststoreFile Connector attribute (as appropriate) to the empty + string ("")
  • +
  • If a password is required, set the certificateKeystorePassword and/or + truststorePassword Connector attribute (as appropriate) to the + required password
  • +
  • If no password is required then you will almost certainly need to + explicitly set the certificateKeystorePassword and/or + truststorePassword Connector attribute (as appropriate) to the empty + string ("")
  • +
+ +

Variations in key store implementations, combined with the key store + manipulation Tomcat does in the background to allow interoperability between + JSSE and OpenSSL configuration styles, means that some keystores may need + slightly different configuration. Assistance is always available from the + Apache Tomcat + users mailing list. We aim to document any key stores that vary from the + above advice here. Currently there are none we are aware of.

+ +
+ +
Connector Comparison
+ +

Below is a small chart that shows how the connectors differ.

+

+                       Java Blocking Connector   Java Non Blocking Connector   APR/native Connector
+                                 BIO                         NIO                       APR
+    Classname              Http11Protocol             Http11NioProtocol         Http11AprProtocol
+    Tomcat Version            since 3.x                  since 6.0.x               since 5.5.x
+    Support Polling              NO                          YES                       YES
+    Polling Size                 N/A                   maxConnections             maxConnections
+    Read Request Headers      Blocking                  Non Blocking                 Blocking
+    Read Request Body         Blocking                    Blocking                   Blocking
+    Write Response            Blocking                    Blocking                   Blocking
+    Wait for next Request     Blocking                  Non Blocking               Non Blocking
+    SSL Support               Java SSL                    Java SSL                   OpenSSL
+    SSL Handshake             Blocking                  Non blocking                 Blocking
+    Max Connections        maxConnections              maxConnections             maxConnections
+
+
+    
+ +
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/index.html new file mode 100644 index 0000000..6cd9ee9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/index.html @@ -0,0 +1,142 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - Overview

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

Overview

Overview
+ +

This manual contains reference information about all of the configuration +directives that can be included in a conf/server.xml file to +configure the behavior of the Tomcat 7 Servlet/JSP container. It does not +attempt to describe which configuration directives should be used to perform +specific tasks - for that, see the various HOW-TO documents on the +main index page.

+ +

Tomcat configuration files are formatted as schemaless XML; elements and +attributes are case-sensitive. Apache Ant-style variable substitution +is supported; a system property with the name propname may be +used in a configuration file using the syntax ${propname}. All +system properties are available including those set using the -D +syntax, those automatically made available by the JVM and those configured in +the $CATALINA_BASE/conf/catalina.properties file. +

+ +

The configuration element descriptions are organized into the following +major categories:

+
    +
  • Top Level Elements - <Server> is the + root element of the entire configuration file, while + <Service> represents a group of Connectors that is + associated with an Engine.
  • +
  • Connectors - Represent the interface between external + clients sending requests to (and receiving responses from) a particular + Service.
  • +
  • Containers - Represent components whose function is to + process incoming requests, and create the corresponding responses. + An Engine handles all requests for a Service, a Host handles all requests + for a particular virtual host, and a Context handles all requests for a + specific web application.
  • +
  • Nested Components - Represent elements that can be + nested inside the element for a Container. Some elements can be nested + inside any Container, while others can only be nested inside a + Context.
  • +
+ +

For each element, the corresponding documentation follows this general +outline:

+
    +
  • Introduction - Overall description of this particular + component. There will be a corresponding Java interface (in + the org.apache.catalina package) that is implemented by one + or more standard implementations.
  • +
  • Attributes - The set of attributes that are legal for + this element. Generally, this will be subdivided into Common + attributes that are supported by all implementations of the corresponding + Java interface, and Standard Implementation attributes that are + specific to a particular Java class that implements this interface. + The names of required attributes are bolded.
  • +
  • Nested Components - Enumerates which of the Nested + Components can be legally nested within this element.
  • +
  • Special Features - Describes the configuration of a large + variety of special features (specific to each element type) that are + supported by the standard implementation of this interface.
  • +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/jar-scanner.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/jar-scanner.html new file mode 100644 index 0000000..be18f42 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/jar-scanner.html @@ -0,0 +1,165 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Jar Scanner Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Jar Scanner Component

Table of Contents
+ +
Introduction
+ +

The Jar Scanner element represents the component that is + used to scan the web application for JAR files. It is typically used during + web application start to identify configuration files such as TLDs or + web-fragment.xml files that must be processed as part of the web application + initialisation.

+ +

A Jar Scanner element MAY be nested inside a + Context component. If it is not included, + a default Jar Scanner configuration will be created automatically, which + is sufficient for most requirements.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Jar Scanner + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the org.apache.tomcat.JarScanner interface. + If not specified, the standard value (defined below) will be used.

+
+ +
+ + +
Standard Implementation
+ +

The standard implementation of Jar Scanner is + org.apache.tomcat.util.scan.StandardJarScanner. + Additional attributes that it supports (in addition to the common attributes + listed above) are listed in the table.

+ +

There are several + system properties + that control what JAR files are skipped by JarScanner. + Those properties are lists of file name pattern. The + patterns are separated by comma (','). The leading and trailing whitespace + characters in a pattern are ignored. The patterns are matched + case-sensitively. The following two special characters are supported:

+ +
    +
  • '*' — means zero or more characters,
  • +
  • '?' — means one and only one character.
  • +
+ +
AttributeDescription
scanAllDirectories +

If true, any directories found on the classpath will be + checked to see if they are expanded JAR files. + The default is false.

+

Tomcat determines if a directory is an expanded JAR file by looking + for a META-INF sub-directory. Only if the META-INF sub-directory exists, + the directory is assumed to be an expanded JAR file.

+
scanAllFiles +

If true, any files found on the classpath will be checked + to see if they are Jar files rather than relying on the file extension + being .jar. The default is false.

+
scanClassPath +

If true, the full web application classpath, including + the shared and common classloaders and the system classpath (but not the + bootstrap classpath) will be scanned for Jar files in addition to the web + application. The default is true.

+
scanBootstrapClassPath +

If scanClassPath is true and this is + true the bootstrap classpath will also be scanned for Jar + files. The default is false.

+
+ +
+ + +
Nested Components
+

No components may be nested inside a Jar Scanner element. +

+
Special Features
+

No special features are associated with a Jar Scanner + element.

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/listeners.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/listeners.html new file mode 100644 index 0000000..176320e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/listeners.html @@ -0,0 +1,591 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The LifeCycle Listener Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The LifeCycle Listener Component

Table of Contents
+ +
Introduction
+ +

A Listener element defines a component that performs + actions when specific events occur, usually Tomcat starting or Tomcat + stopping.

+ +

Listeners may be nested inside a Server, + Engine, Host or + Context. Some Listeners are only intended to be + nested inside specific elements. These constraints are noted in the + documentation below.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Listener + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.LifecycleListener + interface.

+
+ +
+ +
Nested Components
+ +

No element may be nested inside a Listener.

+ +
Standard Implementations
+ +

Unlike most Catalina components, there are several standard + Listener implementations available. As a result, + the className attribute MUST be used to select the + implementation you wish to use.

+ +
APR Lifecycle Listener - org.apache.catalina.core.AprLifecycleListener
+ +

The APR Lifecycle Listener checks for the presence of + the APR/native library and loads the library if it is present. For more + information see the APR/native guide.

+ +

This listener must only be nested within Server + elements.

+ +

The following additional attributes are supported by the APR + Lifecycle Listener:

+ +
AttributeDescription
SSLEngine +

Name of the SSLEngine to use. off: do not use SSL, + on: use SSL but no specific ENGINE.

+

The default value is on. This initializes the + native SSL engine, which must be enabled in the APR/native connector by + the use of the SSLEnabled attribute.

+

See the Official OpenSSL website + for more details on supported SSL hardware engines and manufacturers. +

+
SSLRandomSeed +

Entropy source used to seed the SSLEngine's PRNG. The default value + is builtin. On development systems, you may want to set + this to /dev/urandom to allow quicker start times.

+
FIPSMode +

Set to on to request that OpenSSL be in FIPS mode + (if OpenSSL is already in FIPS mode, it will remain in FIPS mode). + Set to enter to force OpenSSL to enter FIPS mode (an error + will occur if OpenSSL is already in FIPS mode). + Set to require to require that OpenSSL already be + in FIPS mode (an error will occur if OpenSSL is not already in FIPS + mode).

+

FIPS mode requires you to have a FIPS-capable OpenSSL library which + you must build yourself. + If this attribute is set to any of the above values, the SSLEngine + must be enabled as well.

+

The default value is off.

+
+ +
+ +
Jasper Listener - org.apache.catalina.core.JasperListener
+ +

The Jasper Listener initializes the Jasper 2 JSP engine + before any web applications that may use it are loaded. For more + information on the Jasper 2 JSP engine see the + Jasper How To.

+ +

This listener must only be nested within Server + elements.

+ +

No additional attributes are supported by the Jasper Listener + .

+ +
+ +
Global Resources Lifecycle Listener - org.apache.catalina.mbeans.GlobalResourcesLifecycleListener
+ +

The Global Resources Lifecycle Listener initializes the + Global JNDI resources defined in server.xml as part of the Global Resources element. Without this + listener, none of the Global Resources will be available.

+ +

This listener must only be nested within Server + elements.

+ +

No additional attributes are supported by the Global Resources + Lifecycle Listener.

+ +
+ +
JNI Library Loading Listener - org.apache.catalina.core.JniLifecycleListener
+ +

The JNI Library Loading Listener makes it possible + for multiple Webapps to use a native library, by loading the native + library using a shared class loader (typically the Common class loader but + may vary in some configurations)

+ +

The listener supports two mutually exclusive attributes, so one of them must be used, but you can not use both together:

+ +
AttributeDescription
libraryName +

The name of the native library, as defined in + java.lang.System.loadLibrary() +

+
libraryPath +

The absolute path of the native library, as defined in + java.lang.System.load() +

+
+
+ +
JRE Memory Leak Prevention Listener - org.apache.catalina.core.JreMemoryLeakPreventionListener
+ +

The JRE Memory Leak Prevention Listener provides + work-arounds for known places where the Java Runtime environment uses + the context class loader to load a singleton as this will cause a memory + leak if a web application class loader happens to be the context class + loader at the time. The work-around is to initialise these singletons when + this listener starts as Tomcat's common class loader is the context class + loader at that time. It also provides work-arounds for known issues that + can result in locked JAR files.

+ +

This listener must only be nested within Server + elements.

+ +

The following additional attributes are supported by the JRE + Memory Leak Prevention Listener:

+ +
AttributeDescription
appContextProtection +

Enables protection so that calls to + sun.awt.AppContext.getAppContext() triggered by a web + application do not result in a memory leak. Note that a call to this + method will be triggered as part of the web application stop process + when running on Java 6. It is therefore strongly recommended that this + protection is enabled when running on Java 6. The default is + true for Java 6. The default is false for Java + 7. This protection is disabled if running on Java 8 onwards since the + leak has been fixed for Java 8 onwards.

+
AWTThreadProtection +

Enables protection so that calls to + java.awt.Toolkit.getDefaultToolkit() triggered by a web + application do not result in a memory leak. + Defaults to false because an AWT thread is launched. This + protection is disabled if running on Java 9 onwards since the leak has + been fixed for Java 9 onwards.

+
classesToInitialize +

List of comma-separated fully qualified class names to load and initialize + during the startup of this Listener. This allows to pre-load classes that are + known to provoke classloader leaks if they are loaded during a request + processing. Non-JRE classes may be referenced, like + oracle.jdbc.driver.OracleTimeoutThreadPerVM. + The default value is empty, but specific JRE classes are loaded by other leak + protection features managed by other attributes of this Listener.

+
driverManagerProtection +

The first use of java.sql.DriverManager will trigger the + loading of JDBC Drivers visible to the current class loader and its + parents. The web application level memory leak protection can take care + of this in most cases but triggering the loading here has fewer + side-effects. The default is true.

+
forkJoinCommonPoolProtection +

Enables protection so the threads created for + ForkJoinPool.commonPool() do not result in a memory leak. + The protection is enabled by setting the + java.util.concurrent.ForkJoinPool.common.threadFactory + system property. If this property is set when Tomcat starts, Tomcat will + not over-ride it even if this protection is explicitly enabled. The + default is true. This protection is only used when running + on Java 8. The common pool does not exist in earlier versions and the + leak has been fixed for Java 9 onwards.

+
gcDaemonProtection +

Enables protection so that calls to + sun.misc.GC.requestLatency(long) triggered by a web + application do not result in a memory leak. Use of RMI is likely to + trigger a call to this method. A side effect of enabling this protection + is the creation of a thread named "GC Daemon". The protection uses + reflection to access internal Sun classes and may generate errors on + startup on non-Sun JVMs. The default is true. This + protection is disabled if running on Java 9 onwards since the leak has + been fixed for Java 9 onwards.

+
java2DDisposerProtection +

Enables protection so that loading the + sun.java2d.Disposer class by a web application does not + result in a memory leak. + Defaults to false because a thread is launched.

+

Note: The underlying leak has been fixed in Java 1.6.0 update 21 + onwards and Java 7 onwards. This option is unnecessary if running on a + fixed version of Java.

+
ldapPoolProtection +

Enables protection so that the PoolCleaner thread started by + com.sun.jndi.ldap.LdapPoolManager does not result in a + memory leak. The thread is started the first time the + LdapPoolManager class is used if the system property + com.sun.jndi.ldap.connect.pool.timeout is set to a value + greater than 0. Without this protection, if a web application uses this + class the PoolCleaner thread will be configured with the thread's + context class loader set to the web application class loader which in + turn will trigger a memory leak on reload. Defaults to + true. This protection is disabled if running on Java 9 + onwards since the leak has been fixed for Java 9 onwards.

+
securityLoginConfigurationProtection +

Enables protection so that usage of the + javax.security.auth.login.Configuration class by a web + application does not provoke a memory leak. The first access of this + class will trigger the initializer that will retain a static reference + to the context class loader. The protection loads the class with the + system class loader to ensure that the static initializer is not + triggered by a web application. Defaults to true. This + protection is disabled if running on Java 8 onwards since the leak has + been fixed for Java 8 onwards.

+
securityPolicyProtection +

Enables protection so that usage of the deprecated + javax.security.auth.Policy class by a web application does not + result in a memory leak. The first access of this class will trigger the + static initializer that will retain a static reference to the context + class loader. The protection calls the getPolicy() method + of this class to ensure that the static initializer is not triggered by + a web application. Defaults to true.

+

Note: The underlying leak has been fixed in Java 7 update 51 onwards + and Java 8 onwards. This protection is therefor disabled if running on + Java 8 onwards.

+
tokenPollerProtection +

Enables protection so that any token poller thread initialized by + sun.security.pkcs11.SunPKCS11.initToken() does not + result in a memory leak. The thread is started depending on various + conditions as part of the initialization of the Java Cryptography + Architecture. Without the protection this can happen during Webapp + deployment when the MessageDigest for generating session IDs is + initialized. As a result the thread has the Webapp class loader as its + thread context class loader. Enabling the protection initializes JCA + early during Tomcat startup. Defaults to true. This + protection is disabled if running on Java 9 onwards since the leak has + been fixed for Java 9 onwards.

+
urlCacheProtection +

Enables protection so that reading resources from JAR files using + java.net.URLConnections does not result in the JAR file + being locked. Note that enabling this protection disables caching by + default for all resources obtained via + java.net.URLConnections. Caching may be re-enabled on a + case by case basis as required. Defaults to true.

+
xmlParsingProtection +

Enables protection so that parsing XML files within a web application + does not result in a memory leak. Note that memory profilers may not + display the GC root associated with this leak making it particularly + hard to diagnose. Defaults to true. This protection is + disabled if running on Java 9 onwards since the leak has been fixed for + Java 9 onwards.

+
+ +
JreMemoryLeakPreventionListener Examples
+ +

The following is an example of how to configure the + classesToInitialize attribute of this listener.

+ +

If this listener was configured in server.xml as:

+ +
  <Listener className="org.apache.catalina.core.JreMemoryLeakPreventionListener"
+            classesToInitialize="oracle.jdbc.driver.OracleTimeoutThreadPerVM" />
+ +

then the OracleTimeoutThreadPerVM class would be loaded + and initialized during listener startup instead of during request + processing.

+ +
+ +
+ +
Security Lifecycle Listener - org.apache.catalina.security.SecurityListener
+ +

The Security Lifecycle Listener performs a number of + security checks when Tomcat starts and prevents Tomcat from starting if they + fail. The listener is not enabled by default. To enabled it uncomment the + listener in $CATALINA_BASE/conf/server.xml. If the operating system supports + umask then the line in $CATALINA_HOME/bin/catalina.sh that obtains the umask + also needs to be uncommented.

+ +

This listener must only be nested within Server + elements.

+ +

The following additional attributes are supported by the Security + Lifecycle Listener:

+ +
AttributeDescription
checkedOsUsers +

A comma separated list of OS users that must not be used to start + Tomcat. If not specified, the default value of root is used. To + disable this check, set the attribute to the empty string. Usernames + are checked in a case-insensitive manner.

+
minimumUmask +

The least restrictive umask that must be configured before Tomcat + will start. If not specified, the default value of 0007 is used. + To disable this check, set the attribute to the empty string. The check + is not performed on Windows platforms.

+
+ +
+ +
ThreadLocal Leak Prevention Listener - org.apache.catalina.core.ThreadLocalLeakPreventionListener
+ +

The ThreadLocal Leak Prevention Listener triggers the + renewal of threads in Executor pools when a + Context is being stopped to avoid thread-local + related memory leaks. Active threads will be renewed one by one when they + come back to the pool after executing their task. The renewal happens + only for contexts that have their renewThreadsWhenStoppingContext + attribute set to true.

+ +

This listener must only be nested within Server + elements.

+ +

No additional attributes are supported by the ThreadLocal Leak + Prevention Listener.

+ +
+ +
UserConfig - org.apache.catalina.startup.UserConfig
+ +

The UserConfig provides feature of User Web Applications. + User Web Applications map a request URI starting with a tilde character ("~") + and a username to a directory (commonly named public_html) in that user's + home directory on the server.

+ +

See the User Web Applications + special feature on the Host element for more information.

+ +

The following additional attributes are supported by the + UserConfig:

+ +
AttributeDescription
directoryName +

The directory name to be searched for within each user home directory. + The default is public_html.

+
userClass +

The class name of the user database class. + There are currently two user database, the + org.apache.catalina.startup.PasswdUserDatabase is used on a + Unix system that uses the /etc/passwd file to identify valid users. + The org.apache.catalina.startup.HomesUserDatabase is used on + a server where /etc/passwd is not in use. HomesUserDatabase deploy all + directories found in a specified base directory.

+
homeBase +

The base directory containing user home directories. This is effective + only when org.apache.catalina.startup.HomesUserDatabase is + used.

+
allow +

A regular expression defining user who deployment is allowed. If this + attribute is specified, the user to deploy must match for this pattern. + If this attribute is not specified, all users will be deployed unless the + user matches a deny pattern.

+
deny +

A regular expression defining user who deployment is denied. If this + attribute is specified, the user to deploy must not match for this + pattern. If this attribute is not specified, deployment of user will be + governed by a allow attribute.

+
+ +
+ +
Version Logging Lifecycle Listener - org.apache.catalina.startup.VersionLoggerListener
+ +

The Version Logging Lifecycle Listener logs Tomcat, Java + and operating system information when Tomcat starts.

+ +

This listener must only be nested within Server + elements and should be the first listener defined.

+ +

The following additional attributes are supported by the Version + Logging Lifecycle Listener:

+ +
AttributeDescription
logArgs +

If true, the command line arguments passed to Java when + Tomcat started will be logged. If not specified, the default value of + true will be used.

+
logEnv +

If true, the current environment variables when Tomcat + starts will be logged. If not specified, the default value of + false will be used.

+
logProps +

If true, the current Java system properties will be + logged. If not specified, the default value of + false will be used.

+
+ +
+ +
Additional Implementations
+ +
System property replacement - org.apache.catalina.util.SystemPropertyReplacerListener
+ +

This listener performs system property replacement using the property + source configured on the digester. When ${parameter} + denoted parameters are found in the values of system properties, + the property source will be invoked to attempt to replace it.

+ +
+ +
Deprecated Implementations
+ +
JMX Remote Lifecycle Listener - org.apache.catalina.mbeans.JmxRemoteLifecycleListener
+ +

This listener is now deprecated as the features it provides are + now available in the remote JMX capability included with the JRE. This + listener will be removed in Tomcat 10 and may be removed from Tomcat 7 some + time after 2020-12-31.

+ +

This listener requires catalina-jmx-remote.jar to be placed + in $CATALINA_HOME/lib. This jar may be found in the extras + directory of the binary download area.

+ +

The JMX Remote Lifecycle Listener fixes the ports used by + the JMX/RMI Server making things much simpler if you need to connect + jconsole or a similar tool to a remote Tomcat instance that is running + behind a firewall. Only these ports are configured via the listener. The + remainder of the configuration is via the standard system properties for + configuring JMX. For further information on configuring JMX see + + Monitoring and Management Using JMX included with the Java SDK + documentation.

+ +

This listener must only be nested within a Server + element.

+ +

The following additional attributes are supported by the JMX Remote + Lifecycle Listener:

+ +
AttributeDescription
rmiRegistryPortPlatform +

The port to be used by the JMX/RMI registry for the Platform MBeans. + This replaces the use of the + com.sun.management.jmxremote.port system property that + should not be set when using this listener.

+
rmiServerPortPlatform +

The port to be used by the Platform JMX/RMI server.

+
rmiBindAddress +

The address of the interface to be used by JMX/RMI server.

+
useLocalPorts +

Should any clients using these ports be forced to use local ports to + connect to the JMX/RMI server. This is useful when tunnelling + connections over SSH or similar. Defaults to false.

+
+ +

Using file-based Authentication and Authorisation

+ +

If this listener was configured in server.xml as:

+
  <Listener className="org.apache.catalina.mbeans.JmxRemoteLifecycleListener"
+          rmiRegistryPortPlatform="10001" rmiServerPortPlatform="10002" />
+

with the following system properties set (e.g. in setenv.sh):

+
  -Dcom.sun.management.jmxremote.password.file=$CATALINA_BASE/conf/jmxremote.password
+  -Dcom.sun.management.jmxremote.access.file=$CATALINA_BASE/conf/jmxremote.access
+  -Dcom.sun.management.jmxremote.ssl=false
+

$CATALINA_BASE/conf/jmxremote.password containing:

+
admin letmein
+

$CATALINA_BASE/conf/jmxremote.access containing:

+
admin readwrite
+

then opening ports 10001 (RMI Registry) and 10002 (JMX/RMI Server) in your + firewall would enable jconsole to connect to a Tomcat instance running + behind a firewall using a connection string of the form:

+
service:jmx:rmi://<hostname>:10002/jndi/rmi://<hostname>:10001/jmxrmi
+

+ with a user name of admin and a password of + letmein. +

+ +

Using JAAS

+ +

If we use the following system properties instead:

+
  -Dcom.sun.management.jmxremote.login.config=Tomcat
+  -Djava.security.auth.login.config=$CATALINA_BASE/conf/login.config
+  -Dcom.sun.management.jmxremote.access.file=$CATALINA_BASE/conf/jmxremote.access
+  -Dcom.sun.management.jmxremote.ssl=false
+

$CATALINA_BASE/conf/login.config containing your choice of JAAS LoginModule implementation, for example:

+
  Tomcat { /* should match to the com.sun.management.jmxremote.login.config property */
+
+    /* for illustration purposes only */
+    com.sun.security.auth.module.LdapLoginModule REQUIRED
+      userProvider="ldap://ldap-svr/ou=people,dc=example,dc=com"
+      userFilter="(&(uid={USERNAME})(objectClass=inetOrgPerson))"
+      authzIdentity="admin"
+      debug=true;
+  };
+

$CATALINA_BASE/conf/jmxremote.access containing:

+
admin readwrite
+

+ then we would need to provide LDAP credentials instead. +

+ +

Note that the examples above do not use SSL. JMX access should + be considered equivalent to administrative access and secured accordingly. +

+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/loader.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/loader.html new file mode 100644 index 0000000..55cbb8f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/loader.html @@ -0,0 +1,225 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Loader Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Loader Component

Table of Contents
+ +
Introduction
+ +

The Loader element represents the web + application class loader that will be used to load Java + classes and resources for your web application. Such + a class loader must follow the requirements of the Servlet + Specification, and load classes from the following locations:

+
    +
  • From the /WEB-INF/classes directory inside your + web application.
  • +
  • From JAR files in the /WEB-INF/lib directory + inside your web application.
  • +
  • From resources made available by Catalina to all web + applications globally.
  • +
+ +

A Loader element MAY be nested inside a Context + component. If it is not included, a default Loader configuration will be + created automatically, which is sufficient for most requirements.

+ +

For a more in-depth description of the class loader hierarchy + that is implemented by Catalina, see the ClassLoader HowTo.

+ +

The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Loader + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Loader interface. + If not specified, the standard value (defined below) will be used.

+
delegate +

Set to true if you want the class loader to follow + the standard Java2 delegation model, and attempt to load classes from + parent class loaders before looking inside the web + application. Set to false (the default) to have the + class loader look inside the web application first, before asking + parent class loaders to find requested classes or resources.

+
reloadable +

Set to true if you want Catalina to monitor classes in + /WEB-INF/classes/ and /WEB-INF/lib for + changes, and automatically reload the web application if a change + is detected. This feature is very useful during application + development, but it requires significant runtime overhead and is + not recommended for use on deployed production applications. You + can use the Manager web + application, however, to trigger reloads of deployed applications + on demand.

+ +

NOTE - The value for this property will be + inherited from the reloadable attribute you set on + the surrounding Context component, + and any value you explicitly set here will be replaced.

+
+ +
+ + +
Standard Implementation
+ +

The standard implementation of Loader is + org.apache.catalina.loader.WebappLoader. + It supports the following additional attributes (in addition to the + common attributes listed above):

+ +
AttributeDescription
loaderClass +

Java class name of the java.lang.ClassLoader + implementation class to use. If not specified, the default value is + org.apache.catalina.loader.WebappClassLoader. Custom + loaderClass implementations must extend + org.apache.catalina.loader.WebappClassLoaderBase.The + default loaderClass is not parallel capable. A parallel + capable loaderClass is available when running on a Java + 7 or higher JRE and can be used by specifying + org.apache.catalina.loader.ParallelWebappClassLoader.

+
searchExternalFirst +

Set to true if you want repositories outside + of WEB-INF/classes and WEB-INF/lib to + be searched first. Default value is false.

+
jarOpenInterval +

The interval in milliseconds to keep all jar files open if no jar + is accessed. The default value is 90000 milliseconds. + A non-positive interval indicates keeping jars always open. +

+
+ +
+ +
VirtualWebappLoader Implementation
+ +

This implementation of Loader is + org.apache.catalina.loader.VirtualWebappLoader. + It extends WebappLoader and supports the following + additional attributes

+ +
AttributeDescription
virtualClasspath +

Additional repositories to search for resources. + Multiple values can be joined using ; + as a separator.

+

Leading and trailing whitespaces in values are ignored. + If a value does not point to an existing directory or + *.jar file, it is silently skipped. + Diagnostic messages can be seen if you enable debug logging for + the VirtualWebappLoader class. +

+

Example: virtualClasspath="${catalina.base}/myapp_config"

+
searchVirtualFirst +

Set to true if you want the virtual + class path to be searched before + WEB-INF/classes and WEB-INF/lib. + Default value is false.

+

If searched before, resources located in the virtual + class path take precendence over resources with the same + name contained in the webapp.

+
+ +
+ + +
Nested Components
+ +

No components may be nested inside a Loader element.

+ +
Special Features
+ +
Logging
+ +

A loader is associated with the log category based on its classname.

+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/manager.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/manager.html new file mode 100644 index 0000000..b23d20b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/manager.html @@ -0,0 +1,561 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Manager Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Manager Component

Table of Contents
+ +
Introduction
+ +

The Manager element represents the session + manager that will be used to create and maintain HTTP sessions + as requested by the associated web application.

+ +

A Manager element MAY be nested inside a + Context component. If it is not included, + a default Manager configuration will be created automatically, which + is sufficient for most requirements, — see + Standard Manager Implementation below for the details + of this configuration.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Manager + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Manager interface. + If not specified, the standard value (defined below) will be used.

+
distributable +

Deprecated: This should be configured via the + Context.

+

Set to true to ask the session manager to enforce + the restrictions described in the Servlet Specification on + distributable applications (primarily, this would mean that all + session attributes must implement java.io.Serializable). + Set to false (the default) to not enforce these + restrictions.

+ +

NOTE - The value for this property is inherited + automatically based on the presence or absence of the + <distributable> element in the web application + deployment descriptor (/WEB-INF/web.xml).

+
maxActiveSessions +

The maximum number of active sessions that will be created by + this Manager, or -1 (the default) for no limit.

+ +

When the limit is reached, any attempt to create a new session + (e.g. with HttpServletRequest.getSession() call) + will fail with an IllegalStateException.

+
maxInactiveInterval +

Deprecated: This should be configured via the + Context.

+

The initial maximum time interval, in seconds, + between client requests before a session is invalidated. A negative value + will result in sessions never timing out. If the attribute is not provided, + a default of 1800 seconds (30 minutes) is used.

+ +

This attribute provides the initial value whenever a + new session is created, but the interval may be dynamically + varied by a servlet via the + setMaxInactiveInterval method of the HttpSession object.

+
sessionIdLength +

The length of session ids created by this Manager, measured in bytes, + excluding subsequent conversion to a hexadecimal string and + excluding any JVM route information used for load balancing. + The default is 16. You should set the length on a nested + SessionIdGenerator element instead.

+
+ +
+ + +
Standard Implementation
+ +

Tomcat provides two standard implementations of Manager + for use — the default one stores active sessions, while the optional one + stores active sessions that have been swapped out (in addition to saving + sessions across a restart of Tomcat) in a storage location that is selected + via the use of an appropriate Store nested element.

+ +

Standard Manager Implementation

+ +

The standard implementation of Manager is + org.apache.catalina.session.StandardManager. + It supports the following additional attributes (in addition to the + common attributes listed above):

+ +
AttributeDescription
pathname +

Absolute or relative (to the work directory for this Context) + pathname of the file in which session state will be preserved + across application restarts, if possible. The default is + "SESSIONS.ser".
See + Persistence Across Restarts + for more information. This persistence may be + disabled by setting this attribute to an empty string.

+
persistAuthentication +

Should authentication information be included when session state is + preserved across application restarts? If true, the session's + authentication is preserved so that the session remains authenticated + after the application has been restarted. If not specified, the default + value of false will be used.
See + Persistence Across Restarts + for more information.

+ +

Please note that the session's Principal class as well + as its descendant classes are all subject to the + sessionAttributeValueClassNameFilter. If such a filter + is specified or a SecurityManager is enabled, the names of + the Principal class and descendant classes must match that + filter pattern in order to be restored.

+
processExpiresFrequency +

Frequency of the session expiration, and related manager operations. + Manager operations will be done once for the specified amount of + backgroundProcess calls (i.e., the lower the amount, the more often the + checks will occur). The minimum value is 1, and the default value is 6. +

+
secureRandomClass +

Name of the Java class that extends + java.security.SecureRandom to use to generate session IDs. + If not specified, the default value is + java.security.SecureRandom.

+
secureRandomProvider +

Name of the provider to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the Manager + will use the platform default provider and the default algorithm. If not + specified, the platform default provider will be used.

+
secureRandomAlgorithm +

Name of the algorithm to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the Manager + will use the platform default provider and the default algorithm. If not + specified, the default algorithm of SHA1PRNG will be used. If the + default algorithm is not supported, the platform default will be used. + To specify that the platform default should be used, do not set the + secureRandomProvider attribute and set this attribute to the empty + string.

+
sessionAttributeNameFilter +

A regular expression used to filter which session attributes will be + distributed. An attribute will only be distributed if its name matches + this pattern. If the pattern is zero length or null, all + attributes are eligible for distribution. The pattern is anchored so the + session attribute name must fully match the pattern. As an example, the + value (userName|sessionHistory) will only distribute the + two session attributes named userName and + sessionHistory. If not specified, the default value of + null will be used.

+
sessionAttributeValueClassNameFilter +

A regular expression used to filter which session attributes will be + distributed. An attribute will only be distributed if the implementation + class name of the value matches this pattern. If the pattern is zero + length or null, all attributes are eligible for + distribution. The pattern is anchored so the fully qualified class name + must fully match the pattern. If not specified, the default value of + null will be used unless a SecurityManager is + enabled in which case the default will be + java\\.lang\\.(?:Boolean|Integer|Long|Number|String)|org\\.apache\\.catalina\\.realm\\.GenericPrincipal\\$SerializablePrincipal|\\[Ljava.lang.String;.

+
warnOnSessionAttributeFilterFailure +

If sessionAttributeNameFilter or + sessionAttributeValueClassNameFilter blocks an + attribute, should this be logged at WARN level? If + WARN level logging is disabled then it will be logged at + DEBUG. The default value of this attribute is + false unless a SecurityManager is enabled in + which case the default will be true.

+
+ +

Persistent Manager Implementation

+ +

NOTE: You must set either the + org.apache.catalina.session.StandardSession.ACTIVITY_CHECK or + org.apache.catalina.STRICT_SERVLET_COMPLIANCE + system properties to true for + the persistent manager to work correctly.

+ +

The persistent implementation of Manager is + org.apache.catalina.session.PersistentManager. In + addition to the usual operations of creating and deleting sessions, a + PersistentManager has the capability to swap active (but + idle) sessions out to a persistent storage mechanism, as well as to save + all sessions across a normal restart of Tomcat. The actual persistent + storage mechanism used is selected by your choice of a + Store element nested inside the Manager + element - this is required for use of PersistentManager.

+ +

This implementation of Manager supports the following attributes in + addition to the Common Attributes + described earlier.

+ +
AttributeDescription
className +

It has the same meaning as described in the + Common Attributes above. + You must specify + org.apache.catalina.session.PersistentManager to use + this manager implementation.

+
maxIdleBackup +

The time interval (in seconds) since the last access to a session + before it is eligible for being persisted to the session store, or + -1 to disable this feature. By default, this feature is + disabled.

+
maxIdleSwap +

The maximum time a session may be idle before it is eligible to be + swapped to disk due to inactivity. Setting this to -1 means + sessions should not be swapped out just because of inactivity. If this + feature is enabled, the time interval specified here should be equal to + or longer than the value specified for maxIdleBackup. By + default, this feature is disabled.

+
minIdleSwap +

The minimum time in seconds a session must be idle before it is + eligible to be swapped to disk to keep the active session count below + maxActiveSessions. Setting to -1 means sessions will not be + swapped out to keep the active session count down. If specified, this + value should be less than that specified by maxIdleSwap. + By default, this value is set to -1.

+
persistAuthentication +

Should authentication information be included when sessions are + swapped out to persistent storage? If true, the session's + authentication is preserved so that the session remains authenticated + after being reloaded (swapped in) from persistent storage. If not + specified, the default value of false will be used.

+ +

Please note that the session's Principal class as well + as its descendant classes are all subject to the + sessionAttributeValueClassNameFilter. If such a filter + is specified or a SecurityManager is enabled, the names of + the Principal class and descendant classes must match that + filter pattern in order to be restored.

+
processExpiresFrequency +

It is the same as described above for the + org.apache.catalina.session.StandardManager class. +

+
saveOnRestart +

Should all sessions be persisted and reloaded when Tomcat is shut + down and restarted (or when this application is reloaded)? By default, + this attribute is set to true.

+
secureRandomClass +

It is the same as described above for the + org.apache.catalina.session.StandardManager class. +

+
secureRandomProvider +

It is the same as described above for the + org.apache.catalina.session.StandardManager class. +

+
secureRandomAlgorithm +

It is the same as described above for the + org.apache.catalina.session.StandardManager class. +

+
sessionAttributeNameFilter +

A regular expression used to filter which session attributes will be + distributed. An attribute will only be distributed if its name matches + this pattern. If the pattern is zero length or null, all + attributes are eligible for distribution. The pattern is anchored so the + session attribute name must fully match the pattern. As an example, the + value (userName|sessionHistory) will only distribute the + two session attributes named userName and + sessionHistory. If not specified, the default value of + null will be used.

+
sessionAttributeValueClassNameFilter +

A regular expression used to filter which session attributes will be + distributed. An attribute will only be distributed if the implementation + class name of the value matches this pattern. If the pattern is zero + length or null, all attributes are eligible for + distribution. The pattern is anchored so the fully qualified class name + must fully match the pattern. If not specified, the default value of + null will be used unless a SecurityManager is + enabled in which case the default will be + java\\.lang\\.(?:Boolean|Integer|Long|Number|String)|org\\.apache\\.catalina\\.realm\\.GenericPrincipal\\$SerializablePrincipal|\\[Ljava.lang.String;.

+
warnOnSessionAttributeFilterFailure +

If sessionAttributeNameFilter or + sessionAttributeValueClassNameFilter blocks an + attribute, should this be logged at WARN level? If + WARN level logging is disabled then it will be logged at + DEBUG. The default value of this attribute is + false unless a SecurityManager is enabled in + which case the default will be true.

+
+ +

In order to successfully use a PersistentManager, you must nest inside + it a <Store> element, as described below.

+ +
+ + +
Nested Components
+ +

All Manager Implementations

+ +

All Manager implementations bundled with Tomcat or extending + ManagerBase allow nesting of a + <SessionIdGenerator> element. It defines + the behavior of session id generation. All implementations + of the SessionIdGenerator allow the + following attributes: +

+ +
AttributeDescription
sessionIdLength +

The length of the session ID may be changed with the + sessionIdLength attribute. +

+
+ +

Persistent Manager Implementation

+ +

If you are using the Persistent Manager Implementation + as described above, you MUST nest a + <Store> element inside, which defines the + characteristics of the persistent data storage. Two implementations + of the <Store> element are currently available, + with different characteristics, as described below.

+ +
File Based Store
+ +

The File Based Store implementation saves swapped out + sessions in individual files (named based on the session identifier) + in a configurable directory. Therefore, you are likely to encounter + scalability problems as the number of active sessions increases, and + this should primarily be considered a means to easily experiment.

+ +

To configure this, add a <Store> nested inside + your <Manager> element with the following attributes: +

+ +
AttributeDescription
checkInterval +

The interval (in seconds) between checks for expired sessions + among those sessions that are currently swapped out. By default, + this interval is set to 60 seconds (one minute).

+
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Store interface. You + must specify + org.apache.catalina.session.FileStore + to use this implementation.

+
directory +

Absolute or relative (to the temporary work directory for this web + application) pathname of the directory into which individual session + files are written. If not specified, the temporary work directory + assigned by the container is utilized.

+
+ + +
JDBC Based Store
+ +

The JDBC Based Store implementation saves swapped out + sessions in individual rows of a preconfigured table in a database + that is accessed via a JDBC driver. With large numbers of swapped out + sessions, this implementation will exhibit improved performance over + the File Based Store described above.

+ +

To configure this, add a <Store> nested inside + your <Manager> element with the following attributes: +

+ +
AttributeDescription
checkInterval +

The interval (in seconds) between checks for expired sessions + among those sessions that are currently swapped out. By default, + this interval is set to 60 seconds (one minute).

+
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Store interface. You + must specify + org.apache.catalina.session.JDBCStore + to use this implementation.

+
connectionURL +

The connection URL that will be handed to the configured JDBC + driver to establish a connection to the database containing our + session table.

+
dataSourceName +

Name of the JNDI resource for a JDBC DataSource-factory. If this option + is given and a valid JDBC resource can be found, it will be used and any + direct configuration of a JDBC connection via connectionURL + and driverName will be ignored. Since this code uses prepared + statements, you might want to configure pooled prepared statements as + shown in the JNDI resources + HOW-TO.

+
driverName +

Java class name of the JDBC driver to be used.

+
sessionAppCol +

Name of the database column, contained in the specified session + table, that contains the Engine, Host, and Web Application Context + name in the format /Engine/Host/Context.

+
sessionDataCol +

Name of the database column, contained in the specified + session table, that contains the serialized form of all session + attributes for a swapped out session. The column type must accept + a binary object (typically called a BLOB).

+
sessionIdCol +

Name of the database column, contained in the specified + session table, that contains the session identifier of the + swapped out session. The column type must accept character + string data of at least as many characters as are contained + in session identifiers created by Tomcat (typically 32).

+
sessionLastAccessedCol +

Name of the database column, contained in the specified + session table, that contains the lastAccessedTime + property of this session. The column type must accept a + Java long (64 bits).

+
sessionMaxInactiveCol +

Name of the database column, contained in the specified + session table, that contains the maxInactiveInterval + property of this session. The column type must accept a + Java integer (32 bits).

+
sessionTable +

Name of the database table to be used for storing swapped out + sessions. This table must contain (at least) the database columns + that are configured by the other attributes of this element.

+
sessionValidCol +

Name of the database column, contained in the specified + session table, that contains a flag indicating whether this + swapped out session is still valid or not. The column type + must accept a single character.

+
+ +

Before attempting to use the JDBC Based Store for the first time, + you must create the table that will be used to store swapped out sessions. + Detailed SQL commands vary depending on the database you are using, but + a script like this will generally be required:

+ +
create table tomcat_sessions (
+  session_id     varchar(100) not null primary key,
+  valid_session  char(1) not null,
+  max_inactive   int not null,
+  last_access    bigint not null,
+  app_name       varchar(255),
+  session_data   mediumblob,
+  KEY kapp_name(app_name)
+);
+ +

In order for the JDBC Based Store to successfully connect to your + database, the JDBC driver you configure must be visible to Tomcat's + internal class loader. Generally, that means you must place the JAR + file containing this driver into the $CATALINA_HOME/lib + directory.

+ +
Special Features
+ + +
Persistence Across Restarts
+ +

Whenever Apache Tomcat is shut down normally and restarted, or when an + application reload is triggered, the standard Manager implementation + will attempt to serialize all currently active sessions to a disk + file located via the pathname attribute. All such saved + sessions will then be deserialized and activated (assuming they have + not expired in the mean time) when the application reload is completed.

+ +

In order to successfully restore the state of session attributes, + all such attributes MUST implement the java.io.Serializable + interface. You MAY cause the Manager to enforce this restriction by + including the <distributable> element in your web + application deployment descriptor (/WEB-INF/web.xml).

+ +

Note that, if persistAuthentication is also set to + true, the Principal class present in the session + MUST also implement the java.io.Serializable interface in order + to make authentication persistence work properly. The actual type of that + Principal class is determined by the + Realm implementation used with the application. Tomcat's standard + Principal class instantiated by most of the Realms (except + JAASRealm) implements java.io.Serializable.

+ +

The persistence across restarts provided by the + StandardManager is a simpler implementation than that + provided by the PersistentManager. If robust, production + quality persistence across restarts is required then the + PersistentManager should be used with an appropriate + configuration.

+ +
+ +
Disable Session Persistence
+ +

As documented above, every web application by default has + standard manager implementation configured, and it performs session + persistence across restarts. To disable this persistence feature, create + a Context configuration file for your web + application and add the following element there:

+ +
<Manager pathname="" />
+
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/realm.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/realm.html new file mode 100644 index 0000000..3f2b0e5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/realm.html @@ -0,0 +1,1031 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Realm Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Realm Component

Table of Contents
+ +
Introduction
+ +

A Realm element represents a "database" of usernames, + passwords, and roles (similar to Unix groups) assigned + to those users. Different implementations of Realm allow Catalina to be + integrated into environments where such authentication information is already + being created and maintained, and then utilize that information to implement + Container Managed Security as described in the Servlet + Specification.

+ +

A Catalina container (Engine, + Host, or Context) may + contain no more than one Realm element (although if supported by the Realm + this one Realm may itself contain multiple nested Realms). In addition, the + Realm associated with an Engine or a Host is automatically inherited by + lower-level containers unless the lower level container explicitly defines its + own Realm. If no Realm is configured for the Engine, an instance of the + Null Realm + will be configured for the Engine automatically.

+ +

For more in-depth information about container managed security in web + applications, as well as more information on configuring and using the + standard realm component implementations, please see the + Container-Managed Security Guide. +

+ +

The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Realm + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Realm interface.

+
+ +

Unlike most Catalina components, there are several standard + Realm implementations available. As a result, + the className attribute MUST be used to select the + implementation you wish to use.

+ +
+ + +
DataSource Database Realm - org.apache.catalina.realm.DataSourceRealm
+ +

The DataSource Database Realm connects Tomcat to + a relational database, accessed through a JNDI named JDBC DataSource + to perform lookups of usernames, passwords, and their associated + roles. Because the lookup is done each time that it is required, + changes to the database will be immediately reflected in the + information used to authenticate new logins.

+ +

The JDBC Realm uses a single db connection. This requires that + realm based authentication be synchronized, i.e. only one authentication + can be done at a time. This could be a bottleneck for applications + with high volumes of realm based authentications.

+ +

The DataSource Database Realm supports simultaneous realm based + authentications and allows the underlying JDBC DataSource to + handle optimizations like database connection pooling.

+ +

A rich set of additional attributes lets you configure the name + of the JNDI JDBC DataSource, as well as the table and + column names used to retrieve the required information:

+ +
AttributeDescription
allRolesMode +

This attribute controls how the special role name * is + handled when processing authorization constraints in web.xml. By + default, the specification compliant value of strict is + used which means that the user must be assigned one of the roles defined + in web.xml. The alternative values are authOnly which means + that the user must be authenticated but no check is made for assigned + roles and strictAuthOnly which means that the user must be + authenticated and no check will be made for assigned roles unless roles + are defined in web.xml in which case the user must be assigned at least + one of those roles.

+

When this attribute has the value of authOnly or + strictAuthOnly, the roleNameCol and + userRoleTable attributes become optional. If those two + attributes are omitted, the user's roles will not be loaded by this + Realm.

+
dataSourceName +

The name of the JNDI JDBC DataSource for this Realm.

+
digest +

The name of the MessageDigest algorithm used + to encode user passwords stored in the database. If not specified, + user passwords are assumed to be stored in clear-text.

+
localDataSource +

When the realm is nested inside a Context element, this allows the + realm to use a DataSource defined for the Context rather than a global + DataSource. If not specified, the default is false: use a + global DataSource.

+
roleNameCol +

Name of the column, in the "user roles" table, which contains + a role name assigned to the corresponding user.

+

This attribute is required in majority of + configurations. See allRolesMode attribute for + a rare case when it can be omitted.

+
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
stripRealmForGss +

When processing users authenticated via the GSS-API, this attribute + controls if any "@..." is removed from the end of the user + name. If not specified, the default is true.

+
userCredCol +

Name of the column, in the "users" table, which contains + the user's credentials (i.e. password). If a value for the + digest attribute is specified, this component + will assume that the passwords have been encoded with the + specified algorithm. Otherwise, they will be assumed to be + in clear text.

+
userNameCol +

Name of the column, in the "users" and "user roles" table, + that contains the user's username.

+
userRoleTable +

Name of the "user roles" table, which must contain columns + named by the userNameCol and roleNameCol + attributes.

+

This attribute is required in majority of + configurations. See allRolesMode attribute for + a rare case when it can be omitted.

+
userTable +

Name of the "users" table, which must contain columns named + by the userNameCol and userCredCol + attributes.

+
X509UsernameRetrieverClassName +

When using X509 client certificates, this specifies the class name + that will be used to retrieve the user name from the certificate. + The class must implement the + org.apache.catalina.realm.X509UsernameRetriever + interface. The default is to use the certificate's SubjectDN + as the username.

+
+ +

See the + DataSource Realm HOW-TO for more information on setting up container + managed security using the DataSource Database Realm component.

+ +
+ + +
JNDI Directory Realm - org.apache.catalina.realm.JNDIRealm
+ +

The JNDI Directory Realm connects Tomcat to + an LDAP Directory, accessed through an appropriate JNDI driver, + that stores usernames, passwords, and their associated + roles. Changes to the directory are immediately reflected in the + information used to authenticate new logins.

+ +

The directory realm supports a variety of approaches to using + LDAP for authentication:

+ +
    +
  • The realm can either use a pattern to determine the + distinguished name (DN) of the user's directory entry, or search + the directory to locate that entry. +
  • + +
  • The realm can authenticate the user either by binding to the + directory with the DN of the user's entry and the password + presented by the user, or by retrieving the password from the + user's entry and performing a comparison locally. +
  • + +
  • Roles may be represented in the directory as explicit entries + found by a directory search (e.g. group entries of which the user + is a member), as the values of an attribute in the user's entry, + or both. +
  • +
+ +

A rich set of additional attributes lets you configure the + required behaviour as well as the connection to the underlying + directory and the element and attribute names used to retrieve + information from the directory:

+ +
AttributeDescription
adCompat +

Microsoft Active Directory often returns referrals. + When iterating over NamingEnumerations these lead to + PartialResultExceptions. If you want us to ignore those exceptions, + set this attribute to "true". Unfortunately there's no stable way + to detect, if the Exceptions really come from an AD referral. + The default value is "false".

+
allRolesMode +

This attribute controls how the special role name * is + handled when processing authorization constraints in web.xml. By + default, the specification compliant value of strict is + used which means that the user must be assigned one of the roles defined + in web.xml. The alternative values are authOnly which means + that the user must be authenticated but no check is made for assigned + roles and strictAuthOnly which means that the user must be + authenticated and no check will be made for assigned roles unless roles + are defined in web.xml in which case the user must be assigned at least + one of those roles.

+
alternateURL +

If a socket connection can not be made to the provider at + the connectionURL an attempt will be made to use the + alternateURL.

+
authentication +

A string specifying the type of authentication to use. + "none", "simple", "strong" or a provider specific definition + can be used. If no value is given the providers default is used.

+
cipherSuites +

Specify which cipher suites are allowed when trying to open + a secured connection using StartTLS. The allowed cipher suites + are specified by a comma separated list. The default is to use the + cipher suites of the JVM.

+
commonRole +

A role name assigned to each successfully authenticated user in + addition to the roles retrieved from LDAP. If not specified, only + the roles retrieved via LDAP are used.

+
connectionName +

The directory username to use when establishing a + connection to the directory for LDAP search operations. If not + specified an anonymous connection is made, which is often + sufficient unless you specify the userPassword + property.

+
connectionPassword +

The directory password to use when establishing a + connection to the directory for LDAP search operations. If not + specified an anonymous connection is made, which is often + sufficient unless you specify the userPassword + property.

+
connectionTimeout +

The timeout in milliseconds to use when establishing the connection + to the LDAP directory. If not specified, a value of 5000 (5 seconds) is + used.

+
connectionURL +

The connection URL to be passed to the JNDI driver when + establishing a connection to the directory.

+
contextFactory +

Fully qualified Java class name of the factory class used + to acquire our JNDI InitialContext. By default, + assumes that the standard JNDI LDAP provider will be utilized.

+
derefAliases +

A string specifying how aliases are to be dereferenced during + search operations. The allowed values are "always", "never", + "finding" and "searching". If not specified, "always" is used.

+
digest +

The digest algorithm to apply to the plaintext password offered + by the user before comparing it with the value retrieved from the + directory. Valid values are those accepted for the algorithm name + by the java.security.MessageDigest class. If not + specified the plaintext password is assumed to be retrieved. Not + required unless userPassword is specified

+
forceDnHexEscape +

A setting of true forces escaping in the String + representation of a distinguished name to use the \nn form. + This may avoid issues with realms using Active Directory which appears + to be more tolerant of optional escaping when the \nn form + is used. If not specified, the default of false will be + used.

+
hostnameVerifierClassName +

The name of the class to use for hostname verification when + using StartTLS for securing the connection to the ldap server. + The default constructor will be used to construct an instance of + the verifier class. The default is to accept only those hostnames, + that are valid according to the peer certificate of the ldap + server.

+
protocol +

A string specifying the security protocol to use. If not given + the providers default is used.

+
readTimeout +

The timeout, in milliseconds, to use when trying to read from a + connection to the directory. If not specified, the default of 5000 + (5 seconds) is used.

+
referrals +

How do we handle JNDI referrals? Allowed values are + "ignore", "follow", or "throw" (see javax.naming.Context.REFERRAL + for more information). + Microsoft Active Directory often returns referrals. + If you need to follow them set referrals to "follow". + Caution: if your DNS is not part of AD, the LDAP client lib might try + to resolve your domain name in DNS to find another LDAP server.

+
roleBase +

The base directory entry for performing role searches. If not + specified the top-level element in the directory context will be used. + If specified it may optionally include pattern replacements + "{0}".."{n}" corresponding to the name parts of the + user's distinguished name (as returned by + javax.naming.Name.get()).

+
roleName +

The name of the attribute that contains role names in the + directory entries found by a role search. In addition you can + use the userRoleName property to specify the name + of an attribute, in the user's entry, containing additional + role names.

+

If roleName is not specified a role + search does not take place, and roles are taken only from the + user's entry.

+
roleNested +

Set to true if you want to nest roles into roles. + When a role search is performed and the value of this property is + true, the search will be repeated recursively to find + all the roles that belong to the user either directly or indirectly. + If not specified, the default value of false is used.

+
roleSearch +

The LDAP filter expression used for performing role + searches.

+ +

Use {0} to substitute the distinguished name (DN) + of the user, and/or {1} to substitute the username, + and/or {2} for the value of an attribute from the + user's directory entry, of the authenticated user. + The name of the attribute that provides the value for {2} + is configured by the userRoleAttribute property.

+ +

When roleNested property is true, + this filter expression will be also used to recursively search for + other roles, which indirectly belong to this user. To find the + roles that match the newly found role, the following values + are used: + {0} is substituted by the distinguished name of the newly + found role, and both {1} and {2} are + substituted by the name of the role (see the roleName + property). The userRoleAttribute property is not + applicable to this search.

+ +

If this property is not specified, a role search does not take + place and roles are taken only from the attribute in the user's entry + specified by the userRoleName property.

+
roleSearchAsUser +

When searching for user roles, should the search be performed as the + user currently being authenticated? If false, + connectionName and connectionPassword will be + used if specified, else an anonymous. If not specified, the default + value of false is used. Note that when accessing the + directory using delegated credentials, this attribute is always ignored + and the search is performed using the delegated credentials.

+
roleSubtree +

Set to true if you want to search the entire + subtree of the element specified by the roleBase + property for role entries associated with the user. The + default value of false causes only the top level + to be searched.

+
sizeLimit +

Specifies the maximum number of records to return when using the + userSearch attribute. If not specified, the default of + 0 is used which indicates no limit.

+
spnegoDelegationQop +

When the JNDI Realm is used with the SPNEGO authenticator and + useDelegatedCredential is true this attribute + controls the QOP (Quality of Protection) that should be used for + the connection to the LDAP + server after authentication. This value is used to set the + javax.security.sasl.qop environment property for the LDAP + connection. This attribute should be a comma-separated list of values + selected from auth-conf, auth-int and + auth. See Java documentation for more details.

+

The default value is auth-conf.

+
sslProtocol +

Specifies which ssl protocol should be used, when connecting with + StartTLS. The default is to let the jre decide. If you need even more + control, you can specify the SSLSocketFactory to use.

+
sslSocketFactory +

Specifies which SSLSocketFactory to use when connecting + to the ldap server using StartTLS. An instance of the class will be + constructed using the default constructor. If none class name is given + the default jre SSLSocketFactory will be used.

+
stripRealmForGss +

When processing users authenticated via the GSS-API, this attribute + controls if any "@..." is removed from the end of the user + name. If not specified, the default is true.

+
timeLimit +

Specifies the time (in milliseconds) to wait for records to be + returned when using the userSearch attribute. If not + specified, the default of 0 is used which indicates no + limit.

+
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
useDelegatedCredential +

When the JNDIRealm is used with the SPNEGO authenticator, delegated + credentials for the user may be available. If such credentials are + present, this attribute controls whether or not they are used to + connect to the directory. If not specified, the default value of + true is used.

+
userBase +

The base element for user searches performed using the + userSearch expression. Not used if you are using + the userPattern expression.

+
userPassword +

Name of the attribute in the user's entry containing the + user's password. If you specify this value, JNDIRealm will + bind to the directory using the values specified by + connectionName and + connectionPassword properties, and retrieve the + corresponding attribute for comparison to the value specified + by the user being authenticated. If you do + not specify this value, JNDIRealm will + attempt a simple bind to the directory using the DN of the + user's entry and the password presented by the user, with a + successful bind being interpreted as an authenticated + user.

+
userPattern +

Pattern for the distinguished name (DN) of the user's + directory entry, with {0} marking where the + actual username should be inserted. You can use this property + instead of userSearch, userSubtree + and userBase when the distinguished name contains + the username and is otherwise the same for all users. Note that + when accessing the directory using delegated credentials, this + attribute is always ignored and userSearch, + userSubtree and userBase are always + used instead.

+
userRoleName +

The name of an attribute in the user's directory entry + containing zero or more values for the names of roles assigned + to this user. In addition you can use the + roleName property to specify the name of an + attribute to be retrieved from individual role entries found + by searching the directory. If userRoleName is + not specified all the roles for a user derive from the role + search.

+
userRoleAttribute +

The name of an attribute in the user's directory entry + containing the value that you wish to use when you search for + roles. This is especially useful for RFC 2307 where + the role memberUid can be the uid or the + uidNumber of the user. This value will be + marked as {2} in your role search filter expression. + This value will NOT be available for nested role searches.

+
userSearch +

The LDAP filter expression to use when searching for a + user's directory entry, with {0} marking where + the actual username should be inserted. Use this property + (along with the userBase and + userSubtree properties) instead of + userPattern to search the directory for the + user's entry.

+
userSearchAsUser +

When searching for a user's entry, should the search be performed as + the user currently being authenticated? If false, + connectionName and connectionPassword will be + used if specified, else an anonymous. If not specified, the default + value of false is used. Note that when accessing the + directory using delegated credentials, this attribute is always ignored + and the search is performed using the delegated credentials.

+
userSubtree +

Set to true if you want to search the entire + subtree of the element specified by the userBase + property for the user's entry. The default value of + false causes only the top level to be searched. + Not used if you are using the userPattern + expression.

+
useStartTls +

Set to true if you want to use StartTLS for securing + the connection to the ldap server. The default value is false. +

+
X509UsernameRetrieverClassName +

When using X509 client certificates, this specifies the class name + that will be used to retrieve the user name from the certificate. + The class must implement the + org.apache.catalina.realm.X509UsernameRetriever + interface. The default is to use the certificate's SubjectDN + as the username.

+
+ +

See the Container-Managed Security Guide for more + information on setting up container managed security using the + JNDI Directory Realm component.

+ +
+ + +
UserDatabase Realm - org.apache.catalina.realm.UserDatabaseRealm
+ +

The UserDatabase Realm is a Realm implementation + that is based on a UserDatabase resource made available through the global + JNDI resources configured for this Tomcat instance.

+ +

The UserDatabase Realm implementation supports the following + additional attributes:

+ +
AttributeDescription
allRolesMode +

This attribute controls how the special role name * is + handled when processing authorization constraints in web.xml. By + default, the specification compliant value of strict is + used which means that the user must be assigned one of the roles defined + in web.xml. The alternative values are authOnly which means + that the user must be authenticated but no check is made for assigned + roles and strictAuthOnly which means that the user must be + authenticated and no check will be made for assigned roles unless roles + are defined in web.xml in which case the user must be assigned at least + one of those roles.

+
resourceName +

The name of the global UserDatabase resource + that this realm will use for user, password and role information.

+
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
X509UsernameRetrieverClassName +

When using X509 client certificates, this specifies the class name + that will be used to retrieve the user name from the certificate. + The class must implement the + org.apache.catalina.realm.X509UsernameRetriever + interface. The default is to use the certificate's SubjectDN + as the username.

+
+ +

See the + Container-Managed Security Guide for more + information on setting up container managed security using the UserDatabase + Realm component and the + JNDI resources how-to for more + information on how to configure a UserDatabase resource.

+ +
+ + +
Memory Based Realm - org.apache.catalina.realm.MemoryRealm
+ +

The Memory Based Realm is a simple Realm implementation + that reads user information from an XML format, and represents it as a + collection of Java objects in memory. This implementation is intended + solely to get up and running with container managed security - it is NOT + intended for production use. As such, there are no mechanisms for + updating the in-memory collection of users when the content of the + underlying data file is changed.

+ +

The Memory Based Realm implementation supports the following + additional attributes:

+ +
AttributeDescription
allRolesMode +

This attribute controls how the special role name * is + handled when processing authorization constraints in web.xml. By + default, the specification compliant value of strict is + used which means that the user must be assigned one of the roles defined + in web.xml. The alternative values are authOnly which means + that the user must be authenticated but no check is made for assigned + roles and strictAuthOnly which means that the user must be + authenticated and no check will be made for assigned roles unless roles + are defined in web.xml in which case the user must be assigned at least + one of those roles.

+
digest +

The digest algorithm used to store passwords in non-plaintext + formats. Valid values are those accepted for the algorithm name by the + java.security.MessageDigest class. If not specified, + passwords are stored in clear text.

+
pathname +

URL, absolute path or relative path (to $CATALINA_BASE) for the XML + file containing our user information. See below for details on the + XML element format required. If no pathname is specified, the + default value is conf/tomcat-users.xml.

+
stripRealmForGss +

When processing users authenticated via the GSS-API, this attribute + controls if any "@..." is removed from the end of the user + name. If not specified, the default is true.

+
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
X509UsernameRetrieverClassName +

When using X509 client certificates, this specifies the class name + that will be used to retrieve the user name from the certificate. + The class must implement the + org.apache.catalina.realm.X509UsernameRetriever + interface. The default is to use the certificate's SubjectDN + as the username.

+
+ +

The XML document referenced by the pathname attribute must + conform to the following requirements:

+
    +
  • The root (outer) element must be <tomcat-users>. +
  • +
  • Each authorized user must be represented by a single XML element + <user>, nested inside the root element.
  • +
  • Each <user> element must have the following + attributes: +
      +
    • username - Username of this user (must be unique + within this file).
      + For compatibility, it is allowed to use name as an + alternative name for this attribute.
    • +
    • password - Password of this user (in + clear text).
    • +
    • roles - Comma-delimited list of the role names + assigned to this user.
    • +
  • +
+ +

See the Container-Managed Security Guide for more + information on setting up container managed security using the + Memory Based Realm component.

+ +
+ + +
JAAS Realm - org.apache.catalina.realm.JAASRealm
+ +

JAASRealm is an implementation of the Tomcat + Realm interface that authenticates users through the Java + Authentication & Authorization Service (JAAS) framework which is now + provided as part of the standard J2SE API.

+ +

Using JAASRealm gives the developer the ability to combine practically + any conceivable security realm with Tomcat's CMA.

+ +

JAASRealm is prototype for Tomcat of the JAAS-based J2EE authentication + framework for J2EE v1.4, based on the JCP Specification Request + 196 to enhance container-managed security and promote 'pluggable' + authentication mechanisms whose implementations would be + container-independent.

+ +

Based on the JAAS login module and principal + (see javax.security.auth.spi.LoginModule and + javax.security.Principal), you can develop your own security + mechanism or wrap another third-party mechanism for integration with the CMA + as implemented by Tomcat.

+ +

The JAAS Realm implementation supports the following additional + attributes:

+ +
AttributeDescription
allRolesMode +

This attribute controls how the special role name * is + handled when processing authorization constraints in web.xml. By + default, the specification compliant value of strict is + used which means that the user must be assigned one of the roles defined + in web.xml. The alternative values are authOnly which means + that the user must be authenticated but no check is made for assigned + roles and strictAuthOnly which means that the user must be + authenticated and no check will be made for assigned roles unless roles + are defined in web.xml in which case the user must be assigned at least + one of those roles.

+
appName +

The name of the application as configured in your login configuration + file + (JAAS LoginConfig).

+

If not specified appName is derived from the Container's + name it is placed in, for example Catalina or ROOT. + If the realm is not placed in any Container, the default is Tomcat. +

+
userClassNames +

A comma-separated list of the names of the classes that you have made + for your user Principals.

+
configFile +

The name of a JAAS configuration file to use with this Realm. It will + be searched for using ClassLoader#getResource(String) so it + is possible for the configuration to be bundled within a web + application. If not specified, the default JVM global JAAS configuration + will be used.

+
roleClassNames +

A comma-separated list of the names of the classes that you have made + for your role Principals.

+
stripRealmForGss +

When processing users authenticated via the GSS-API, this attribute + controls if any "@..." is removed from the end of the user + name. If not specified, the default is true.

+
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
useContextClassLoader +

Instructs JAASRealm to use the context class loader for loading the + user-specified LoginModule class and associated + Principal classes. The default value is true, + which is backwards-compatible with the way Tomcat 5 works. To load + classes using the container's classloader, specify + false.

+
X509UsernameRetrieverClassName +

When using X509 client certificates, this specifies the class name + that will be used to retrieve the user name from the certificate. + The class must implement the + org.apache.catalina.realm.X509UsernameRetriever + interface. The default is to use the certificate's SubjectDN + as the username.

+
+ +

See the Container-Managed Security + Guide for more information on setting up container managed security + using the JAAS Realm component.

+ +
+ + +
Combined Realm - org.apache.catalina.realm.CombinedRealm
+ +

CombinedRealm is an implementation of the Tomcat + Realm interface that authenticates users through one or more + sub-Realms.

+ +

Using CombinedRealm gives the developer the ability to combine multiple + Realms of the same or different types. This can be used to authenticate + against different sources, provide fall back in case one Realm fails or for + any other purpose that requires multiple Realms.

+ +

Sub-realms are defined by nesting Realm elements inside the + Realm element that defines the CombinedRealm. Authentication + will be attempted against each Realm in the order they are + listed. Authentication against any Realm will be sufficient to authenticate + the user. The authenticated user, and their associated roles, will be taken + from the first Realm that successfully authenticates the user.

+ +

See the Container-Managed Security + Guide for more information on setting up container managed security + using the CombinedRealm component.

+ +

The CombinedRealm implementation supports the following additional + attributes.

+ +
AttributeDescription
allRolesMode +

This attribute controls how the special role name * is + handled when processing authorization constraints in web.xml. By + default, the specification compliant value of strict is + used which means that the user must be assigned one of the roles defined + in web.xml. The alternative values are authOnly which means + that the user must be authenticated but no check is made for assigned + roles and strictAuthOnly which means that the user must be + authenticated and no check will be made for assigned roles unless roles + are defined in web.xml in which case the user must be assigned at least + one of those roles.

+
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
+
+ + +
LockOut Realm - org.apache.catalina.realm.LockOutRealm
+ +

LockOutRealm is an implementation of the Tomcat + Realm interface that extends the CombinedRealm to provide lock + out functionality to provide a user lock out mechanism if there are too many + failed authentication attempts in a given period of time.

+ +

To ensure correct operation, there is a reasonable degree of + synchronization in this Realm.

+ +

This Realm does not require modification to the underlying Realms or the + associated user storage mechanisms. It achieves this by recording all failed + logins, including those for users that do not exist. To prevent a DOS by + deliberating making requests with invalid users (and hence causing this + cache to grow) the size of the list of users that have failed authentication + is limited.

+ +

Sub-realms are defined by nesting Realm elements inside the + Realm element that defines the LockOutRealm. Authentication + will be attempted against each Realm in the order they are + listed. Authentication against any Realm will be sufficient to authenticate + the user.

+ +

The LockOutRealm implementation supports the following additional + attributes.

+ +
AttributeDescription
allRolesMode +

This attribute controls how the special role name * is + handled when processing authorization constraints in web.xml. By + default, the specification compliant value of strict is + used which means that the user must be assigned one of the roles defined + in web.xml. The alternative values are authOnly which means + that the user must be authenticated but no check is made for assigned + roles and strictAuthOnly which means that the user must be + authenticated and no check will be made for assigned roles unless roles + are defined in web.xml in which case the user must be assigned at least + one of those roles.

+
cacheRemovalWarningTime +

If a failed user is removed from the cache because the cache is too + big before it has been in the cache for at least this period of time (in + seconds) a warning message will be logged. Defaults to 3600 (1 hour).

+
cacheSize +

Number of users that have failed authentication to keep in cache. Over + time the cache will grow to this size and may not shrink. Defaults to + 1000.

+
failureCount +

The number of times in a row a user has to fail authentication to be + locked out. Defaults to 5.

+
lockOutTime +

The time (in seconds) a user is locked out for after too many + authentication failures. Defaults to 300 (5 minutes). Further + authentication failures during the lock out time will cause the lock out + timer to reset to zero, effectively extending the lock out time. Valid + authentication attempts during the lock out period will not succeed but + will also not reset the lock out time.

+
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
+ +

See the Container-Managed Security + Guide for more information on setting up container managed security + using the LockOutRealm component.

+ +
+ +
Null Realm - org.apache.catalina.realm.NullRealm
+ +

NullRealm is a minimal implementation of the Tomcat + Realm interface that always returns null when an attempt is + made to validate a user name and associated credentials. It is intended to + be used as a default Realm implementation when no other Realm is + specified.

+ +

The NullRealm implementation supports the following additional + attributes.

+ +
AttributeDescription
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
+ +
+ +
JDBC Database Realm - org.apache.catalina.realm.JDBCRealm
+ +

The JDBC Database Realm has been deprecated and will be removed + in Tomcat 10 onwards. Use the DataSourceRealm instead.

+ +

The JDBC Database Realm connects Tomcat to + a relational database, accessed through an appropriate JDBC driver, + to perform lookups of usernames, passwords, and their associated + roles. Because the lookup is done each time that it is required, + changes to the database will be immediately reflected in the + information used to authenticate new logins.

+ +

A rich set of additional attributes lets you configure the required + connection to the underlying database, as well as the table and + column names used to retrieve the required information:

+ +
AttributeDescription
allRolesMode +

This attribute controls how the special role name * is + handled when processing authorization constraints in web.xml. By + default, the specification compliant value of strict is + used which means that the user must be assigned one of the roles defined + in web.xml. The alternative values are authOnly which means + that the user must be authenticated but no check is made for assigned + roles and strictAuthOnly which means that the user must be + authenticated and no check will be made for assigned roles unless roles + are defined in web.xml in which case the user must be assigned at least + one of those roles.

+

When this attribute has the value of authOnly or + strictAuthOnly, the roleNameCol and + userRoleTable attributes become optional. If those two + attributes are omitted, the user's roles will not be loaded by this + Realm.

+
connectionName +

The database username to use when establishing the JDBC + connection.

+
connectionPassword +

The database password to use when establishing the JDBC + connection.

+
connectionURL +

The connection URL to be passed to the JDBC driver when + establishing a database connection.

+
digest +

The name of the MessageDigest algorithm used + to encode user passwords stored in the database. If not specified, + user passwords are assumed to be stored in clear-text.

+
digestEncoding +

The charset for encoding digests. If not specified, the platform + default will be used.

+
driverName +

Fully qualified Java class name of the JDBC driver to be + used to connect to the authentication database.

+
roleNameCol +

Name of the column, in the "user roles" table, which contains + a role name assigned to the corresponding user.

+

This attribute is required in majority of + configurations. See allRolesMode attribute for + a rare case when it can be omitted.

+
stripRealmForGss +

When processing users authenticated via the GSS-API, this attribute + controls if any "@..." is removed from the end of the user + name. If not specified, the default is true.

+
transportGuaranteeRedirectStatus +

The HTTP status code to use when the container needs to issue an HTTP + redirect to meet the requirements of a configured transport + guarantee. The provided status code is not validated. If not + specified, the default value of 302 is used.

+
userCredCol +

Name of the column, in the "users" table, which contains + the user's credentials (i.e. password). If a value for the + digest attribute is specified, this component + will assume that the passwords have been encoded with the + specified algorithm. Otherwise, they will be assumed to be + in clear text.

+
userNameCol +

Name of the column, in the "users" and "user roles" table, + that contains the user's username.

+
userRoleTable +

Name of the "user roles" table, which must contain columns + named by the userNameCol and roleNameCol + attributes.

+

This attribute is required in majority of + configurations. See allRolesMode attribute for + a rare case when it can be omitted.

+
userTable +

Name of the "users" table, which must contain columns named + by the userNameCol and userCredCol + attributes.

+
X509UsernameRetrieverClassName +

When using X509 client certificates, this specifies the class name + that will be used to retrieve the user name from the certificate. + The class must implement the + org.apache.catalina.realm.X509UsernameRetriever + interface. The default is to use the certificate's SubjectDN + as the username.

+
+ +

See the Container-Managed Security Guide for more + information on setting up container managed security using the + JDBC Database Realm component.

+ +
+ +
Nested Components
+ +

CombinedRealm Implementation

+ +

If you are using the CombinedRealm Implementation or a Realm + that extends the CombinedRealm, e.g. the LockOutRealm, + <Realm> elements may be nested inside it.

+ +

Other Realm Implementations

+ +

No other Realm implementation supports nested components.

+ +
Special Features
+ +

See Single Sign On for information about + configuring Single Sign On support for a virtual host.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/resources.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/resources.html new file mode 100644 index 0000000..a33bccf --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/resources.html @@ -0,0 +1,168 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Resources Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Resources Component

Table of Contents
+ +
Introduction
+ +

The Resources element represents the web + application static resources, from which classes will be loaded, + HTML, JSP and the other static files will be served. This allows the webapp + to reside on various mediums other than the filesystem, like compressed + in a WAR file, in a JDBC database, or in a more advanced versioning + repository.

+ +

A unified caching engine is provided for all accesses to the webapp + resources made by the servlet container and web applications which use the + container provided mechanisms to access such resources, such as classloader + access, access through the ServletContext interface, or native + access through the DirectoryContext interface.

+ +

Note: Running a webapp with non-filesystem based + Resources implementations is only possible when the webapp does not + rely on direct filesystem access to its own resources, and uses the methods + in the ServletContext interface to access them.

+ +

A Resources element MAY be nested inside a + Context component. If it is not included, + a default filesystem based Resources will be created automatically, + which is sufficient for most requirements.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Resources + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the javax.naming.directory.DirContext interface. + It is recommended for optimal functionality and performance, + but not mandatory, that the class extend + org.apache.naming.resources.BaseDirContext, as well as + use the special object types provided in the + org.apache.naming.resources for returned objects. + If not specified, the standard value (defined below) will be used.

+
+ +
+ + +
Standard Implementation
+ +

The standard implementation of Resources is + org.apache.naming.resources.FileDirContext, and + is configured by its parent Context element.

+ +
+ +
VirtualDirContext implementation
+

This implementation of Resources is + org.apache.naming.resources.VirtualDirContext and is aimed to be used + during development to deploy a webapp without copying files to a webapp compliant + directory structure. + It extends FileDirContext and supports the following + additional attributes

+ +
AttributeDescription
extraResourcePaths +

Allows to map a path of the filesystem to a path in the webapp. Multiple + filesystem paths can be mapped to the same path in the webapp. Filesystem + path and virtual path must be separated by an equal signe (=). Pairs of paths + must be separated by a column.

+ Example: /=/Users/jdoe/mywebapp/src/main/webapp,/=/Users/jdoe/mywebapp/src/main/webapp2,/pictures=/Users/jdoe/sharedpictures +

The path to the docBase (as declared in the Context) must not be added here.

+

This attribute enhances the feature provided by the aliases + attribute of the StandardContext.

+
+
+ +
Nested Components
+ +

No components may be nested inside a Resources element.

+ +
Special Features
+ +

No special features are associated with a Resources + element.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/server.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/server.html new file mode 100644 index 0000000..efa202f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/server.html @@ -0,0 +1,150 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Server Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Server Component

Table of Contents
+ +
Introduction
+ +

A Server element represents the entire Catalina + servlet container. Therefore, it must be the single outermost element + in the conf/server.xml configuration file. Its attributes + represent the characteristics of the servlet container as a whole.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Server + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Server interface. + If no class name is specified, the standard implementation will + be used.

+
address +

The TCP/IP address on which this server waits for a shutdown + command. If no address is specified, localhost is used.

+
port +

The TCP/IP port number on which this server waits for a shutdown + command. Set to -1 to disable the shutdown port.

+

Note: Disabling the shutdown port works well when Tomcat is started + using Apache Commons Daemon + (running as a service on Windows or with jsvc on un*xes). It cannot be + used when running Tomcat with the standard shell scripts though, as it + will prevent shutdown.bat|.sh and catalina.bat|.sh from stopping it + gracefully.

+
shutdown +

The command string that must be received via a TCP/IP connection + to the specified port number, in order to shut down Tomcat.

+
+ +
+ +
Standard Implementation
+ +

The standard implementation of Server is + org.apache.catalina.core.StandardServer. + It supports the following additional attributes (in addition to the + common attributes listed above):

+ +
AttributeDescription
+ +
+ +
Nested Components
+ +

The following components may be nested inside a Server + element:

+ + +
Special Features
+ +

There are no special features associated with a Server. +

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/service.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/service.html new file mode 100644 index 0000000..5d97b3c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/service.html @@ -0,0 +1,137 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Service Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Service Component

Table of Contents
+ +
Introduction
+ +

A Service element represents the combination of one or + more Connector components that share a single + Engine component for processing incoming + requests. One or more Service elements may be nested + inside a Server element.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of Service + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.Service interface. + If no class name is specified, the standard implementation will + be used.

+
name +

The display name of this Service, which will + be included in log messages if you utilize standard Catalina + components. The name of each Service that is + associated with a particular Server + must be unique.

+
+ +
+ +
Standard Implementation
+ +

The standard implementation of Service is + org.apache.catalina.core.StandardService. + It supports the following additional attributes (in addition to the + common attributes listed above):

+ +
AttributeDescription
+ +
+ +
Nested Components
+ +

The only components that may be nested inside a Service + element are one or more Connector elements, + followed by exactly one Engine element.

+ +
Special Features
+ +

There are no special features associated with a Service. +

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/sessionidgenerator.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/sessionidgenerator.html new file mode 100644 index 0000000..1f2a549 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/sessionidgenerator.html @@ -0,0 +1,158 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The SessionIdGenerator Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The SessionIdGenerator Component

Table of Contents
+ +
Introduction
+ +

The SessionIdGenerator element represents the session + id generator that will be used to create session ids used by + web application HTTP sessions.

+ +

A SessionIdGenerator element MAY be nested inside a + Manager component. If it is not included, + a default SessionIdGenerator configuration will be created automatically, which + is sufficient for most requirements, — see + Standard SessionIdGenerator Implementation below for the details + of this configuration.

+ +
Attributes
+ +
Common Attributes
+ +

All implementations of SessionIdGenerator + support the following attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This class must + implement the org.apache.catalina.SessionIdGenerator interface. + If not specified, the standard value (defined below) will be used.

+
jvmRoute +

A routing identifier for this Tomcat instance. It will be added + to the session id to allow for stateless stickyness routing by + load balancers. The details on how the jvmRoute + will be included in the id are implementation dependent. + See Standard Implementation + for the default behavior.

+ +

NOTE - The value for this property is inherited + automatically from the jvmRoute attribute of the + Engine element.

+
sessionIdLength +

The length of session ids created by this SessionIdGenerator. + The details on how the sessionIdLength + influences the session id length are implementation dependent. + See Standard Implementation + for the default behavior.

+
+ +
+ + +
Standard Implementation
+ +

Tomcat provides a standard implementations of SessionIdGenerator + for use.

+ +

Standard SessionIdGenerator Implementation

+ +

The standard implementation of SessionIdGenerator is + org.apache.catalina.util.StandardSessionIdGenerator. + It supports the following attributes:

+ +
AttributeDescription
jvmRoute +

A routing identifier for this Tomcat instance. It will be added + to the end of the session id separated by a ".".

+
sessionIdLength +

The length of session ids created by this SessionIdGenerator. + More precisely the session id length is twice the value of + sessionIdLength plus the length of the trailing + jvmRoute if given. The factor 2 is because + the session id is constructed using sessionIdLength + random bytes, each byte being encoded in two hex characters + in the actual id. The default value is 16.

+
+ +
+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/systemprops.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/systemprops.html new file mode 100644 index 0000000..814032e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/systemprops.html @@ -0,0 +1,593 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - System Properties

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

System Properties

Table of Contents
+ +
Introduction
+

The following sections list the system properties that may be set to modify + the default Tomcat behaviour.

+
Property replacements
+
PropertyDescription
org.apache.tomcat.util.digester. PROPERTY_SOURCE +

Set this to a fully qualified name of a class that implements + org.apache.tomcat.util.IntrospectionUtils.PropertySource. + Required to have a public constructor with no arguments.

+

Use this to add a property source, that will be invoked when + ${parameter:-default-value} denoted parameters (with + optional default values) are found in the XML files that Tomcat + parses.

+

org.apache.tomcat.util.digester.EnvironmentPropertySource + can be used to replace parameters from the process' environment + variables, e.g. injected ConfigMaps or Secret objects in container + based systems like OpenShift or Kubernetes.

+
+ +
Clustering
+
PropertyDescription
org.apache.catalina. tribes.dns_lookups +

This system property is deprecated and will be removed without + replacement in Apache Tomcat 10 onwards.

+

If true, the clustering module will attempt to use DNS to + resolve any host names provided in the cluster configuration.

+

If not specified, the default value of false will be used.

+
+ +
Expression Language
+
PropertyDescription
org.apache.el.BeanELResolver. CACHE_SIZE +

The number of javax.el.BeanELResolver.BeanProperties objects that will + be cached by the EL Parser.

+

If not specified, the default of 1000 will be used.

+
org.apache.el.ExpressionBuilder. CACHE_SIZE +

The number of parsed EL expressions that will be cached by the EL + Parser.

+

If not specified, the default of 5000 will be used.

+
org.apache.el.parser. COERCE_TO_ZERO +

If true, when coercing expressions to numbers + "" and null will be coerced to zero as required + by the specification.

+

If not specified, the default value of true will be used.

+
org.apache.el.parser. SKIP_IDENTIFIER_CHECK +

If true, when parsing expressions, identifiers will not be + checked to ensure that they conform to the Java Language Specification for + Java identifiers.

+

If not specified, the default value of false will be used.

+
+
Jasper
+
PropertyDescription
org.apache.jasper.compiler. Generator.POOL_TAGS_WITH_EXTENDS +

By default, JSPs that use their own base class via the extends + attribute of the page directive, will have Tag pooling disabled since + Jasper cannot guarantee that the necessary initialisation will have taken + place. This can have a negative impact on performance. Providing the + alternative base class calls _jspInit() from Servlet.init(), setting this + property to true will enable pooling with an alternative base + class. If the alternative base class does not call _jspInit() and this + property is true, NPEs will occur when attempting to use + tags.

+

If not specified, the default value of false will be used. +

+
org.apache.jasper.compiler. Generator.STRICT_GET_PROPERTY +

If true, the requirement to have the object referenced in + jsp:getProperty action to be previously "introduced" + to the JSP processor, as specified in the chapter JSP.5.3 of JSP 2.0 and + later specifications, is enforced.

+

If not specified, the specification compliant default of + true will be used.

+
org.apache.jasper.compiler. Generator.VAR_EXPRESSIONFACTORY +

The name of the variable to use for the expression language expression + factory.

+

If not specified, the default value of _el_expressionfactory + will be used.

+
org.apache.jasper.compiler. Generator.VAR_INSTANCEMANAGER +

The name of the variable to use for the instance manager factory.

+

If not specified, the default value of _jsp_instancemanager + will be used.

+
org.apache.jasper.compiler. Parser.STRICT_QUOTE_ESCAPING +

If false the requirements for escaping quotes in JSP + attributes will be relaxed so that an unescaped quote will not + cause an error.

+

If not specified, the specification compliant default of + true will be used.

+
org.apache.jasper.compiler. Parser.STRICT_WHITESPACE +

If false the requirements for whitespace before an + attribute name will be relaxed so that the lack of whitespace will not + cause an error.

+

If not specified, the specification compliant default of + true will be used.

+
org.apache.jasper.runtime. BodyContentImpl.BUFFER_SIZE +

The size (in characters) to use when creating a tag buffer.

+

If not specified, the default value of + org.apache.jasper.Constants.DEFAULT_TAG_BUFFER_SIZE (512) + will be used.

+
org.apache.jasper.runtime. BodyContentImpl.LIMIT_BUFFER +

If true, any tag buffer that expands beyond + org.apache.jasper.runtime.BodyContentImpl.BUFFER_SIZE will be + destroyed and a new buffer created.

+

If not specified, the default value of false will be used.

+
org.apache.jasper.runtime. JspFactoryImpl.USE_POOL +

If true, a ThreadLocal PageContext pool will + be used.

+

If not specified, the default value of true will be used.

+
org.apache.jasper.runtime. JspFactoryImpl.POOL_SIZE +

The size of the ThreadLocal PageContext.

+

If not specified, the default value of 8 will be used.

+
org.apache.jasper.Constants. JSP_SERVLET_BASE +

The base class of the Servlets generated from the JSPs.

+

If not specified, the default value of + org.apache.jasper.runtime.HttpJspBase will be used.

+
org.apache.jasper.Constants. SERVICE_METHOD_NAME +

The name of the service method called by the base class.

+

If not specified, the default value of _jspService + will be used.

+
org.apache.jasper.Constants. SERVLET_CLASSPATH +

The name of the ServletContext attribute that provides the classpath + for the JSP.

+

If not specified, the default value of + org.apache.catalina.jsp_classpath will be used.

+
org.apache.jasper.Constants. JSP_FILE +

The name of the request attribute for <jsp-file> + element of a servlet definition. If present on a request, this overrides + the value returned by request.getServletPath() to select the + JSP page to be executed.

+

If not specified, the default value of + org.apache.catalina.jsp_file will be used.

+

Deprecated: This will be removed in Tomcat 9.0.x + onwards. It is replaced by the use of the jspFile servlet initialisation + parameter

+
org.apache.jasper.Constants. PRECOMPILE +

The name of the query parameter that causes the JSP engine to just + pregenerate the servlet but not invoke it.

+

If not specified, the default value of jsp_precompile + will be used, as defined by JSP specification (JSP.11.4.2).

+
org.apache.jasper.Constants. JSP_PACKAGE_NAME +

The default package name for compiled jsp pages.

+

If not specified, the default value of org.apache.jsp + will be used.

+
org.apache.jasper.Constants. TAG_FILE_PACKAGE_NAME +

The default package name for tag handlers generated from tag files.

+

If not specified, the default value of org.apache.jsp.tag + will be used.

+
org.apache.jasper.Constants. ALT_DD_ATTR +

The servlet context attribute under which the alternate deployment + descriptor for this web application is stored.

+

If not specified, the default value of + org.apache.catalina.deploy.alt_dd will be used.

+
org.apache.jasper.Constants. TEMP_VARIABLE_NAME_PREFIX +

Prefix to use for generated temporary variable names.

+

If not specified, the default value of _jspx_temp + will be used.

+
org.apache.jasper.Constants. USE_INSTANCE_MANAGER_FOR_TAGS +

If true, the instance manager is used to obtain tag + handler instances.

+

If not specified, the default value of false will be used.

+
+ +
Security
+ +
PropertyDescription
org.apache.catalina.connector. RECYCLE_FACADES +

If this is true or if a security manager is in use a new + facade object will be created for each request.

+

If not specified, the default value of false will be used.

+
org.apache.catalina.connector. CoyoteAdapter.ALLOW_BACKSLASH +

If this is true the '\' character will be permitted as a + path delimiter.

+

If not specified, the default value of false will be used.

+
org.apache.tomcat.util.buf. UDecoder.ALLOW_ENCODED_SLASH +

Use of this system property is deprecated. It will be removed from + Tomcat 10 onwards.

+

If this system property is set to true, the default for + the encodedSolidusHandling attribute of all Connectors will + be changed from reject to decode. If decoded, it + will be treated a path delimiter.

+
+ +
Specification
+ +
PropertyDescription
org.apache.catalina. STRICT_SERVLET_COMPLIANCE +

The default value of this system property is false.

+

If this is true the default values will be changed for:

+
    +
  • org.apache.catalina.core.
    ApplicationContext.GET_RESOURCE_REQUIRE_SLASH
  • +
  • org.apache.catalina.core.
    ApplicationDispatcher.WRAP_SAME_OBJECT
  • +
  • org.apache.catalina.core.
    StandardHostValve.ACCESS_SESSION
  • +
  • org.apache.catalina.session.
    StandardSession.ACTIVITY_CHECK
  • +
  • org.apache.catalina.session.
    StandardSession.LAST_ACCESS_AT_START
  • +
  • org.apache.tomcat.util.http.
    ServerCookie.ALWAYS_ADD_EXPIRES
  • +
  • org.apache.tomcat.util.http.
    ServerCookie.FWD_SLASH_IS_SEPARATOR
  • +
  • org.apache.tomcat.util.http.
    ServerCookie.PRESERVE_COOKIE_HEADER
  • +
  • org.apache.tomcat.util.http.
    ServerCookie.STRICT_NAMING
  • +
  • The resourceOnlyServlets attribute of any + Context element.
  • +
  • The tldValidation attribute of any + Context element.
  • +
  • The useRelativeRedirects attribute of any + Context element.
  • +
  • The xmlNamespaceAware attribute of any + Context element.
  • +
  • The xmlValidation attribute of any + Context element.
  • +
+ +

Note that changing a number of the above defaults is likely to break + the majority of systems as some browsers are unable to correctly handle + the cookie headers that result from a strict adherence to the + specifications. Defaults, regardless of whether or not they have been + changed by setting + org.apache.catalina.STRICT_SERVLET_COMPLIANCE can always be + overridden by explicitly setting the appropriate system property or element + attribute.

+
org.apache.catalina.connector. Response.ENFORCE_ENCODING_IN_GET_WRITER +

If this is true then + a call to Response.getWriter() if no character encoding + has been specified will result in subsequent calls to + Response.getCharacterEncoding() returning + ISO-8859-1 and the Content-Type response header + will include a charset=ISO-8859-1 component. (SRV.15.2.22.1)

+

If not specified, the default specification compliant value of + true will be used.

+
org.apache.catalina.core.ApplicationContext .GET_RESOURCE_REQUIRE_SLASH +

If this is true then the path passed to + ServletContext.getResource() or + ServletContext.getResourceAsStream() must start with + "/". If false, code like + getResource("myfolder/myresource.txt") will work.

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be true, + else the default value will be false.

+
org.apache.catalina.core. ApplicationDispatcher.WRAP_SAME_OBJECT +

If this is true then any wrapped request or response + object passed to an application dispatcher will be checked to ensure that + it has wrapped the original request or response.

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be true, + else the default value will be false.

+
org.apache.tomcat.util.http. ServerCookie.ALLOW_EQUALS_IN_VALUE +

If this is true Tomcat will allow '=' + characters when parsing unquoted cookie values. If false, + cookie values containing '=' will be terminated when the + '=' is encountered and the remainder of the cookie value will + be dropped.

+

If not specified, the default value specification compliant value of + false will be used.

+
org.apache.tomcat.util.http. ServerCookie.ALLOW_HTTP_SEPARATORS_IN_V0 +

If this is true Tomcat will allow HTTP separators in + cookie names and values.

+

If not specified, the default specification compliant value of + false will be used.

+
org.apache.tomcat.util.http. ServerCookie.ALLOW_NAME_ONLY +

If this is false then the requirements of the cookie + specifications that cookies must have values will be enforced and cookies + consisting only of a name but no value will be ignored.

+

If not specified, the default specification compliant value of + false will be used.

+
org.apache.tomcat.util.http. ServerCookie.ALWAYS_ADD_EXPIRES +

If this is true Tomcat will always add an expires + parameter to a SetCookie header even for cookies with version greater than + zero. This is to work around a known IE6 and IE7 bug that causes IE to + ignore the Max-Age parameter in a SetCookie header.

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be false, + else the default value will be true.

+
org.apache.tomcat.util.http. ServerCookie.FWD_SLASH_IS_SEPARATOR +

If this is true then the / (forward slash) character will + be treated as a separator. Note that this character is frequently used in + cookie path attributes and some browsers will fail to process a cookie if + the path attribute is quoted as is required by a strict adherence to the + specifications. This is highly likely to break session tracking using + cookies.

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be true, + else the default value will be false.

+
org.apache.tomcat.util.http. ServerCookie.PRESERVE_COOKIE_HEADER +

If this is true Tomcat will ensure that cookie + processing does not modify cookie header returned by + HttpServletRequest.getHeader().

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be true, + else the default value will be false.

+
org.apache.tomcat.util.http. ServerCookie.STRICT_NAMING +

If this is true then the requirements of the Servlet specification + that Cookie names must adhere to RFC2109 (no use of separators) will be + enforced.

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be true, + else the default value will be false.

+
+ +
Sessions
+ +
PropertyDescription
org.apache.catalina.authenticator. Constants.SSO_SESSION_COOKIE_NAME +

An alternative name for the single sign on session cookie. Defaults to + JSESSIONIDSSO.

+
org.apache.catalina.core. StandardHostValve.ACCESS_SESSION +

If this is true, every request that is associated with a + session will cause the session's last accessed time to be updated + regardless of whether or not the request explicitly accesses the session.

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be true, + else the default value will be false.

+
org.apache.catalina.session. StandardSession.ACTIVITY_CHECK +

If this is true, Tomcat will track the number of active + requests for each session. When determining if a session is valid, any + session with at least one active request will always be considered valid.

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be true, + else the default value will be false.

+
org.apache.catalina.session. StandardSession.LAST_ACCESS_AT_START +

If this is true, the last accessed time for sessions will + be calculated from the beginning of the previous request. If + false, the last accessed time for sessions will be calculated + from the end of the previous request. This also affects how the idle time + is calculated.

+

If org.apache.catalina.STRICT_SERVLET_COMPLIANCE is set to + true, the default of this setting will be true, + else the default value will be false.

+
+ +
Logging
+ +
PropertyDescription
org.apache.juli.formatter +

If no logging configuration file is specified and no logging configuration class is specified + using the java.util.logging.config.class and java.util.logging.config.file + properties the default logging framework org.apache.juli will use the default + java.util.logging.SimpleFormatter for all console output. + To simply override the console output formatter, one can use the described property. Example: + -Dorg.apache.juli.formatter=org.apache.juli.OneLineFormatter

+
org.apache.juli. AsyncOverflowDropType +

When the memory limit of records has been reached the system needs to determine what action to take. + Currently there are three actions that can be taken: +

+
    +
  • int OVERFLOW_DROP_LAST = 1 - the record that caused the overflow will be dropped and not logged
  • +
  • int OVERFLOW_DROP_FIRST = 2 - the record that is next in line to be logged will be dropped to make room for the latest record on the queue
  • +
  • int OVERFLOW_DROP_FLUSH = 3 - suspend the thread while the queue empties out and flushes the entries to the write buffer
  • +
  • int OVERFLOW_DROP_CURRENT = 4 - drop the current log entry
  • +
+

The default value is 1 (OVERFLOW_DROP_LAST).

+
org.apache.juli. AsyncMaxRecordCount +

The max number of log records that the async logger will keep in memory. When this limit is reached and a new record is being logged by the + JULI framework the system will take an action based on the org.apache.juli.AsyncOverflowDropType setting.

+

The default value is 10000 records. + This number represents the global number of records, not on a per handler basis. +

+
org.apache.juli. AsyncLoggerPollInterval +

The poll interval in milliseconds for the asynchronous logger thread in milliseconds. + If the log queue is empty, the async thread will issue a poll(poll interval) + in order to not wake up too often.

+

The default value is 1000 milliseconds.

+
org.apache.juli.logging. UserDataHelper.CONFIG +

The type of logging to use for errors generated by invalid input data. + The options are: DEBUG_ALL, INFO_THEN_DEBUG, + INFO_ALL and NONE. When + INFO_THEN_DEBUG is used, the period for which errors are + logged at DEBUG rather than INFO is controlled by the system property + org.apache.juli.logging.UserDataHelper.SUPPRESSION_TIME. +

+

The default value is INFO_THEN_DEBUG.

+

The errors currently logged using this system are:

+
    +
  • invalid cookies;
  • +
  • invalid parameters;
  • +
  • too many headers, too many parameters (hitting + maxHeaderCount or maxParameterCount limits + of a connector).
  • +
  • invalid host names
  • +
+

Other errors triggered by invalid input data may be added to this + system in later versions.

+
org.apache.juli.logging. UserDataHelper.SUPPRESSION_TIME +

When using INFO_THEN_DEBUG for + org.apache.juli.logging.UserDataHelper.CONFIG this system + property controls how long messages are logged at DEBUG after a message + has been logged at INFO. Once this period has elapsed, the next message + will be logged at INFO followed by a new suppression period where + messages are logged at DEBUG and so on. The value is measured + in seconds.

+

A value of 0 is equivalent to using INFO_ALL + for org.apache.juli.logging.UserDataHelper.CONFIG.

+

A negative value means an infinite suppression period.

+

The default value is 86400 (24 hours).

+
+ +
JAR Scanning
+ +
PropertyDescription
tomcat.util.scan. DefaultJarScanner.jarsToSkip +

The comma-separated list of file name patterns of JARs that Tomcat will + not scan for configuration information when using the + JarScanner functionality. The file name + pattern syntax is described in + JarScanner documentation. Note that + there are additional system properties that enable JARs to be excluded + from specific scans rather than all scans.

+

The coded default is that no JARs are skipped however the system + property is set in a default Tomcat installation via the + $CATALINA_BASE/conf/catalina.properties file.

+
org.apache.catalina.startup. ContextConfig.jarsToSkip +

The comma-separated list of additional filenames of JARs that Tomcat + will not scan for Servlet 3.0 pluggability features.

+

The coded default is that no JARs are skipped however the system + property is set in a default Tomcat installation via the + $CATALINA_BASE/conf/catalina.properties file.

+
org.apache.catalina.startup. TldConfig.jarsToSkip +

The comma-separated list of additional filenames of JARs that Tomcat + will not scan for TLDs.

+

The coded default is that no JARs are skipped however the system + property is set in a default Tomcat installation via the + $CATALINA_BASE/conf/catalina.properties file.

+
+ +
Websockets
+ +
PropertyDescription
org.apache.tomcat .websocket.ALLOW_UNSUPPORTED_EXTENSIONS +

If true, allow unknown extensions to be declared by + the user.

+

The default value is false.

+
org.apache.tomcat. websocket.DEFAULT_BUFFER_SIZE +

The default size for buffers used in the Websockets container.

+

The default value is 8192 which corresponds to 8KB.

+
org.apache.tomcat. websocket.DEFAULT_ORIGIN_HEADER_VALUE +

Default value of the origin header that will be sent by the client + during the upgrade handshake.

+

The default is null so that no origin header is sent.

+
org.apache.tomcat. websocket.DEFAULT_PROCESS_PERIOD +

The number of periodic ticks between periodic processing which + involves in particular session expiration checks.

+

The default value is 10 which corresponds to 10 + seconds.

+
org.apache.tomcat. websocket.DISABLE_BUILTIN_EXTENSIONS +

If true, disable all built-in extensions provided by the + server, such as message compression.

+

The default value is false.

+
+ +
Other
+ +
PropertyDescription
org.apache.coyote. USE_CUSTOM_STATUS_MSG_IN_HEADER

If this is + true, custom HTTP status messages will be used within HTTP + headers. If a custom message is specified that is not valid for use in an + HTTP header (as defined by RFC2616) then the custom message will be + ignored and the default message used.

+

If not specified, the default value of false will be used.

+
catalina.useNaming +

If this is false it will override the + useNaming attribute for all + Context elements.

+
javax.sql.DataSource.Factory +

The class name of the factory to use to create resources of type + javax.sql.DataSource. If not specified the default of + org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory is used + which is a package renamed (to avoid conflicts) copy of + Apache Commons DBCP 1.x.

+
javax.mail.Session.Factory +

The class name of the factory to use to create resources of type + javax.mail.Session. If not specified the default of + org.apache.naming.factory.MailSessionFactory is used.

+
jvmRoute +

Provides a default value for the jvmRoute attribute of the + Engine element. It does not override the value + configured on the Engine element.

+
catalina.config +

The URL for the catalina.properties configuration file.

+
tomcat.util.buf.StringCache.byte.enabled +

If true, the String cache is enabled for + ByteChunk.

+

If not specified, the default value of false will be used.

+
tomcat.util.buf.StringCache.char.enabled +

If true, the String cache is enabled for + CharChunk.

+

If not specified, the default value of false will be used.

+
tomcat.util.buf.StringCache.trainThreshold +

The number of times toString() must be called before the + cache is activated.

+

If not specified, the default value of 20000 will be used.

+
tomcat.util.buf.StringCache.cacheSize +

The size of the String cache.

+

If not specified, the default value of 200 will be used.

+
tomcat.util.buf.StringCache.maxStringSize +

The maximum length of String that will be cached.

+

If not specified, the default value of 128 will be used.

+
org.apache.tomcat.util. http.FastHttpDateFormat.CACHE_SIZE +

The size of the cache to use parsed and formatted date value.

+

If not specified, the default value of 1000 will be used.

+
org.apache.tomcat.util. net.NioSelectorShared +

If true, use a shared selector for servlet write/read.

+

If not specified, the default value of true will be used.

+
org.apache.catalina.startup. EXIT_ON_INIT_FAILURE +

If true, the server will exit if an exception happens + during the server initialization phase.

+

If not specified, the default value of false will be used.

+
org.apache.catalina.startup. RealmRuleSet.MAX_NESTED_REALM_LEVELS +

The CombinedRealm allows nested Realms. This property controls the + maximum permitted number of levels of nesting.

+

If not specified, the default value of 3 will be used.

+
tomcat.util.http.parser.HttpParser. requestTargetAllow +

This system property is deprecated. Use the + relaxedPathChars and relaxedQueryChars + attributes of the Connector instead. These attributes permit a wider range + of characters to be configured as valid.

+

A string comprised of characters the server should allow even when they are not encoded. + These characters would normally result in a 400 status.

+

The acceptable characters for this property are: |, { + , and }

+

WARNING: Use of this option may expose the server to CVE-2016-6816. +

+

If not specified, the default value of null will be used.

+
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/valve.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/valve.html new file mode 100644 index 0000000..e984c20 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/config/valve.html @@ -0,0 +1,1772 @@ +Apache Tomcat 7 Configuration Reference (7.0.108) - The Valve Component

+    The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

Top Level Elements

Executors

Connectors

Containers

Nested Components

Cluster Elements

web.xml

Other

The Valve Component

Table of Contents
+ +
Introduction
+ +

A Valve element represents a component that will be + inserted into the request processing pipeline for the associated + Catalina container (Engine, + Host, or Context). + Individual Valves have distinct processing capabilities, and are + described individually below.

+ +

The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+ +
Access Logging
+ +

Access logging is performed by valves that implement +org.apache.catalina.AccessLog interface.

+ +
Access Log Valve
+ +
Introduction
+ +

The Access Log Valve creates log files in the + same format as those created by standard web servers. These logs + can later be analyzed by standard log analysis tools to track page + hit counts, user session activity, and so on. This Valve + uses self-contained logic to write its log files, which can be + automatically rolled over at midnight each day. (The essential + requirement for access logging is to handle a large continuous + stream of data with low overhead. This Valve does not + use Apache Commons Logging, thus avoiding additional overhead and + potentially complex configuration).

+ +

This Valve may be associated with any Catalina container + (Context, Host, or Engine), and + will record ALL requests processed by that container.

+ +

Some requests may be handled by Tomcat before they are passed to a + container. These include redirects from /foo to /foo/ and the rejection of + invalid requests. Where Tomcat can identify the Context that + would have handled the request, the request/response will be logged in the + AccessLog(s) associated Context, Host + and Engine. Where Tomcat cannot identify the + Context that would have handled the request, e.g. in cases + where the URL is invalid, Tomcat will look first in the Engine, + then the default Host for the Engine and finally + the ROOT (or default) Context for the default Host + for an AccessLog implementation. Tomcat will use the first + AccessLog implementation found to log those requests that are + rejected before they are passed to a container.

+ +

The output file will be placed in the directory given by the + directory attribute. The name of the file is composed + by concatenation of the configured prefix, timestamp and + suffix. The format of the timestamp in the file name can be + set using the fileDateFormat attribute. This timestamp will + be omitted if the file rotation is switched off by setting + rotatable to false.

+ +

Warning: If multiple AccessLogValve instances + are used, they should be configured to use different output files.

+ +

If sendfile is used, the response bytes will be written asynchronously + in a separate thread and the access log valve will not know how many bytes + were actually written. In this case, the number of bytes that was passed to + the sendfile thread for writing will be recorded in the access log valve. +

+
+ +
Attributes
+ +

The Access Log Valve supports the following + configuration attributes:

+ +
AttributeDescription
buffered +

Flag to determine if logging will be buffered. + If set to false, then access logging will be written after each + request. Default value: true +

+
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.AccessLogValve to use the + default access log valve.

+
condition +

The same as conditionUnless. This attribute is + provided for backwards compatibility. +

+
conditionIf +

Turns on conditional logging. If set, requests will be + logged only if ServletRequest.getAttribute() is + not null. For example, if this value is set to + important, then a particular request will only be logged + if ServletRequest.getAttribute("important") != null. + The use of Filters is an easy way to set/unset the attribute + in the ServletRequest on many different requests. +

+
conditionUnless +

Turns on conditional logging. If set, requests will be + logged only if ServletRequest.getAttribute() is + null. For example, if this value is set to + junk, then a particular request will only be logged + if ServletRequest.getAttribute("junk") == null. + The use of Filters is an easy way to set/unset the attribute + in the ServletRequest on many different requests. +

+
directory +

Absolute or relative pathname of a directory in which log files + created by this valve will be placed. If a relative path is + specified, it is interpreted as relative to $CATALINA_BASE. If + no directory attribute is specified, the default value is "logs" + (relative to $CATALINA_BASE).

+
encoding +

Character set used to write the log file. An empty string means + to use the system default character set. Default value: use the + system default character set. +

+
fileDateFormat +

Allows a customized timestamp in the access log file name. + The file is rotated whenever the formatted timestamp changes. + The default value is yyyy-MM-dd. + If you wish to rotate every hour, then set this value + to yyyy-MM-dd.HH. + The date format will always be localized + using the locale en_US. +

+
locale +

The locale used to format timestamps in the access log + lines. Any timestamps configured using an + explicit SimpleDateFormat pattern (%{xxx}t) + are formatted in this locale. By default the + default locale of the Java process is used. Switching the + locale after the AccessLogValve is initialized is not supported. + Any timestamps using the common log format + (CLF) are always formatted in the locale + en_US. +

+
maxDays +

The maximum number of days rotated access logs will be retained for + before being deleted. If not specified, the default value of + -1 will be used which means never delete old files.

+
pattern +

A formatting layout identifying the various information fields + from the request and response to be logged, or the word + common or combined to select a + standard format. See below for more information on configuring + this attribute.

+
prefix +

The prefix added to the start of each log file's name. If not + specified, the default value is "access_log".

+
renameOnRotate +

By default for a rotatable log the active access log file name + will contain the current timestamp in fileDateFormat. + During rotation the file is closed and a new file with the next + timestamp in the name is created and used. When setting + renameOnRotate to true, the timestamp + is no longer part of the active log file name. Only during rotation + the file is closed and then renamed to include the timestamp. + This is similar to the behavior of most log frameworks when + doing time based rotation. + Default value: false +

+
requestAttributesEnabled +

Set to true to check for the existence of request + attributes (typically set by the RemoteIpValve and similar) that should + be used to override the values returned by the request for remote + address, remote host, server port and protocol. If the attributes are + not set, or this attribute is set to false then the values + from the request will be used. If not set, the default value of + false will be used.

+
resolveHosts +

This attribute is no longer supported. Use the connector + attribute enableLookups instead.

+

If you have enableLookups on the connector set to + true and want to ignore it, use %a instead of + %h in the value of pattern.

+
rotatable +

Flag to determine if log rotation should occur. + If set to false, then this file is never rotated and + fileDateFormat is ignored. + Default value: true +

+
suffix +

The suffix added to the end of each log file's name. If not + specified, the default value is "" (a zero-length string), + meaning that no suffix will be added.

+
+ +

Values for the pattern attribute are made up of literal + text strings, combined with pattern identifiers prefixed by the "%" + character to cause replacement by the corresponding variable value from + the current request and response. The following pattern codes are + supported:

+
    +
  • %a - Remote IP address
  • +
  • %A - Local IP address
  • +
  • %b - Bytes sent, excluding HTTP headers, or '-' if zero
  • +
  • %B - Bytes sent, excluding HTTP headers
  • +
  • %h - Remote host name (or IP address if + enableLookups for the connector is false)
  • +
  • %H - Request protocol
  • +
  • %l - Remote logical username from identd (always returns + '-')
  • +
  • %m - Request method (GET, POST, etc.)
  • +
  • %p - Local port on which this request was received. + See also %{xxx}p below.
  • +
  • %q - Query string (prepended with a '?' if it exists)
  • +
  • %r - First line of the request (method and request URI)
  • +
  • %s - HTTP status code of the response
  • +
  • %S - User session ID
  • +
  • %t - Date and time, in Common Log Format
  • +
  • %u - Remote user that was authenticated (if any), else '-'
  • +
  • %U - Requested URL path
  • +
  • %v - Local server name
  • +
  • %D - Time taken to process the request in millis. Note: In + httpd %D is microseconds. Behaviour will be aligned to httpd + in Tomcat 10 onwards.
  • +
  • %T - Time taken to process the request, in seconds. Note: This + value has millisecond resolution whereas in httpd it has + second resolution. Behaviour will be align to httpd + in Tomcat 10 onwards.
  • +
  • %F - Time taken to commit the response, in millis
  • +
  • %I - Current request thread name (can compare later with stacktraces)
  • +
+ +

+ There is also support to write information incoming or outgoing + headers, cookies, session or request attributes and special + timestamp formats. + It is modeled after the + Apache HTTP Server log configuration + syntax. Each of them can be used multiple times with different xxx keys: +

+
    +
  • %{xxx}i write value of incoming header with name xxx
  • +
  • %{xxx}o write value of outgoing header with name xxx
  • +
  • %{xxx}c write value of cookie with name xxx
  • +
  • %{xxx}r write value of ServletRequest attribute with name xxx
  • +
  • %{xxx}s write value of HttpSession attribute with name xxx
  • +
  • %{xxx}p write local (server) port (xxx==local) or + remote (client) port (xxx=remote)
  • +
  • %{xxx}t write timestamp at the end of the request formatted using the + enhanced SimpleDateFormat pattern xxx
  • +
+ +

All formats supported by SimpleDateFormat are allowed in %{xxx}t. + In addition the following extensions have been added:

+
    +
  • sec - number of seconds since the epoch
  • +
  • msec - number of milliseconds since the epoch
  • +
  • msec_frac - millisecond fraction
  • +
+

These formats cannot be mixed with SimpleDateFormat formats in the same format + token.

+ +

Furthermore one can define whether to log the timestamp for the request start + time or the response finish time:

+
    +
  • begin or prefix begin: chooses + the request start time
  • +
  • end or prefix end: chooses + the response finish time
  • +
+

By adding multiple %{xxx}t tokens to the pattern, one can + also log both timestamps.

+ +

The shorthand pattern pattern="common" + corresponds to the Common Log Format defined by + '%h %l %u %t "%r" %s %b'.

+ +

The shorthand pattern pattern="combined" + appends the values of the Referer and User-Agent + headers, each in double quotes, to the common pattern.

+ +

When Tomcat is operating behind a reverse proxy, the client information + logged by the Access Log Valve may represent the reverse proxy, the browser + or some combination of the two depending on the configuration of Tomcat and + the reverse proxy. For Tomcat configuration options see + Proxies Support and the + Proxy How-To. For reverse proxies that + use mod_jk, see the generic + proxy documentation. For other reverse proxies, consult their + documentation.

+
+ +
+ + +
Extended Access Log Valve
+ +
Introduction
+ +

The Extended Access Log Valve extends the + Access Log Valve class, and so + uses the same self-contained logging logic. This means it + implements many of the same file handling attributes. The main + difference to the standard AccessLogValve is that + ExtendedAccessLogValve creates log files which + conform to the Working Draft for the + Extended Log File Format + defined by the W3C.

+ +
+ +
Attributes
+ +

The Extended Access Log Valve supports all + configuration attributes of the standard + Access Log Valve. Only the + values used for className and pattern differ.

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.ExtendedAccessLogValve to + use the extended access log valve.

+
pattern +

A formatting layout identifying the various information fields + from the request and response to be logged. + See below for more information on configuring this attribute.

+
+ +

Values for the pattern attribute are made up of + format tokens. Some of the tokens need an additional prefix. Possible + prefixes are c for "client", s for "server", + cs for "client to server", sc for + "server to client" or x for "application specific". + Furthermore some tokens are completed by an additional selector. + See the W3C specification + for more information about the format.

+ +

The following format tokens are supported:

+
    +
  • bytes - Bytes sent, excluding HTTP headers, or '-' if zero
  • +
  • c-dns - Remote host name (or IP address if + enableLookups for the connector is false)
  • +
  • c-ip - Remote IP address
  • +
  • cs-method - Request method (GET, POST, etc.)
  • +
  • cs-uri - Request URI
  • +
  • cs-uri-query - Query string (prepended with a '?' if it exists)
  • +
  • cs-uri-stem - Requested URL path
  • +
  • date - The date in yyyy-mm-dd format for GMT
  • +
  • s-dns - Local host name
  • +
  • s-ip - Local IP address
  • +
  • sc-status - HTTP status code of the response
  • +
  • time - Time the request was served in HH:mm:ss format for GMT
  • +
  • time-taken - Time (in seconds as floating point) taken to serve the request
  • +
  • x-threadname - Current request thread name (can compare later with stacktraces)
  • +
+ +

For any of the x-H(XXX) the following method will be called from the + HttpServletRequest object:

+
    +
  • x-H(authType): getAuthType
  • +
  • x-H(characterEncoding): getCharacterEncoding
  • +
  • x-H(contentLength): getContentLength
  • +
  • x-H(locale): getLocale
  • +
  • x-H(protocol): getProtocol
  • +
  • x-H(remoteUser): getRemoteUser
  • +
  • x-H(requestedSessionId): getRequestedSessionId
  • +
  • x-H(requestedSessionIdFromCookie): + isRequestedSessionIdFromCookie
  • +
  • x-H(requestedSessionIdValid): + isRequestedSessionIdValid
  • +
  • x-H(scheme): getScheme
  • +
  • x-H(secure): isSecure
  • +
+ +

+ There is also support to write information about headers + cookies, context, request or session attributes and request + parameters. +

+
    +
  • cs(XXX) for incoming request headers with name XXX
  • +
  • sc(XXX) for outgoing response headers with name XXX
  • +
  • x-A(XXX) for the servlet context attribute with name XXX
  • +
  • x-C(XXX) for the first cookie with name XXX
  • +
  • x-O(XXX) for a concatenation of all outgoing response headers with name XXX
  • +
  • x-P(XXX) for the URL encoded (using UTF-8) request parameter with name XXX
  • +
  • x-R(XXX) for the request attribute with name XXX
  • +
  • x-S(XXX) for the session attribute with name XXX
  • +
+ +
+ +
+ +
Access Control
+ + +
Remote Address Valve
+ +
Introduction
+ +

The Remote Address Valve allows you to compare the + IP address of the client that submitted this request against one or more + regular expressions, and either allow the request to continue + or refuse to process the request from this client. A Remote Address + Valve can be associated with any Catalina container + (Engine, Host, or + Context), and must accept any request + presented to this container for processing before it will be passed on.

+ +

The syntax for regular expressions is different than that for + 'standard' wildcard matching. Tomcat uses the java.util.regex + package. Please consult the Java documentation for details of the + expressions supported.

+ +

Optionally one can append the server connector port separated with a + semicolon (";") to allow different expressions for each connector.

+ +

The behavior when a request is refused can be changed + to not deny but instead set an invalid authentication + header. This is useful in combination with the context attribute + preemptiveAuthentication="true".

+ +

Note: There is a caveat when using this valve with + IPv6 addresses. Format of the IP address that this valve is processing + depends on the API that was used to obtain it. If the address was obtained + from Java socket using Inet6Address class, its format will be + x:x:x:x:x:x:x:x. That is, the IP address for localhost + will be 0:0:0:0:0:0:0:1 instead of the more widely used + ::1. Consult your access logs for the actual value.

+ +

See also: Remote Host Valve, + Remote IP Valve.

+
+ +
Attributes
+ +

The Remote Address Valve supports the following + configuration attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.RemoteAddrValve.

+
allow +

A regular expression (using java.util.regex) that the + remote client's IP address is compared to. If this attribute + is specified, the remote address MUST match for this request to be + accepted. If this attribute is not specified, all requests will be + accepted UNLESS the remote address matches a deny + pattern.

+
deny +

A regular expression (using java.util.regex) that the + remote client's IP address is compared to. If this attribute + is specified, the remote address MUST NOT match for this request to be + accepted. If this attribute is not specified, request acceptance is + governed solely by the allow attribute.

+
denyStatus +

HTTP response status code that is used when rejecting denied + request. The default value is 403. For example, + it can be set to the value 404.

+
addConnectorPort +

Append the server connector port to the client IP address separated + with a semicolon (";"). If this is set to true, the + expressions configured with allow and + deny is compared against ADDRESS;PORT + where ADDRESS is the client IP address and + PORT is the Tomcat connector port which received the + request. The default value is false.

+
invalidAuthenticationWhenDeny +

When a request should be denied, do not deny but instead + set an invalid authentication header. This only works + if the context has the attribute preemptiveAuthentication="true" + set. An already existing authentication header will not be + overwritten. In effect this will trigger authentication instead of deny + even if the application does not have a security constraint configured.

+

This can be combined with addConnectorPort to trigger authentication + depending on the client and the connector that is used to access an application.

+
+ +
+ +
Example 1
+

To allow access only for the clients connecting from localhost:

+
<Valve className="org.apache.catalina.valves.RemoteAddrValve"
+   allow="127\.\d+\.\d+\.\d+|::1|0:0:0:0:0:0:0:1"/>
+
+ +
Example 2
+

To allow unrestricted access for the clients connecting from localhost + but for all other clients only to port 8443:

+
<Valve className="org.apache.catalina.valves.RemoteAddrValve"
+   addConnectorPort="true"
+   allow="127\.\d+\.\d+\.\d+;\d*|::1;\d*|0:0:0:0:0:0:0:1;\d*|.*;8443"/>
+
+ +
Example 3
+

To allow unrestricted access to port 8009, but trigger basic + authentication if the application is accessed on another port:

+
<Context>
+  ...
+  <Valve className="org.apache.catalina.valves.RemoteAddrValve"
+         addConnectorPort="true"
+         invalidAuthenticationWhenDeny="true"
+         allow=".*;8009"/>
+  <Valve className="org.apache.catalina.authenticator.BasicAuthenticator" />
+  ...
+</Context>
+
+ +
+ + +
Remote Host Valve
+ +
Introduction
+ +

The Remote Host Valve allows you to compare the + hostname of the client that submitted this request against one or more + regular expressions, and either allow the request to continue + or refuse to process the request from this client. A Remote Host + Valve can be associated with any Catalina container + (Engine, Host, or + Context), and must accept any request + presented to this container for processing before it will be passed on.

+ +

The syntax for regular expressions is different than that for + 'standard' wildcard matching. Tomcat uses the java.util.regex + package. Please consult the Java documentation for details of the + expressions supported.

+ +

Optionally one can append the server connector port separated with a + semicolon (";") to allow different expressions for each connector.

+ +

The behavior when a request is refused can be changed + to not deny but instead set an invalid authentication + header. This is useful in combination with the context attribute + preemptiveAuthentication="true".

+ +

Note: This valve processes the value returned by + method ServletRequest.getRemoteHost(). To allow the method + to return proper host names, you have to enable "DNS lookups" feature on + a Connector.

+ +

See also: Remote Address Valve, + HTTP Connector configuration.

+
+ +
Attributes
+ +

The Remote Host Valve supports the following + configuration attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.RemoteHostValve.

+
allow +

A regular expression (using java.util.regex) that the + remote client's hostname is compared to. If this attribute + is specified, the remote hostname MUST match for this request to be + accepted. If this attribute is not specified, all requests will be + accepted UNLESS the remote hostname matches a deny + pattern.

+
deny +

A regular expression (using java.util.regex) that the + remote client's hostname is compared to. If this attribute + is specified, the remote hostname MUST NOT match for this request to be + accepted. If this attribute is not specified, request acceptance is + governed solely by the allow attribute.

+
denyStatus +

HTTP response status code that is used when rejecting denied + request. The default value is 403. For example, + it can be set to the value 404.

+
addConnectorPort +

Append the server connector port to the client hostname separated + with a semicolon (";"). If this is set to true, the + expressions configured with allow and + deny is compared against HOSTNAME;PORT + where HOSTNAME is the client hostname and + PORT is the Tomcat connector port which received the + request. The default value is false.

+
invalidAuthenticationWhenDeny +

When a request should be denied, do not deny but instead + set an invalid authentication header. This only works + if the context has the attribute preemptiveAuthentication="true" + set. An already existing authentication header will not be + overwritten. In effect this will trigger authentication instead of deny + even if the application does not have a security constraint configured.

+

This can be combined with addConnectorPort to trigger authentication + depending on the client and the connector that is used to access an application.

+
+ +
+ +
+ +
Remote CIDR Valve
+ +
Introduction
+ +

The Remote CIDR Valve allows you to compare the + IP address of the client that submitted this request against one or more + netmasks following the CIDR notation, and either allow the request to + continue or refuse to process the request from this client. IPv4 and + IPv6 are both fully supported. A Remote CIDR Valve can be associated + with any Catalina container (Engine, + Host, or Context), and + must accept any request presented to this container for processing before + it will be passed on. +

+ +

This valve mimicks Apache's Order, + Allow from and Deny from directives, + with the following limitations: +

+ +
    +
  • Order will always be allow, deny;
  • +
  • dotted quad notations for netmasks are not supported (that is, you + cannot write 192.168.1.0/255.255.255.0, you must write + 192.168.1.0/24; +
  • +
  • shortcuts, like 10.10., which is equivalent to + 10.10.0.0/16, are not supported; +
  • +
  • as the valve name says, this is a CIDR only valve, + therefore subdomain notations like .mydomain.com are not + supported either. +
  • +
+ +

Some more features of this valve are: +

+ +
    +
  • if you omit the CIDR prefix, this valve becomes a single IP + valve;
  • +
  • unlike the Remote Host Valve, + it can handle IPv6 addresses in condensed form (::1, + fe80::/71, etc).
  • +
+ +
+ +
Attributes
+ +

The Remote CIDR Valve supports the following + configuration attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.RemoteCIDRValve.

+
allow +

A comma-separated list of IPv4 or IPv6 netmasks or addresses + that the remote client's IP address is matched against. + If this attribute is specified, the remote address MUST match + for this request to be accepted. If this attribute is not specified, + all requests will be accepted UNLESS the remote IP is matched by a + netmask in the deny attribute. +

+
deny +

A comma-separated list of IPv4 or IPv6 netmasks or addresses + that the remote client's IP address is matched against. + If this attribute is specified, the remote address MUST NOT match + for this request to be accepted. If this attribute is not specified, + request acceptance is governed solely by the accept + attribute. +

+
+ +
+ +
Example
+

To allow access only for the clients connecting from localhost:

+
+      <Valve className="org.apache.catalina.valves.RemoteCIDRValve"
+      allow="127.0.0.1, ::1"/>
+    
+
+ +
+ + +
Proxies Support
+ +
Remote IP Valve
+ +
Introduction
+ +

Tomcat port of + mod_remoteip, + this valve replaces the apparent client remote IP address and hostname for + the request with the IP address list presented by a proxy or a load balancer + via a request headers (e.g. "X-Forwarded-For").

+ +

Another feature of this valve is to replace the apparent scheme + (http/https), server port and request.secure with the scheme presented + by a proxy or a load balancer via a request header + (e.g. "X-Forwarded-Proto").

+ +

This Valve may be used at the Engine, Host or + Context level as required. Normally, this Valve would be used + at the Engine level.

+ +

If used in conjunction with Remote Address/Host valves then this valve + should be defined first to ensure that the correct client IP address is + presented to the Remote Address/Host valves.

+ +

Note: By default this valve has no effect on the + values that are written into access log. The original values are restored + when request processing leaves the valve and that always happens earlier + than access logging. To pass the remote address, remote host, server port + and protocol values set by this valve to the access log, + they are put into request attributes. Publishing these values here + is enabled by default, but AccessLogValve should be explicitly + configured to use them. See documentation for + requestAttributesEnabled attribute of + AccessLogValve.

+ +

The names of request attributes that are set by this valve + and can be used by access logging are the following:

+ +
    +
  • org.apache.catalina.AccessLog.RemoteAddr
  • +
  • org.apache.catalina.AccessLog.RemoteHost
  • +
  • org.apache.catalina.AccessLog.Protocol
  • +
  • org.apache.catalina.AccessLog.ServerPort
  • +
  • org.apache.tomcat.remoteAddr
  • +
+ +
+ +
Attributes
+ +

The Remote IP Valve supports the + following configuration attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.RemoteIpValve.

+
remoteIpHeader +

Name of the HTTP Header read by this valve that holds the list of + traversed IP addresses starting from the requesting client. If not + specified, the default of x-forwarded-for is used.

+
internalProxies +

Regular expression (using java.util.regex) that a + proxy's IP address must match to be considered an internal proxy. + Internal proxies that appear in the remoteIpHeader will + be trusted and will not appear in the proxiesHeader + value. If not specified the default value of + 10\.\d{1,3}\.\d{1,3}\.\d{1,3}|192\.168\.\d{1,3}\.\d{1,3}|169\.254\.\d{1,3}\.\d{1,3}|127\.\d{1,3}\.\d{1,3}\.\d{1,3}|0:0:0:0:0:0:0:1 + will be used.

+
proxiesHeader +

Name of the HTTP header created by this valve to hold the list of + proxies that have been processed in the incoming + remoteIpHeader. If not specified, the default of + x-forwarded-by is used.

+
requestAttributesEnabled +

Set to true to set the request attributes used by + AccessLog implementations to override the values returned by the + request for remote address, remote host, server port and protocol. + Request attributes are also used to enable the forwarded remote address + to be displayed on the status page of the Manager web application. + If not set, the default value of true will be used.

+
trustedProxies +

Regular expression (using java.util.regex) that a + proxy's IP address must match to be considered an trusted proxy. + Trusted proxies that appear in the remoteIpHeader will + be trusted and will appear in the proxiesHeader value. + If not specified, no proxies will be trusted.

+
protocolHeader +

Name of the HTTP Header read by this valve that holds the protocol + used by the client to connect to the proxy. If not specified, the + default of X-Forwarded-Proto is used.

+
hostHeader +

Name of the HTTP Header read by this valve that holds the host + used by the client to connect to the proxy. If not specified, the + default of null is used.

+
portHeader +

Name of the HTTP Header read by this valve that holds the port + used by the client to connect to the proxy. If not specified, the + default of null is used.

+
protocolHeaderHttpsValue +

Value of the protocolHeader to indicate that it is + an HTTPS request. If not specified, the default of https is + used.

+
httpServerPort +

Value returned by ServletRequest.getServerPort() + when the protocolHeader indicates http + protocol and no portHeader is present. If not + specified, the default of 80 is used.

+
httpsServerPort +

Value returned by ServletRequest.getServerPort() + when the protocolHeader indicates https + protocol and no portHeader is present. If not + specified, the default of 443 is used.

+
changeLocalHost +

If true, the value returned by + ServletRequest.getLocalHost() and + ServletRequest.getServerHost() is modified by the this + valve. If not specified, the default of false is used.

+
changeLocalPort +

If true, the value returned by + ServletRequest.getLocalPort() and + ServletRequest.getServerPort() is modified by the this + valve. If not specified, the default of false is used.

+
+ +
+ +
+ + +
SSL Valve
+ +
Introduction
+ +

When using mod_proxy_http, the client SSL information is not included in + the protocol (unlike mod_jk and mod_proxy_ajp). To make the client SSL + information available to Tomcat, some additional configuration is required. + In httpd, mod_headers is used to add the SSL information as HTTP headers. In + Tomcat, this valve is used to read the information from the HTTP headers and + insert it into the request.

+ +

Note: Ensure that the headers are always set by httpd for all requests to + prevent a client spoofing SSL information by sending fake headers.

+ +

To configure httpd to set the necessary headers, add the following:

+
<IfModule ssl_module>
+  RequestHeader set SSL_CLIENT_CERT "%{SSL_CLIENT_CERT}s"
+  RequestHeader set SSL_CIPHER "%{SSL_CIPHER}s"
+  RequestHeader set SSL_SESSION_ID "%{SSL_SESSION_ID}s"
+  RequestHeader set SSL_CIPHER_USEKEYSIZE "%{SSL_CIPHER_USEKEYSIZE}s"
+</IfModule>
+ +
+ +
Attributes
+ +

The SSL Valve supports the following configuration + attribute:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.SSLValve. +

+
sslClientCertHeader +

Allows setting a custom name for the ssl_client_cert header. + If not specified, the default of ssl_client_cert is + used.

+
sslCipherHeader +

Allows setting a custom name for the ssl_cipher header. + If not specified, the default of ssl_cipher is + used.

+
sslSessionIdHeader +

Allows setting a custom name for the ssl_session_id header. + If not specified, the default of ssl_session_id is + used.

+
sslCipherUserKeySizeHeader +

Allows setting a custom name for the ssl_cipher_usekeysize header. + If not specified, the default of ssl_cipher_usekeysize is + used.

+
+ +
+ +
+ + +
Single Sign On Valve
+ +
Introduction
+ +

The Single Sign On Valve is utilized when you wish to give users + the ability to sign on to any one of the web applications associated with + your virtual host, and then have their identity recognized by all other + web applications on the same virtual host.

+ +

See the Single Sign On special + feature on the Host element for more information.

+ +
+ + +
Attributes
+ +

The Single Sign On Valve supports the following + configuration attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.authenticator.SingleSignOn.

+
requireReauthentication +

Default false. Flag to determine whether each request needs to be + reauthenticated to the security Realm. If "true", this + Valve uses cached security credentials (username and password) to + reauthenticate to the Realm each request associated + with an SSO session. If "false", the Valve can itself authenticate + requests based on the presence of a valid SSO cookie, without + rechecking with the Realm.

+
cookieDomain +

Sets the host domain to be used for sso cookies.

+
+ +
+ + +
Authentication
+ +

The valves in this section implement +org.apache.catalina.Authenticator interface.

+ +
Basic Authenticator Valve
+ +
Introduction
+ +

The Basic Authenticator Valve is automatically added to + any Context that is configured to use BASIC + authentication.

+ +

If any non-default settings are required, the valve may be configured + within Context element with the required + values.

+ +
+ +
Attributes
+ +

The Basic Authenticator Valve supports the following + configuration attributes:

+ +
AttributeDescription
allowCorsPreflight +

Are requests that appear to be CORS preflight requests allowed to + bypass the authenticator as required by the CORS specification. The + allowed values are never, filter and + always. never means that a request will never + bypass authentication even if it appears to be a CORS preflight request. + filter means that a request will bypass authentication if + it appears to be a CORS preflight request; it is mapped to a web + application that has the CORS + Filter enabled; and the CORS Filter is mapped to /*. + always means that all requests that appear to be CORS + preflight requests will bypass authentication. If not set, the default + value is never.

+
alwaysUseSession +

Should a session always be used once a user is authenticated? This + may offer some performance benefits since the session can then be used + to cache the authenticated Principal, hence removing the need to + authenticate the user via the Realm on every request. This may be of + help for combinations such as BASIC authentication used with the + JNDIRealm or DataSourceRealms. However there will also be the + performance cost of creating and GC'ing the session. If not set, the + default value of false will be used.

+
cache +

Should we cache authenticated Principals if the request is part of an + HTTP session? If not specified, the default value of true + will be used.

+
changeSessionIdOnAuthentication +

Controls if the session ID is changed if a session exists at the + point where users are authenticated. This is to prevent session fixation + attacks. If not set, the default value of true will be + used.

+
charset +

Controls if the WWW-Authenticate HTTP header includes a + charset authentication parameter as per RFC 7617. The only + permitted options are null, the empty string and + UTF-8. If UTF-8 is specified then the + charset authentication parameter will be sent with that + value and the provided user name and optional password will be converted + from bytes to characters using UTF-8. Otherwise, no charset + authentication parameter will be sent and the provided user name and + optional password will be converted from bytes to characters using + ISO-8859-1. The default value is null

+
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.authenticator.BasicAuthenticator.

+
disableProxyCaching +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers but will also cause secured pages to be + cached by proxies which will almost certainly be a security issue. + securePagesWithPragma offers an alternative, secure, + workaround for browser caching issues. If not set, the default value of + true will be used.

+
securePagesWithPragma +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers by using + Cache-Control: private rather than the default of + Pragma: No-cache and Cache-control: No-cache. + If not set, the default value of false will be used.

+
secureRandomAlgorithm +

Name of the algorithm to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the platform + default provider and the default algorithm will be used. If not + specified, the default algorithm of SHA1PRNG will be used. If the + default algorithm is not supported, the platform default will be used. + To specify that the platform default should be used, do not set the + secureRandomProvider attribute and set this attribute to the empty + string.

+
secureRandomClass +

Name of the Java class that extends + java.security.SecureRandom to use to generate SSO session + IDs. If not specified, the default value is + java.security.SecureRandom.

+
secureRandomProvider +

Name of the provider to use to create the + java.security.SecureRandom instances that generate SSO + session IDs. If an invalid algorithm and/or provider is specified, the + platform default provider and the default algorithm will be used. If not + specified, the platform default provider will be used.

+
sendAuthInfoResponseHeaders +

Controls whether the auth information (remote user and auth type) + shall be returned as response headers for a forwarded/proxied request. + When the RemoteIpValve or RemoteIpFilter mark + a forwarded request with the Globals.REQUEST_FORWARDED_ATTRIBUTE + this authenticator can return the values of + HttpServletRequest.getRemoteUser() and + HttpServletRequest.getAuthType() as response headers + remote-user and auth-type to a reverse proxy. + This is useful, e.g., for access log consistency or other decisions to make. + If not specified, the default value is false.

+
+ +
+ +
+ + +
Digest Authenticator Valve
+ +
Introduction
+ +

The Digest Authenticator Valve is automatically added to + any Context that is configured to use DIGEST + authentication.

+ +

If any non-default settings are required, the valve may be configured + within Context element with the required + values.

+ +
+ +
Attributes
+ +

The Digest Authenticator Valve supports the following + configuration attributes:

+ +
AttributeDescription
allowCorsPreflight +

Are requests that appear to be CORS preflight requests allowed to + bypass the authenticator as required by the CORS specification. The + allowed values are never, filter and + always. never means that a request will never + bypass authentication even if it appears to be a CORS preflight request. + filter means that a request will bypass authentication if + it appears to be a CORS preflight request; it is mapped to a web + application that has the CORS + Filter enabled; and the CORS Filter is mapped to /*. + always means that all requests that appear to be CORS + preflight requests will bypass authentication. If not set, the default + value is never.

+
alwaysUseSession +

Should a session always be used once a user is authenticated? This + may offer some performance benefits since the session can then be used + to cache the authenticated Principal, hence removing the need to + authenticate the user via the Realm on every request. This may be of + help for combinations such as BASIC authentication used with the + JNDIRealm or DataSourceRealms. However there will also be the + performance cost of creating and GC'ing the session. If not set, the + default value of false will be used.

+
cache +

Should we cache authenticated Principals if the request is part of an + HTTP session? If not specified, the default value of false + will be used.

+
changeSessionIdOnAuthentication +

Controls if the session ID is changed if a session exists at the + point where users are authenticated. This is to prevent session fixation + attacks. If not set, the default value of true will be + used.

+
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.authenticator.DigestAuthenticator.

+
disableProxyCaching +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers but will also cause secured pages to be + cached by proxies which will almost certainly be a security issue. + securePagesWithPragma offers an alternative, secure, + workaround for browser caching issues. If not set, the default value of + true will be used.

+
key +

The secret key used by digest authentication. If not set, a secure + random value is generated. This should normally only be set when it is + necessary to keep key values constant either across server restarts + and/or across a cluster.

+
nonceCacheSize +

To protect against replay attacks, the DIGEST authenticator tracks + server nonce and nonce count values. This attribute controls the size + of that cache. If not specified, the default value of 1000 is used.

+
nonceCountWindowSize +

Client requests may be processed out of order which in turn means + that the nonce count values may be processed out of order. To prevent + authentication failures when nonce counts are presented out of order + the authenticator tracks a window of nonce count values. This attribute + controls how big that window is. If not specified, the default value of + 100 is used.

+
nonceValidity +

The time, in milliseconds, that a server generated nonce will be + considered valid for use in authentication. If not specified, the + default value of 300000 (5 minutes) will be used.

+
opaque +

The opaque server string used by digest authentication. If not set, a + random value is generated. This should normally only be set when it is + necessary to keep opaque values constant either across server restarts + and/or across a cluster.

+
securePagesWithPragma +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers by using + Cache-Control: private rather than the default of + Pragma: No-cache and Cache-control: No-cache. + If not set, the default value of false will be used.

+
secureRandomAlgorithm +

Name of the algorithm to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the platform + default provider and the default algorithm will be used. If not + specified, the default algorithm of SHA1PRNG will be used. If the + default algorithm is not supported, the platform default will be used. + To specify that the platform default should be used, do not set the + secureRandomProvider attribute and set this attribute to the empty + string.

+
secureRandomClass +

Name of the Java class that extends + java.security.SecureRandom to use to generate SSO session + IDs. If not specified, the default value is + java.security.SecureRandom.

+
secureRandomProvider +

Name of the provider to use to create the + java.security.SecureRandom instances that generate SSO + session IDs. If an invalid algorithm and/or provider is specified, the + platform default provider and the default algorithm will be used. If not + specified, the platform default provider will be used.

+
sendAuthInfoResponseHeaders +

Controls whether the auth information (remote user and auth type) + shall be returned as response headers for a forwarded/proxied request. + When the RemoteIpValve or RemoteIpFilter mark + a forwarded request with the Globals.REQUEST_FORWARDED_ATTRIBUTE + this authenticator can return the values of + HttpServletRequest.getRemoteUser() and + HttpServletRequest.getAuthType() as response headers + remote-user and auth-type to a reverse proxy. + This is useful, e.g., for access log consistency or other decisions to make. + If not specified, the default value is false.

+
validateUri +

Should the URI be validated as required by RFC2617? If not specified, + the default value of true will be used. This should + normally only be set when Tomcat is located behind a reverse proxy and + the proxy is modifying the URI passed to Tomcat such that DIGEST + authentication always fails.

+
+ +
+ +
+ + +
Form Authenticator Valve
+ +
Introduction
+ +

The Form Authenticator Valve is automatically added to + any Context that is configured to use FORM + authentication.

+ +

If any non-default settings are required, the valve may be configured + within Context element with the required + values.

+ +
+ +
Attributes
+ +

The Form Authenticator Valve supports the following + configuration attributes:

+ +
AttributeDescription
allowCorsPreflight +

Are requests that appear to be CORS preflight requests allowed to + bypass the authenticator as required by the CORS specification. The + allowed values are never, filter and + always. never means that a request will never + bypass authentication even if it appears to be a CORS preflight request. + filter means that a request will bypass authentication if + it appears to be a CORS preflight request; it is mapped to a web + application that has the CORS + Filter enabled; and the CORS Filter is mapped to /*. + always means that all requests that appear to be CORS + preflight requests will bypass authentication. If not set, the default + value is never.

+
changeSessionIdOnAuthentication +

Controls if the session ID is changed if a session exists at the + point where users are authenticated. This is to prevent session fixation + attacks. If not set, the default value of true will be + used.

+
characterEncoding +

Character encoding to use to read the username and password parameters + from the request. If not set, the encoding of the request body will be + used.

+
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.authenticator.FormAuthenticator.

+
disableProxyCaching +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers but will also cause secured pages to be + cached by proxies which will almost certainly be a security issue. + securePagesWithPragma offers an alternative, secure, + workaround for browser caching issues. If not set, the default value of + true will be used.

+
landingPage +

Controls the behavior of the FORM authentication process if the + process is misused, for example by directly requesting the login page + or delaying logging in for so long that the session expires. If this + attribute is set, rather than returning an error response code, Tomcat + will redirect the user to the specified landing page if the login form + is submitted with valid credentials. For the login to be processed, the + landing page must be a protected resource (i.e. one that requires + authentication). If the landing page does not require authentication + then the user will not be logged in and will be prompted for their + credentials again when they access a protected page.

+
securePagesWithPragma +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers by using + Cache-Control: private rather than the default of + Pragma: No-cache and Cache-control: No-cache. + If not set, the default value of false will be used.

+
secureRandomAlgorithm +

Name of the algorithm to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the platform + default provider and the default algorithm will be used. If not + specified, the default algorithm of SHA1PRNG will be used. If the + default algorithm is not supported, the platform default will be used. + To specify that the platform default should be used, do not set the + secureRandomProvider attribute and set this attribute to the empty + string.

+
secureRandomClass +

Name of the Java class that extends + java.security.SecureRandom to use to generate SSO session + IDs. If not specified, the default value is + java.security.SecureRandom.

+
secureRandomProvider +

Name of the provider to use to create the + java.security.SecureRandom instances that generate SSO + session IDs. If an invalid algorithm and/or provider is specified, the + platform default provider and the default algorithm will be used. If not + specified, the platform default provider will be used.

+
sendAuthInfoResponseHeaders +

Controls whether the auth information (remote user and auth type) + shall be returned as response headers for a forwarded/proxied request. + When the RemoteIpValve or RemoteIpFilter mark + a forwarded request with the Globals.REQUEST_FORWARDED_ATTRIBUTE + this authenticator can return the values of + HttpServletRequest.getRemoteUser() and + HttpServletRequest.getAuthType() as response headers + remote-user and auth-type to a reverse proxy. + This is useful, e.g., for access log consistency or other decisions to make. + If not specified, the default value is false.

+
+ +
+ +
+ + +
SSL Authenticator Valve
+ +
Introduction
+ +

The SSL Authenticator Valve is automatically added to + any Context that is configured to use SSL + authentication.

+ +

If any non-default settings are required, the valve may be configured + within Context element with the required + values.

+ +
+ +
Attributes
+ +

The SSL Authenticator Valve supports the following + configuration attributes:

+ +
AttributeDescription
allowCorsPreflight +

Are requests that appear to be CORS preflight requests allowed to + bypass the authenticator as required by the CORS specification. The + allowed values are never, filter and + always. never means that a request will never + bypass authentication even if it appears to be a CORS preflight request. + filter means that a request will bypass authentication if + it appears to be a CORS preflight request; it is mapped to a web + application that has the CORS + Filter enabled; and the CORS Filter is mapped to /*. + always means that all requests that appear to be CORS + preflight requests will bypass authentication. If not set, the default + value is never.

+
cache +

Should we cache authenticated Principals if the request is part of an + HTTP session? If not specified, the default value of true + will be used.

+
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.authenticator.SSLAuthenticator.

+
changeSessionIdOnAuthentication +

Controls if the session ID is changed if a session exists at the + point where users are authenticated. This is to prevent session fixation + attacks. If not set, the default value of true will be + used.

+
disableProxyCaching +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers but will also cause secured pages to be + cached by proxies which will almost certainly be a security issue. + securePagesWithPragma offers an alternative, secure, + workaround for browser caching issues. If not set, the default value of + true will be used.

+
securePagesWithPragma +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers by using + Cache-Control: private rather than the default of + Pragma: No-cache and Cache-control: No-cache. + If not set, the default value of false will be used.

+
secureRandomAlgorithm +

Name of the algorithm to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the platform + default provider and the default algorithm will be used. If not + specified, the default algorithm of SHA1PRNG will be used. If the + default algorithm is not supported, the platform default will be used. + To specify that the platform default should be used, do not set the + secureRandomProvider attribute and set this attribute to the empty + string.

+
secureRandomClass +

Name of the Java class that extends + java.security.SecureRandom to use to generate SSO session + IDs. If not specified, the default value is + java.security.SecureRandom.

+
secureRandomProvider +

Name of the provider to use to create the + java.security.SecureRandom instances that generate SSO + session IDs. If an invalid algorithm and/or provider is specified, the + platform default provider and the default algorithm will be used. If not + specified, the platform default provider will be used.

+
+ +
+ +
+ + +
SPNEGO Valve
+ +
Introduction
+ +

The SPNEGO Authenticator Valve is automatically added to + any Context that is configured to use SPNEGO + authentication.

+ +

If any non-default settings are required, the valve may be configured + within Context element with the required + values.

+ +
+ +
Attributes
+ +

The SPNEGO Authenticator Valve supports the following + configuration attributes:

+ +
AttributeDescription
allowCorsPreflight +

Are requests that appear to be CORS preflight requests allowed to + bypass the authenticator as required by the CORS specification. The + allowed values are never, filter and + always. never means that a request will never + bypass authentication even if it appears to be a CORS preflight request. + filter means that a request will bypass authentication if + it appears to be a CORS preflight request and the web application the + request maps to has the CORS + Filter enabled and mapped to /*. always + means that all requests that appear to be CORS preflight requests will + bypass authentication. If not set, the default value is + never.

+
alwaysUseSession +

Should a session always be used once a user is authenticated? This + may offer some performance benefits since the session can then be used + to cache the authenticated Principal, hence removing the need to + authenticate the user on every request. This will also help with clients + that assume that the server will cache the authenticated user. However + there will also be the performance cost of creating and GC'ing the + session. For an alternative solution see + noKeepAliveUserAgents. If not set, the default value of + false will be used.

+
applyJava8u40Fix +

A fix introduced in Java 8 update 40 ( + JDK-8048194) + onwards broke SPNEGO authentication for IE with Tomcat running on + Windows 2008 R2 servers. This option enables a work-around that allows + SPNEGO authentication to continue working. The work-around should not + impact other configurations so it is enabled by default. If necessary, + the workaround can be disabled by setting this attribute to + false.

+
cache +

Should we cache authenticated Principals if the request is part of an + HTTP session? If not specified, the default value of true + will be used.

+
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.authenticator.SpnegoAuthenticator. +

+
changeSessionIdOnAuthentication +

Controls if the session ID is changed if a session exists at the + point where users are authenticated. This is to prevent session fixation + attacks. If not set, the default value of true will be + used.

+
disableProxyCaching +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers but will also cause secured pages to be + cached by proxies which will almost certainly be a security issue. + securePagesWithPragma offers an alternative, secure, + workaround for browser caching issues. If not set, the default value of + true will be used.

+
loginConfigName +

The name of the JAAS login configuration to be used to login as the + service. If not specified, the default of + com.sun.security.jgss.krb5.accept is used.

+
noKeepAliveUserAgents +

Some clients (not most browsers) expect the server to cache the + authenticated user information for a connection and do not resend the + credentials with every request. Tomcat will not do this unless an HTTP + session is available. A session will be available if either the + application creates one or if alwaysUseSession is enabled + for this Authenticator.

+

As an alternative to creating a session, this attribute may be used + to define the user agents for which HTTP keep-alive is disabled. This + means that a connection will only used for a single request and hence + there is no ability to cache authenticated user information per + connection. There will be a performance cost in disabling HTTP + keep-alive.

+

The attribute should be a regular expression that matches the entire + user-agent string, e.g. .*Chrome.*. If not specified, no + regular expression will be defined and no user agents will have HTTP + keep-alive disabled.

+
securePagesWithPragma +

Controls the caching of pages that are protected by security + constraints. Setting this to false may help work around + caching issues in some browsers by using + Cache-Control: private rather than the default of + Pragma: No-cache and Cache-control: No-cache. + If not set, the default value of false will be used.

+
secureRandomAlgorithm +

Name of the algorithm to use to create the + java.security.SecureRandom instances that generate session + IDs. If an invalid algorithm and/or provider is specified, the platform + default provider and the default algorithm will be used. If not + specified, the default algorithm of SHA1PRNG will be used. If the + default algorithm is not supported, the platform default will be used. + To specify that the platform default should be used, do not set the + secureRandomProvider attribute and set this attribute to the empty + string.

+
secureRandomClass +

Name of the Java class that extends + java.security.SecureRandom to use to generate SSO session + IDs. If not specified, the default value is + java.security.SecureRandom.

+
secureRandomProvider +

Name of the provider to use to create the + java.security.SecureRandom instances that generate SSO + session IDs. If an invalid algorithm and/or provider is specified, the + platform default provider and the default algorithm will be used. If not + specified, the platform default provider will be used.

+
sendAuthInfoResponseHeaders +

Controls whether the auth information (remote user and auth type) + shall be returned as response headers for a forwarded/proxied request. + When the RemoteIpValve or RemoteIpFilter mark + a forwarded request with the Globals.REQUEST_FORWARDED_ATTRIBUTE + this authenticator can return the values of + HttpServletRequest.getRemoteUser() and + HttpServletRequest.getAuthType() as response headers + remote-user and auth-type to a reverse proxy. + This is useful, e.g., for access log consistency or other decisions to make. + If not specified, the default value is false.

+
storeDelegatedCredential +

Controls if the user' delegated credential will be stored in + the user Principal. If available, the delegated credential will be + available to applications (e.g. for onward authentication to external + services) via the org.apache.catalina.realm.GSS_CREDENTIAL + request attribute. If not set, the default value of true + will be used.

+
+ +
+ +
+ + +
Error Report Valve
+ +
Introduction
+ +

The Error Report Valve is a simple error handler + for HTTP status codes that will generate and return HTML error pages.

+ +

NOTE: Disabling both showServerInfo and showReport will + only return the HTTP status code.

+ +
+ +
Attributes
+ +

The Error Report Valve supports the following + configuration attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.ErrorReportValve to use the + default error report valve.

+
showReport +

Flag to determine if the error report (custom error message and/or + stack trace) is presented when an error occurs. If set to + false, then the error report is not returned in the HTML + response. + Default value: true +

+
showServerInfo +

Flag to determine if server information is presented when an error + occurs. If set to false, then the server version is not + returned in the HTML response. + Default value: true +

+
+ +
+ +
Crawler Session Manager Valve
+ +
Introduction
+ +

Web crawlers can trigger the creation of many thousands of sessions as + they crawl a site which may result in significant memory consumption. This + Valve ensures that crawlers are associated with a single session - just like + normal users - regardless of whether or not they provide a session token + with their requests.

+ +

This Valve may be used at the Engine, Host or + Context level as required. Normally, this Valve would be used + at the Engine level.

+ +

If used in conjunction with Remote IP valve then the Remote IP valve + should be defined before this valve to ensure that the correct client IP + address is presented to this valve.

+ +
+ +
Attributes
+ +

The Crawler Session Manager Valve supports the + following configuration attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.CrawlerSessionManagerValve. +

+
contextAware +

Flag to use the context name together with the client IP to + identify the session to re-use. Can be combined with hostAware. + Default value: true +

+
crawlerIps +

Regular expression (using java.util.regex) that client + IP is matched against to determine if a request is from a web crawler. + By default such regular expression is not set.

+
crawlerUserAgents +

Regular expression (using java.util.regex) that the user + agent HTTP request header is matched against to determine if a request + is from a web crawler. If not set, the default of + .*[bB]ot.*|.*Yahoo! Slurp.*|.*Feedfetcher-Google.* is used.

+
hostAware +

Flag to use the configured host together with the client IP to + identify the session to re-use. Can be combined with contextAware. + Default value: true +

+
sessionInactiveInterval +

The minimum time in seconds that the Crawler Session Manager Valve + should keep the mapping of client IP to session ID in memory without any + activity from the client. The client IP / session cache will be + periodically purged of mappings that have been inactive for longer than + this interval. If not specified the default value of 60 + will be used.

+
+ +
+ +
Stuck Thread Detection Valve
+ +
Introduction
+ +

This valve allows to detect requests that take a long time to process, + which might indicate that the thread that is processing it is stuck. + Additionally it can optionally interrupt such threads to try and unblock + them.

+

When such a request is detected, the current stack trace of its thread is + written to Tomcat log with a WARN level.

+

The IDs and names of the stuck threads are available through JMX in the + stuckThreadIds and stuckThreadNames attributes. + The IDs can be used with the standard Threading JVM MBean + (java.lang:type=Threading) to retrieve other information + about each stuck thread.

+ +
+ +
Attributes
+ +

The Stuck Thread Detection Valve supports the + following configuration attributes:

+ +
AttributeDescription
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.StuckThreadDetectionValve. +

+
threshold +

Minimum duration in seconds after which a thread is considered stuck. + Default is 600 seconds. If set to 0, the detection is disabled.

+

Note: since the detection (and optional interruption) is done in the + background thread of the Container (Engine, Host or Context) declaring + this Valve, the threshold should be higher than the + backgroundProcessorDelay of this Container.

+
interruptThreadThreshold +

Minimum duration in seconds after which a stuck thread should be + interrupted to attempt to "free" it.

+

Note that there's no guarantee that the thread will get unstuck. + This usually works well for threads stuck on I/O or locks, but is + probably useless in case of infinite loops.

+

Default is -1 which disables the feature. To enable it, the value + must be greater or equal to threshold.

+
+ +
+ +
Semaphore Valve
+ +
Introduction
+ +

The Semaphore Valve is able to limit the number of + concurrent request processing threads.

+

org.apache.catalina.valves.SemaphoreValve provides + methods which may be overridden by a subclass to customize behavior:

+
    +
  • controlConcurrency may be overridden to add + conditions;
  • +
  • permitDenied may be overridden to add error handling + when a permit isn't granted.
  • +
+ +
+ +
Attributes
+ +

The Semaphore Valve supports the following + configuration attributes:

+ +
AttributeDescription
block +

Flag to determine if a thread is blocked until a permit is available. + The default value is true.

+
className +

Java class name of the implementation to use. This MUST be set to + org.apache.catalina.valves.SemaphoreValve.

+
concurrency +

Concurrency level of the semaphore. The default value is + 10.

+
fairness +

Fairness of the semaphore. The default value is + false.

+
interruptible +

Flag to determine if a thread may be interrupted until a permit is + available. The default value is false.

+
+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/connectors.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/connectors.html new file mode 100644 index 0000000..8f3954a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/connectors.html @@ -0,0 +1,121 @@ +Apache Tomcat 7 (7.0.108) - Connectors How To

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Connectors How To

Table of Contents
+ +
Introduction
+ +

Choosing a connector to use with Tomcat can be difficult. This page will +list the connectors which are supported with this Tomcat release, and will +hopefully help you make the right choice according to your needs.

+ +
HTTP
+ +

The HTTP connector is setup by default with Tomcat, and is ready to use. This +connector features the lowest latency and best overall performance.

+ +

For clustering, an HTTP load balancer with support for web sessions stickiness +must be installed to direct the traffic to the Tomcat servers. Tomcat supports mod_proxy +(on Apache HTTP Server 2.x, and included by default in Apache HTTP Server 2.2) as the load balancer. +It should be noted that the performance of HTTP proxying is usually lower than the +performance of AJP, so AJP clustering is often preferable.

+ +
AJP
+ +

When using a single server, the performance when using a native webserver in +front of the Tomcat instance is most of the time significantly worse than a +standalone Tomcat with its default HTTP connector, even if a large part of the web +application is made of static files. If integration with the native webserver is +needed for any reason, an AJP connector will provide faster performance than +proxied HTTP. AJP clustering is the most efficient from the Tomcat perspective. +It is otherwise functionally equivalent to HTTP clustering.

+ +

The native connectors supported with this Tomcat release are:

+
    +
  • JK 1.2.x with any of the supported servers
  • +
  • mod_proxy on Apache HTTP Server 2.x (included by default in Apache HTTP Server 2.2), +with AJP enabled
  • +
+ +

Other native connectors supporting AJP may work, but are no longer supported.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/default-servlet.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/default-servlet.html new file mode 100644 index 0000000..aa82d84 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/default-servlet.html @@ -0,0 +1,314 @@ +Apache Tomcat 7 (7.0.108) - Default Servlet Reference

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Default Servlet Reference

Table of Contents
+ +
What is the DefaultServlet
+

+The default servlet is the servlet which serves static resources as well +as serves the directory listings (if directory listings are enabled). +

+
Where is it declared?
+

+It is declared globally in $CATALINA_BASE/conf/web.xml. +By default here is it's declaration: +

+
    <servlet>
+        <servlet-name>default</servlet-name>
+        <servlet-class>
+          org.apache.catalina.servlets.DefaultServlet
+        </servlet-class>
+        <init-param>
+            <param-name>debug</param-name>
+            <param-value>0</param-value>
+        </init-param>
+        <init-param>
+            <param-name>listings</param-name>
+            <param-value>false</param-value>
+        </init-param>
+        <load-on-startup>1</load-on-startup>
+    </servlet>
+
+...
+
+    <servlet-mapping>
+        <servlet-name>default</servlet-name>
+        <url-pattern>/</url-pattern>
+    </servlet-mapping>
+ +So by default, the default servlet is loaded at webapp startup and +directory listings are disabled and debugging is turned off. +
What can I change?
+

+ The DefaultServlet allows the following initParameters: +

+ +
PropertyDescription
debug + Debugging level. It is not very useful unless you are a tomcat + developer. As + of this writing, useful values are 0, 1, 11. [0] +
listings + If no welcome file is present, can a directory listing be + shown? + value may be true or false [false] +
+ Welcome files are part of the servlet api. +
+ WARNING: Listings of directories containing many entries are + expensive. Multiple requests for large directory listings can consume + significant proportions of server resources. +
readmeFile + If a directory listing is presented, a readme file may also + be presented with the listing. This file is inserted as is + so it may contain HTML. +
globalXsltFile + If you wish to customize your directory listing, you + can use an XSL transformation. This value is a relative file name (to + either $CATALINA_BASE/conf/ or $CATALINA_HOME/conf/) which will be used + for all directory listings. This can be overridden per context and/or + per directory. See contextXsltFile and + localXsltFile below. The format of the xml is shown + below. +
contextXsltFile + You may also customize your directory listing by context by + configuring contextXsltFile. This must be a context + relative path (e.g.: /path/to/context.xslt) to a file with + a .xsl or .xslt extension. This overrides + globalXsltFile. If this value is present but a file does + not exist, then globalXsltFile will be used. If + globalXsltFile does not exist, then the default + directory listing will be shown. +
localXsltFile + You may also customize your directory listing by directory by + configuring localXsltFile. This must be a file in the + directory where the listing will take place to with a + .xsl or .xslt extension. This overrides + globalXsltFile and contextXsltFile. If this + value is present but a file does not exist, then + contextXsltFile will be used. If + contextXsltFile does not exist, then + globalXsltFile will be used. If + globalXsltFile does not exist, then the default + directory listing will be shown. +
input + Input buffer size (in bytes) when reading + resources to be served. [2048] +
output + Output buffer size (in bytes) when writing + resources to be served. [2048] +
readonly + Is this context "read only", so HTTP commands like PUT and + DELETE are rejected? [true] +
fileEncoding + File encoding to be used when reading static resources. + [platform default] +
sendfileSize + If the connector used supports sendfile, this represents the minimal + file size in KB for which sendfile will be used. Use a negative value + to always disable sendfile. [48] +
useAcceptRanges + If true, the Accept-Ranges header will be set when appropriate for the + response. [true] +
showServerInfo + Should server information be presented in the response sent to clients + when directory listing is enabled. [true] +
+
How do I customize directory listings?
+

You can override DefaultServlet with you own implementation and use that +in your web.xml declaration. If you +can understand what was just said, we will assume you can read the code +to DefaultServlet servlet and make the appropriate adjustments. (If not, +then that method isn't for you) +

+

+You can use either localXsltFile or +globalXsltFile and DefaultServlet will create +an xml document and run it through an xsl transformation based +on the values provided in localXsltFile and +globalXsltFile. localXsltFile is first +checked, followed by globalXsltFile, then default +behaviors takes place. +

+ +

+Format: +

+
    <listing>
+     <entries>
+      <entry type='file|dir' urlPath='aPath' size='###' date='gmt date'>
+        fileName1
+      </entry>
+      <entry type='file|dir' urlPath='aPath' size='###' date='gmt date'>
+        fileName2
+      </entry>
+      ...
+     </entries>
+     <readme></readme>
+    </listing>
+
    +
  • size will be missing if type='dir'
  • +
  • Readme is a CDATA entry
  • +
+ +

+ The following is a sample xsl file which mimics the default tomcat behavior: +

+
<?xml version="1.0" encoding="UTF-8"?>
+
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+  version="3.0">
+
+  <xsl:output method="html" html-version="5.0"
+    encoding="UTF-8" indent="no"
+    doctype-system="about:legacy-compat"/>
+
+  <xsl:template match="listing">
+   <html>
+    <head>
+      <title>
+        Sample Directory Listing For
+        <xsl:value-of select="@directory"/>
+      </title>
+      <style>
+        h1 {color : white;background-color : #0086b2;}
+        h3 {color : white;background-color : #0086b2;}
+        body {font-family : sans-serif,Arial,Tahoma;
+             color : black;background-color : white;}
+        b {color : white;background-color : #0086b2;}
+        a {color : black;} HR{color : #0086b2;}
+        table td { padding: 5px; }
+      </style>
+    </head>
+    <body>
+      <h1>Sample Directory Listing For
+            <xsl:value-of select="@directory"/>
+      </h1>
+      <hr style="height: 1px;" />
+      <table style="width: 100%;">
+        <tr>
+          <th style="text-align: left;">Filename</th>
+          <th style="text-align: center;">Size</th>
+          <th style="text-align: right;">Last Modified</th>
+        </tr>
+        <xsl:apply-templates select="entries"/>
+        </table>
+      <xsl:apply-templates select="readme"/>
+      <hr style="height: 1px;" />
+      <h3>Apache Tomcat/7.0</h3>
+    </body>
+   </html>
+  </xsl:template>
+
+
+  <xsl:template match="entries">
+    <xsl:apply-templates select="entry"/>
+  </xsl:template>
+
+  <xsl:template match="readme">
+    <hr style="height: 1px;" />
+    <pre><xsl:apply-templates/></pre>
+  </xsl:template>
+
+  <xsl:template match="entry">
+    <tr>
+      <td style="text-align: left;">
+        <xsl:variable name="urlPath" select="@urlPath"/>
+        <a href="{$urlPath}">
+          <pre><xsl:apply-templates/></pre>
+        </a>
+      </td>
+      <td style="text-align: right;">
+        <pre><xsl:value-of select="@size"/></pre>
+      </td>
+      <td style="text-align: right;">
+        <pre><xsl:value-of select="@date"/></pre>
+      </td>
+    </tr>
+  </xsl:template>
+
+</xsl:stylesheet>
+ +
How do I secure directory listings?
+Use web.xml in each individual webapp. See the security section of the +Servlet specification. + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/deployer-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/deployer-howto.html new file mode 100644 index 0000000..61063bc --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/deployer-howto.html @@ -0,0 +1,388 @@ +Apache Tomcat 7 (7.0.108) - Tomcat Web Application Deployment

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Tomcat Web Application Deployment

Table of Contents
+ +
Introduction
+

+ Deployment is the term used for the process of installing a web + application (either a 3rd party WAR or your own custom web application) + into the Tomcat server. +

+

+ Web application deployment may be accomplished in a number of ways + within the Tomcat server. +

+
    +
  • Statically; the web application is setup before Tomcat is started
  • +
  • + Dynamically; by directly manipulating already deployed web + applications (relying on auto-deployment + feature) or remotely by using the Tomcat Manager web + application +
  • +
+

+ The Tomcat Manager is a web + application that can be used interactively (via HTML GUI) or + programmatically (via URL-based API) to deploy and manage web + applications. +

+

+ There are a number of ways to perform deployment that rely on + the Manager web application. Apache Tomcat provides tasks + for Apache Ant build tool. + Apache Tomcat Maven Plugin + project provides integration with Apache Maven. + There is also a tool called the Client Deployer, which can be + used from a command line and provides additional functionality + such as compiling and validating web applications as well as + packaging web application into web application resource (WAR) + files. +

+
Installation
+

+ There is no installation required for static deployment of web + applications as this is provided out of the box by Tomcat. Nor is any + installation required for deployment functions with the Tomcat Manager, + although some configuration is required as detailed in the + Tomcat Manager manual. + An installation is however required if you wish + to use the Tomcat Client Deployer (TCD). +

+

+ The TCD is not packaged with the Tomcat core + distribution, and must therefore be downloaded separately from + the Downloads area. The download is usually labelled + apache-tomcat-7.0.x-deployer. +

+

+ TCD has prerequisites of Apache Ant 1.6.2+ and a Java installation. + Your environment should define an ANT_HOME environment value pointing to + the root of your Ant installation, and a JAVA_HOME value pointing to + your Java installation. Additionally, you should ensure Ant's ant + command, and the Java javac compiler command run from the command shell + that your operating system provides. +

+
    +
  1. Download the TCD distribution
  2. +
  3. + The TCD package need not be extracted into any existing Tomcat + installation, it can be extracted to any location. +
  4. +
  5. Read Using the + Tomcat Client Deployer
  6. +
+
A word on Contexts
+

+ In talking about deployment of web applications, the concept of a + Context is required to be understood. A Context is what Tomcat + calls a web application. +

+

+ In order to configure a Context within Tomcat a Context Descriptor + is required. A Context Descriptor is simply an XML file that contains + Tomcat related configuration for a Context, e.g naming resources or + session manager configuration. In earlier versions of + Tomcat the content of a Context Descriptor configuration was often stored within + Tomcat's primary configuration file server.xml but this is now + discouraged (although it currently still works). +

+

+ Context Descriptors not only help Tomcat to know how to configure + Contexts but other tools such as the Tomcat Manager and TCD often use + these Context Descriptors to perform their roles properly. +

+

+ The locations for Context Descriptors are: +

+
    +
  1. $CATALINA_BASE/conf/[enginename]/[hostname]/[webappname].xml
  2. +
  3. $CATALINA_BASE/webapps/[webappname]/META-INF/context.xml
  4. +
+

+ Files in (1) are named [webappname].xml but files in (2) are named + context.xml. If a Context Descriptor is not provided for a Context, + Tomcat configures the Context using default values. +

+
Deployment on Tomcat startup
+

+ If you are not interested in using the Tomcat Manager, or TCD, + then you'll need to deploy your web applications + statically to Tomcat, followed by a Tomcat startup. The location you + deploy web applications to for this type of deployment is called the + appBase which is specified per Host. You either copy a + so-called exploded web application, i.e non-compressed, to this + location, or a compressed web application resource .WAR file. +

+

+ The web applications present in the location specified by the Host's + (default Host is "localhost") appBase attribute (default + appBase is "$CATALINA_BASE/webapps") will be deployed on Tomcat startup + only if the Host's deployOnStartup attribute is "true". +

+

+ The following deployment sequence will occur on Tomcat startup in that + case: +

+
    +
  1. Any Context Descriptors will be deployed first.
  2. +
  3. + Exploded web applications not referenced by any Context + Descriptor will then be deployed. Note that if an exploded web + application has an associated .WAR file in the appBase, Tomcat + will not detect if the associated .WAR has been updated while + Tomcat was stopped and will deploy the exploded web application + as is. The exploded web application will not be removed and + replaced with the contents of the updated .WAR file. +
  4. +
  5. .WAR files will be deployed
  6. +
+
Deploying on a running Tomcat server
+

+ It is possible to deploy web applications to a running Tomcat server. +

+

+ If the Host autoDeploy attribute is "true", the Host will + attempt to deploy and update web applications dynamically, as needed, + for example if a new .WAR is dropped into the appBase. + For this to work, the Host needs to have background processing + enabled which is the default configuration. +

+ +

+ autoDeploy set to "true" and a running Tomcat allows for: +

+
    +
  • Deployment of .WAR files copied into the Host appBase.
  • +
  • + Deployment of exploded web applications which are + copied into the Host appBase. +
  • +
  • + Re-deployment of a web application which has already been deployed from + a .WAR when the new .WAR is provided. In this case the exploded + web application is removed, and the .WAR is expanded again. + Note that the explosion will not occur if the Host is configured + so that .WARs are not exploded with a unpackWARs + attribute set to "false", in which case the web application + will be simply redeployed as a compressed archive. +
  • +
  • + Re-loading of a web application if the /WEB-INF/web.xml file (or + any other resource defined as a WatchedResource) is updated. +
  • +
  • + Re-deployment of a web application if the Context Descriptor + file from which the web application has been deployed is + updated. +
  • +
  • + Re-deployment of dependent web applications if the global or + per-host Context Descriptor file used by the web application is + updated. +
  • +
  • + Re-deployment of a web application if a Context Descriptor file (with a + filename corresponding to the Context path of the previously deployed + web application) is added to the + $CATALINA_BASE/conf/[enginename]/[hostname]/ + directory. +
  • +
  • + Undeployment of a web application if its document base (docBase) + is deleted. Note that on Windows, this assumes that anti-locking + features (see Context configuration) are enabled, otherwise it is not + possible to delete the resources of a running web application. +
  • +
+

+ Note that web application reloading can also be configured in the loader, in which + case loaded classes will be tracked for changes. +

+
Deploying using the Tomcat Manager
+

+ The Tomcat Manager is covered in its own manual page. +

+
Deploying using the Client Deployer Package
+

+ Finally, deployment of web application may be achieved using the + Tomcat Client Deployer. This is a package which can be used to + validate, compile, compress to .WAR, and deploy web applications to + production or development Tomcat servers. It should be noted that this feature + uses the Tomcat Manager and as such the target Tomcat server should be + running. +

+ +

+ It is assumed the user will be familiar with Apache Ant for using the TCD. + Apache Ant is a scripted build tool. The TCD comes pre-packaged with a + build script to use. Only a modest understanding of Apache Ant is + required (installation as listed earlier in this page, and familiarity + with using the operating system command shell and configuring + environment variables). +

+ +

+ The TCD includes Ant tasks, the Jasper page compiler for JSP compilation + before deployment, as well as a task which + validates the web application Context Descriptor. The validator task (class + org.apache.catalina.ant.ValidatorTask) allows only one parameter: + the base path of an exploded web application. +

+ +

+ The TCD uses an exploded web application as input (see the list of the + properties used below). A web application that is programmatically + deployed with the deployer may include a Context Descriptor in + /META-INF/context.xml. +

+ +

+ The TCD includes a ready-to-use Ant script, with the following targets: +

+
    +
  • + compile (default): Compile and validate the web + application. This can be used standalone, and does not need a running + Tomcat server. The compiled application will only run on the associated + Tomcat X.Y.Z server release, and is not guaranteed to work + on another Tomcat release, as the code generated by Jasper depends on its runtime + component. It should also be noted that this target will also compile + automatically any Java source file located in the + /WEB-INF/classes folder of the web application.
  • +
  • + deploy: Deploy a web application (compiled or not) to + a Tomcat server. +
  • +
  • undeploy: Undeploy a web application
  • +
  • start: Start web application
  • +
  • reload: Reload web application
  • +
  • stop: Stop web application
  • +
+ +

+ In order for the deployment to be configured, create a file + called deployer.properties in the TCD installation + directory root. In this file, add the following name=value pairs per + line: +

+ +

+ Additionally, you will need to ensure that a user has been + setup for the target Tomcat Manager (which TCD uses) otherwise the TCD + will not authenticate with the Tomcat Manager and the deployment will + fail. To do this, see the Tomcat Manager page. +

+ +
    +
  • + build: The build folder used will be, by default, + ${build}/webapp/${path} (${build}, by + default, points to ${basedir}/build). After the end + of the execution of the compile target, the web + application .WAR will be located at + ${build}/webapp/${path}.war. +
  • +
  • + webapp: The directory containing the exploded web application + which will be compiled and validated. By default, the folder is + myapp. +
  • +
  • + path: Deployed context path of the web application, + by default /myapp. +
  • +
  • + url: Absolute URL to the Tomcat Manager web application of a + running Tomcat server, which will be used to deploy and undeploy the + web application. By default, the deployer will attempt to access + a Tomcat instance running on localhost, at + http://localhost:8080/manager/text. +
  • +
  • + username: Tomcat Manager username (user should have a role of + manager-script) +
  • +
  • password: Tomcat Manager password.
  • +
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/developers.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/developers.html new file mode 100644 index 0000000..73d5b67 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/developers.html @@ -0,0 +1,124 @@ +Apache Tomcat 7 (7.0.108) - Tomcat Developers

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Tomcat Developers

Active Developers
+ +

+ The list indicates the developers' main areas of interest. Feel free to + add to the list :) The developers email addresses are + [login]@apache.org. Please do not contact + developers directly for any support issues (please post to the + tomcat-users mailing list instead, or one of the other support + resources; some organizations and individual consultants also offer + for pay Tomcat support, as listed on the + support and + training page on the Tomcat Wiki). +

+ +
    +
  • Bill Barker (billbarker): Connectors
  • +
  • Costin Manolache (costin): Catalina, Connectors
  • +
  • Filip Hanik (fhanik): Clustering, Release Manager
  • +
  • Jean-Frederic Clere (jfclere): Connectors
  • +
  • Jim Jagielski (jim): Connectors
  • +
  • Konstantin Kolinko (kkolinko): Catalina
  • +
  • Mark Thomas (markt): CGI, SSI, WebDAV, bug fixing
  • +
  • Mladen Turk (mturk): Connectors
  • +
  • Peter Rossbach (pero): Catalina, Clustering, JMX
  • +
  • Rainer Jung (rjung): Catalina, Clustering, Connectors
  • +
  • Remy Maucherat (remm): Catalina, Connectors, Docs
  • +
  • Tim Funk (funkman): Catalina, Docs
  • +
  • Tim Whittington (timw): Connectors
  • +
+ +
Retired Developers
+ +
    +
  • Amy Roh (amyroh): Catalina
  • +
  • Glenn Nielsen (glenn): Catalina, Connectors
  • +
  • Henri Gomez (hgomez): Connectors
  • +
  • Jan Luehe (luehe): Jasper
  • +
  • Jean-Francois Arcand (jfarcand): Catalina
  • +
  • Kin-Man Chung (kinman): Jasper
  • +
  • Yoav Shapira (yoavs): Docs, JMX, Catalina, balancer
  • +
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/elapi/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/elapi/index.html new file mode 100644 index 0000000..0592562 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/elapi/index.html @@ -0,0 +1,34 @@ + + + + + + API docs + + + + +The EL Javadoc is not installed by default. Download and install +the "fulldocs" package to get it. + +You can also access the javadoc online in the Tomcat + +documentation bundle. + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/extras.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/extras.html new file mode 100644 index 0000000..f15b041 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/extras.html @@ -0,0 +1,163 @@ +Apache Tomcat 7 (7.0.108) - Additional Components

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Additional Components

Table of Contents
+ +
Introduction
+

+ A number of additional components may be used with Apache Tomcat. These + components may be built by users should they need them or they can be + downloaded from one of the mirrors. +

+ +
Downloading
+

+ To download the extras components open the + Tomcat download page + and select "Browse" from the Quick Navigation Links. The extras components + can be found in bin/extras. +

+
Building
+ +

+ The additional components are built using the extras target + of the standard Tomcat Ant script which is present in the source bundle of + Tomcat. +

+ +

The build process is the following:

+ +
    +
  • Follow the build instructions to build a + Tomcat binary from the source bundle (note: it will be used by the build + process of the additional components, but does not need to be actually + used later on)
  • +
  • Execute the command ant extras to run the build + script
  • +
  • The additional components JARs will be placed in the + output/extras folder
  • +
  • Refer to the documentation below about the usage of these JARs
  • +
+ +
Components list
+ +
Full commons-logging implementation
+ +

+ Tomcat uses a package renamed commons-logging API implementation which is + hardcoded to use the java.util.logging API. The commons-logging additional + component builds a full fledged package renamed commons-logging + implementation which can be used to replace the implementation provided with + Tomcat. See the logging page for usage + instructions. +

+ +
+ +
Web Services support (JSR 109)
+ +

+ Tomcat provides factories for JSR 109 which may be used to resolve web + services references. Place the generated catalina-ws.jar as well as + jaxrpc.jar and wsdl4j.jar (or another implementation of JSR 109) in the + Tomcat lib folder. +

+ +

+ Users should be aware that wsdl4j.jar is licensed under CPL 1.0 and not the + Apache License version 2.0. +

+ +
+ +
JMX Remote Lifecycle Listener
+ +

+ The JMX protocol requires the JMX server (Tomcat in this instance) to listen + on two network ports. One of these ports can be fixed via configuration but + the second is selected randomly. This makes it difficult to use JMX through + a firewall. The JMX Remote Lifecycle Listener allows both ports to be fixed, + simplifying the process of connecting to JMX through a firewall. See the listeners page for usage instructions. +

+ +
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/host-manager-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/host-manager-howto.html new file mode 100644 index 0000000..77c1bcb --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/host-manager-howto.html @@ -0,0 +1,266 @@ +Apache Tomcat 7 (7.0.108) - Host Manager App -- Text Interface

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Host Manager App -- Text Interface

Table of Contents
+ +
Introduction
+

+ The Tomcat Host Manager application enables you to create, + delete, and otherwise manage virtual hosts within Tomcat. This how-to guide + is best accompanied by the following pieces of documentation: +

+
    +
  • + Virtual Hosting How-To for more + information about virtual hosting. +
  • +
  • + The Host Container for more information + about the underlying xml configuration of virtual hosts and description + of attributes. +
  • +
+ +

+ The Tomcat Host Manager application is a part of + Tomcat installation, by default available using the following + context: /host-manager. You can use the host manager in the + following ways: +

+ +
    +
  • + Utilizing the graphical user interface, accessible at: + {server}:{port}/host-manager/html. +
  • +
  • + Utilizing a set of minimal HTTP requests suitable for scripting. + You can access this mode at: + {server}:{port}/host-manager/text. +
  • +
+

+ Both ways enable you to add, remove, start, and stop virtual hosts. Changes + are not persisted to the Tomcat configuraiton files. If you want your + settings to be persistent, you must write them into the server.xml + configuration file manually. For full documentation about the configuration, + see The Host Container. This document focuses + on the text interface. For further information about the graphical + interface, see + Host Manager App -- HTML Interface. +

+
Configuring Manager Application Access
+

The description below uses $CATALINA_HOME to refer the + base Tomcat directory. It is the directory in which you installed + Tomcat, for example C:\tomcat7, or + /usr/share/tomcat7.

+ +

+ The Host Manager application requires a user with one of the following + roles: +

+ +
    +
  • + admin-gui - use this role for the graphical web interface. +
  • +
  • + admin-script - use this role for the scripting web interface. +
  • +
+ +

+ To enable access to the text interface of the Host Manager application, + either grant your Tomcat user the appropriate role, or create a new one with + the correct role. For example, open + ${CATALINA_BASE}/conf/tomcat-users.xml and enter the following: +

+
<user username="test" password="chang3m3N#w" roles="admin-script"/>
+

+ No further settings is needed. When you now access + {server}:{port}/host-manager/text/${COMMAND},you are able to + log in with the created credentials. For example: +

$ curl -u ${USERNAME}:${PASSWORD} http://localhost:8080/host-manager/text/list
+OK - Listed hosts
+localhost:
+

+

+ If you are using a different realm you will need to add the necessary role + to the appropriate user(s) using the standard user management tools for that + realm. +

+
List of Commands
+

The following commands are supported:

+
    +
  • list
  • +
  • add
  • +
  • remove
  • +
  • start
  • +
  • stop
  • +
+

+ In the following subsections, the username and password is assumed to be + test:test. For your environment, use credentials created in the + previous sections. +

+
List command
+

+ Use the list command to see the available virtual hosts on your + Tomcat instance. +

+

Example command:

+ curl -u test:test http://localhost:8080/host-manager/text/list +

Example response:

+
OK - Listed hosts
+localhost:
+
+
Add command
+

+ Use the add command to add a new virtual host. Parameters used + for the add command: +

+
    +
  • String name: Name of the virtual host. REQUIRED
  • +
  • String aliases: Aliases for your virtual host.
  • +
  • String appBase: Base path for the application that will be + served by this virtual host. Provide relative or absolute path.
  • +
  • Boolean manager: If true, the Manager app is added to the + virtual host. You can access it with the /manager context.
  • +
  • Boolean autoDeploy: If true, Tomcat automatically redeploys + applications placed in the appBase directory.
  • +
  • Boolean deployOnStartup: If true, Tomcat automatically deploys + applications placed in the appBase directory on startup.
  • +
  • Boolean deployXML: If true, the /META-INF/context.xml + file is read and used by Tomcat.
  • +
  • Boolean copyXML: If true, Tomcat copies /META-INF/context.xml + file and uses the original copy regardless of updates to the application's + /META-INF/context.xml file. Available only for + Tomcat 8 and newer.
  • +
+

Example command:

+
curl -u test:test http://localhost:8080/host-manager/text/add?name=www.awesomeserver.com&aliases=awesomeserver.com&appBase/mnt/appDir&deployOnStartup=true
+

Example response:

+
add: Adding host [www.awesomeserver.com]
+
+
Remove command
+

+ Use the remove command to remove a virtual host. Parameters used + for the remove command: +

+
    +
  • String name: Name of the virtual host to be removed. + REQUIRED
  • +
+

Example command:

+
curl -u test:test http://localhost:8080/host-manager/text/remove?name=www.awesomeserver.com
+

Example response:

+
remove: Removing host [www.awesomeserver.com]
+
+
Start command
+

+ Use the start command to start a virtual host. Parameters used + for the start command: +

+
    +
  • String name: Name of the virtual host to be started. + REQUIRED
  • +
+

Example command:

+
curl -u test:test http://localhost:8080/host-manager/text/start?name=www.awesomeserver.com
+

Example response:

+
OK - Host www.awesomeserver.com started
+
+
Stop command
+

+ Use the stop command to stop a virtual host. Parameters used + for the stop command: +

+
    +
  • String name: Name of the virtual host to be stopped. + REQUIRED
  • +
+

Example command:

+
curl -u test:test http://localhost:8080/host-manager/text/stop?name=www.awesomeserver.com
+

Example response:

+
OK - Host www.awesomeserver.com stopped
+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/html-host-manager-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/html-host-manager-howto.html new file mode 100644 index 0000000..637e616 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/html-host-manager-howto.html @@ -0,0 +1,235 @@ +Apache Tomcat 7 (7.0.108) - Host Manager App -- HTML Interface

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Host Manager App -- HTML Interface

Table of Contents
+ +
Introduction
+

+ The Tomcat Host Manager application enables you to create, + delete, and otherwise manage virtual hosts within Tomcat. This how-to guide + is best accompanied by the following pieces of documentation: +

+ + +

+ The Tomcat Host Manager application is a part of + Tomcat installation, by default available using the following + context: /host-manager. You can use the host manager in the + following ways: +

+ +
    +
  • + Utilizing the graphical user interface, accessible at: + {server}:{port}/host-manager/html. +
  • +
  • + Utilizing a set of minimal HTTP requests suitable for scripting. + You can access this mode at: + {server}:{port}/host-manager/text. +
  • +
+

+ Both ways enable you to add, remove, start, and stop virtual hosts. + Changes are not persisted to the Tomcat configuraiton files. If you want + your settings to be persistent, you must write them into the + server.xml configuration file manually. For full documentation + about the configuration, see The Host + Container. This document focuses on the HTML interface. For further + information about the graphical interface, see + Host Manager App -- Text Interface. +

+
Configuring Manager Application Access
+

The description below uses $CATALINA_HOME to refer the + base Tomcat directory. It is the directory in which you installed + Tomcat, for example C:\tomcat8, or + /usr/share/tomcat8.

+ +

+ The Host Manager application requires a user with one of the following + roles: +

+ +
    +
  • + admin-gui - use this role for the graphical web interface. +
  • +
  • + admin-script - use this role for the scripting web interface. +
  • +
+ +

+ To enable access to the HTML interface of the Host Manager application, + either grant your Tomcat user the appropriate role, or create a new one with + the correct role. For example, open + ${CATALINA_BASE}/conf/tomcat-users.xml and enter the following: +

+
<user username="test" password="chang3m3N#w" roles="admin-gui"/>
+

+ No further settings is needed. When you now access + {server}:{port}/host-manager/html,you are able to + log in with the created credentials. +

+

+ If you are using a different realm you will need to add the necessary role + to the appropriate user(s) using the standard user management tools for + that realm. +

+
Interface Description
+

The interface is divided into six sections:

+
    +
  • Message - Displays success and failure messages.
  • +
  • Host Manager - Provides basic Host Manager operations + , like list and help.
  • +
  • Host name - Provides a list of virtual Host Names and + enables you to operate them.
  • +
  • Add Virtual Host - Enables you to add a new Virtual + Host.
  • +
  • Server Information - Information about the Tomcat + server.
  • +
+
Message
+ +

+ Displays information about the success or failure of the last Host Manager + command you performed: +

+
    +
  • Success: OK is displayed + and may be followed by a success message.
  • +
  • Failure: FAIL + is displayed followed by an error message.
  • +
+

+ Note that the console of your Tomcat server may reveal more information + about each command. +

+
Host Manager
+ +

The Host Manager section enables you to:

+
    +
  • List Virtual Hosts - Refresh a list of + currently-configured virtual hosts.
  • +
  • HTML Host Manager Help - A documentation link.
  • +
  • Host Manager Help - A documentation link.
  • +
  • Server Status - A link to the Manager + application. Note that you user must have sufficient permissions to access + the application.
  • +
+
Host Name
+ +

The Host name section contains a list of currently-configured virtual host + names. It enables you to:

+
    +
  • View the host names
  • +
  • View the host name aliases
  • +
  • Perform basic commands, that is start, + stop, and remove.
  • +
+
Add Virtual Host
+ +

The Add Virtual Host section enables you to add a virtual host using a + graphical interface. For a description of each property, see the + Host Manager App -- Text Interface + documentation. Note that any configuration added via this interface is + non-persistent.

+
Server Information
+

+ Provides a basic information about the currently-running Tomcat instance, + the JVM, and the underlying operating system. +

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/html-manager-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/html-manager-howto.html new file mode 100644 index 0000000..2653646 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/html-manager-howto.html @@ -0,0 +1,572 @@ +Apache Tomcat 7 (7.0.108) - Tomcat Web Application Manager How To

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Tomcat Web Application Manager How To

Table of Contents
+ +
Introduction
+ +

In many production environments it is very useful to have the capability +to manage your web applications without having to shut down and restart +Tomcat. This document is for the HTML web interface to the web application +manager.

+ +

The interface is divided into six sections:

+
    +
  • Message - Displays success and failure messages.
  • +
  • Manager - General manager operations like list and + help.
  • +
  • Applications - List of web applications and + commands.
  • +
  • Deploy - Deploying web applications.
  • +
  • Diagnostics - Identifying potential problems.
  • +
  • Server Information - Information about the Tomcat + server.
  • +
+ +
Message
+ +

+Displays information about the success or failure of the last web application +manager command you performed. If it succeeded OK is displayed +and may be followed by a success message. If it failed FAIL +is displayed followed by an error message. Common failure messages are +documented below for each command. The complete list of failure messages for +each command can be found in the manager web +application documentation. +

+ +
Manager
+ +

The Manager section has three links:

+
    +
  • List Applications - Redisplay a list of web + applications.
  • +
  • HTML Manager Help - A link to this document.
  • +
  • Manager Help - A link to the comprehensive Manager + App HOW TO.
  • +
+ +
Applications
+ +

The Applications section lists information about all the installed web +applications and provides links for managing them. For each web application +the following is displayed:

+
    +
  • Path - The web application context path.
  • +
  • Display Name - The display name for the web application + if it has one configured in its "web.xml" file.
  • +
  • Running - Whether the web application is running and + available (true), or not running and unavailable (false).
  • +
  • Sessions - The number of active sessions for remote + users of this web application. The number of sessions is a link which + when submitted displays more details about session usage by the web + application in the Message box.
  • +
  • Commands - Lists all commands which can be performed on + the web application. Only those commands which can be performed will be + listed as a link which can be submitted. No commands can be performed on + the manager web application itself. The following commands can be + performed: +
      +
    • Start - Start a web application which had been + stopped.
    • +
    • Stop - Stop a web application which is currently + running and make it unavailable.
    • +
    • Reload - Reload the web application so that new + ".jar" files in /WEB-INF/lib/ or new classes in + /WEB-INF/classes/ can be used.
    • +
    • Undeploy - Stop and then remove this web + application from the server.
    • +
    +
  • +
+ +
Start
+ +

Signal a stopped application to restart, and make itself available again. +Stopping and starting is useful, for example, if the database required by +your application becomes temporarily unavailable. It is usually better to +stop the web application that relies on this database rather than letting +users continuously encounter database exceptions.

+ +

If this command succeeds, you will see a Message like this:

+
OK - Started application at context path /examples
+ +

Otherwise, the Message will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to start the web application. + Check the Tomcat logs for the details.

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character, unless you are + referencing the ROOT web application -- in which case the context path + must be a zero-length string.

    +
  • +
  • No context exists for path /foo +

    There is no deployed application on the context path + that you specified.

    +
  • +
  • No context path was specified +

    + The path parameter is required. +

    +
  • +
+ +
+ +
Stop
+ +

Signal an existing application to make itself unavailable, but leave it +deployed. Any request that comes in while an application is +stopped will see an HTTP error 404, and this application will show as +"stopped" on a list applications command.

+ +

If this command succeeds, you will see a Message like this:

+
OK - Stopped application at context path /examples
+ +

Otherwise, the Message will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to stop the web application. + Check the Tomcat logs for the details.

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character, unless you are + referencing the ROOT web application -- in which case the context path + must be a zero-length string.

    +
  • +
  • No context exists for path /foo +

    There is no deployed application on the context path + that you specified.

    +
  • +
  • No context path was specified +

    + The path parameter is required. +

    +
  • +
+ +
+ +
Reload
+ +

Signal an existing application to shut itself down and reload. This can +be useful when the web application context is not reloadable and you have +updated classes or property files in the /WEB-INF/classes +directory or when you have added or updated jar files in the +/WEB-INF/lib directory. +

+

NOTE: The /WEB-INF/web.xml +web application configuration file is not checked on a reload; +the previous web.xml configuration is used. +If you have made changes to your web.xml file you must stop +then start the web application. +

+ +

If this command succeeds, you will see a Message like this:

+

+OK - Reloaded application at context path /examples
+
+ +

Otherwise, the Message will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to restart the web application. + Check the Tomcat logs for the details.

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character, unless you are + referencing the ROOT web application -- in which case the context path + must be a zero-length string.

    +
  • +
  • No context exists for path /foo +

    There is no deployed application on the context path + that you specified.

    +
  • +
  • No context path was specified +

    The path parameter is required.

    +
  • +
  • Reload not supported on WAR deployed at path /foo +

    Currently, application reloading (to pick up changes to the classes or + web.xml file) is not supported when a web application is + installed directly from a WAR file, which happens when the host is + configured to not unpack WAR files. As it only works when the web + application is installed from an unpacked directory, if you are using + a WAR file, you should undeploy and then deploy + the application again to pick up your changes.

    +
  • +
+ +
+ +
Undeploy
+ +

WARNING - This command will delete the +contents of the web application directory and/or ".war" file if it exists within +the appBase directory (typically "webapps") for this virtual host +. The web application temporary work directory is also deleted. If +you simply want to take an application out of service, you should use the +/stop command instead.

+ +

Signal an existing application to gracefully shut itself down, and then +remove it from Tomcat (which also makes this context path available for +reuse later). This command is the logical opposite of the +/deploy Ant command, and the related deploy features available +in the HTML manager.

+ +

If this command succeeds, you will see a Message like this:

+
OK - Undeployed application at context path /examples
+ +

Otherwise, the Message will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to undeploy the web application. + Check the Tomcat logs for the details.

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character, unless you are + referencing the ROOT web application -- in which case the context path + must be a zero-length string.

    +
  • +
  • No context exists for path /foo +

    There is no deployed application on the context path + that you specified.

    +
  • +
  • No context path was specified + The path parameter is required. +
  • +
+ +
+ +
Deploy
+ +

Web applications can be deployed using files or directories located +on the Tomcat server or you can upload a web application archive (WAR) +file to the server.

+ +

To install an application, fill in the appropriate fields for the type +of install you want to do and then submit it using the Install +button.

+ +
Deploy directory or WAR file located on server
+ +

Deploy and start a new web application, attached to the specified Context +Path: (which must not be in use by any other web application). +This command is the logical opposite of the Undeploy command.

+ +

There are a number of different ways the deploy command can be used.

+ +
Deploy a Directory or WAR by URL
+ +

Install a web application directory or ".war" file located on the Tomcat +server. If no Context Path is specified, the directory name or the +war file name without the ".war" extension is used as the path. The +WAR or Directory URL specifies a URL (including the file: +scheme) for either a directory or a web application archive (WAR) file. The +supported syntax for a URL referring to a WAR file is described on the Javadocs +page for the java.net.JarURLConnection class. Use only URLs that +refer to the entire WAR file.

+ +

In this example the web application located in the directory +C:\path\to\foo on the Tomcat server (running on Windows) +is deployed as the web application context named /footoo.

+
Context Path: /footoo
+WAR or Directory URL: file:C:/path/to/foo
+
+ + +

In this example the ".war" file /path/to/bar.war on the +Tomcat server (running on Unix) is deployed as the web application +context named /bar. Notice that there is no path +parameter so the context path defaults to the name of the web application +archive file without the ".war" extension.

+
WAR or Directory URL: jar:file:/path/to/bar.war!/
+ +
+ +
Deploy a Directory or War from the Host appBase
+ +

Install a web application directory or ".war" file located in your Host +appBase directory. If no Context Path is specified the directory name +or the war file name without the ".war" extension is used as the path.

+ +

In this example the web application located in a subdirectory named +foo in the Host appBase directory of the Tomcat server is +deployed as the web application context named /foo. Notice +that there is no path parameter so the context path defaults +to the name of the web application directory.

+
WAR or Directory URL: foo
+ + +

In this example the ".war" file bar.war located in your +Host appBase directory on the Tomcat server is deployed as the web +application context named /bartoo.

+
Context Path: /bartoo
+WAR or Directory URL: bar.war
+ +
+ +
Deploy using a Context configuration ".xml" file
+ +

If the Host deployXML flag is set to true, you can install a web +application using a Context configuration ".xml" file and an optional +".war" file or web application directory. The Context Path +is not used when installing a web application using a context ".xml" +configuration file.

+ +

A Context configuration ".xml" file can contain valid XML for a +web application Context just as if it were configured in your +Tomcat server.xml configuration file. Here is an +example for Tomcat running on Windows:

+
<Context path="/foobar" docBase="C:\path\to\application\foobar">
+</Context>
+ + +

Use of the WAR or Directory URL is optional. When used +to select a web application ".war" file or directory it overrides any +docBase configured in the context configuration ".xml" file.

+ +

Here is an example of installing an application using a Context +configuration ".xml" file for Tomcat running on Windows.

+
XML Configuration file URL: file:C:/path/to/context.xml
+ + +

Here is an example of installing an application using a Context +configuration ".xml" file and a web application ".war" file located +on the server (Tomcat running on Unix).

+
XML Configuration file URL: file:/path/to/context.xml
+WAR or Directory URL: jar:file:/path/to/bar.war!/
+ +
+
+ +
Upload a WAR file to install
+ +

Upload a WAR file from your local system and install it into the +appBase for your Host. The name of the WAR file without the ".war" +extension is used as the context path name.

+ +

Use the Browse button to select a WAR file to upload to the +server from your local desktop system.

+ +

The .WAR file may include Tomcat specific deployment configuration, by +including a Context configuration XML file in +/META-INF/context.xml.

+ +

Upload of a WAR file could fail for the following reasons:

+
    +
  • File uploaded must be a .war +

    The upload install will only accept files which have the filename + extension of ".war".

    +
  • +
  • War file already exists on server +

    If a war file of the same name already exists in your Host's + appBase the upload will fail. Either undeploy the existing war file + from your Host's appBase or upload the new war file using a different + name.

    +
  • +
  • File upload failed, no file +

    The file upload failed, no file was received by the server.

    +
  • +
  • Install Upload Failed, Exception: +

    The war file upload or install failed with a Java Exception. + The exception message will be listed.

    +
  • +
+ +
+ +
Deployment Notes
+ +

If the Host is configured with unpackWARs=true and you install a war +file, the war will be unpacked into a directory in your Host appBase +directory.

+ +

If the application war or directory is deployed in your Host appBase +directory and either the Host is configured with autoDeploy=true the Context +path must match the directory name or war file name without the ".war" +extension.

+ +

For security when untrusted users can manage web applications, the +Host deployXML flag can be set to false. This prevents untrusted users +from installing web applications using a configuration XML file and +also prevents them from installing application directories or ".war" +files located outside of their Host appBase.

+ +
+ +
Deploy Message
+ +

If deployment and startup is successful, you will receive a Message +like this:

+
OK - Deployed application at context path /foo
+ +

Otherwise, the Message will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Application already exists at path /foo +

    The context paths for all currently running web applications must be + unique. Therefore, you must either undeploy the existing web + application using this context path, or choose a different context path + for the new one.

    +
  • +
  • Document base does not exist or is not a readable directory +

    The URL specified by the WAR or Directory URL: field must + identify a directory on this server that contains the "unpacked" version + of a web application, or the absolute URL of a web application archive + (WAR) file that contains this application. Correct the value entered for + the WAR or Directory URL: field.

    +
  • +
  • Encountered exception +

    An exception was encountered trying to start the new web application. + Check the Tomcat logs for the details, but likely explanations include + problems parsing your /WEB-INF/web.xml file, or missing + classes encountered when initializing application event listeners and + filters.

    +
  • +
  • Invalid application URL was specified +

    The URL for the WAR or Directory URL: field that you specified + was not valid. Such URLs must start with file:, and URLs + for a WAR file must end in ".war".

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character, unless you are + referencing the ROOT web application -- in which case the context path + must be a "/" string.

    +
  • +
  • Context path must match the directory or WAR file name: +

    If the application war or directory is deployed in your Host appBase + directory and either the Host is configured with autoDeploy=true the Context + path must match the directory name or war file name without the ".war" + extension.

    +
  • +
  • Only web applications in the Host web application directory can + be deployed +

    + If the Host deployXML flag is set to false this error will happen + if an attempt is made to install a web application directory or + ".war" file outside of the Host appBase directory. +

  • +
+ +
+
Diagnostics
+ +
Finding memory leaks
+ +

The find leaks diagnostic triggers a full garbage collection. It +should be used with extreme caution on production systems.

+ +

The find leaks diagnostic attempts to identify web applications that have +caused memory leaks when they were stopped, reloaded or undeployed. Results +should always be confirmed +with a profiler. The diagnostic uses additional functionality provided by the +StandardHost implementation. It will not work if a custom host is used that +does not extend StandardHost.

+ +

This diagnostic will list context paths for the web applications that were +stopped, reloaded or undeployed, but which classes from the previous runs +are still present in memory, thus being a memory leak. If an application +has been reloaded several times, it may be listed several times.

+ +

Explicitly triggering a full garbage collection from Java code is documented +to be unreliable. Furthermore, depending on the JVM used, there are options to +disable explicit GC triggering, like -XX:+DisableExplicitGC. +If you want to make sure, that the diagnostics were successfully running a full GC, +you will need to check using tools like GC logging, JConsole or similar.

+ +
+
Server Information
+ +

This section displays information about Tomcat, the operating system of the +server Tomcat is hosted on, the Java Virtual Machine Tomcat is running in, the +primary host name of the server (may not be the host name used to access Tomcat) +and the primary IP address of the server (may not be the IP address used to +access Tomcat).

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/add.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/add.gif new file mode 100644 index 0000000..0774d07 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/add.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/asf-logo.svg b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/asf-logo.svg new file mode 100644 index 0000000..e24cbe5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/asf-logo.svg @@ -0,0 +1,226 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/code.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/code.gif new file mode 100644 index 0000000..d27307b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/code.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/cors-flowchart.png b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/cors-flowchart.png new file mode 100644 index 0000000..9abb09d Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/cors-flowchart.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/design.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/design.gif new file mode 100644 index 0000000..f5db0a9 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/design.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/docs.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/docs.gif new file mode 100644 index 0000000..d64a4a1 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/docs.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/fix.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/fix.gif new file mode 100644 index 0000000..d59ad64 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/fix.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/printer.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/printer.gif new file mode 100644 index 0000000..5021187 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/printer.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.gif new file mode 100644 index 0000000..f2aa6f8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.png b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.png new file mode 100644 index 0000000..209b07f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.svg b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.svg new file mode 100644 index 0000000..8823f79 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/tomcat.svg @@ -0,0 +1,967 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + 2006-05-09T08:17:21Z + 2006-05-09T08:37:38Z + Illustrator + + + + JPEG + 256 + 184 + /9j/4AAQSkZJRgABAgEASABIAAD/7QAsUGhvdG9zaG9wIDMuMAA4QklNA+0AAAAAABAASAAAAAEA +AQBIAAAAAQAB/+4ADkFkb2JlAGTAAAAAAf/bAIQABgQEBAUEBgUFBgkGBQYJCwgGBggLDAoKCwoK +DBAMDAwMDAwQDA4PEA8ODBMTFBQTExwbGxscHx8fHx8fHx8fHwEHBwcNDA0YEBAYGhURFRofHx8f +Hx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8f/8AAEQgAuAEAAwER +AAIRAQMRAf/EAaIAAAAHAQEBAQEAAAAAAAAAAAQFAwIGAQAHCAkKCwEAAgIDAQEBAQEAAAAAAAAA +AQACAwQFBgcICQoLEAACAQMDAgQCBgcDBAIGAnMBAgMRBAAFIRIxQVEGE2EicYEUMpGhBxWxQiPB +UtHhMxZi8CRygvElQzRTkqKyY3PCNUQnk6OzNhdUZHTD0uIIJoMJChgZhJRFRqS0VtNVKBry4/PE +1OT0ZXWFlaW1xdXl9WZ2hpamtsbW5vY3R1dnd4eXp7fH1+f3OEhYaHiImKi4yNjo+Ck5SVlpeYmZ +qbnJ2en5KjpKWmp6ipqqusra6voRAAICAQIDBQUEBQYECAMDbQEAAhEDBCESMUEFURNhIgZxgZEy +obHwFMHR4SNCFVJicvEzJDRDghaSUyWiY7LCB3PSNeJEgxdUkwgJChgZJjZFGidkdFU38qOzwygp +0+PzhJSktMTU5PRldYWVpbXF1eX1RlZmdoaWprbG1ub2R1dnd4eXp7fH1+f3OEhYaHiImKi4yNjo ++DlJWWl5iZmpucnZ6fkqOkpaanqKmqq6ytrq+v/aAAwDAQACEQMRAD8A9U4q7FXYq7FXYq7FXYq7 +FXYq7FXYq7FXYq7FXYq7FXhH/OYHnWfQ/wAurfRLSUxXXmK49GQqaN9VtwJJqH3cxqfYnFXhP5Y/ +85O+f/JU0enaw769okbBJLS8ZvrUKg0IhnarDj/I9R2HHFX2F+Xn5neT/P8ApP6R8u3glKAfW7KS +iXNuzdFljqaezCqnsTirK8VdirsVdirsVdirsVdirC/zM/Nvyd+XemC71255Xcqk2WmQUa5nI2+F +CRxUd3ag+nbFXx1+Zf8Azkn+YvneaW1tLh9C0NgwXTrB2V3Sm/rzji8m3UDitP2cVfV//OOfmabz +D+T3l+6uHMl1aRPYTsxqSbVzEhJ7kxKhxV6VirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVd +irsVfHn/ADlxdSa7+bvlvyvGx4RW0EVARtNfXJVqf7BY+uRlKgT3JAt5r/zkD5ZGgfmfqSRR+nZ6 +gsd9agdOMq0f/ksj5h9nZvEwgnmNi2Z4cMiw/wAqebPMHlTXLfW9BvHstQtjVZEPwstQWjkXo6NT +4lOxzOan3v8Akl+cel/mX5a+tAJa69ZcU1fTlJojGvGWLluYpKbV6GqmtKlV6NirsVdirsVdirsV +eWfnr+eGl/lroywwBLzzPfox02wJqqL0+sT03EanoOrnYdyFXwh5i8x655j1i41jW7yS+1K6blNc +SmpPgABQKo6BVFB2xVnf5Q+SjrWh+d9Yli5w6XolylsadbqSNnTj8kiYf7IZg6zUeHKERzlIfL8U +3YoWCe4Pff8AnCfVTN5D1zTCamz1P11HcLcQIAPlWE5nNL6KxV2KuxV2KuxV2KuxV2KuxV2KuxV2 +KuxV2KuxV2KuxV2KvjD8wm/Sv/OX8UTGsdrqGnCMNUU+rW0Mp6f5ammY2sNYZ/1T9zZi+oe9m/8A +zkx+Xc/mPytFrunRepqehc3ljUVeS0cAyAU6mMqHA8OXfNB2PqhCfAeUvv8A2uZqcdix0fIedQ69 +m35OefrryN+YOla2kpjsjKttqqDo9nMwEoI78ftr/lKMVfaeqf8AOSH5KaaSs3meCZx0W1inuanf +YNDG69vHFWM3v/OYn5QW5YQ/pK8ArQwWqitPD1pIuvviqVT/APObH5cKR6GjaxIP2i8dqhB9qTvi +qmP+c2fIFd9C1Wnfa2/6q4qmFv8A85n/AJUSvxksdZtx/NJb25H/ACTuHOKp3bf85XfkpPBI7avN +BIisywS2lwGcqCeIZUdKmm1WGKvijzz5x1bzl5q1HzFqjlrm+lLrHWqxRDaOFP8AJjSij7+uKpNb +W1xdXMVtbRtNcTuscMKAszu54qqgbkkmgwE1uVfbHkL8uk8o/lTPoMiK+o3drPNqZHRrieIhlr4I +tEB9q5yWo1fi6gS/hBFfN2UMfDAjqwT/AJwdvyt/5usC20sVlOq77em0yMR2/wB2Cudc619ZYq7F +XYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXxZKTJ/zmFc+oedNTmA5b/ZtG49fCgpmH2h/ +cS9zbh+sPqDrsc4t2r57/Nf/AJxkGo3c+teSTFb3ExMlxo0hEcTMdybd/spU/sN8PgQNs3+i7Xoc +OX5/rcLLpusWIaF/zif56vFWTVr6y0pG6xgtczL81QLH90mZWTtnFH6bk1x0sjz2Z1pf/OIvlOIL ++lNbvrthSv1dYrZSe+zC4ND88wp9uTP0xA9+/wCptGkHUsms/wDnGf8AKS3AEunT3dOpmupxXam/ +pNFmPPtjOeRA+H67bBpoPDv+ch/yt03yXrdjeaFbG30HUouCQ8pJBFcQ0DqXkZ2+NSrCrfzeGbns +vWHNAiX1BxdRi4TtySH8jfJdn5u/MOy07UIfrGl28ct3fw1IDRxrxUEqQaGV0By7X6g4sRkOfRhh +hxSp9N3X/OO/5P3FSdBETGnxRXN0nT/JEvH8M50dq6gfxfYHOOnh3JDqP/OKn5a3NTazajYt+yIp +0dfpEsbn/hsvj21lHMRP497A6SPmwzW/+cQr9A76H5himO/CG9haL5AyxGT/AIhmXj7cifqiR7t/ +1NUtIehZh+S3/OP8Xk+5GveYXivNfTkLSKIloLYGqlwzBecjL3p8P45i9odqeIOCH09fNtw6fh3P +N7DfIz2VwijkzRuFA6klTmpxmpD3uRLk+bf+cJrrj+Yet2tT+90hpeP7J9O5hWp9/wB5tneunfZm +KuxV2KuxV2KuxV2KuxVZLNFDG0srrHGu7O5CqB7k4qks3nzyNC5jm8xaZHIOqPeW6nf2L4qmFhrW +j6iK6ff294KVrbypLt1r8BPjirAvzb/Pnyf+WrW9rqKS6hq90vqRaba8eaxVp6krMQEUkEL1JPbq +cVYFof8Azmp5BupVj1fR9Q0wNsZo/SuY1/1qGN6fJDir2Xyf+Yfkrzjam48taxb6iqgGSKNisyA9 +PUhcLKn+yXFWRYq7FXYq7FXxRrBNj/zl/NVwC+rL8XtcWw+Hf/jJTMXXC8M/6pbMP1h9SZxLtnYq +7FWG+afzg/LnyvdNZ6vrUSXqGj2sKvcSofB1hV+B/wBamZmHs/NkFxjt8mqWaMeZRPk78zvI/nF5 +ItA1RLm5hHKS1dXhmC1pyEcoRmXputRkdRosuLeQ2TDLGXJCfm/5JXzj5D1HSo05X8a/WtNPcXMI +JUD/AFxVP9lk+z9R4WUE8jsWOaHFGnl3/OI/lpodN1zzFMlGuJUsLcsKELCPUlpXsWkQfNc2Xbmb +eMPj+r9LRpI8y+hc0DmuxV2KuxV2Kvl//nClHP5oas4B4Lok6luwLXdqQPpoc9AdK+08VdirsVdi +rsVdiqXeYPMOi+XtIudY1q7jsdNtF5z3EpooHQAd2ZjsqjcnYYq+VfPf/OV3nXzNqp0D8stPlto5 +mMcF0IfrGoT+8UIDrGD8mbvVcVSqz/5xn/Pjzs66h5t1RbUueX+5W7kurgA/yxx+sq/6pZaeGKsj +h/5wanMYM3nNUk7qmml1/wCCN0n6sVQt7/zhDr8B56Z5stppEIMZntZLfcb1qkk9KHFXzr5mtdUs +tfv9O1S5a7vtOuJbKaZndwWt3MZ4mSjcartUDFUsxVFabqeo6XfQ3+m3UtlfW7c4Lq3dopUbxV1I +IxV9Sfkr/wA5aNcT2+gfmG6K8hWO18wqAi1OwF2q0Vf+Mi0H8w6tir6lVlZQykMrCqsNwQe4xVvF +XYq+Kfzzro3/ADlLa6oxKJLdaReFiaApGsMLeG1ISMqzw4sco94LKBogvqPOEdw7FXkf55/mBrlj +Jp3kbykX/wAVeYSFE0Zo8FuzFOSt+wzlW+P9lQx2NDm27N0sZXlyfRFxs+Qj0jmUd5B/IHyP5bsI +31Oyh1zWnAa6vb1BMnqHciKKSqKAehI5e+Q1XamTIfSeGPlzTj08YjfcsJ/PDy5pXkHX/LH5geW7 +WPTGhvlt9Rt7RBFHKpBk+wgCjnGkiPQbg5m9m5jnhLFM3s1Z4iBEg+hOu4zn3NQOkaLpuj20ltp8 +IghlnnunRe8tzK0sh/4JzQdhtlmXLKZuXdXyYxiByR2VsnYqxjV/zO/L3SJWh1DzDYQzoaPD66PI +p/ykQsw+kZlY9Dmnyifu+9qOWI6pvoOvaRr+kwato9yt3p1zz9C4UMob03MbbMFOzoR0ynLiljkY +yFEM4yBFhV1WVYdLvJWJCxwSOxHWioTjhFzA8wsuRfPn/OEVoX83eZLzekOnxQnpSsswb/mVneOn +fYOKuxV2KuxV2KqF9e2lhZT315KsFpaxtNcTuaKkcYLMzHwAFcVfFHnPzR50/wCchPzJi8veXlaH +y7aO5sYnqsUUCkK97dU/bYdB2qFXcklV9U/lj+UnlH8u9IWz0a2WS+dQL7VpVBuLhh1q37KV+yg2 +Huakqs1xV2KuxV8v/nf/AM4patrnmG+80eSp4Xn1GR7m/wBIuW9ImdyWd4JSOH7xjUq9KGvxb0Cr +5/1j8mPzX0iRkvfKepgL9qSC3e5jG9P7yASJ1PjiqRjyb5vMvpDQ9QMtePpi1m5culKca1xVPtG/ +JT82dYdUsvKepUf7MlxA1rGe395cekn44q+zf+cffKv5m+VvJ50bzvPbzRwFf0RFHK01xbxU+KCV +6cCqmnDizU3FaUAVeo4q7FXx5/zmxpD2vnTy7rcdUN5YPbh12POzmL1qO4FyuKsl/Lz/AJyc8ra2 +sNj5mUaHqZAU3TGtnI3Qnn1ir1o/wj+bOY1XY8474/UO7r+1z8epB2Oz2iKWKaJJYnWSKQBkkQhl +ZTuCCNiDmnIINFygVGXTNOmvYb6W1hkvbbkLe6eNWljDgq3ByOS1UkGhwjJIDhs0ei0LtE5FLxD/ +AJyycP5F0ezQcp59WjaNdt+NvMp/GQZuuxI/vJH+j+lxNWfSPe9rgiEMEcQNRGoQE9+IpmmlKyS5 +QCpgSsllihieWVxHFGpeR2NFVVFSST0AGEAk0EEvn2fVfOv5269e6foN9Jof5e6fIYbm9QMst2af +ZIBUtyG4QkKqkFqmgzfiGLRQBkOLKfx+C4ZMspobRZzof/OOv5U6VCiyaUdSnUUa4vZZJGb5opSL +7kzBydrZ5HY8PuDbHTQDP9G0XStE02HTNJtks9Pt+Xo20Qoi83LtQe7MTmBkyynLikbJboxAFBJv +zO1Aaf8Al35lu60ZNNuljP8AlvEyJ/wzDL9FDizQH9IfYxymol59/wA4P6S0eg+adXI+G6ura0Vv +e2jeRgP+kkZ2zqX01irsVdirsVdir50/5zJ/MGbSfK1j5PspOFxrrGa/KmhFpAwon/PWWn0KR3xV +mf8Azjd+WEPkj8vrae5iA17XES91KQijorrWG333HpI24/mLYq9YxV2KuxV2KuxV2KuxV2KuxV2K +obUdT03TbR7zUbuGytI/7y4uJFijX5u5VRir5U/5yz/MX8tfNfl7S7DQtZh1LW9NvS5W2V3iFvJG +yyUnC+kfjVPsscVSv8i/yi/LTzn5Ij1XVLSafU4J5rW9C3EkaFlIdCFQrT926980XaOuy4cnDGqI +vk5eDDGQsvdvKXkby35StXtdBgmtrZ6Vge6uZ4wf5ljmkkRCe5UCuaPPqp5Tc9/gHLhjEeSN8x3+ +o6foGoX2m2hv9QtoJJbWyFazSKpKxjjv8R22yOCEZTAkaBZTJAsPHv8AlcP53/8Altpv+BuP+ac3 +H8n6X/VPti4vjZP5rzz8wfPP5i+bfNvluw1Dyq1rqWjzG+g0ROZmuRVZDVGHPjxgbcDpXNhpdNiw +wkYy9Mutj8dWnJOUiAQ9D/5XD+d//ltpv+BuP+ac1/8AJ+l/1T7Yt3jZP5rv+Vw/nf8A+W2m/wCB +uP8AmnH+T9L/AKp9sV8bJ/NYp+ZX5v8A5qXnli40LVfKbaCutAWkdyxlWRwWXnHGrheRdfhI8DmV +pNBgE+KMuLh9zXkzTIoirR/kbzf+bvlHy1Y+XtO/LedobYENM6zK0kjtyeRzxoOTH6BtkNTp9Plm +ZyyfaEwnOIoRej+RPO35o6xr62fmPyf+hdNMTub71C1HWnFaV/azX6rS4IQuE+KXds348kyaIZ7q +jaqthKdKSCS/pSBbp3jhr4uY1kbbwA38Rmux8PF6r4fJuldbPlv8+YvzstdPS483apafoO7nEEVh +pcjJbl6NIA0bKkjgenWsnKhpnTdnHTH+7HqHfz+f6nAz8f8AFyfQ3/OLHl06N+TWkyOnCfVpJ9Rm +Hj6r+nEfphiQ5t3GeuYq7FXYq7FXYq+MfzQhXzz/AM5YWmgz1lsLe7sbB4zvW3gRbi5TvSrNLir7 +OxV2KuxV2KuxV2KuxV2KuxV5j59/5yM/K7yb6kFxqQ1TU0qP0dpvG4cMO0kgIij36hn5e2KvAvMv +/OWP5p+arl9P8laWukxtXiYIzfXvHpUuy+mg+UdR/NkJ5IwFyIA80xiSaDF/+VT/AJo+b7sah5w1 +h1kavx3sz3k617KgYoo9uYp4ZptR7QYIbRuZ8uXzP7XMx6GcuezJYf8AnH3yrBptwjXFxd6g8LrB +NIwSNJSpCOEQA7NvRmOak+0eQzGwjCxfU11/FOT/ACfEDnZYH+S+sfmZZeajoHlC8htrq6ZnubC/ +K/VnMAPLkrAtyUdfT+Kg8BnSa7HhMOLINg6/CZA1F9k6KdbOmw/pxbZdTp/pH1IyNAW8U9UK9Pnn +I5eDi9F8PnzdlG63R2VsmndUUu5CooJZiaAAdSTiBaHhP5N8/On5r+bPzEkBbT7dv0do7EGhWgUM +tRswgjUsP+LM3vaH7nBDCOZ5/j3/AHOJh9UzJ7vmicx2KvEf+clQLS78i63cEjT9O1cC6O3H4mjl +FR/qwPm77G3GSPUj9f63E1XQvbQQQCDUHoc0jlN4pSXzN5z8q+V7ZLjX9Tg0+OSvpLK37x+PXhGv +J3pXfiMuw6bJlNQFsJ5BHmXzJ+dn5haf+Z/mby75e8qtLPbLN6EbyI0YluruRI0oh+KigChIHU50 +/ZmilhieL6i4GoyiZ2fbWh6Ra6Noun6PaClpp1tFaW4/4rgQRr+C5s3HR2KuxV2KuxV2KvjfymCP ++c0p/rdK/pTU+POlKfUp/S/4144q+yMVdirsVdirsVdirsVeQfmX/wA5Ofl55MaaxtZv0/rcdVNl +ZMDEj+E1x8SL4ELyYdxir5W/Mf8A5yD/ADJ88GSC6vjpmjyVC6VYFoYmQ1FJXr6kte/I8fADFXme +Kvpj8jdTtb3yJBFFGkdxYyyW9zwVU5MDzRzTqSjipPU1zhvaDHKOosk8Mht5d/6/i7rQSBh5h6Fm +ic12Kvnvz6l35B/Nqz8z2CEQyzLqMSqeIY143UVf8upr7Pnedl5RqdLwS5gcJ/R9n2uj1MPDyWPe ++wdL1Ky1TTbXUrGQTWd5Ek9vKOjJIoZT9xznMkDCRieYc2JsWisgyYZ+b1p5vvfIGqWPlSFZ9Tu0 +9F1LiN/q77TelXYuV+EAkddt6A5vZ8sccoMzsPv6NOYSMdnzl+Wn5m/mVoKR+RtEtNLsrmGWSsOp +q1vM87t8Su8ssS+p0UKaGgAGdDqtHhyfvJ2fd3fBwseWUfSHq36V/wCcqf8AqzaN/wAGn/ZRms4N +B/OP2/qci83c79K/85U/9WbRv+DT/sox4NB/OP2/qW83c8o/Mj8z/wAy/MAm8i6zaaZfXU0sY9HT +Ea4lSdGqqxvFLKvqbFSBXqQc2el0eHH+8jY2693xcfJllL0l9KflXb+bbXyJpVp5riWLV7aIQsqu +JGMSbRGUio9ThQNQnx70znNccZyk4+R+9zsIkIi2W5iNqB1xdH/RF2+sxQy6XFE8t4tyiyRelGpZ +i6uCpAAyzFxcQ4D6ixlVb8nzj/zjB5UtfNn5xal5tisltNE0Rpbu1tEUCOOa6ZktYgBt+7j5tt3U +Z3UIkRAJt1BO77PySHYq7FXYq7FXYq+M/wAyX/wb/wA5b2WsP+7s7q90+7Zz8NILlEt7htqV3EmK +vszFXYq7FXYq7FWGfmR+bnkn8vrD6xr16PrkilrXS4KPdTdacY6jitRTmxC++Kvjz80/+clPPvnk +TWVq50Py45KfULRj6kqntcTjiz1H7K8V8QeuKsQ/KyLyvP5wtbTzFbC4trn91bc2IjW4JBj9QAjk +G+zQ7VIrmB2mcowE4jUh93Vv0wiZgS5Po7zD5J8ta/pa6bf2UfoQrxtWiAjeDbb0io+Hp06eIzht +N2jmwz4oyu+d7373dZNPCYoh8/effyj17yuZLu3B1DRgSRdRr8cS9f3yD7P+sPh+XTOz7P7Wxajb +6Z936u90+fSyx78wnP8Azj5r4s/M11o8jUi1OHlED/v63qwA+cbP92YvtDp+PCJjnA/Ydv1NugyV +Ou99C5xDuWDeefKvnzV9WiufL+v/AKKskt1jkt+Ui8pQ7sX+AEbqyj6M3XZ2t02LGRlhxyvnQO23 +e4eow5JSuJoe8sD81/lL+ZF9pj3Go65Hq7WKPLBbMZGc7VZY+S9WC9O+bnSdsaQTEYQ4OLyAHxou +Jl0mWrJuvel/5Q/8rK80ySeXdA85S6P9Qh9W2spZ51RouXx+kEDD4CwqPfbvmz1pw4xxzhxX5Bxc +XFLYGnv35Y+RfzR0DXri881+af03p0lq8MVp6s0nGZpI2WSkiqNkRh9OaLW6rBkgBjjwm+4D7nMx +Y5g7m3p2axyGGfmF+U3k/wA82pGq23paii8bfVIAFuEpWgLU+NN/st9FDvmZpddkwnbePc1ZMMZ+ +95R/iv8AMz8lbm20/wAzMPMvk2Z/Ssr5XpcIBvxXmSwKr/ut6r2Vxm28HDrAZQ9OTr+P0uNxzxbH +cNSeb/zJ/Om9uNM8pk+XPJ0Lelf6g7D13DD7L8DyJZf91oafzNTEYMOjAlP1ZOn7P1qZyymhsHrH +5d/lN5R8i2gXS7f1tRdaXGqTgNcPXqAeiJ/kr9NTvmq1euyZjvtHucjHhEPezPMJuePedvy3/OXV +fNF/qGg+c/0ZpM7KbWx9a4X0wI1VhxRSoqwJ2zc6fWaaMAJQuXuDizxZCbB2eNfm7F+Z3lQQaDr3 +nKXV21SJmm0+GedgIQwCmVXC7OwIUd6HNtopYcvrhDhrrQcbKJR2JeieSv8AnHD8+9H0SJtG83Q+ +XlvlS5udPinuonSR0Hwy+nHxLqPhO5zYtD2r8mvJH5m+V/0x/jjzN/iL659W/R/76eb0PS9X1f75 +Vpz5p08MVel4q7FXYq7FXYq+Xv8AnNjya81joXnG3Sv1Vm0y/YCp4SEy25PgquJB82GKva/yY87J +5z/LXRNbaTneNALfUfEXVv8Au5SR25leY9mGKs2xV2KrZJI4o2kkYJGgLO7EBVUCpJJ6AYq+aPzm +/wCctrTTWn0L8vmjvL1ax3GvOA9vEehFsh2lYH9tvg8A1cVeMfl95AvPzCvLrzP5l1SW6iNwUueT +tJdTyqqsQ7tXgvFgPGmwp1zS9rdrflqjEXMj4OZpdL4m5Oz3O18seXrXSP0PDp0C6ZSjWhjVkb3c +NXk3ud842etzSyeIZHi73bDDAR4a2eaeb/yBsLlmvPK9x9QuQeX1OYs0JPX4JN3j/EfLN9ovaIj0 +5hfmP0j9XycLNoBzh8noHku+1y50OKLXrV7XWLT9xeB6FZGUCkyOvwsHG549DUds03aOLHHJxYiD +jluPLy8v1OXp5SMakPUE9IBBBFQdiDmCDTe841/8pLaHW7bzL5U42OqWkyzvYfZt5+JqyrT+6LrV +f5fl1zoNL21xQOLPvGQri6j39/3+9wMujo8UOY6PSB06U9s54uewnzt5H8z69qsV5pXme60W3jgW +F7WAyhWcO7GQ+nLGKkMB07Zt9BrsGGBjkxiZvnt5d7iZ8M5m4ypj/wDyqbz9/wBT/f8A/BXP/ZRm +d/K+k/1CPyj+pp/K5f55+15z518keZ/y91G01W01SZ2nLiPVrYyW8qTMDzQurFgXQnfl8Qrm90Pa +GLVxIrl/CXCz4JYiHv8A+Qeia/NDH5tufO155k0u+s3gGm3Tzt9XufUjZuQkmlUPHwZdh0NQaHfV +9qTgP3YgIyB57bhv04PO7eyZp3KYZ+afm/zN5Z0KGby5okmtanezC1gVAXSF3UlXkRPjYbdqDxYd +83Q6eGWR45cIG7TmmYjYMC8p/kVrGu6ovmj81b1tV1Njyi0YODBEOoWQp8FB/vuP4fEtXM7P2nGE +eDAKHf8Aj7y1QwEm5orzX+Rd9pepP5n/ACuvm0HWlq0mlhqWc46lFBqqV/kYFP8AVyODtMSHBnHF +Hv8Ax9/NM8BBuGxZB+VP5j+ZPMs9/ovmbQJ9J13R1Q3s3ErbPzNEoGPJWehIA5KQKhu2Ua7RwxgT +hK4yZYcplsRuHo2a1yHh35u+SvN1nNrXnD/lYl/omiIFli0yB7gBSEVFiiC3EacpHGwAG5zd6HPi +lw4/DEpd+3z5OJmhIXLi2eW/lJ+UXnn829Svtdl1ue0XTjGo127MtzM9ytDHHG5dXrGg5E8vh+Hx +zo4QERQFBwSSeb2z/oXX86P/AC8Gq/8AI2+/7Kskh6L+UP5dedPJv6W/xN5wu/Nf1/6v9U+tvO/1 +f0fV9Th68s3956i1pT7OKvRcVdirsVdirsVY/wCf/J9l5x8nar5bvKLFqMDRpKRX05R8UUlP8iRV +b6MVfLf/ADiz50vvJX5han+XXmGtsmoztDHE/SLU4Dw4jt++Qca9yEpir7ExVK/MnmbQvLOjXGs6 +5eR2Om2q8pZ5TT5KoG7M3RVUVJ6Yq+M/zS/PHzr+bWrnyv5Vt5rPy67fDZoaS3CqaerduDRU/wAi +vEd+RplWbNDFEymaiGUIGRoc0Nc/846uugI1vqXPX1BaRGFLVtv7tTTmtP5z18BnOw9pInLRj+77 ++vv/AB9rsD2eeHY+pV/Io6rofmDWPK2rwSWlzJEl3FBIKCsbem5UjZuYddxUHjke34xy4YZYGwDW +3n/YuhJjMxL2rOSdq7FXYq7FXYq7FXYq7FUt8w6Bp2v6Pc6VqCc7a5XiSPtIw3V0J6Mp3GZGl1M8 +GQTjzH2+TXlxicaLxryB5w1r8nPPM+i63yl8v3rKbrgCVKE0ju4V8R0ZR13HUDO3ywx67CJw59P1 +H8ebpgZYZ0X1xZXlpfWkN5ZyrPa3CLLBNGQyOjiqspHUEZzE4mJo8w54N7q2RS7FXYq73xVTuLi3 +treS4uJFht4VMk00hCoiKKszMdgAOpwxiSaHNBNPlfzv5j8wfnh+Yll5O8qBhoVtKTFKwIQqvwzX +047IgNEB33p9p6Z13Z2iGGNn6zz/AFOtz5eM+T7B8j+TdG8m+V7Hy7o8fCzso+Jc/blkO8ksh7s7 +bn7htTNi0J9irsVdirsVdirsVdirsVfLP/OXf5WXENxb/mXoKNHNCY4tbMNVdWQhbe7BG9RtGx/1 +PfFWefl3/wA5I+VdQ/KqTzN5mu0ttV0YLbavarT1Z7gqfSaCPbl9YCkgdFIb9la4q+cvNPm3z/8A +nr5uCUNnolo1YLRSxtrOIkgSSdPUmYd+p7cV6Yms1mPTw4pn3DqW3FhlkNB695O8l6J5U00Wemx/ +vHAN1duB6szDux8B2XoM4LXdoZNTK5cug7vx3u7w4I4xQT/MFvUJbGzluYbqSFGubfl6ExA5oHFG +AbrQjqMsjmkImIPplzDEwBIPUNahew2Nhc3s54wWsTzSt4JGpZj9wxw4zOYiP4iB81nLhBPc8w/J +Tzn5v8y3mqHV7oXFlaIhjHpojLJKxIAZQtQFQ9a50XbujwYYRMI8MifsH4DgaLNOZNmwHq+cy7F2 +KuxV2KuxV2KuxVjXnzyLpnm/SDZ3P7m7hq9leAVaJyO/ijftL/EDNj2d2jLTTsbxPMfjq4+o04yD +zeb/AJZ/mj5g/KrXZPKnmyKSTQS9QFq5t+Z/v7c/txP1ZR8x8VQet1Gmx6vGMmM+r8bF1UJyxS4Z +PqrTNT0/VLCDUNOuI7qyuVDwXETBkZT3BGczkxygeGQohzgQRYRWRZOxVSurq2tLaW6upUgtoVLz +TSMEREUVLMxoABhjEyNDcoJp8v8A5n/mrr/5n65D5E8hQTTadcy+kxQcZL1lNeTV+xbpTl8VNvia +nTOp7O7OGL1S+v7v2uvz5+LYcn0j+SX5N6V+Wvlv6uCl1r96FfV9RUGjMKlYoq7iKOu38x+I+A2z +jPR8VdirsVdirsVdirsVdirsVSDz3rvlfQ/KWp6h5oaMaGsDx3kUgDCZJFK+iqEjm0leIXvir81d +SfTpdTupdPhkt9MedzawyMJJI4WYmNGeihmCbV74q+q/y8tfLEHlOyPlsV06VefqGnqvJ0czH/fl +RQ+HQbUzzrtWeY5z4v1D5V5eTv8ATCAgOFkma5yHYq7FWIfm3qBsfy81mRftSxLbge08ixN/wrHN +r2Jj4tVHys/Z+txdZKsZSD/nH3TRb+S5rwj4767kYH/IjVYwP+CDZm+0mQnNGPQR+/8AAauz4+gn +zenZzrnuxV2KuxV2KuxV2KuxVjnnbyLovm3Tfqt+np3MYJtL1APUiY+Feqn9pe/zocz9B2jk00rj +vHqPx1aM+njkG/N4/ovmf8xfyX1w2rr9b0W4fkbVyxtLgDq8T0Jikp12r4gimdkPA12PiHP7R7/x +7nUETwyovpX8vvzc8m+eLZf0ZdCDUgKzaVcEJcKR1KitJF/ykr70O2aHVaDJhO4uPf8Ajk5ePNGX +vTXzl578seTtMOoa9eLboa+hAPimmYfsxRjdj+A7kZVp9LPMaiP1Mp5BEbvmXzJ54/Mb87vMcflj +y1ZyQ6SzhksENFCKf96L2YbcV60+yDQAM1Cep0eghgF85d/6nX5cxn7n1H+S35IaB+Wmkkxlb3zD +eIo1LVGHyJhgrukQbfxbqewGe0vSsVdirsVdirsVdirsVdirsVQup6np+l6fc6jqNwlrY2kbTXNx +KeKJGgqzMfYYq+HfzQ/MTzL+dvnmHSNFR4PLtm7fo+2eoUIKh7y5pX42BoB+yPhG5JajU6mGGBnM +7BnjxmZoPQ4Pyv8AK8fk1vK5i5W8g5yXVAJjcU2nr/MO3am3TOGl2xmOfxfs6V3ft73dDSQ4OH7X +kehaz5g/KfzbLpWqK0+jXLB5VQfDJGaqlxDU7MKfEv0HsR0uowYu0MAlA+ocvI9x/HmHXY5ywTo8 +n0Fp2o2OpWMN9YzLcWlwoeGZDUEH/Pcds4jNhljkYyFSDuYTEhY5KzTQoaPIqnwJAOCOOR3AKmQH +VyzQueKyKx8AQTiccgLIKiQPV5t/zkDctD5FijHS5voYm37BJJP1x5vPZwf4Qf6h+8OH2h/dj3p3 ++UNt9X/LnRkoQXjklNRQ/vJnf9TbZjdtyvVT+H3Bs0Y/dBmOalynYq7FXYq7FXYq7FXYq7FUHq+j +6ZrFhLYanbJdWkwo8Tjb2II3Vh2I3GXYNRPFLigaLCeMSFF4R50/JTXdCnOq+VpJby1ib1FjjJF5 +ARuCvGhenYr8Xt3zstB25jzenJ6Z/Yf1fF1OfRShvHcJFJ5F/M7zRY3PmTUI7m8eKMFHvZHa6mRe +0SvV2CjcdK/s1OZsu0NNimMVgHy5D39zQMGSQ4qfTP8AziV518hXnlX/AA3p1lBpPmi0XnqUIr6l +6F2+sq7lnfr8SV+A9AFIzYtD6BxV2KuxV2KuxV2KuxV2KuxV2KvjX/nI7847/wA+eYk/L/ye7XGj +QTiO4kgNRfXSnswNDBEeh6Egt0CnIZMkYRMpGgExiSaDJvy88h2PlDRRbJxl1G4o9/dAfbcDZVPX +gn7P3988/wC0+0Zamd8oDkP0+93um04xx82vOP5meVvKoMV7OZ7+lVsLejy+3PcKg/1j8q4dF2Tm +1G4HDDvP6O9c2qhj25l47r/mfzt+ak6aXovlxrmO3f1I47SF7meOuxLzAURT32UZ1/Z/ZcNNdEkn +n3fJ1OfUnJzDFvNXl7z35Lu/8P8AmCG60uQoLhbNpaxMsg+2nps0TVpQkHqKHcZseEXdbtFsbySH +Yqu9ST0/T5H068uFTx5UpWnjir2HyZ+T/wCfGr+U9O1/yreSS6VdKzWkEOo+iQI5HRlMcjxoPjjI +pXKMmmxT+qMT7wGcckhyJCOudA/5yq0IfvtM1G4VDuscNvqFadqwidj07HMXJ2Tpp84D4bfc2x1W +QdUvl/Oj8y9CmEPmHQ0iPQpc209pKT1/aNP+FzCyezunly4o/H9bbHX5Bzop1pv/ADkboslBqWkX +FsfG3dJx8/j9HNfl9mZfwTB94r9bkR7RHUMv0r82/wAvtSoserx28ndLoNb0/wBlIFT7mzWZuxdT +D+HiHlv9nP7HIhrMcutMst7i3uIlmt5Umib7MkbBlPyIqM1s8coGpAg+bkxkDuFTIJdirsVdirsV +dirH/PXm608q+XZ9Umo8391ZwH/dk7A8V+Qpyb2GZ/Z2iOoyiP8AD19zRqMwxxvq+cfL9n+Yf19/ +Omi29ytzYytfnU41CgPyLOyhqCTqeSqDt1FM7+WoxYyIGQBOwDoxjlIE0+1/yK/O7S/zJ0IpP6dp +5nsVA1LT1OzrsPrEAO5jYncdVOx/ZJyGt6jirsVdirsVdirsVdirsVfO/wDzlT+dh8vaa/kfQJ6a +7qUf+5S4jPxWtrINoxTpJMD8wm/7SnFWA/k3+W48v6eNZ1OL/c1ep8EbDe3hbfhQ9Hbq3h08a8V2 +52n4svCgfRHn5n9Q/HR3Gi03COI8yl/5qfm5LYTt5d8sP6mqM3pXd3GOZiY7elFStZa9T+z0+10v +7I7G4gMmUbdI/pP6mGr1demPzZX+UH/OJcl6I/MP5lNKZJj6sehB2EjV35XkoPKp68FNfFuq51wF +OqfT2j6Jo+i2Een6RZQafYxf3dtbRrFGPfigAqe5xVj35mflh5Y/MLy++k61CBKgLWGoIB69tKf2 +o2PY0HJejD6CFXwV+Z35WeaPy715tL1qHlbyFmsNRjB9C4jBoGU/st/Mh3X5UJVYdirsVfb3/OHX +mKPUfyrfSS9Z9EvpovTrUiK4/wBIRvYM7yD6MVe7YqsmhhniaKaNZYnFHjcBlI8CDtirDde/JX8q +Ne5HUvK1g0j15zQRC1lJPcyW/pOT9OKvMfMn/OF/5eXwZ9D1K+0aY/ZRit3AP9g/CT/krirzTVv+ +cTvzh8tSPdeVNVh1EDoLS4exuWp4rIVj/wCSpyGTHGYqQBHmmMiNwxq58/fnT5ImW382aVMYgeIO +oWzRch0pHcRhUfp1+LNVn7C02TcDhPl+rk5UNbkj1tlGgf8AOQHlS94x6rBNpUx6uR68P/BIOf8A +wmaPUezmWO+MiX2H9X2uZj7QifqFPRNK1vR9Wg9fTL2G9iHVoHV6V7NQ7H2OaTPpsmI1OJi5sMkZ +cjaNyhm7FXYqlGq+VNC1fULe91S2F69opW2hn+OFCxqzekfhLGg3avTbMzDrsuKBhA8N8yOfz/U0 +zwRlKzumyqqqFUAKBQKNgAO2YhJJttp84edta0nyl+Y0Gu+Qr/0NQtH9W4WAfuI5wfiRSDxdJBUO +lOPUd6D0PsqWc4R4w36d5Hm6HUiAn6H2P+TH5xaN+ZXlwXcIW11u0ATVdM5VMbnpJHXcxP8Asnt0 +PTNk470PFXYq7FXYq7FXYqwf84fzP078uvJtxrU/GXUJawaTZMf765YbVA34IPic+G3UjFXyR+U/ +lPUvNnmK589+ZXa65XDzRPKB/pF2Wq0h7cIz0AFK7D7NM5/tztLwo+HA+uXPyH6z+OjnaLT8R4jy +DOPzf89t5Y8v+hZScdX1HlHbEdY0A/eS/MVovufbNJ2J2f4+TikPRD7T3fr/AGubrM/BGhzKf/8A +OK/5HQWtjb/mF5ltxLqV3+90K2mBPoxHpdMD1kk6x+C/F1O3dukfTGKuxV2KpL5v8neXfN+hz6J5 +gs0vLCffi2zxuPsyROPiR17EfqxV8N/nR/zj/wCZfy5umvYeep+VpXpb6mq/FFyPwx3Kj7Ddg32W +7UO2KvKcVeu/84z/AJoQeRvPwi1KX0tC11Vs7+RjRIpA1YJ29kZipJ6KxPbFX3sCCKjcHocVbxV2 +KuxV2Kqc9vBcQvBcRrNDIOMkUihlYHsVNQcVeX+cP+cZ/wAovM3OQ6QNIvH/AOPrSmFsQf8AjDRo +D/yLrirw/wA0f84fef8AQZ21DyRrKal6dTHEWNhejwVH5GJvmXT5ZGURIURYSCRyYf8A8rL/ADW8 +jXo03zjpUslK8Y7+JreVlXasU6rxdf8AKo3zzT6rsHBk3j6D5cvl+qnLx62cee7P/LX5zeSdbKxS +XJ0y7bb0byiKT/kygmP5VIPtnO6rsLPi3iOOPlz+X6rc/HrYS57FnSsrKGUhlIqCNwRmmIINFywW +8CWLebfLnmTzCG0+PVV0jRm2n+rK0lzOpG6s7FFjXtRa17nembXRavBp/VwmeTz2A93P5uLmxTnt +dRSjR/yO8g6cVea2l1GVTUPdyEiv+pH6aEfMHL83tBqJ/TUfcP12whocY57sS80+XfMH5YeaLfz3 +5JdorSKStxbAExxBz8UUigjlbydP8n58Tm97H7WGccE/7wf7L9vf8/dhavS8BsfT9z6x/Kf81NB/ +MbyzHq2nEQXsVI9U0xmDSW03genJHpVHpuPAggb1wmbYq7FXYq7FVK6ure0tprq5lWG2gRpZ5nIV +ERByZmJ2AAFTir4W89eZtV/PD81xHas8Xlyw5RWXb0bJGHqTsDt6s7U/4Vei1zE12rjp8Rmfh5lt +w4jOVB7Zp2n2enWMFjZxiG1tkWKGMdAqig655xmyyyTM5G5F6CEREUOTxPS9Gb81/wA/YNJlLNo1 +tMUuKbUsrEky0I6es9QD25jPQ+zNL4OCMevM+8/inQ6nJxzJfdcUUUUSRRIscUahY41AVVVRQAAb +AAZntC/FXYq7FXYqo3dnaXtrLaXkKXFrOpjnglUOjowoVZWqCD74q+T/AM7f+cTri0a48wfl7E09 +pvJdeX6lpY+5NqTu6/8AFZ+Ifs16BV8xyRyRSNHIpSRCVdGBDBgaEEHoRiqLv9b1nUEjS/v7m7SF +VjhWeV5QiIOKqocmgUbADFU/8k/mp588l38N1oOrzwxREcrCR2ktJFH7MkDHgRTaoow7EYq/Qb8v +POFv5y8laR5mt4/RXUoBI8NeXpyqxjlQNtULIjCuKsixV2KuxV2KuxVB6rpGlavZSWGq2cF/ZS7S +W1zGssbfNHBGKvD/AD5/zh75B1r1Lny1PL5cvmqREtbizY/8YnYOlT/K9B/LirxDWPy7/Pr8pmea +GKW90OI8nuLOt5ZcQakvERzhHixVfnmJqdDhzj1xvz6/Ntx5pw5FNvKv/OQWi3fCDzDbNp0/Q3UI +aWAmnUqKyJv2+L55zWr9nJDfEeLyPP58vudhi7QB2kKepWGo6fqNst1YXMd1bP8AZmhcOp+lSc57 +LhnjPDMGJ83YRmJCwbROVMlk0MU8LwzIJIZVKSRsKqysKEEHqCMlCZiQRsQggEUXiepWHmf8m/OM +PnDyiS+jSH07i3erxhHYFrafuY2oOD9QadwCe77J7UGojwy2yD7fN0mq0xxmx9L7C/Lr8wvL/n3y +zBr+iyExSfBc2z/3tvOAC8Ug8RXY9CNxm5cRk+KuxV2Kvm7/AJzA/NOTTNHg8haVKRf6ugn1ZkJ5 +JacqJDt3mdTyH8op0bFUg/KjyOvlfy2n1iMDVr8LNfsaVXb4Ia/8Vg7/AOVXOB7Z1/j5aH0R5fpL +vNJg4I2eZZRr1/8Ao/Q9Rv8A/lktZp/+RUZf+Ga7SwE8sInkZAfa35ZVEnyYp/zg/o0Ump+atccV +mghtbKJu/Gd3ll/GBM9PecfWeKuxV2KuxV2KuxV2KvOfPf5Aflj521UatrGmtHqRFJ7m0kMDTdKG +Xjs7CmzUr+GKsb/6FD/Jv/lmvv8ApLb+mKu/6FD/ACb/AOWa+/6S2/pir0/yZ5Q0byf5as/LmirI +mmWPqfV1lcyOPWleZ6sevxyHFU7xV2KuxV2KuxV2KuxV2KvMfzC/5x1/LLzr6lzcaf8AovVn3/Se +ncYJGbrWSOhikr3LLy9xir5080f846/nH+XVzJqnlK6k1nT1NTLpwYXHFenrWR58/kvMZTmwQyx4 +ZgSDKEzE2DSH8r/85ABZRZea7IwSoeD3lup+FgaH1YT8Qp34/wDA5zes9nBzwn4H9B/X83Y4u0Ok +w9b0nWdK1e0W80y7iu7ZukkTBgD4Hup9jvnM59PkxS4ZgxLsYZIyFg2q31jaX9pNZ3kKz2s6lJoX +FVZT2ORxZZY5CUTUgmURIUeTxy2svzN/KLzbcaj5Eil1DS9RRkNuIZLqMqDVUnij35Rk/A+3z3YZ +3Wg7YxZYXOQhMc7NfK/wHS59JKMthYZVB/zlL+eWlMZNc8owTWiEmRzaXlsaClaS83jp/sTmxx6r +FM1GUZe4guPLHIcwQ9C8jf8AOYH5ea7NFaa9bzeW7uUhRLMwns+RNADOgVl+bxhR3OXsHulvcW9z +BHcW0qTW8yh4Zo2Do6MKqysKggjoRir849U/MZtX/M6688azZnUTNdNcxWTSekFVPhtk5cZPhhVV +FKb0yjU4pZMZjE8JPVnjkIyBItnP/Qyn/fuf9Pv/AF4zm/8AQx/tn+x/487D+Uv6P2/sQWuf85A/ +pXRNQ0z9A+j9etprb1vrfLh60ZTlx9Fa05VpXLcHs74eSM+O+Eg/T3f5zGev4okcPPz/AGPU/wDn +B7UUbTvNmmkgPFNaXCjuRIsqH7vTH350zrn1DirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsV +dirsVdirsVdirBPzB/JP8uvPivJremKmpFaJqtofQul2oKuopJTsJFYYq+afOP8AzjN+afkK7fWP +JF7LrNjGeX+iVjvVUb0ktqlZh/qcq/yjK8uKGSPDIAjzZRkYmwl/lf8AP1opf0f5vsmgnjb05LyB +CCrA0PqwH4lI78f+BzmtZ7OA74T8D+g/r+bsMPaHSfzet6TrOlavZreaZdR3ds3SSJgwB8D3B9jv +nMZ9PkxS4ZgxLsoZIyFg2jMpZsJ87flR5Z8zxSTLCthqxBKX0Kgcm/4uQUEg9/te+bjQds5cBAke +KHcf0H8BxM+kjPlsWPfkJ+aPmL8t/PS+QfNEjHQbycWyo7FktbiZh6U8LH/dMpYcxsN+WxBr3OHN +HLATibiXSzgYmjzfWP8AyrzyB/1LOlf9INt/zRlrF3/KvPIH/Us6V/0g23/NGKu/5V55A/6lnSv+ +kG2/5oxVHaV5Z8uaRJJJpOlWenySgLK9rbxQMyg1AYxqtRiqZYq7FXYq7FXYq7FXYq7FXYq7FXYq +7FXYq7FXYq7FXYq7FXYq7FXYq7FXYqwT8xvyU/L/AM/xFtbsBHqQXjFq1pSG6XsKuARIB2EisB2x +V856t/ziZ+bHl/VpT5M1qO4sZhtcpcPYT0B2SVFJBp4hj8hleTFCYqQEh5i2UZGPI0of9C+f85Nf +9XeT/uLS/wDNWUfkNP8A6nD/AEo/Uz8ef84/N3/Qvn/OTX/V3k/7i0v/ADVj+Q0/+pw/0o/Uvjz/ +AJx+aX3n/OK/576ldpcalLBdTgKguLi/MzqoNQAzVagqTTMjHijAVECI8tmEpEmybf/Z + + + + + + + image/svg+xml + + +image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + eJzdffle8sqy6H0B3gFUFGQwEyEBB2YHUEFwwJlJRJlkWGuv88d59lvVSUgICWmQ75x1716/7aed +Tnd1dXXN1fF6iuVQsjmot0J8mHG7vN70qFWbDEYxN2l1n3e70/FkhE2+G7+bZcMMdEqeS29qx7vW +aNwZ9GPkEXmYw7d951e565vTrN/t80NbpTPptqB1Mug1apPw+K+2X5sLXs7UJvAwciAfMKKbZWJ8 +1J28hOepwbTf7PTbqcF/YPyo6OYZzi3AU0GKwuOzzk1rbO4TjrK8jB3DnAy/CLwYluBNQYInDL6V +GTSmvVZ/UhwNGq3xOD3oDkbjmDv9T63vvqy14UnNXW11u4O/3alurfHtgtVG3nKdbgsW1qtN3FFc +ZfKcfyOv3o7hHXgdf8fm6Nt5D1rKrckEoIKBESXpy2reOB9Aqv7ne7pptTsEw4CIF78ycqXVG3YB +KWRRPCCFl0XtX7UHwEOehqJsmJdlGfAmhiMy9BMlPiwwjAC/RMgj5Q193a2/Oq2/Y+6rQb+lLC45 +mpQ7/9XCqRg3xzBK68202xrd9jsTWASHTbKy4stBs9VVm8i7uW6NLJT8x+o/lQ6V2qjdmsBODbrT +CaEUSZvhator1P5pjfQJroetfmVwR+ALiUJYFMWIWxQY5Rc2HHFLouyOMoA6ScEgC8tUp2TJtKwy +No6E42gTRHHvi7Az16NOu9OPsYLoDnHYint2Ouo09S2Lcm5J+UHWEZYM/5e1/ysAw9onk1Zf2eZs +v5ke9BDJY6Re2Ng+7Hp30FaezX4nT2C66VCBlfz9BvtRHHX6CIPrijyR3ordKTw6HQ2mw/P+x8Dl +U05lEScd9a/78MunOzWajj/dlcGgC6dtroP6SBkFH44mxt5L54C+9uPrA601drrW7Xbao9rws9Ow +Gt7i+Wweu3eXTgjbNGrpY5A/Z/8ufbPcIKi0gnL+0WxwizeWz/BPrz7odsY9fWBDi/67E0XARnVb +/eZ4Nozypw5YofOX1rh8sEzrA1idYWtJa7b/V6s7GBrQOGup9Zvu+9poaDcsQvfR6TcBK+VpZ9LS +N3rQGyIDd5c/a0NsXuipnBA4PcbzEQotPzgrvyArT5ARTv7ptsaug3x/8Hef/OGOuXxPgJLatDt5 +8bsPrmq9ljvoOih3gEm3tC6M+9rFqDzwG367cWn8MO/SuCLjfvgH/riAX76g6W+34L50P70w7ia0 +Pty4kIE9NF0HxRoA54673AcwLfxLAIQV6eA5rrFY6wI7axEginWXnbhBkMauhdZiY/bGt+XTYmoG +gjbTKvgtwHBGpC6skHRYZyNZRnmkHBsc5v+ozTCQqdFmcBVWTV6CclJzed8OtL9hr/GvTgOxURv9 +o/z9cFm4ArlI/vBtN9W+QC3lCQzedvv+0+v2oUMIf/SBgvxAQt436+d/1bpTtYPsPjiHOeceT/4Z +qk8PkqNRzQqCXmtSawLgvweAXQ+Av2qjTq3eRT1o/G8A4n8dhv9JLMT1Po3PTrc5avXVPiayNXQE +mTXq1KcTBDRIHgUX1xIb15Dn4ZH4H95Y6iXNQ4zvOIPp2+2P3xpg5wx6cZvOBpi5/9lt0NawuB3k +QewvuuUBHY7/rYvDNQRpyHFNKoC1A7leEYQ44areIeYk++9DlXEVi8TQHTS+W03n9fXB6vv3rU2D +/k9SwQq84N98WCiRNL/28cff/2sScNztNP6/EH9kIeXBdNRoEa/Tv3JN8yD/4wjizFN2cNOqdf81 +pP6PpcBzXM3MAfjvWs1/rFbzd6c5+XRcEScyYVbk2H/ZilTgF1f12eq0P53VbVYSwgLL/9uWpUG/ +uK76YALqYaH1MVEciM4rdB+kBoN/z9IWF/AvEbYgm/4fl7WbEzgbAt7ggMAWRsVd8pxl3TM/BnFA +uwu1fntaa7fcxcFwOjSRLnmhOGqNW6O/Wu5K6z8Td7bZmdTqnW5norJoMRLhI7MJZHdtNKkPaqOm +u4HBAjfrHmmKnWPP9qilrdexb31GGRFO4CT7rpwOgGNPAwCOfesLQnyx2zzp4vPJqNYfD2uwr41/ +YLpO0z3u/Fdrtk0a2mX3sDZsjeBhb9olfjdNWjMax8RO19PJcDpx39TGk9ao81+ko1sPtajgRebe +uWyNPx3eYOb2X6Mldwd61SYtWHmL2EhLO3/3QaUfAHBtdAOrx/3pstXsTHuGCV8MJ9+KPNX4CqCC +kOHEbbB/TEdCIxfAvIr4qIb55rATNkFb63bGpqZebfytolnUMDasNXWzJHnuTk4ngxn2tP1nDAeM +cX/MQB6RfqG/Wo0JkEy91q31G4t7PfcKYKzb6bfcEzhrdD3Hk9HgWzv7rE3nRrczBJJE581/4Dy0 +AW0Obwy1Uz/4qzUaooN0xl4ANY3BqNlqLm6D++BqMJl7vCrvcRhOp5YDne8djJqjcVhx4JgV74Vu +tX5/MJmtXdnlhU4aHsbjeQ662HHabzh0AXkHJ6ZJdQSML/9nGNYlpdXo0GEwbE4dOoydRmgM5tmY +qQOSzvIOgz6QyEShw6VzqT112iasyaonMOJ5lsQzNj1H5p7RiHXHueNnufNDZd+X7zp0AjY038/A +lc1dP2vN1qi1fLwuiyezNlnaCXA3Ia6bpX16eGzHRkZu1a/fagPj/2v5YPUOnsF5CWYGvPVXq2s/ +yEd/Eh5P6+MlC8Muze5w9DGY8RcrKlO69UDbUbUDS3S3e9/hXm30PR58fIQVdZe6+0jX+yl6TwZD +6r5d0LhnCLDpDPyh1TRDTdHdADVF7xnUFH3noF7ce+xLNJx6bbSMuLHfyBA9dOg6BGHQ6X8MnGYe +GVZi3YUsRO0T5iK2C262PlCKGsxZa2ZMOn8N6hNMZHLsqIiij0532RHDjmMMdjr0mZMfVr0ao2Z4 +Ahq5ppFZnSDsM240+ssOo9Jn2G38Y9BrFvGmdKt1W+G/KPt9LiE77DUYtbWxlvZRx7Fi8NhlOBh3 +lhMZ9oL9Hn4ORv+lcraoXb/BqIO5YA4DdkfhmYJUx3Sx5X01WTkcTJYcG+ypMztrOgNadFAPsEe9 +M+nVhmYRadebrKI2Vl6i6DpYTuGzfnXVW7qsY7M17rT7TugeDkdhYkItoxbs9AlMbNxaxhtJt7/p +uhndQksGc2Qi0Enfs2iUDwuWjAm6dTCJcE4cROSIU3eDOGClsLVsmnWeSQNWdOqqC4OozNl1NeJI +ZG27GZBkxaewS1NJC1nCFqGTs7Y/nnTVXsNh035G7KbOOOtnPyB0wZPZtfLxL/RF2m+N5lyCS6dX ++muGgiHlyGoGEL/dFjGVdJM4PnPZYAJRUuvsRpuKyryyO504WW3icNZHoA6Oxi0cbWS/YOw5/u4M +gVv2v504HCoEcNzbluu7GNQxvcywOt0TA52yxbL72mS8zvlP1D4FtKIxexGz2IiPa6kHRX3rdFRr +ooAgbyk+FTtDZPaO4jc4uFP8ASk7f4AKumrfV3RrybZP2c4HoHRLo/WfVq3/G6P1T+ORwRGWuGFY +o9eqP9D9Be5On7gcUCpbuWwWqc/3ZEg3d69B/1Z2Cq6hmMm9pYmN1TG6Lq3IU+uueT0NEKHrE8BI +14aKA7TTWmKyaOOcItbg6FQ+p716v9bpLpGD2juYtwz/5pZKV61zDojqvlXHd5yhIQncmcHffSWR +J9/pNw0kTvuamdI5zkols3mZpMcn64O/dFtu+atp3arV4V2+0/NvlaY1fc+5iOOEmFtf1r17yzZ3 +VPtndWzOv7UaMuffXQWX+ObKqDS9tAIm8U16RF4O+oPG52jQa1mh09r5s+xdM1KFpRuCI9gjVaCa +2xK1y4+i8gJIHudDXhl1epfoUXDuCvydsich9tRSA37GDQEl50sNc51vEiUGQajMwnN2Jrh5efct +BzeM9sI1UdtzgHhA39+D0XdhpqKu9l7KyU1k++bNuqBWlrphtNdS6MAoLPcdzfW9cTBR5jqvAIMR +Q8voWQG4019iAWtds716q3meThdHxILUpOjSU16e1hGNg/7kBo1EZ3hmqh+FCFW0m4ohNkelHi0Z +C54rmtKVIdNmKbLNL17W/rNED6UaodO31Ulp3lf01JTJb079OmqdqtKp6JyrD6Hqt2WH0ILD6xVj +LM1R4Us2RoN6baLUjc3MDuihrmqmdppNDtkc3hrW+pp7XJOx5btTJGGFmCcLHjv1cWHQqC3OAA/J +wVGsCJWm9GcAXqOju/4NM2b7jYEerxX0B6TUQufSM00eHpHyHKRdOBANi+daheLik2L7Y7HxoWZO +LcDpu53GDKz4ojmgF77M12Lgjik1Griz2jMX2UljC5oYyXL6/FyKZGDcJlbteAPHYmgnMfY/bGXy +F42PnL/EJRM/qVefcHL9fhy955lmvBXz9smf8fPx4CP3Xpju5TyBJ8bUFji5qx8wXHcSSd5UcpVE +bPgii49i79HlPQy95wZkMJgvPk6Wp7e+ZL/eHqvvHP/0kvn77PZodFzrn3bvvuqp98tSMhnssy/x +E/ZOymw3p9lM+uz5hQwVOD4aeoUxv1MKnHxOeAKIy0sBygqAHNWTweHVRSIvj4+ls8P7cG7wKNy5 +vNnR8yOTecxVK7mj5FHDCp7jof9wCBOchdLcztF7JjxN3Cajz29VsTpki7nd0kNXna+R3M18DP1s +snIxmeptLq/Smn/wT2Cci2kmfP15OBoJmQ7DiVvDxN1eeUfpzjLFWs4/2a1lgy9XBykxyG2p47wP +EqNRfFwBeIPnDBv6iunIiqdu0i2XdyzlJnfc6+B7Vyy19gMRT9p/LRyWYpXA0Y34OXphxodhviBz +geNTz64w5saXAM2dFD4YS6eC9BP/gj/9fqa5W83MT/o8erl8LpFJgcbmp4V3o6+R2Plr2HLS152r +gu2kYid/6rWa1OUdjQ49vtGY9Y6s1jqWiuyzsMXF9q0mHe8FL0M2k0Y+fbW9apZM6vIurFXwPwcO +uXbJctKt3KuwfTvsFqwmZXKpfMJqUpcXphW3d/oj/5E1goXqK5P7uCpbT3rqOdxlL94qlpOennEV +Mime/UUEc4/HlXcyKbufrGfnd/V+9Dw9LuCk8cU99VX5py7rh0lDQX1SmEUhpQKTUtda3NszTRqJ +9N6GdpO+jV4++xWbSRM1MZrbYV1e07QqKZ2839hNerbD++LP1pMeel7G25+tG9OkwGGUaUtp//HP +Tq9gNWkg3o0d20wa+dw/eUxcW08qVKtMTmaugMas1rqVa0d3bnrctdWkTO7lJWczqbjt/e5fpk2T +wizatDXmNPh+Zz3pKZPca/miVUv0TraDJ+qk1ZDPhN6TK+Ho2aWcVTb7/J2bW+vjIVOIhlic9HBh +0rPWQLyphTiYlAmZV1p4eqyZJiWzqGuNfjdzr3aTZpjL/RfZetLzn1jia3R1YzlpOb7Hw6m0Xqu4 +nW+VecZm0qcQU37zb1lPmj9rXT09+n36pC6vYdq7vX7bdtLyZ+m9bjfpKXOXHx5aTw== + + + WuC9Lu9tLnF4ZLnWu+HFlu2kd2+nWxO7Sa+Z+5N8Rp8U1mKY9vI4+/ZaenmxnPTl+vvcdtKvaqSZ +s5n0Gbgl8zLuhqzXevU17F3LEm856dt5qG876chbDnj0SVGKGc/qLZPt9C4sJ5WuQluexEsoC5Py +YfOhmb5F39RJ67zfdGhcXv9jobZPpuX2jn1n82stMO/7sSROemyaFIb9+tGYvnhgnnQ82D1SJ52c +BGBf5tfqea49+ZVJU1X2fJ4VBkfj22MPTppY5EnnIW2lh6xpUsBY/GxLVKY9YfMhEysMDoUrRdLw +O7F0fn7SndGoVu/jpCnzSkfJ1kCj3hTQmFmUR75iqqQ5iZXCJgRvDVrvFUWmtmpv4jxIZ7e7r4OY +1VMikSNn1RLbu7N7+5M5e/dObZ8C683s2jyFHdgNpL0qt2RaX62o6bkosW8a3ONvyfy0/7n1YPs0 +WjyPPetPF3Zf4vZv3m3flj5rr3u2T5Pc7mPD6qmqwxQC/RPO9u1C/fojbvv0eqtRP7N5Kp3tnh3e +jjWMfez9yKa3bwMdTT39YLdi5qf1i3Lf9uldJvA90p8uYOzeWz/w2L59/5yJHdk+ffe+RnesnqoY ++5oUh2e2b3/fcamS7dPed+741e4poKoUj8wwtvj8ghOOH2yfNvr1csHu6a5n9/x53x5ju9nkZb1l ++/YFd7LF2j1Nergdf8wWY5EzJnu0r6065oubznSgUhqfqE/T4UPT08r76X7S+FQI3iBDKSnGXDq0 +nwbdcjJ8fUm3Pyvo1EseHctnO0hZ9z7VWj5pxGzMvvFD4u7jtpysVLz3hEUlK5dNIVsbPXkDqcH4 +Sm8Du7I2etwjfC7GSp4rwsw8+/k46wlmbu49wbvXsif41qx4fE/+Kf5WBBL8TntC+bfIolFYbSdL +fFkCqNMBsE4H3+JOVP5AS3yf82h25YuUe5s81xLxIbuVuQhsR7Sl7faSg8wrkOm2vMXtHRWPM639 +rJecOzRnnjQsWvdzKT3R2pKX9yT9jmPpp6pjPzDD6js333o/l9e257730DNwHFHcpl0L2GLRG/8L +xYg7fT7+RtHPe925rFGsRdxGod6gGHHvvB5ua/22e7n0x4V0cHnRisKf+9vJ6GOXV2xkPwjHj0OF +Tpgx101Wkv0ccxER9hWyQfcHWMsRThe84lZVuMw+Nn4+DjpHdb/4KBbOVLs5ujuaCeB0cvBz60cO +s7glft/JU3c5eGhLv9AAt5WrhY1eBVvwmFz+sGgCz3I3hKvMuxVwhFvq4FXfqMA73RFpgDstbT8a +dH478KSzOWKxxV31ZjlwQGPK1l7l72jAy2ZvczPcZZLl4PcODFCqHnS2Y8G5CQKHZhqLGUBh9yKv +mY9KhkeQBVzaob5SNnjLhvRJR1M+zVBMCjr//LREO15z0kBsMMnipEOCFoabJj7Tn8Kbui+gah4P +M9lGsSJqbsX2NNuoth6UNo2P5zPnzSPQlHLTbjReui6ib5GbPb3B38AI/5bPAergdy59EiuTbTdY +FuPA8XF2D6At7yOMYbLq46GvOVZdNfMORmWlbW83ebt9hFoBs5Usdz2jXFa6OVAHvWr8BI6LuwOY +BYWZOPGxp+qLO82MojYDZKmDz1bGq/wAOriHwYqiam3BfLMtIcvIoJMhN7+MjMGrQJbhNfzAmWPv +P8WYQbTOgfezEnDkVC4Fr86fWYFnAdy+LXC4FhW8MQ14hEIJVaojXkh2y53q42m7b7tg+HGjLFfx +3VgsF4yrwvLlulbZjb2tNUlF5ckLu3Fa7CERt/EgbStcR7wgauyddCyf3hbBctr1kh/c3glzjoCc +z4YqaZyvKELnpwzsCxhId5T7S0F8A3Y/9ZVjWDnyleATj6jB7fpmvosK04Rd9Xq1H8K+eiCJy2Au +AhF7H43rsE3xEC0CXXSn7fT55zcI1LVxFYWoJz/++oDoCORSj/IF+i3nULgSAi042o0VR5udympw +aMYyM3xNr8fRsgjNqY4RVSJb4+Q0v4sz31jufvb5emLaq8jwQC6a9oqwd5fXlsHPjXjnoRhR/VF7 +yCCCzmx3/zXL78Tzhbm92t6z3KtWMbyr7osFxk5ipcvNYCwToNzJXZfKD615w2sWHQX3Jvm6Okgu +LwIVpgXKASSwWatWIFnISic8MU4gDQJHugpBWIFyXi6WgJcOPy3F2K6uihhPL3FeamC6vBbnt7xE +I6lzCyLf+fSSfbE8vzkrxcpi43Xd6omMqAbW5sZzeZURT3zZPBUpGYTMpWzNI2G5CmOenTqiw5jO +nU+yVv3mUG2giNrWJbcci3he5mhCXzq8PTmdLX2ojy1VdvcuTyvPX02GTT23M+Gb26Ae7iczw1C3 +I50nqbLSSiYtV2PnRnwYL5dxLu8cITrrWd/SZHW9zeVdOuJ0M5rgTIp9yx6qEY/q+/o5sKJa7HyK +3v0LM082SXYa82JuXz63N70v8s6m90Wmsm5W2RdppMhSJ5UGjVCCVFXtOrXhtM1TXWt1eZeqXTRM +St3u07uB7eYAT17nGN4tCJmlqHR5nY/hiK3t7J39BpUmHQaQSafBroLK+hilmKOWvbJhfmsSgzN7 +n2BnckxlXNKpsWe6GutAY7pqb6lscKmHT7PSaYUMl8HosN79yQmVNbn0aJowdkLFPuiM5zPdeP4t +xqpbu5vB2PGYjvXMrKlFDV3RYYAcTsv9lSxHW5BWtpGtzQYEqTpcCSQlwmsNFBVfoQDpbUR19uct +bDulun1moVQv8Y/NLOxyfD70dKMNe+hLRl89Ye5lXE+lP6Nnw0w+/5PSgjVk0q9zprlXyxJkuLz0 +RjjJFrIg55dx34EBuLwWODmzwcnX+Yp7pQHnMqd5auBNHNSSleSey8u9TLzUJGBlZpuWu2hk0/iU +bHdjEtijBc5FsxuYg3C7qgfIaN3M8eQTX2ZixSDWJ75PbhZ7XUUu2nD58+UuNKOmREvOq7vQiAZr +YyAiAokT7TcIJAxu5k9WtY97eyP8hL1YMGcoXWiWnt4LkxNtTe8LvxPz7ZC9Aj7m7ESjON0wYtgs +m/XxFnbf8XT3LlZ3odlgbN6JtjbG5B9m8bys46/qXVC40Fy0QPG/caGpUR4FKDsn2sp4iphAAilG +QfNzvpI5igezgcI561qmOqgpJ9eGIOJJrDixCyLmkc6zlB5FZ/89UOD2SttkoOR52hnmTT4um2NB +ZTKTUwkjvkxTeZqDhj+WSxX+5DbmM+0V6JbWrnT/LuECdhjzbwpjFnJ4HcI+ufXyixHedRgAgPSx +9/NgC9JcJNERKPNpowXJZO8jUAvi1tYba61Pz+2fxypiZUtZ1j5vC1MfyWc7btLQdT72ULY9uusE +3k6LPTb7Mj416fxrBHPSALdg1o+s+RitzEXCPqDWLubtdEtZiTAe0YTWHE4voo0/uatc0u2+E9r8 +PmcPPM25I7Sx4M2jXd+8hwRWuPwQ0x5h3ES/brj9msb8C4FxC4pw0UpfMiJtlM48noHGLGIfrz9L +Ylen5T6toHN5KUQd7n7lN+GmmY08B+MqLNPrwDJxPDgvjrFCpxEtnBqob/p1Xcflndd20sARYpTH +giJ95OGWGCmEJ//2bIy/HRjcjJJpIyPAAFZXeHAtNioPwugQIaTkTrd4XjZhqyBIgUX/prpIrLBb +gaVgrk1w9fXNPIomwlj0TK4lX+4GxFzZEI0FFnmN0S9AMiHnA8eOfBPR5hjlmQsbu+hNF8SibeAY +xZL9hilnf6WIRxoenI9W2jU7fzLAvWn75eFuo1kEAKHJ8WCVRUB3crLPz2YHqi3aXN5l5A7bvREj +BuULUMeiH3HN9Vkn8Gj1lSvwvjsr7+HaNLZW7p21WCYV3DiiTbThN7EGZGEBIpZdXqtMZmAuBUqc +0IhlktO7Ce8hws3ScRh6sfz8s5JYdjl4IhBG4ddiWeEw9xsSywBSyEos28Qslh++2tblatlzth4S +WN+mxPLzD3KYTfgRCbJsxbKuw6wqlq3yuezEMkpkLcePTiy/jZaI5ZiPnlvSiGUA7snJWG9Nbg8s +rSS7wOrDg0Vm/9JsRf1sl+O2PPlttHG5/7BZuf82WkHu2/mr5rdb3KgljnlDNLa9YTw7Xx9usrMj +ZEY7NA4/Jb7vfPZpMl2tvH5c6qGaJF4/l3cxMv9Q3azXD/OUdL+fDcGumEqKKoSZ9VhERqhSSY1k +kXr43lq+k2pkhNqtCIDSOpUNbkXAmE1oGGGcmAP/zoqMJYtSzn6VXiLTkG59bFKvl2baL0tRQtwd +OKrXKuXMPL3OZz/18OboZFhMTCdYnJf7qtjSdYpUrPMafEiWgw+D5E2/nk+FpMH1Ap5md2iZb8vi +xm1PqF96c3mxejrrCSX5V0/oQs6qhdMXctUT/Pyq4I8wtuWw1DpN6q3xBonDZPm795Ft3J80cC1Z +rMisZmrl40LOPzpD9+rOXi7zHdrCKmpB1ZSUAuviWaWYDYz5XV3Sikdf9fNsPZRYLLa9OrnR92pJ +v+IBM1f3at+zFCtS9BtN38Mhq34u72LPGEsz81bu1XLExX7NA7q1bOW+KGce8lRrwQuyIlQjnoZk +Qz+7StnROBYYG+4hsS/kFR4+C7P7CewKeQ+3fLaFvBizMGwJG6YAL3AY7904Aidub/+I02c98m5f +Z/xEV6PdcyggV28GY3KDSoUCvN1C67PpXATdMgEH1qtlfftV6YECd0z26umUYmNd3rnCf3vwSmsX +Ru8fHRhojLoeG6ux4ytN6vIa1o/3Da0zqeAvKpOqroXCQyKW89ZUGJRYktgflhOHnckDjn2bDew3 +w8lr9uQe2qZbJhVrSTgmNx052vu6OWCvwVsZTcXdnl0aRkbX6hwyh/cpyygX6hnnbT9DJNEYMLWv +Gl1wp9AAZ2clFXcXsOxcqGILHHKYhYKt3yTwZywMroy5sn4Fk6u4R12XQ1fDu6gTrkYq8xHe4u6A +LkccmB5dyXJghXxLGuKjrUyZVwjtq74tAtoOCCT5lsuqvqkSkp0QiLOoKFyIBv7igJgSy5ZU2C1B +oBVHqwb7dhwtq9wISmGp0nG0atCSMa/ugX/Nru6gUSq57OLtMOJGEsu03c8+Vx3sXCofZTVkmYq3 +DsZWj8lYZ9pjIIXWs+NYCQ1HeANRUQSJMvJOA5RTloS9V8geY/YRiOX2sNXpVXZfO791bmB3fnO/ +Ob0WOSR1jio9nDqMUue3qHMUKUq3csSvZ3Xq1PtgLTyFzj7mWo62It5lsXTHCh7QtxM2FTzNU72C +Z3nNCH3NqWNRhjqUGk2gKpSkUist9TbLvL5Tytt6qEs5qXXL+XNgX1tsWcA4x5NpzIu5fVmUPr/e +F+dLgFbdFzqVdaV9obsJaJVqZXPYCj0kv7mcCauVnSuZXKsdQ0rl1YzK2W3zVoeG7k4gClSqOgwi +0zH6uCoq9Zqm5TWJKxvmk+MfKzGo172aBeH6hvnk2CwG7Whsptpb00H7bCWTY3anyg== + + + wu6fUTK4oKJdvHOv77ZHU8OYhfm8tvE8OTGL+bUxRjK1N4IxOtaj62N2xDDGU7kop5dYjvYgrWwj +2wK1GBCkAsngUZwBRcVXKEDSbbblZ3/ewrYJUGKQaSFlxto/ZrKwna65GX7YX3PzMm6bkxhcXmcj +fEkRNOU2uSjLZH/MVudKwJki71/ny1NNV1U/YTxUc2jvhXOq3+JeJj77GxbsfUpLarRXYS5OudZY +tLyOB8jCulF48vlyBrH6ck1aiOXtQBZycUnJMoU8cy0e8SUIdDjitgi01GDPraozV0TgnO7h8qrV +mezF2M4Iv/i1C22+sp7NL5gf69X1Utw/ttLphhGdXWgu+urMnRhrvuJgreonwJhDSRZ9JTR93oVT +2TF1FcbyGw6xEnoThV0uLwL1+xxUFSQbF9oKt50Y9+9iungVwpJct1m2rVOe1oN9EBFLQilreaj8 +9/k1k5mNGRFaES1Lk51EfRXCyW10b+Gum5XuEzVV5tpehbBaLU9+zTxmK4x5Hd2vlJXQs6sQDBHe +Ncuzac6ai648+5cpzKq9j0DRJIFSpoDmrSNWK2bSWSYuF3u2GjreBV17o6rGpzu4WFMaNitda90S +gHCvFLYy1FjZlomWf51XvFApvJHbgBFtiSnt7juhjTZ25aIqX/5tPZGijZNiY+p7ih0rvReM7LVp +bKWbEVzOhb44In2Zr6U0V2ZZLPT9avlsv4zANHePaOr4dEE3k/u2NxB8tRwvTHYMNyla3wxGjr7e +XB/Rtn4dxjugvrfHdkSr+vWRla4zu90US1QXfFhWx4IqfQTFpCFErHGY9eqMaS9ypo6MYLVrYbqm +wmNTKbwYa1mzuJffzK1NpHh5wb9pnWlPU77sfAWU7fpUzq+XLzuWKlBXeoc3R2M2gWNT2NgQ5XHO +08eqb6c6TMtUApRijiUmoK8cH9sEjkmBqpPPwbVCxOO0Olxz18z+5PRK30Ogqv/Y++E2mUWQts3d +mcsioDo51eGiR3Gte+HSK30UwbF4+W5Aa/E5rW9Td0Mpld4L3sO1acz5ywj0lgwZj13re0mOYnkS +WHYXNGiFmxTLYCjSaxfLqeieQizPqjgpxXJt640yZ84olpdVCm9GLAPaIpu5S40ULy8Ry6abJ53K +l9cUywseElK+vCGxXNu63NDNkwRZTmIZ7f3VKj8BbSuLZWqPYnFZPhcpZF0ill1GK4pKLL+NVq/7 +tF7LfC3watmKVnWfCzwZetZpvlpEL/djPmGjch8g/N6hlfsUt35jzfcKdZ8UlvjbiD6J16buU/X1 +kfp+2spP6rrPvaM71vnsr5DpOuf1q49NXr85ywJLWTfo9eNSD82p453DK6aSYuG3zXUFhsiI/YUF +NmRRH9O6Falvn6tu+va5+pjarUhzXUE6HF3h7NOVLK9834X9Jq96XQHF2Qfq/+11BarcV8SWzhuO +xRKfvBkkaqluNN87DDCZV4tjMftQ9eInqX03O1GsmC5jxXTB5fWEpNCb5Yeq9ytJcc0PVZs+U+3y +/pEPVZs+U004/+Y/VG3q5/L+kQ9Vmz5TvXwta3+o2nYtG/1Qtekz1XgTxR/4ULXVl743/6FqE3Au +7x/5UHVg/jPVsJY/8aFqE3DEB7v5D1WbPlOt1b5t+EPVps9UY5baH/hQtWlS/Dr2H/hQNcJg+Ez1 +zKuw2Q9Vz0sfowd+kx+qXjVz2KGM0uZD1RaRRINm88sPVdsBZ7aSaD9UTVtAPqar4V3vQ9Wm8Rbv +6nQ0uWg+VL1SDS/dh6qdSUVZC/WHqqlLluc/U22fb0lLfJYfqnbOt/zth6otEGj7pe8Vk8eXIxDv +7KK6LJP2gAysvrFjVWFHjcAF14nTLQEOZu+y8uwNR3lsyrMp/HYLX5Te4P15enE27dcZnDJLlxdn +r+KDtSnPXgdjm7ky11Sc/ZuoqFqevYGsG4rybAqQyL78rjybojjbDmNrOq1sirO1L0pv8nKFxeJs +my8ZrVKeTZ2j+KvybAqPmm2Uh748m6I4Wz+Va5dnU3A527XQl2dTf7X8V+XZFptoLs6212FWGNGx +dtFKiq1Ynm2gWrvi7CX7QluevcK+/KI82xKL87GGjeyLo/a74l2dVuXZv/8CO015NoWyoX+Vae3y +bIribGM04beV7vbF2evdaj5Xnk2BSrv85BXKsymKs1eOii6WZ1OUGlvl9a1Ynk1RnO1wLxxNeTZF +cfZ81s1a5dlrY2zFCkrH4myn80JRdkwhpV2UQK1YfWkCaZZtu3559iJIFnnjvy7Ppqys/2V5tnNx +tjHXGtfaMicOUq/U6uad2bezre7oNn49m75Wfdm3s6m+J05dNm7HmEw1VrTgrfjtbKdM+818O1uX +yNZfz157N+a+nU19k96vvp1tpcEuq6OmUmkWlmv7bfRPuotcHAvRSRU1sffX8Out9u1sy7s6qRFI +p8jQ36vwuVAZR319CahDBj9//s9VjNvc1LrhinEKL9wGKsYXa0X/RMW4PcY2WTG+gRsOKSrGaW84 +/F3FuDHn6s9VjNN80eD3FeMuh4SjzVSML2YQ/YmK8VmFnWWx8aYqxvVK4SjlQVunYnzdb9itVjG+ +HGObqhjH/OT1a6doK8bNsdc/UzFuWVm/8Ypx+rsIflMxPl+V9qcqxpfljm6uYnyluwfXrhi3/VrW +RivGN1OX5FQxvkJd0i8qxhdy4P9IxfgGaIyiYtxFL31/UTE+R2N/rGJ8lW/Wr18xbvPN+g1XjJMb +QTna6Oq6FeMu7+I3zzdfMb6hGiuHinEDJdOXpq1cMa74+uxUnk1VjCvaBb8ptNmUpq1e97pOxbi1 +72LTFeObo7HFWPbi3YMrlqatWDHuWsl0Wbdi3Hxn15+pGLe/qXWTFeOz6qc96vvX1qgY/81dN/QV +4y6KD17/XtnQvlpOUdLyi4pxu+/ybLZifDmNLVaMr1rfPXc7kOVHHzZXMY7f4LbKl95sxbjyjdTf +524trxg3c5g/UzHucvZEbKBifMZh2C3ar5KuUTG+5t1QK1aML/GQbLBiHLTxWc34H6kYJ2LZ/gsg +m6wY178AssK3gleuGKeIjGygYtzCSvoDFeNk923LiTdVMW6oeqZ1WK9RMb7eDYerVoyvZImvXTFu +cUfEH6gYJxVDd5v8NtKc10+tGHd5rT9xv9mKcVjLrGb8z1WMW0ZGNl4xrkdGqN2Ka1SMk7w+20/c +b6pifHb20+Hon6sYd8i031DF+Er3j61dMW5z/9jyivFFPC2pGMfacPwG95+qDtdrw+Hs/7HqcL0f +YuxPVYfr/VzeP1cdvnwtm6oO1/u5vH+uOlwvtl380vfmqsP12nC9amDz1eE6cHNfYd5wdThdZf1v +q8NNlfV/qDrcsbJ+I9Xhepk26Px/rDpcrw3X5MufqA5XRUK3PQWM/bHqcF0xVK2kP1IdbpcDv9nq +cJMO84eqw80+pT9THb65L+Utqw5fo15sjerwpV8v3Vh1uF4bvkZOL3V1uL5cy69mbKg63CKj+w9U +h1tmdG+8OlwPYzvUWfyqOtzKStpYdbiGO6s6iz9QHa4jw+VIT+tXhy/U8P6R6nC6/LHfVocbswj+ +XHX4YtXzn6gOX5ajuLnqcKcI72aqw/XacIds219Vh9thbLPV4XptOE3m8LrV4TbZgxuuDtdlvVrN +8Ueqw3VEm+5V2Gh1uJ6M5PL+uepw27VstDpcrw0309gmq8PtdZhNVodbSbHNV4cv2ZcNVofrteGb +3Re7T3f/Yl9W+HT3Eovv19Xh+mZb6Pwbqw7XNxtj4n+qOtypinMz1eFzttgfqw6nuleB+SgIz0tR +afAbqAs3xpENCRIur5Yi0WvZf8A39fC6+gdAz23PfvtsU4W8lLdq6NLeUsOD9X1TfQH4nXtFz1Wn ++MA6kFLq4cd8K/ZKpZwLGFuxlNMOY7T3XThjbPHm3xXu7Jpbmq0JvxJIJJL4RpWO5Py9dFtmZZ/X +Z4unFYtI56xXE1Br3OJmF+giX2Cnrfek0PlxpQu5O7jSOZ3fwlK31/RPfJmRnaZ/brLTf/0V5uxC +GZoN56er9l3L6Wh7EziAt2AU/8bpCON5V/gyi6PT8dzW6bg8D9Z+N/ZWOjQOVtL5eldSLqust0gJ ++90nwGcC0eXdxM0Jnwvp7fMItPkO7xIELknctkWgrQ6DxetOyWHUCMRZsHjdyZ5QcWchIS0yRsft +JbVv/I48pKlsoPPB9i6sdn+NrMCLjX/172KzXzQALrFwsNcrfdbzvX+LMccP/tH5LbF6ekPfSL0g +Gd+/zxsnIFmkelvd1EqBJ0c/03zKnlLLY5eihcXrv/w86sw7Olfsxp9UJhkb79Iwv2aWt7UPlj+5 +DZhvgFlnm2IlLSrqlFNHK95jJftjtsaN0/nVE7xtMXbk3wjGPFq92C8TqfMUSWR0X/xEoH6T222I +8eWtfBtr4skUNVoe5XFS8rF0nSYd0LV6gcZwScIClsZaHNy1b5zGuBB1kY/L61RTTCdzl0vcue8j +n73HzO6W9S+KwNJ17fQaIrxrfWm39kZzwYOLshSbSvDakrj+FWasW9/EbRFK1fr8EV73Vg1StR7c +HI2tKn2tZK9uv5AR69Q0tkLyeLmPPNnGj4iOHqoybmdBp+9+uW97HdLqYWyEcF9nmY66pWFEuzIP +MuLSa3VcXooRLWtT95ORI7simFtLD8n6sVAQkxTizUVzNgDuHA3x2TruF+ssgAHQ3j1DVZu6nywu +3j24VvnY3WB5berc7juWYu+vaT6Z/MmEOjZTm4rl15qz9LfyBavWnWtTaWksvpAgYXYiLctAsPlm +vQXfNDtCKArlZoFxwpO1ezoAj/u2yaJs9jlNYxRa+Rws13K30lVZSyuKKb9dSx01A/N3o3fcIYyr +3fdg/33ku5Xuy1peiK1V1/76kga7FCVLi8/5S+freB+svl+JdetrXZplhSyrexStXKSUH8PEEe3C +H1Y0tsKVEbWt0xM7sXyvi2UHbkkplp9/lovlFeRLbeuBxqtpJZZt7iGB3ac9dzRimdS91jfgc0G0 +2Yrlxd13/Hg3taavHz1Lnny/MbGM5dcgljdwi6ZStb5ULK9EY5eOFzzYiOVl36zfnFhe8Chi2DVo +K5YBxlsa08wklu3X8uAslqkrV3Ur6W3kqFgtfPPcuX6d27TcfxttWO7HfLQXSnjnIolLyuv7v7xq +cd4Sf1jBEaKOaIs7kxuEourZWUxi/brz2aepYLfw+r15lnn96oaPECy3xOm8fh/psIONiH4YmysX +lpU0fzpduDCfgeuiuNOg+mu34sI9ilY5Sb9wK1Yt8y3Xvn2YlK7TS2S6z50fUKvXWi2PjdiyTC1a +48KF+bNfpfHzr2JN6kIL8y0LQthebL2M2w7Xg6nLWPZdiHnr9TZ2YDsfRcTcdr7ZjTqqxxHxWKhk +6weNXrLfCA2Ske700iQDyFSpbktkEoff18+5/d1rjbk0kruZj6GfTebvHwuzfQYrSQ== + + + r7xXT5G5+/uV3l3vrNRqqTgpXKe6kodNX92XWrnD7HMY1nfvy/lLXDLxk3r1YWWKYg7MWk8aORyx +mIhXSlOsjz6TQp7dafY+de+ZP1zFTCNWa2Yb79niaMSNk5799qh0EPLGdvn7y0gyIgbGn+cHg2nN +5d07a0ny/snTzuOW53zi9yRzNwdb1VcxtlO+3854v/vlwl7rcxgSy4Wft+h3s9BOfL9ffeZbZVm+ +ej77uSuzw/xH+bPU6d6eHlxO795O/b63t3TA/1WNfF33ioH4h8s7DDwmJiNv2bc3GvE7nq1Ba3Dg +ZXY+4/7HQuMuIAcufcc/O71CjHu/OUoyh4dbo9FJrOjZfzm99HCp624g3hASTI45OWZylfscc7o9 +uGJOr68+R6POSWg0/TwGbjneC17Vw3xBjiXL2+09UkIO63vOhqKF3S8pepLOp7rRUoAUb8NKKxWA +odUMWFy4YJHnoOyky2t55YK/05U9ga5Qwul5nXRjXG2vlDgMnQlKQfte6ufGGsddVih/3u78jBJ9 +8crl9dxf5QMOKJq+h3f2d70PxR0p3k15i+XTi7338vmRIO9eirCqlCdZOaifYIF8JXB0ELpH4KKJ ++MtrN3Ph852Qr2NXS0z2Lvo2Grcvthmu9LydjL4kWpnz3slDIjZ8OTR58oFHXv5kg9I4LBcvSp3Z +6TXQOciFYlo/FC6vdixeLnXxznDdyWH6U7yuwl6NX5OwF/dz4zx5rcY2433/JTf1BD+/HvC+i7vX +rCd4ef/g8YVqW3jLxQX+iHtCSb7oCR3svuI2HXtC/dKzJ9AIy4iOSPKm8ryXrTPxKBk7es8zTXLz +Bfkt3notfgL3vffBqrYP8Tbgs4+XTGs0CiZ7g8IYVnX/g23NXDrl2Up8bSe76U7tgGWY8ftupn79 +dpWUgsNBIHv3cAadH7ZgvsA7ov+ceztrBhn2ddub6l2/SLl0clpLDMdsXfvi57HYCGYbje39RPzi +G459Pj8hRhPDTSfbidF2c5QKSd0rht3zt5Plxt40WdqX7pKDQbiAiuqOWM3384nYdfor+x5qTxKH +J4I3kyrcNXAtUZc39/52PUxWMo8ckHvwKPPBVPFaD5kla8U/3xOHomeEx8I/a+sd+hOFcqrb3wvh +YLe4k5HU90/Mmyold8SUMAk85XyDdzbzEXq6Jpz/XQCiak5wnGrm4+U+muomujyOSOJBnvTnU2Ma +uwzwT0gHeQI8kFfoIpe9vJNynuBNLvfmf8qLk+FrEfbqJAiAeHynk7dhHVb1ICBPvpgGEvGCB+/V +3d/O5PNnUXh7Ozw3jm9P25zMCBc+zqVboaeUEOn7CQloe/rgTX+Gzptn22FvVN9nPPvv51sAfI8N +ZILeac53dn4eu0pNnzLn54ldvS3e5qrfqbPb/o8yHzethmCRzS29i/gofj0lbz7ao8zHwc5btrH9 +fUKmgrUAAP5c9uc5ltv3BwPiduyhnG0ED0Nzi7ziYNJUn7iOdBhT35c3B0AHzyO8iyBNeFvmI3Uv +5TKRRw4IqVrIZTk/6DAGdHDbb98JPnXwpfzJtqMDgDa9bVhQ/vF0YAD+KPdzRnYNtuSplBhNc3tA +DNU7hvdsSZnw9WeGbCLoYx+9+E6y5Km2YRnRi8zF+3gX5N3RC8MFW92UmLj/IfKVYQfVLrCmh0ny +mg2V1c1pDktkf9UuqXorcfdxew8Mda+QKlVPGYIMQmMfsIM3vXLu+azQSl6nU9VM/txzt/CgzVyQ +033kCwXfxWrhNpF7be1UM+fdwFXmYzA6VhgXHy/vptqPpbv4x7SYRsJ9hrOPh1PRrggLm3U68k25 +99PDoa+We/fHMhhuu1ZhfNr/zgY6jxNxO339tgCS2JzAvpzswMjnfTwvd2Qtzy9HL/nsQaYd8tWT +khgN5zLVShDQFn1iuEk8KRe97Yf4RapxnzsZnxZz73fVJChTFQGPVCpZDu1cpi+P+mmVWzQK41Sp +dH2bavSnr+q+SP32M5+tlx5QF8yHxRPx4TSdvREmKgnkq9108z54n/kojd+QCd/msuxoJxOs/eAK +HkOZg9rhbqzd37sFuCK+TGt8Iqi48wgyUYJAt+S5wiT3FryLoRpbMpoNVr4prnAPxBmXcP+KtDOD +fLGYe+WZc+nPaF710CJHAz6dq6AElMXbI7wVMHm7G38nnfAukXt85yLV9VYq6XZ77AG4LyUET8o2 +Iu/+6F23cKqfl+hd6akCP3q13OHp0ylhZqQtdtWOd2KdV+kDHrCwFvVAAgCZVmfwdOo9ff7K1ivZ +iD4YcLTUrfhQG96R7UbiLGdaD35+9ud76ps78mhC5GwPr35pprrhmwBYQS9+QmPZXaB5IZvztU5e +koPP633VAtMfNL+esrVaRD6Wz7mBgtnLs7vvxOi0B/qD/7WUCd80OPJ0XudPI59+gbW0PytvoFsn +jyx02ZjBLQ5MagtY6+1OIj7oVVPXk9o43op5+4oFdj4efOTeC9M9PUtAb5vd1nj80yNX1YDiGN2L +7Q44ARTjn7vEwWQ/E5AjwiH8dniROBgPT+DB5UVmWitew4Ojk5y8c9NMv1xsnxEFK3oX2rrMvV/u +RlWn4zAJVtL8Mb0GkLlptvF4RITjDUixwxGezw7uwTnoAjxPfBd44ivkyEXjjYeQqV82sC9+iEdf +9fNsPZQ4V7I7duIfZweV5DUzvERCO1dE+bTH12HPfyrkphhyKxdwgYc0UWjhnAs+YKg/DaJsHIbe +cwP99i5JHhx8JMuT4TSZf/RLsBYkP0PrTf/7OVvf3X87O3rm7xV1+PrH30hdT/d8yMzOMh+vW99n +2zenYeDyz/d4MdBPznfx5QO0DBh1qGmJUCAcXCZ44PKysOXHMJjMAQNsbwMf37uA/f3ZBUWm6kve +dIf72cb3jwwaUDKEU3WIiILDEHwE9p/YIlRCrhc68t8HOgQtZLnECsTPI4XVbFv29DWMBS/ZrVw2 +44+aepqdFWyl4wOQmE9QjbY+U6FYZkdhlLMfYBS2PDDAzVaydNX6grMvtKeNeRLA+wKkQeZi/2kH +hmgNDVpfIwVSG9EvC29PN4fBx8xzLhMUAwb5eXJzeJ/z7b50svVyfpoNFMJKpXDKm8mn3vncc3On +TXYf21hgAPEJKMHXHrmbazzHW7f+TqrxszVSucXO1jjnL3ZigePo3Vn6/Tu1n2m9Tx9zb5PPbiKW +89ZmD7ZcXmApL8cKD3kU28+gj+UN2gxYP2I0l+kGFUGIBzslTvKTo9xb98CTiGXjxaQcz4e03Q0O +QPdoT3PJXiyo3X7Uvp73Wq9iNhivwQvtJMb+h61M/uLxPc3e9sY5z345pD/AL0tefLRhzyPRlBhk +H3DEi9Q3W2tkcs+X7Wzg8/URT+A78TilO1/iAehM99PoiD/rpAqPgwc4i7FnEOSfO8Ajr4RE7Opb +Tl0Xhx1QaWK78tfI8+TyqqSksLAPJtXtDUPK0dUV7MdGixmNjg6wyzZoLh95llC8PphisOxGBvr1 +WFWQcjdbOX+1OAEau06HjomCiRufRMM9hBYKo8O9ON8ooHuzjnzdeAfw2fYkfpLbicRhsNkkl34R +X8H2jzi9dHkNyuTifEXDDVx2OFHuvkrvnGRtVwq7r6z1kbuwWqvFzNuOKx3sm1ZK/DBWawXb3pva +ySxdaYl2pWBX8udPPaPF0GyXTLhlcw+n7MztlIpx9YMO2mw1NCC+iDwj/EB7UM+bpB2efXgeb3u8 +X9lG9Z1LdS8OemAWHkfQ45jCjwsUcu+xgZDzyaI/GwoMhrqNddAJxvAsPsqJ+5J3y/Ld1w+s5AJG +ko/GOunMJ+G1KPJ9yDyD8Y/g6DHdvLu/VC3e42wQDTcZTIlTwGKd2cl8fJT4mR3rz4TD58E4c/Lh +gS4Hr7psdnnl67v2de71eaAIodgV030Tpzf8Pdj7500Ypxgh3hC8bxF08OHTa/K6cPaIqn0p984l +IwqNHcZ7Nwx3dj3NnE6irVQkE7rTnwLG4o3rS5BExQFIIrkGnLgxVuAhasD0nTXc9mcECeSnPUhP +I5CzM5BA5zcDlRmXbYEKxLu3V6uDhLtf3O3ZAKXcI3lli6f52wqvwIZ6207ExqEBbvxZNnA1qIBh +cwUWX7LYK7dz6cZNGv0+j3jkuHTnKBWwnPSmx71qzuLMOHMR2N9OCfdcCk1PJlke98tAVAfTufUl +eCLF/FOQKhcPZNq5Sf3PhnNnNAA7JQWpuWSmYYlyBanntQcyKdiVxmljrPVOT45/aHd6YVKuXTJE +RgxoxS8bF3S0Lq7PFqkwaeJ+v0ZAgmMWfCVP0T+mPce7Sp8VoEr78Wcr8rICCXSh70s7kF4JSGhZ +2AGFmDABpT/FOzhfaEGC86IDdVKZXC0Hak2QXN6VgNJBwrinn5YdWZz9ZQxpTXZEfH3V4UrUbzpy +6oGc5J4tJ8XjiDT2ctFWVNq5jajaHMiX2rJzDgfO4pRjnpI6LF7IKh/j7jcsJn3Qd9+O5LoWrOcE +bwS6ACm2ucNne/RA66Mlqo90OLQmm4Hd/xMCBUjqc6qTlI0UW0JUR5z1sMVne0rV1rJkWDs+XXz7 +oT0AQGP00LbGtsMyuZR4bQuryzveyrUZm2EHnvWPK8A6O654e7bNgV31uL63bY8rruX0LLVMLFf7 +NsM23myHBQR9GbgAcpiFYV/smMuLDdWW+9YnrCAc6XFkI0fgT24LBQt0vNpsXXVgqSkFC4G4znDI +rebKBAkuVWXPLSZozaLHX9n6wQfGNkqvROlW3kD/fOr7MjQBdf/5PtvYFncUV/j1q3hMwhHogVfM +WX6XuInU3y4+vtEPc8MGvqN7DJtP9k4fTo7qSeb4oqc5Z6Gtuu9ppD+fUt6Z77+L8ZwfLb7kF4l3 +BTO7NL8QrL8bRhfNceajUsJgzuN++uPos4iGu+KwP6yL8X7q23fzEW/tiUXcqyd84wIMlrO+4myC +P6VZXOgZzDrf9uyrGaL/Z2YbfQEXzDJKqIfkTighsVz1VQkVsPnvSS7BXNwCHsKP6p97mXsllKV4 +/LEtefotkKgRWuJq3OgcgxhcsnJ3GwC6ewkYbRowOQ5Pu8fVbH1wFkoWm/GmIVjF+/vbYMfd7mTO +u7e3JscnCQShlcTEo5pDNzhGk8urhE8OQ/et1Hfha6T4B+eCObXk7e7hMWz33fViQOm+q9u2JCKF +33ycj0lxZ+mhQiL5armv7fTkSwmu5E9+BD3yg9vZSXde3zit7TEOW7LvnwWw9mHNzD5Sss/vM8TF +Lr62f8haovf8Yc04PYnHPo2F1PfeaU4z631eY6ArffyilmvNXmPzVZT775feLkasRMXi67xe9IHG +RiLG6bbk72QW0ObnZzHTBw8cvvxohp2JEj0ddRp+DdZ7KfHA+MPan7tg7+d8ecaLzulLOHK1XYUY +mrvBfG6fO+a0bXyU0Oru5N738i9wAo+2SWQE3ZgZA0sBGkqA/f3QS1Yus3l9c1xezQ== + + + /+uVsVMcWj1fydIVaJkY6tHRMYsgyXgOCkrwCO24+QfFRLx3nDYEfV74bBdsZOKA04JCxEFV1UJG +4ihRTudvQA/xn5MoHjpBJQw4PGldUl9JqfH4kDl4KEWVcNosGAXblPlIxJ+TF4Qnm4GKYrToKNmv +196V84K35xzujVvtrG/rrp3JeT8u5gNKF+J9zz9IDobDekqYpkqmiJTCYT5zJ+Pnu8Dx9uE2vnMG +mA/siNssc39wWf5GHfVkB/Sj/SfVEfJ+fgyc6mRsiFx2vZWSIZQzH4QBi6/16v8A7SqHmTPbEvqg +B7MY0d3Z9s1RHInhEihmb0LcEYpD15wHqmVuzYIs1/qkuJa5aTc+Kbt3gRbfee27uBjb8l9IJVk6 +BS7YqpDAuPoOCcaNIoVUKB6PEe89MArvNF0YTK4RzKF2Srhp+nN6U8HARA45jMLCSGvvK1lJ336Q +ZcyOoV8JtxWfLp6zb8PmF9DiVkQbjASC2Ex2J/R5z3Ah3yRZDHUraswf/yxdle8wMuJvXish++/W +C4xTYGup7vd5WQvjA51PfOHLxfi++kDc/vGUT4c7hyL63bcQqYVovHF7Q4QWSfZAWQm41aJFC6I1 +1u6nSing0lupwmMpqbJWRbqeMBhFD6NQ68/kx2Gq+yzHCAx6nGYWf+metnOJduJZOQJkG9lU/dMU +0VHjNPL4hHwyQOmH9/wnfhKjQ+IdVN+VO57sXn+3BCCxTy6vOTfk+DTvI9GLROzB10lxX2E1Jq70 +C4Z7Sngk3SjHzCGTdGtag+mTLVX3eKgWsvVws4VWUqe9rTiWQDiO1SDN6O5UTZBIpTygMBwntFCP +b5cczePdcqwTOK4OFE1BCfoQl+xD7eeC8Omzo9c7hhAX0cf0AI/gzZxWE/Vk/8QzyJw/idtKyi1/ +6BOSkebpbeLno91XL/h6mISVQodOMBZAPWqQrNzv7GffxWHD0M/iTntxB4DK/aAH/gsTaUZqoHP2 +A0OQmon31MzWvc26iQQQTxktEUqVj2QtO3u5zHfw9Oj+I51guO3vj6z/tdYGPaMyzj62Jruq0Nv7 +8CYOI18dZMcvChcAZCW1lL5sH/NdSMpQEiQJxyditUI/9fl+iXZlJ/n8nq2XqjPZpgV97t+PK6nu +Vj9HojyyeOpvYDgGtbCHDHkQPbwX3zDtpYMh8lI2WPk4MMCFn6AA6v0Za7qlwj7k5Hvi8CwdxsHi +amhY3d9YshxMgLLRqUxIsgtqzJdaduT4v49dAsMKbiHKiu6Dm2m3NboeddqdvjvoirsOkucse9tv +DnKjVqvS+s8kM2hMe63+xB1zHyTL6fNzCfhrY9BsQXfvXDyn8aFnOuppV7QxX8sg/aPYe3R5SehT +zeES42PMMPWBrGuPF6LEx7X+affuq556vywlk8E++xI/Ye+kzHZzms2kz55ftCjq0FyxBKLIGZQV +AAHdPji8ukjk5fGxdHZ4H84NHgVgrNnR8yOTecxVK7mj5FHDCh6NISo6z9dKkfOZwFseORfqB6ks +d5YgQfPEx23lKnkmvl9RRc5Re1dVBEWT7/a30KR4UyLit6+5GvD8pytDogS2SZXn1H3qe1eaaCcE +j+VXp6bwx5kQ1APgbLDdPlaYkS9br3QOM/n84d68CVMAtb8XxByeoprIo6RHvEQTsWtfCznJKVE0 +NTWz9pT6zpwxKg9nMi8khIRhp/RTCxihvK9EX0h8ngTkhffQi/IlF9x4NVyvpRLqOVN6WyzPHhzo +gRwlf6ReOdxGsRp8ieTejpM1+4w5e6PncXAJyziVVaEU8vWUPKrKxVRWRYh8+ePyJkaNMFGkJ9lm +7LhnYbj00UwMn748+2LpVrl4OxtnlohmCAKWrYwjlzd2WSudKOaBvtP3l8NzAvycDXSHcfeTH2Nb +z7eX8zWeZ+zyBZTP4uOBIeqO6QioVPWOMDmvWwWB+CIbktfQqkp1Wyk20bseltQw3selrKf7YZxw +V8lHNybtFB7A0mC+CWtE5OfwEz6RgYRZmSJIxZNbEA3j4JzhkhxlznOPW9qfhwB3/uHDuKDGjxfU +ndeQJky07M3rglgiGYGouIeeMOVd+diaoOkWJGW20Mrkdv2lVOSuNNEyygw+EYwEHqN0vP/J+c4f +bmabc6mmuoYS6J5gdmD3MTdAswwq9Rk6QpqZ4XlDFfBmMauNPDg6U3TDxWS5C80weQ7PJeeh7UOU +Lu1oPj5ye8e+M2OXe/kj0w7kaxa2y2G2cfyyDasPPphAArFaehx2zGL+ZVwvgfWSDYPpIbfErdxb +CbpIrOZveX45er5KH+WSjXYDU+Su0vxR5ZjYuEoCByba6VYMWct9kFhBhgQ7dvBzBiRXJCSSydQu +Lm4T8ZPpZE4rP79Pd46OYwoTBu39OxEvT4qpkPQVSHXD7f1ksfFRQLjK5FNkzcfsY/MCY7Avx5ge +gihq+NKd8SFL6iTmy2FN18KkNPPg+9p2UnSmzE3760nF41vhKskcTscqHzt4BEpW0unZg+3xYeA2 +PlI6oXZE3lET4zBZbhZZVlMAX/NZ4xFXbKDgI1ZonKksDNtaA6EBp3LBelET8UwJduoJROvlOtXL +qZuMVsDgIvui/4kZna3UWWX7Ffc0jSkfQWK0n2DKSLo3S7W7RLfLQ7J/tv8zy+vSH1zMvvU10JBa +64FmXPlBsVVNxCs3Y+Xp3AUcqyfMcIUK+t0+QUQNt+OtyvsNCNtaz1yaUrmYTGdyXy9YUT7seDHF +xN3D0Yib7Hr8h1eCJ3Swd4cp9BnPTkY6nGXUn+CDC0/wZ3iND04wwb7pCV4+nHn2f7ZHsC+XLyYX +J70RtroJhqkzqxphq5tgcF5WNsJWN8HURJCVjLDVTTDtoodVjLDVTTDislnRCFvdBMOSjFWNsNVN +MCUpfzUjbHUTzOVdNMK0mljiifZXR6TqoZ87zDVZs0Kv2AbG4rezTMszDOIZaiTuKue1XFYqtZRy +39zsURv3PEw+5KoU3UrcbS5ZnmyVcZObWPNxrBTKGzKq2qXXWXrdrVVaHGoXmL71Vpm8ZANjfnfG +wpZngiUcM8Eau0ZbbHnWG36is7Q0E+yOIhNMS2jzTHzj5ZlgzPlzMKxFkpalCk7rxR/TSkHuO2e9 +2a50a+v45HTpSm/nPnW5NOuNyR5eZx1W2tqKHNiuVNt9ZRmpg0untMiz3TNjcdjJaSATDouPxGhQ +5JlS/aA+uCfSjhTkaPJOed7bAuMk86Vkus1y2fb53fgTO59e92Wwqy4i4bieJ2d61+VV3gbl9gvs +pdhuLlnqjWcxpQZ7+tpmQOa8jlDNO8/6b8/HimoL6ucNBu5bWAHYIlFivZgJU+7ec8kn1gPyI/WK +7lq9sH2+NsY+2sy1S7TRZhJrNiVOhUNrRZtfLpcHwNHe/2XGCgVIJPBgCMlerRnsXxLqrwZBVm48 +L6+2dXpuymExpM44pUYZP1JtMPvSy/PyDGlAq+TldW9WT3UgsnJZvgdGnH6dFApr2VwWFl6BPbYC +yeWlShb8ZQ6P8ZpCI1Cx4mTt/MVFkDBM+/vEorvBcna0/OwvMKQ12ZHp7L+8U1C/He2/2uaqkQJp +Mu062WpW59wqVw3k/m+z1Shy1VAik1yamC/4RzKyydGb7f5qRFW3T9SiSP/dlECZJ6kW8fasS1R2 +qU/vZkq1Wsvq+dPvS9M1HdOybaFtLMv/ah6YBjWnmD/ZDfvxG8wCT16WXLrmcU2Y8pXNa+ktT5dH +dvxjMWwSTbysDReoPitrsR8W7Zd31SF06x0ky4+eSYp7v/wislmpNrlKH7wSp/l83cmLfrOBegH6 +8rsNfn2zAWDM+W6DX99soAbpl99t8OubDVxeirsNAr+92YAU4TvdbfDrmw3UhLbldxv8+mYDl5fi +boNf32wANOZ8t8GvbzZweSnuNvj1zQbouXK82yDw25sNMC7meLfBr282wFJMx7sNAr+92QB23/lu +g1/fbABrcbrbAAxgh/sFHC81QHt/tQsVVptUuc9gVh6/eKPBBu8zUEvKrW402OB9Bvq1OAs3GgQ2 +d58BXryl3mhgIVoNlZsF081B0jDIjVPfmb3PmTC6RWob5fZ9/g7AkL4HWVHdJnC5lExV9Au9zF8K +EM+cN47u9J7Yj/jopGQ5+L1DHEuGywO2qsJl9rHpbRNXMuxVXxV0IPck5YqfWUq47+ygs1XcnaVN +vM2c5kRg9vQwgybU78d6W1LknzvJSJNrq36B0vM2iWjgqVRiGiUmt783muphDxQE7yAIvv2pXmC3 +qgyWPxmWofMgljn/+jnjMqGngDGW0mxfZAPj7G7685kPJpnjaZQQl8ur31iAQraRhR0ZAPqDUzWO +fFS8IUEYY1TiOBuaRSXUT3ZwwZEHyed7vp93ti/aB8qUKvGr3e/qLBSSnt3Nu6uFQuDgoslBrihY +JIHPJ4Z9ufxMRfziyJgRQfJFMOuWI/EJvK/sKdPKPuwBEvQ06fte7r0w4MFw2/pMdfKJseoO1Or9 +UUDf4+5Xoe00DIpKqJ3zfUivWP5fx5i4d7hvOGiRA7meaX1dHDKRev4ED1Ioze0cvWfC0/EDSJ/K +VHvABJOV7G5HzWzeO+NzvnxSVyH2E7HsAXDQVP1E0S0vSbRBi2Tc1xOVG6mMmaEldX+1AIia4Y4R +R/2GgMF/H7viQEbnLPuW7TeNuWQurxdayq3JdIgdIm+pVrvTL9T+aY1crFv5j4H/WDfnjspuLhLB +fxg3D/8v1F2+xqA7GI397kLf5X07SI4mmU5j0hn0a6N/3DFsergs3J5n3DH3rGvc7QNImDfoDE/8 +mLz2BtC9uRh3Ev7/8LdrfwpzZ+D3axcTZjg+4mbCLCcL8E+EkSWY+tvFqIDBC//AHxfwyxc0/e0W +3JfupxfG3cSxblwCK4R5GcAWInyYkeDtntIWjUKTFGZFRnRjQ1SGhQnRaDgiwUwCy4Yl8prEhwWZ +4dxpl8AIAI0IDyUAxM3LXDjKiCym74UlkHxuXpLDgihIbkFkw5gCBC/xUT4s8xzMIQphjmOjbj4i +hAWOg8lEeCREeTfPywCaQF7jZFguvMaL4QjHRsjgcoQX3TwnhMWIDFBH5TDLsvAaQC1HRAXGKBPF +11gmLIk8QBAVwxLDYCc2zETgF5wtKokiaYmwLC6fA0AkjrzHwioFVmljYd2kJRpRWxgYkrREohHS +wsusSN7jw1wEloC4EWVWgLXwAGaUcwOCw7LMwS+48IgIA0RkpQXekyPhKC/xSi+JgUHZCKBHgl8Y +QIYgSWRT+EhUIDsHC5ZwC8jOMazSxghKJwkXjNsr46YubHja9QETQn+YXMGxBLvWI22wgIjSJsJa +sUXgcBBsEQSlJSLwSgP8z91wKZ0krRMfdSsDCbOBRPfidA0AggGiBsTBS6zyROQEAgduiCiSpoiE +hAQtUVmQlRYetxGIjYmyCiCw3wIBZLEXjiSpI0UlZaS56RCO/Vvrw0pOoXb4wiyMzA== + + + IPBw1sNSVMLjx8Ay4fBxoFlGOaQlwDEflWRcBeCdY4AKeUEGJCBa4HiJER7pmwHqwpPCSHBSgKp5 +IBegdDwgAg/HgQFUzdoKpC0aZZR+oN5ESFtEwSTPiGExipvEc2FJ4pAykT/g8YWJGFw/0iXP424J +XAQQF4XXWJhbJCQjKQTCs3Bco4h3eJ8nYEELJ/HaYQfCBrA4EagPVyHKYZ6JwuBwklgBtrvqQtqO +EMKOIow8TAa/8BKLrUDRPJwVNxx2RAgH/Tl8EoFfkUphRs7NCZEwnGGBkIyMZMVxeKwFmCfKAb9D +YIBvhCWYi8DAsTATxwHIwK2gJRoWETwOliUzEraIsE+AKGA2wEMAoQilIMEpbbhYOHiiRHYJUCVE +ZDcL7AQISybwwiRzLSpXSLv0Njie5GQADAycDQ4OmKmN4QSln8wqsDLALqMRmBMQIUUA8xwTBUaJ +x59H/gHUzOGGMQJH4OJkgKLhQvgJqQMWYbGMRFCj8KIIo5x2DqkCuQ3wpGiEENQicRacaL6QUoQf +iEIi+kKhtYThZNBr1CZUwlDrSiUMiSB0t1eQeVGNBQq6zIuqMk/WZF5ElXkozRSZx2kyT9RlXkST +eTyReYwm83hN5kU1mcfrMo/VZJ64IPMiZpnHW8g8XpN5vCrzJE6Tebwm80RN5gGlqTJPVmUesBmT +zIOWBZkHbSaZhy3zMg9bFmQeYy/zhAWZJ1rIPEGTeZIq81hGk3lRTeYJusyLajJPUGVeVJN5gibz +zBuuyDxWE0K8LvNYTebxmsxjNZnHazKPVWUer8s8VpN5vCbzWE3m8ZrMM083k3mSrAkhXpN50KTK +PF6VedCiSjNek2aMJvP4mcxb7EVGktSRiMwzT4dwIHELMuKMCYtAKeRI8ApDR/TLEYmwYCaCHB4o +CTghS/YxCoyHsHxRIrsv4mmRCOETKQBDANkCBxeEqCInkZNGeZacLAGJFV8DkmR5RCD8AhySMEMg +OlwdSC+ZQTICBHKIUiAaEJ4CvofgImkRlVKAo4AaUwQXIIiEJHG/kGgiynuyQtx4bkVCLNBL5nBX +NNkrgFgBquHIsiMRWSRwskyUSGNAU1RAARVl8OiwbgVxiE0CCse7F1CZduKvU3K2EYG8DP/KcHh6 +5NzKHApWra1gbOPIlhQMby62zN77mDXCsQ3LUZCehglmbQVjG6yPFwTDeJZNszfxPAE9inxkBgqS +kKjqBDPoDE36svQ3rdq0Vw1TzGAxzGGAz9CmL01/16pt9u4HbgfsuETYAHBYVuIJa4jgaRH1poJC +fUwkMtfGAwELeAIt20D3kGUydQQYRASp2dgGS5WRunhU6YncRtUZGR7IA4kTUFSwirAXBGQ/ArIR +hANoH4hRAJYbxbMCSiacF2xRtSzQhsKiGNUb4DXUcfA8651gX4Fjw2t8FMSOzJOWqERAEhXJogii +qBTR2mSi2oFKysC5I2/KyIyUNo5lUO+UUF7gaHjM4QVBANYuskaw1AZlNaAyCoZOEdT0WMJBQNuV +CVok5ABkwShj8DUQpiIyOgHPLbK+CAhTCTkPoJOXREXOwmAGpKM0jhJJqTaR/cLtZ/Dko/rECgo3 +4ySJJfsQAWUayBKMYxaPu9aCImzWBlwQeQiOBaQYlWW9DWQTTITyiVdsDpwO6JHVQUgrVpQEG2Ak +D2xTCVCWOA3QOTolupxiovCgFER5lKPA2qISCKqe0oaESJoiZAxg5qh5ALeXJNRCo7AIGeUbil8B +dWHoIQqMYWbEGlgZojxP5lFgqjzqOmAnSBLuN/RiCC9EWxwsFTJ6RJYUoSICTnAs2GdgOpLephyt +KIeUgnZTBAWKonQocImipFDB3IlMW59INLhA8qmWTZTQHEgunqwZ9CeOaNDA9QRiXcvAEQhUAop5 +BVeirFC0iDJc5MnuE9JWDrLEsaoNilZVgfAK2DhJkb6oguC7qABGFH4eYSKyijGOVfuBbCNNomrb +oZohs4Sjo56IG4jTMqgN4NaDwBNV8ECdB4YqabIJNxctzDuVBiReaSPDkhY8FKQFjaYFOklrigmA +LEWJwQ1oifJEakTQRANyB8qAHZIi2sZzgtrEaaudf1W1Mm5dstvndz/cu5ZJRK0Ph4pVhKiAcGii +HApGMKlQj5VUHQtW0HVxUcQpSm+wfjng5Ni28G4XQLCfkxMRUlRv0XCLAP5gLmAOIOUVNUqG0wHD +ossCSJNsBuEqXYtXHaYCWgazQVaEG2jvOFUE7UtBUa4icNpgWCBB0CZEhf3wUVzB4qvLp0IHGyIB +2WOEiaJURnKKsGhBC7hvcIi7hAswHE6vyZfu4qsOM0mCIkN5kEwysapwBKJO88hIQVTgqBJaNsjE +gXEC5ZAm05sOExGjAfmliLiAXcc1RZQTh2IRrG6ewI/ePpRT0I8YUV2Ldx3mQncZw0pEFBDeDHNx +ILPwBHBwGkEq4LCg0ooiylt4xrEcWejCq05TgeYqEi0BmJhEDhs6TDhUldHW59RhkVsSLhuBbZTJ +qsyvLp9J0WKRXDkZLVFclMAAGxNR7YU5QQ1EaJEfS0TX4HhFu+5avOswF4NMl0eGDxKDEYkvDHkC +4V3o5kEGDOPCwY2KaIKybDjKsjJpM7+7fC5V8KG4n3Nzwepwq2zcXBxrdnNxrIWbS1LdXGC8L7q5 +ZDRaoIlRLCvQQBn0I6C1CFsDz4jbDu0oBjUAaGPRVIA2dF2xqGihBSSJskpVHDrIOFSyZYJpURkL +IOTRT4WePEmUOGKBy+iDRGUClKYosbeiRNxBi4xuCvQIRlVvInE7RfQmlFUo/1nF18QSrzlxcxG5 +xqMfh7jQ0JeG+pQiHBUnEqpmcIyEKJxiOHthiZhbyAtZ0c0BouDoKwoFx0RY8hpOi2tDJicR4cYR +7xu6xMhxBV7LEZNZVjGM/jD8BRBEOBF6z2CkCApgVlaYUxQ9hRFeUxRgEjTUOaI/otNMa2kQlspw +6GDRezEKmnliVgLj5UBTg8MkkwWjcgrT8cAtRBRnuMXoSOOQIEgngB+1EHS+SRySmIiCNYLmKScg +USP5yKjqwUpA1spIh3iMiJwiXEIhSPTTRKNq2EB1jQqKaxTQBBhTXaOi5hrlFlyj7IJrFOYBjosi +JIKyBNaLvh5CKKCHMKiHKO5GpBiM4PACKuEcg5qbdkRBhSDvCSIwaWQGQjQCK4ZHgog8F6hRBnMD +34OHircJoBPRaObQlGAjCmcGUgYwQUkDBRNb0KJnRLKfwLii2AtMBOLcIr1ERlGcJVDHoQU1LZkl +DJUokQ0iNVEnBgg4Hl7n0HkUVZkzUfU5UMBFDq0HHmMVMiHfqKS4YdHyAWQAMmFfRRZ1woga2MGR +0Y0gYDhJIjhBB5PMysQw4XmwylAYK6cPNlpGjxi2sCKgXiAqJfH3gdmGDjTSiZFYluxcFIQPaYmi +3sfxsuo0gxYRthIxGVUIDJvIatHhSxyR8DqPh59DhiKyioEDFEe8wgxhqVGVj+PSgLMD61HCeBLL +oH8ZGST6LOAXYLKc+l6EHAwZNw5sKw4dh1FB8dezHJIOMk+Dnz1NfNBmP3tkwc8uWPjZuQU/u6h5 +1XnNzy7qPvWZn33WFtV96hHNzz7Xtuhn51H9jxBWSyw2JHJRwBYOYzLYMvOzEwPY7GfnzH52IAST +n52Z+dmB04DOAfwAqJwHBgK0gfChps6rMoSLomcN0QAnV0RhAu/JnGKdzNoKxjYeScDUJoaBAGA0 +9DAyRKRhZAnIEpQTVbrA+WAjxE7mkBGAugRtOABuGViRsEkCacHzzEWRVyBeAFCGJxYBgioJguIj +YDmF4cObPEGLwn70yAKrRBbSxrBX1Bz24qSFsBenh71ELezF6WEv0SLsFV0Ie0UWwl68Oeyl2DeE +wnlZIFSIZlhPDdDwircRaE5ws6CskOOD+8FEyYFCZiMpwWMiQ4AwgbEz6GuYtRWgDf2caCkAaxcx +ukDeRCUHcSZE8HDAoMSYAP01wiiEg5FscoCA3eHZQk4gS0TWgcxB1zOHngMGhS0GDnji58eRMPSA +yFdpGTkB8E0SH4oi3zGv1zHaaRX58RZr7VZlVOt0WyNXe1z7q+Wu9fuDSW3SGsITd3vUGk8Go5Z7 +/Dn4G1vgFa2715u9zrn+L1T7Dxc= + + + TM + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/update.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/update.gif new file mode 100644 index 0000000..31e22ab Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/update.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/void.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/void.gif new file mode 100644 index 0000000..e565824 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/images/void.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/index.html new file mode 100644 index 0000000..37e5b22 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/index.html @@ -0,0 +1,255 @@ +Apache Tomcat 7 (7.0.108) - Documentation Index

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Documentation Index

Introduction
+ +

This is the top-level entry point of the documentation bundle for the +Apache Tomcat Servlet/JSP container. Apache Tomcat version 7.0 +implements the Servlet 3.0 and JavaServer Pages 2.2 +specifications from the +Java Community Process, and includes many +additional features that make it a useful platform for developing and deploying +web applications and web services.

+ +

Select one of the links from the navigation menu (to the left) to drill +down to the more detailed documentation that is available. Each available +manual is described in more detail below.

+ +
Apache Tomcat User Guide
+ +

The following documents will assist you in downloading, installing +Apache Tomcat 7, and using many of the Apache Tomcat features.

+ +
    +
  1. Introduction - A + brief, high level, overview of Apache Tomcat.
  2. +
  3. Setup - How to install and run + Apache Tomcat on a variety of platforms.
  4. +
  5. First web application + - An introduction to the concepts of a web application as defined + in the Servlet Specification. Covers basic organization of your web application + source tree, the structure of a web application archive, and an + introduction to the web application deployment descriptor + (/WEB-INF/web.xml).
  6. +
  7. Deployer - + Operating the Apache Tomcat Deployer to deploy, precompile, and validate web + applications.
  8. +
  9. Manager - + Operating the Manager web app to deploy, undeploy, and + redeploy applications while Apache Tomcat is running.
  10. +
  11. Host Manager - + Operating the Host Manager web app to add and remove + virtual hosts while Apache Tomcat is running.
  12. +
  13. Realms and Access Control + - Description of how to configure Realms (databases of users, + passwords, and their associated roles) for use in web applications that + utilize Container Managed Security.
  14. +
  15. Security Manager + - Configuring and using a Java Security Manager to + support fine-grained control over the behavior of your web applications. +
  16. +
  17. JNDI Resources + - Configuring standard and custom resources in the JNDI naming context + that is provided to each web application.
  18. +
  19. + JDBC DataSource + - Configuring a JNDI DataSource with a DB connection pool. + Examples for many popular databases.
  20. +
  21. Classloading + - Information about class loading in Apache Tomcat, including where to place + your application classes so that they are visible.
  22. +
  23. JSPs + - Information about Jasper configuration, as well as the JSP compiler + usage.
  24. +
  25. SSL/TLS - + Installing and configuring SSL/TLS support so that your Apache Tomcat will + serve requests using the https protocol.
  26. +
  27. SSI - + Using Server Side Includes in Apache Tomcat.
  28. +
  29. CGI - + Using CGIs with Apache Tomcat.
  30. +
  31. Proxy Support - + Configuring Apache Tomcat to run behind a proxy server (or a web server + functioning as a proxy server).
  32. +
  33. MBeans Descriptors - + Configuring MBean descriptors files for custom components.
  34. +
  35. Default Servlet - + Configuring the default servlet and customizing directory listings.
  36. +
  37. Apache Tomcat Clustering - + Enable session replication in a Apache Tomcat environment.
  38. +
  39. Balancer - + Configuring, using, and extending the load balancer application.
  40. +
  41. Connectors - + Connectors available in Apache Tomcat, and native web server integration.
  42. +
  43. Monitoring and Management - + Enabling JMX Remote support, and using tools to monitor and manage Apache Tomcat.
  44. +
  45. Logging - + Configuring logging in Apache Tomcat.
  46. +
  47. Apache Portable Runtime - + Using APR to provide superior performance, scalability and better + integration with native server technologies.
  48. +
  49. Virtual Hosting - + Configuring virtual hosting in Apache Tomcat.
  50. +
  51. Advanced IO - + Extensions available over regular, blocking IO.
  52. +
  53. Additional Components - + Obtaining additional, optional components.
  54. +
  55. Using Tomcat libraries with Maven - + Obtaining Tomcat jars through Maven.
  56. +
  57. Security Considerations - + Options to consider when securing an Apache Tomcat installation.
  58. +
  59. Windows Service - + Running Tomcat as a service on Microsoft Windows.
  60. +
  61. Windows Authentication - + Configuring Tomcat to use integrated Windows authentication.
  62. +
  63. High Concurrency JDBC Pool - + Configuring Tomcat to use an alternative JDBC pool.
  64. +
  65. WebSocket support - + Developing WebSocket applications for Apache Tomcat.
  66. + +
+ +
Reference
+ +

The following documents are aimed at System Administrators who +are responsible for installing, configuring, and operating an Apache Tomcat server. +

+ + +
Apache Tomcat Developers
+ +

The following documents are for Java developers who wish to contribute to +the development of the Apache Tomcat project.

+
    +
  • Building from Source - + Details the steps necessary to download Apache Tomcat source code (and the + other packages that it depends on), and build a binary distribution from + those sources. +
  • +
  • Changelog - Details the + changes made to Apache Tomcat. +
  • +
  • Status - + Apache Tomcat development status. +
  • +
  • Developers - List of active + Apache Tomcat contributors. +
  • +
  • Javadocs + - Javadoc API documentation for Apache Tomcat's internals.
  • +
  • Apache Tomcat Architecture + - Documentation of the Apache Tomcat Server Architecture.
  • +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/introduction.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/introduction.html new file mode 100644 index 0000000..153438e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/introduction.html @@ -0,0 +1,337 @@ +Apache Tomcat 7 (7.0.108) - Introduction

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Introduction

Table of Contents
+ +
Introduction
+ +

For administrators and web developers alike, there are some important bits +of information you should familiarize yourself with before starting out. This +document serves as a brief introduction to some of the concepts and +terminology behind the Tomcat container. As well, where to go when you need +help.

+ +
Terminology
+ +

In the course of reading these documents, you will run across a number of +terms; some specific to Tomcat, and others defined by the +Servlet and +JSP specifications.

+ +
    +
  • Context - In a nutshell, a Context is a + web application.
  • +
+

That is it. If you find any more terms we need to add to this section, please +do let us know.

+ +
Directories and Files
+ +

These are some of the key tomcat directories:

+ +
    +
  • /bin - Startup, shutdown, and other scripts. The + *.sh files (for Unix systems) are functional duplicates of + the *.bat files (for Windows systems). Since the Win32 + command-line lacks certain functionality, there are some additional + files in here.
  • +
  • /conf - Configuration files and related DTDs. The most + important file in here is server.xml. It is the main configuration file + for the container.
  • +
  • /logs - Log files are here by default.
  • +
  • /webapps - This is where your webapps go.
  • +
+ +
CATALINA_HOME and CATALINA_BASE
+

Throughout the documentation, there are references to the two following + properties: +

    +
  • + CATALINA_HOME: Represents the root of your Tomcat + installation, for example /home/tomcat/apache-tomcat-9.0.10 + or C:\Program Files\apache-tomcat-9.0.10. +
  • +
  • + CATALINA_BASE: Represents the root of a runtime + configuration of a specific Tomcat instance. If you want to have + multiple Tomcat instances on one machine, use the CATALINA_BASE + property. +
  • +
+

+

+ If you set the properties to different locations, the CATALINA_HOME location + contains static sources, such as .jar files, or binary files. + The CATALINA_BASE location contains configuration files, log files, deployed + applications, and other runtime requirements. +

+
Why Use CATALINA_BASE
+

+ By default, CATALINA_HOME and CATALINA_BASE point to the same directory. + Set CATALINA_BASE manually when you require running multiple Tomcat + instances on one machine. Doing so provides the following benefits: +

+
    +
  • + Easier management of upgrading to a newer version of Tomcat. Because all + instances with single CATALINA_HOME location share one set of + .jar files and binary files, you can easily upgrade the files + to newer version and have the change propagated to all Tomcat instances + using the same CATALIA_HOME directory. +
  • +
  • + Avoiding duplication of the same static .jar files. +
  • +
  • + The possibility to share certain settings, for example the setenv shell + or bat script file (depending on your operating system). +
  • +
+
+
Contents of CATALINA_BASE
+

+ Before you start using CATALINA_BASE, first consider and create the + directory tree used by CATALINA_BASE. Note that if you do not create + all the recommended directories, Tomcat creates the directories + automatically. If it fails to create the necessary directory, for example + due to permission issues, Tomcat will either fail to start, or may not + function correctly. +

+

+ Consider the following list of directories: +

    +
  • +

    + The bin directory with the setenv.sh, + setenv.bat, and tomcat-juli.jar files. +

    +

    + Recommended: No. +

    +

    + Order of lookup: CATALINA_BASE is checked first; fallback is provided + to CATALINA_HOME. +

    +
  • +
  • +

    + The lib directory with further resources to be added on + classpath. +

    +

    + Recommended: Yes, if your application depends on external libraries. +

    +

    + Order of lookup: CATALINA_BASE is checked first; CATALINA_HOME is + loaded second. +

    +
  • +
  • +

    + The logs directory for instance-specific log files. +

    +

    + Recommended: Yes. +

    +
  • +
  • +

    + The webapps directory for automatically loaded web + applications. +

    +

    + Recommended: Yes, if you want to deploy applications. +

    +

    + Order of lookup: CATALINA_BASE only. +

    +
  • +
  • +

    + The work directory that contains temporary working + directories for the deployed web applications. +

    +

    + Recommended: Yes. +

    +
  • +
  • +

    + The temp directory used by the JVM for temporary files. +

    +

    + Recommended: Yes. +

    +
  • +
+

+

+ We recommend you not to change the tomcat-juli.jar file. + However, in case you require your own logging implementation, you can + replace the tomcat-juli.jar file in a CATALINA_BASE location + for the specific Tomcat instance. +

+

+ We also recommend you copy all configuration files from the + CATALINA_HOME/conf directory into the + CATALINA_BASE/conf/ directory. In case a configuration file + is missing in CATALINA_BASE, there is no fallback to CATALINA_HOME. + Consequently, this may cause failure. +

+

+ At minimum, CATALINA_BASE must contain: +

    +
  • conf/server.xml
  • +
  • conf/web.xml
  • +
+ That includes the conf directory. Otherwise, Tomcat fails + to start, or fails to function properly. +

+

+ For advanced configuration information, see the + + RUNNING.txt + file. +

+
+
How to Use CATALINA_BASE
+

+ The CATALINA_BASE property is an environment variable. You can set it + before you execute the Tomcat start script, for example: +

    +
  • On Unix: CATALINA_BASE=/tmp/tomcat_base1 bin/catalina.sh start
  • +
  • On Windows: CATALINA_BASE=C:\tomcat_base1 bin/catalina.bat start
  • +
+

+
+
Configuring Tomcat
+ +

This section will acquaint you with the basic information used during +the configuration of the container.

+ +

All of the information in the configuration files is read at startup, +meaning that any change to the files necessitates a restart of the container. +

+ +
Where to Go for Help
+ +

While we've done our best to ensure that these documents are clearly +written and easy to understand, we may have missed something. Provided +below are various web sites and mailing lists in case you get stuck.

+ +

As Tomcat 7 is a new release of Tomcat, keep in mind that some of the +issues and solutions vary between the major versions of Tomcat (6.x versus +7.x). As you search around the web, there will be some documentation that +is not relevant to Tomcat 7, but 6.x, 5.x or earlier versions. Doing 3.x +or 4.x things to 7 will probably not work in most cases as the server.xml +files are very different.

+ +
    +
  • Current document - most documents will list potential hangups. Be sure + to fully read the relevant documentation as it will save you much time + and effort. There's nothing like scouring the web only to find out that + the answer was right in front of you all along!
  • +
  • Tomcat FAQ
  • +
  • Tomcat WIKI
  • +
  • Tomcat FAQ at jGuru
  • +
  • Tomcat mailing list archives - numerous sites archive the Tomcat mailing + lists. Since the links change over time, clicking here will search + Google. +
  • +
  • The TOMCAT-USER mailing list, which you can subscribe to + here. If you don't + get a reply, then there's a good chance that your question was probably + answered in the list archives or one of the FAQs. Although questions + about web application development in general are sometimes asked and + answered, please focus your questions on Tomcat-specific issues.
  • +
  • The TOMCAT-DEV mailing list, which you can subscribe to + here. This list is + reserved for discussions about the development of Tomcat + itself. Questions about Tomcat configuration, and the problems you run + into while developing and running applications, will normally be more + appropriate on the TOMCAT-USER list instead.
  • +
+ +

And, if you think something should be in the docs, by all means let us know +on the TOMCAT-DEV list.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jasper-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jasper-howto.html new file mode 100644 index 0000000..d047640 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jasper-howto.html @@ -0,0 +1,440 @@ +Apache Tomcat 7 (7.0.108) - Jasper 2 JSP Engine How To

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Jasper 2 JSP Engine How To

Table of Contents
+ +
Introduction
+ +

Tomcat 7.0 uses the Jasper 2 JSP Engine to implement +the JavaServer Pages 2.2 +specification.

+ +

Jasper 2 has been redesigned to significantly improve performance over +the original Jasper. In addition to general code improvements the following +changes were made:

+
    +
  • JSP Custom Tag Pooling - The java objects instantiated +for JSP Custom Tags can now be pooled and reused. This significantly boosts +the performance of JSP pages which use custom tags.
  • +
  • Background JSP compilation - If you make a change to +a JSP page which had already been compiled Jasper 2 can recompile that +page in the background. The previously compiled JSP page will still be +available to serve requests. Once the new page has been compiled +successfully it will replace the old page. This helps improve availability +of your JSP pages on a production server.
  • +
  • Recompile JSP when included page changes - Jasper 2 +can now detect when a page included at compile time from a JSP has changed +and then recompile the parent JSP.
  • +
  • JDT used to compile JSP pages - The +Eclipse JDT Java compiler is now used to perform JSP java source code +compilation. This compiler loads source dependencies from the container +classloader. Ant and javac can still be used.
  • +
+ + +

Jasper is implemented using the servlet class +org.apache.jasper.servlet.JspServlet.

+ +
Configuration
+ +

By default Jasper is configured for use when doing web application +development. See the section +Production Configuration for information on configuring Jasper +for use on a production Tomcat server.

+ +

The servlet which implements Jasper is configured using init parameters +in your global $CATALINA_BASE/conf/web.xml. +

+
    +
  • checkInterval - If development is false and checkInterval +is greater than zero, background compiles are enabled. checkInterval is the time +in seconds between checks to see if a JSP page (and its dependent files) needs +to be recompiled. Default 0 seconds.
  • + +
  • classdebuginfo - Should the class file be compiled with +debugging information? true or false, default +true. +
  • + +
  • classpath - Defines the class path to be used to compile +the generated servlets. This parameter only has an effect if the ServletContext +attribute org.apache.jasper.Constants.SERVLET_CLASSPATH is not set. This +attribute is always set when Jasper is used within Tomcat. By default the +classpath is created dynamically based on the current web application.
  • + +
  • compiler - Which compiler Ant should use to compile JSP +pages. The valid values for this are the same as for the compiler attribute of +Ant's +javac +task. If the value is not set, then the default Eclipse JDT Java compiler will +be used instead of using Ant. There is no default value. If this attribute is +set then setenv.[sh|bat] should be used to add +ant.jar, ant-launcher.jar and tools.jar +to the CLASSPATH environment variable.
  • + +
  • compilerSourceVM - What JDK version are the source files +compatible with? (Default value: 1.6)
  • + +
  • compilerTargetVM - What JDK version are the generated files +compatible with? (Default value: 1.6)
  • + +
  • development - Is Jasper used in development mode? If true, +the frequency at which JSPs are checked for modification may be specified via +the modificationTestInterval parameter.true or false, +default true.
  • + +
  • displaySourceFragment - Should a source fragment be +included in exception messages? true or false, +default true.
  • + +
  • dumpSmap - Should the SMAP info for JSR45 debugging be +dumped to a file? true or false, default +false. false if suppressSmap is true.
  • + +
  • enablePooling - Determines whether tag handler pooling is +enabled. This is a compilation option. It will not alter the behaviour of JSPs +that have already been compiled. true or false, +default true. +
  • + +
  • engineOptionsClass - Allows specifying the Options class +used to configure Jasper. If not present, the default EmbeddedServletOptions +will be used. This option is ignored if running under a SecurityManager. +
  • + +
  • errorOnUseBeanInvalidClassAttribute - Should Jasper issue +an error when the value of the class attribute in an useBean action is not a +valid bean class? true or false, default +true.
  • + +
  • fork - Have Ant fork JSP page compiles so they are +performed in a separate JVM from Tomcat? true or +false, default true.
  • + +
  • genStringAsCharArray - Should text strings be generated as char +arrays, to improve performance in some cases? Default false.
  • + +
  • ieClassId - The class-id value to be sent to Internet +Explorer when using <jsp:plugin> tags. Default +clsid:8AD9C840-044E-11D1-B3E9-00805F499D93.
  • + +
  • javaEncoding - Java file encoding to use for generating +java source files. Default UTF8.
  • + +
  • keepgenerated - Should we keep the generated Java source +code for each page instead of deleting it? true or +false, default true.
  • + +
  • mappedfile - Should we generate static content with one +print statement per input line, to ease debugging? +true or false, default true.
  • + +
  • maxLoadedJsps - The maximum number of JSPs that will be +loaded for a web application. If more than this number of JSPs are loaded, the +least recently used JSPs will be unloaded so that the number of JSPs loaded at +any one time does not exceed this limit. A value of zero or less indicates no +limit. Default -1
  • + +
  • jspIdleTimeout - The amount of time in seconds a JSP can be +idle before it is unloaded. A value of zero or less indicates never unload. +Default -1
  • + +
  • modificationTestInterval - Causes a JSP (and its dependent +files) to not be checked for modification during the specified time interval +(in seconds) from the last time the JSP was checked for modification. A value of +0 will cause the JSP to be checked on every access. Used in development mode +only. Default is 4 seconds.
  • + +
  • recompileOnFail - If a JSP compilation fails should the +modificationTestInterval be ignored and the next access trigger a re-compilation +attempt? Used in development mode only and is disabled by default as compilation +may be expensive and could lead to excessive resource usage.
  • + +
  • scratchdir - What scratch directory should we use when +compiling JSP pages? Default is the work directory for the current web +application. This option is ignored if running under a SecurityManager.
  • + +
  • suppressSmap - Should the generation of SMAP info for JSR45 +debugging be suppressed? true or false, default +false.
  • + +
  • trimSpaces - Should template text that consists entirely of +whitespace be removed? true or false, default +false.
  • + +
  • xpoweredBy - Determines whether X-Powered-By response +header is added by generated servlet. true or false, +default false.
  • + +
  • quoteAttributeEL - When EL is used in an attribute value +on a JSP page, should the rules for quoting of attributes described in JSP.1.6 +be applied to the expression? true or false, default +true.
  • +
+ + +

The Java compiler from Eclipse JDT in included as the default compiler. It is +an advanced Java compiler which will load all dependencies from the Tomcat class +loader, which will help tremendously when compiling on large installations with +tens of JARs. On fast servers, this will allow sub-second recompilation cycles +for even large JSP pages.

+ +

Apache Ant, which was used in previous Tomcat releases, can be used instead +of the new compiler by configuring the compiler attribute as explained above. +

+ +
Known issues
+ +

As described in + +bug 39089, a known JVM issue, + +bug 6294277, may cause a +java.lang.InternalError: name is too long to represent exception +when compiling very large JSPs. If this is observed then it may be worked around +by using one of the following: +

+
    +
  • reduce the size of the JSP
  • +
  • disable SMAP generation and JSR-045 support by setting +suppressSmap to true.
  • +
+ +
Production Configuration
+ +

The main JSP optimization which can be done is precompilation of JSPs. +However, this might not be possible (for example, when using the +jsp-property-group feature) or practical, in which case the configuration of the +Jasper servlet becomes critical.

+ +

When using Jasper 2 in a production Tomcat server you should consider making +the following changes from the default configuration.

+
    +
  • development - To disable on access checks for JSP +pages compilation set this to false.
  • +
  • genStringAsCharArray - To generate slightly more efficient +char arrays, set this to true.
  • +
  • modificationTestInterval - If development has to be set to +true for any reason (such as dynamic generation of JSPs), setting +this to a high value will improve performance a lot.
  • +
  • trimSpaces - To remove useless bytes from the response, +set this to true.
  • +
+ +
Web Application Compilation
+ +

Using Ant is the preferred way to compile web applications using JSPC. Note +that when pre-compiling JSPs, SMAP information will only be included in the +final classes if suppressSmap is false and compile is true. +Use the script given below (a similar script is included in the "deployer" +download) to precompile a webapp: +

+ +
<project name="Webapp Precompilation" default="all" basedir=".">
+
+   <import file="${tomcat.home}/bin/catalina-tasks.xml"/>
+
+   <target name="jspc">
+
+    <jasper
+             validateXml="false"
+             uriroot="${webapp.path}"
+             webXmlInclude="${webapp.path}/WEB-INF/generated_web.xml"
+             outputDir="${webapp.path}/WEB-INF/src" />
+
+  </target>
+
+  <target name="compile">
+
+    <mkdir dir="${webapp.path}/WEB-INF/classes"/>
+    <mkdir dir="${webapp.path}/WEB-INF/lib"/>
+
+    <javac destdir="${webapp.path}/WEB-INF/classes"
+           optimize="off"
+           debug="on" failonerror="false"
+           srcdir="${webapp.path}/WEB-INF/src"
+           excludes="**/*.smap">
+      <classpath>
+        <pathelement location="${webapp.path}/WEB-INF/classes"/>
+        <fileset dir="${webapp.path}/WEB-INF/lib">
+          <include name="*.jar"/>
+        </fileset>
+        <pathelement location="${tomcat.home}/lib"/>
+        <fileset dir="${tomcat.home}/lib">
+          <include name="*.jar"/>
+        </fileset>
+        <fileset dir="${tomcat.home}/bin">
+          <include name="*.jar"/>
+        </fileset>
+      </classpath>
+      <include name="**" />
+      <exclude name="tags/**" />
+    </javac>
+
+  </target>
+
+  <target name="all" depends="jspc,compile">
+  </target>
+
+  <target name="cleanup">
+    <delete>
+        <fileset dir="${webapp.path}/WEB-INF/src"/>
+        <fileset dir="${webapp.path}/WEB-INF/classes/org/apache/jsp"/>
+    </delete>
+  </target>
+
+</project>
+ +

+The following command line can be used to run the script +(replacing the tokens with the Tomcat base path and the path to the webapp +which should be precompiled): +

+
$ANT_HOME/bin/ant -Dtomcat.home=<$TOMCAT_HOME> -Dwebapp.path=<$WEBAPP_PATH>
+ + +

+Then, the declarations and mappings for the servlets which were generated +during the precompilation must be added to the web application deployment +descriptor. Insert the ${webapp.path}/WEB-INF/generated_web.xml +at the right place inside the ${webapp.path}/WEB-INF/web.xml file. +Restart the web application (using the manager) and test it to verify it is +running fine with precompiled servlets. An appropriate token placed in the +web application deployment descriptor may also be used to automatically +insert the generated servlet declarations and mappings using Ant filtering +capabilities. This is actually how all the webapps distributed with Tomcat +are automatically compiled as part of the build process. +

+ +

+At the jasper task you can use the option addWebXmlMappings for +automatic merge the ${webapp.path}/WEB-INF/generated_web.xml +with the current web application deployment descriptor at +${webapp.path}/WEB-INF/web.xml. When you want to use Java 6 +features inside your jsp's, add the following javac compiler task attributes: +source="1.6" target="1.6". For live +applications you can also compile with optimize="on" and +without debug info debug="off". +

+ +

+When you don't want to stop the jsp generation at first jsp syntax error, use +failOnError="false" and with +showSuccess="true" all successful jsp to java +generation are printed out. Sometimes it is very helpful, when you cleanup the +generate java source files at ${webapp.path}/WEB-INF/src +and the compile jsp servlet classes at +${webapp.path}/WEB-INF/classes/org/apache/jsp. +

+ +

Hints:

+
    +
  • When you switch to another Tomcat release, then regenerate and recompile +your jsp's with the new Tomcat version.
  • +
  • Use java system property at server runtime to disable PageContext pooling +org.apache.jasper.runtime.JspFactoryImpl.USE_POOL=false. +and limit the buffering with +org.apache.jasper.runtime.BodyContentImpl.LIMIT_BUFFER=true. Note +that changing from the defaults may affect performance, but it will vary +depending on the application.
  • +
+
Optimisation
+

+There are a number of extension points provided within Jasper that enable the +user to optimise the behaviour for their environment. +

+ +

+The first of these extension points is the tag plug-in mechanism. This allows +alternative implementations of tag handlers to be provided for a web application +to use. Tag plug-ins are registered via a tagPlugins.xml file +located under WEB-INF. A sample plug-in for the JSTL is included +with Jasper. +

+ +

+The second extension point is the Expression Language interpreter. Alternative +interpreters may be configured through the ServletContext. See the +ELInterpreterFactory javadoc for details of how to configure an +alternative EL interpreter. +

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jdbc-pool.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jdbc-pool.html new file mode 100644 index 0000000..c0aa79e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jdbc-pool.html @@ -0,0 +1,875 @@ +Apache Tomcat 7 (7.0.108) - The Tomcat JDBC Connection Pool

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

The Tomcat JDBC Connection Pool

Table of Contents
+ +
Introduction
+ +

The JDBC Connection Pool org.apache.tomcat.jdbc.pool + is a replacement or an alternative to the Apache Commons DBCP + connection pool.

+ +

So why do we need a new connection pool?

+ +

Here are a few of the reasons:

+
    +
  1. Commons DBCP 1.x is single threaded. In order to be thread safe + Commons locks the entire pool for short periods during both object + allocation and object return. Note that this does not apply to + Commons DBCP 2.x.
  2. +
  3. Commons DBCP 1.x can be slow. As the number of logical CPUs grows and + the number of concurrent threads attempting to borrow or return + objects increases, the performance suffers. For highly concurrent + systems the impact can be significant. Note that this does not apply + to Commons DBCP 2.x.
  4. +
  5. Commons DBCP is over 60 classes. tomcat-jdbc-pool core is 8 classes, + hence modifications for future requirement will require much less + changes. This is all you need to run the connection pool itself, the + rest is gravy.
  6. +
  7. Commons DBCP uses static interfaces. This means you have to use the + right version for a given JRE version or you may see + NoSuchMethodException exceptions.
  8. +
  9. It's not worth rewriting over 60 classes, when a connection pool can + be accomplished with a much simpler implementation.
  10. +
  11. Tomcat jdbc pool implements the ability retrieve a connection + asynchronously, without adding additional threads to the library + itself.
  12. +
  13. Tomcat jdbc pool is a Tomcat module, it depends on Tomcat JULI, a + simplified logging framework used in Tomcat.
  14. +
  15. Retrieve the underlying connection using the + javax.sql.PooledConnection interface.
  16. +
  17. Starvation proof. If a pool is empty, and threads are waiting for a + connection, when a connection is returned, the pool will awake the + correct thread waiting. Most pools will simply starve.
  18. +
+ +

Features added over other connection pool implementations

+
    +
  1. Support for highly concurrent environments and multi core/cpu systems.
  2. +
  3. Dynamic implementation of interface, will support java.sql and javax.sql interfaces for + your runtime environment (as long as your JDBC driver does the same), even when compiled with a lower version of the JDK.
  4. +
  5. Validation intervals - we don't have to validate every single time we use the connection, we can do this + when we borrow or return the connection, just not more frequent than an interval we can configure.
  6. +
  7. Run-Once query, a configurable query that will be run only once, when the connection to the database is established. + Very useful to setup session settings, that you want to exist during the entire time the connection is established.
  8. +
  9. Ability to configure custom interceptors. + This allows you to write custom interceptors to enhance the functionality. You can use interceptors to gather query stats, + cache session states, reconnect the connection upon failures, retry queries, cache query results, and so on. + Your options are endless and the interceptors are dynamic, not tied to a JDK version of a + java.sql/javax.sql interface.
  10. +
  11. High performance - we will show some differences in performance later on
  12. +
  13. Extremely simple, due to the very simplified implementation, the line count and source file count are very low, compare with c3p0 + that has over 200 source files(last time we checked), Tomcat jdbc has a core of 8 files, the connection pool itself is about half + that. As bugs may occur, they will be faster to track down, and easier to fix. Complexity reduction has been a focus from inception.
  14. +
  15. Asynchronous connection retrieval - you can queue your request for a connection and receive a Future<Connection> back.
  16. +
  17. Better idle connection handling. Instead of closing connections directly, it can still pool connections and sizes the idle pool with a smarter algorithm.
  18. +
  19. You can decide at what moment connections are considered abandoned, is it when the pool is full, or directly at a timeout + by specifying a pool usage threshold. +
  20. +
  21. The abandon connection timer will reset upon a statement/query activity. Allowing a connections that is in use for a long time to not timeout. + This is achieved using the ResetAbandonedTimer +
  22. +
  23. Close connections after they have been connected for a certain time. Age based close upon return to the pool. +
  24. +
  25. Get JMX notifications and log entries when connections are suspected for being abandoned. This is similar to + the removeAbandonedTimeout but it doesn't take any action, only reports the information. + This is achieved using the suspectTimeout attribute.
  26. +
  27. Connections can be retrieved from a java.sql.Driver, javax.sql.DataSource or javax.sql.XADataSource + This is achieved using the dataSource and dataSourceJNDI attributes.
  28. +
  29. XA connection support
  30. +
+ + +
How to use
+

+ Usage of the Tomcat connection pool has been made to be as simple as possible, for those of you that are familiar with commons-dbcp, the + transition will be very simple. Moving from other connection pools is also fairly straight forward. +

+
Additional features
+

The Tomcat connection pool offers a few additional features over what most other pools let you do:

+
    +
  • initSQL - the ability to run an SQL statement exactly once, when the connection is created
  • +
  • validationInterval - in addition to running validations on connections, avoid running them too frequently.
  • +
  • jdbcInterceptors - flexible and pluggable interceptors to create any customizations around the pool, + the query execution and the result set handling. More on this in the advanced section.
  • +
  • fairQueue - Set the fair flag to true to achieve thread fairness or to use asynchronous connection retrieval
  • +
+
+
Inside the Apache Tomcat Container
+

+ The Tomcat Connection pool is configured as a resource described in The Tomcat JDBC documentation + With the only difference being that you have to specify the factory attribute and set the value to + org.apache.tomcat.jdbc.pool.DataSourceFactory +

+
+
Standalone
+

+ The connection pool only has another dependency, and that is on tomcat-juli.jar. + To configure the pool in a stand alone project using bean instantiation, the bean to instantiate is + org.apache.tomcat.jdbc.pool.DataSource. The same attributes (documented below) as you use to configure a connection + pool as a JNDI resource, are used to configure a data source as a bean. +

+
+
JMX
+

+ The connection pool object exposes an MBean that can be registered. + In order for the connection pool object to create the MBean, the flag jmxEnabled has to be set to true. + This doesn't imply that the pool will be registered with an MBean server, merely that the MBean is created. + In a container like Tomcat, Tomcat itself registers the DataSource with the MBean server, the + org.apache.tomcat.jdbc.pool.DataSource object will then register the actual + connection pool MBean. + If you're running outside of a container, you can register the DataSource yourself under any object name you specify, + and it propagates the registration to the underlying pool. To do this you would call mBeanServer.registerMBean(dataSource.getPool().getJmxPool(),objectname). + Prior to this call, ensure that the pool has been created by calling dataSource.createPool(). +

+
+ +
Attributes
+

To provide a very simple switch to and from commons-dbcp and tomcat-jdbc-pool, + Most attributes are the same and have the same meaning.

+
JNDI Factory and Type
+
AttributeDescription
factory +

factory is required, and the value should be org.apache.tomcat.jdbc.pool.DataSourceFactory

+
type +

Type should always be javax.sql.DataSource or javax.sql.XADataSource

+

Depending on the type a org.apache.tomcat.jdbc.pool.DataSource or a org.apache.tomcat.jdbc.pool.XADataSource will be created.

+
+
+ +
Common Attributes
+

These attributes are shared between commons-dbcp and tomcat-jdbc-pool, in some cases default values are different.

+
AttributeDescription
defaultAutoCommit +

(boolean) The default auto-commit state of connections created by this pool. If not set, default is JDBC driver default (If not set then the setAutoCommit method will not be called.)

+
defaultReadOnly +

(boolean) The default read-only state of connections created by this pool. If not set then the setReadOnly method will not be called. (Some drivers don't support read only mode, ex: Informix)

+
defaultTransactionIsolation +

(String) The default TransactionIsolation state of connections created by this pool. One of the following: (see javadoc )

+
    +
  • NONE
  • +
  • READ_COMMITTED
  • +
  • READ_UNCOMMITTED
  • +
  • REPEATABLE_READ
  • +
  • SERIALIZABLE
  • +
+

If not set, the method will not be called and it defaults to the JDBC driver.

+
defaultCatalog +

(String) The default catalog of connections created by this pool.

+
driverClassName +

(String) The fully qualified Java class name of the JDBC driver to be used. The driver has to be accessible + from the same classloader as tomcat-jdbc.jar +

+
username +

(String) The connection username to be passed to our JDBC driver to establish a connection. + Note that method DataSource.getConnection(username,password) + by default will not use credentials passed into the method, + but will use the ones configured here. See alternateUsernameAllowed + property for more details. +

+
password +

(String) The connection password to be passed to our JDBC driver to establish a connection. + Note that method DataSource.getConnection(username,password) + by default will not use credentials passed into the method, + but will use the ones configured here. See alternateUsernameAllowed + property for more details. +

+
maxActive +

(int) The maximum number of active connections that can be allocated from this pool at the same time. + The default value is 100

+
maxIdle +

(int) The maximum number of connections that should be kept in the pool at all times. + Default value is maxActive:100 + Idle connections are checked periodically (if enabled) and + connections that been idle for longer than minEvictableIdleTimeMillis + will be released. (also see testWhileIdle)

+
minIdle +

+ (int) The minimum number of established connections that should be kept in the pool at all times. + The connection pool can shrink below this number if validation queries fail. + Default value is derived from initialSize:10 (also see testWhileIdle) +

+
initialSize +

(int)The initial number of connections that are created when the pool is started. + Default value is 10

+
maxWait +

(int) The maximum number of milliseconds that the pool will wait (when there are no available connections) + for a connection to be returned before throwing an exception. + Default value is 30000 (30 seconds)

+
testOnBorrow +

(boolean) The indication of whether objects will be validated before being borrowed from the pool. + If the object fails to validate, it will be dropped from the pool, and we will attempt to borrow another. + In order to have a more efficient validation, see validationInterval. + Default value is false +

+
testOnConnect +

(boolean) The indication of whether objects will be validated when a connection is first created. + If an object fails to validate, it will be throw SQLException. + Default value is false +

+
testOnReturn +

(boolean) The indication of whether objects will be validated before being returned to the pool. + The default value is false. +

+
testWhileIdle +

(boolean) The indication of whether objects will be validated by the idle object evictor (if any). + If an object fails to validate, it will be dropped from the pool. + The default value is false and this property has to be set in order for the + pool cleaner/test thread is to run (also see timeBetweenEvictionRunsMillis) +

+
validationQuery +

(String) The SQL query that will be used to validate connections from this pool before returning them to the caller. + If specified, this query does not have to return any data, it just can't throw a SQLException. + The default value is null. + If not specified, connections will be validation by the isValid() method. + Example values are SELECT 1(mysql), select 1 from dual(oracle), SELECT 1(MS Sql Server) +

+
validationQueryTimeout +

(int) The timeout in seconds before a connection validation queries fail. This works by calling + java.sql.Statement.setQueryTimeout(seconds) on the statement that executes the validationQuery. + The pool itself doesn't timeout the query, it is still up to the JDBC driver to enforce query timeouts. + A value less than or equal to zero will disable this feature. + The default value is -1. +

+
validatorClassName +

(String) The name of a class which implements the + org.apache.tomcat.jdbc.pool.Validator interface and + provides a no-arg constructor (may be implicit). If specified, the + class will be used to create a Validator instance which is then used + instead of any validation query to validate connections. The default + value is null. An example value is + com.mycompany.project.SimpleValidator. +

+
timeBetweenEvictionRunsMillis +

(int) The number of milliseconds to sleep between runs of the idle connection validation/cleaner thread. + This value should not be set under 1 second. It dictates how often we check for idle, abandoned connections, and how often + we validate idle connections. + The default value is 5000 (5 seconds).
+

+
numTestsPerEvictionRun +

(int) Property not used in tomcat-jdbc-pool.

+
minEvictableIdleTimeMillis +

(int) The minimum amount of time an object may sit idle in the pool before it is eligible for eviction. + The default value is 60000 (60 seconds).

+
accessToUnderlyingConnectionAllowed +

(boolean) Property not used. Access can be achieved by calling unwrap on the pooled connection. + see javax.sql.DataSource interface, or call getConnection through reflection or + cast the object as javax.sql.PooledConnection

+
removeAbandoned +

(boolean) Flag to remove abandoned connections if they exceed the removeAbandonedTimeout. + If set to true a connection is considered abandoned and eligible for removal if it has been in use + longer than the removeAbandonedTimeout Setting this to true can recover db connections from + applications that fail to close a connection. See also logAbandoned + The default value is false.

+
removeAbandonedTimeout +

(int) Timeout in seconds before an abandoned(in use) connection can be removed. + The default value is 60 (60 seconds). The value should be set to the longest running query your applications + might have.

+
logAbandoned +

(boolean) Flag to log stack traces for application code which abandoned a Connection. + Logging of abandoned Connections adds overhead for every Connection borrow because a stack trace has to be generated. + The default value is false.

+
connectionProperties +

(String) The connection properties that will be sent to our JDBC driver when establishing new connections. + Format of the string must be [propertyName=property;]* + NOTE - The "user" and "password" properties will be passed explicitly, so they do not need to be included here. + The default value is null.

+
poolPreparedStatements +

(boolean) Property not used.

+
maxOpenPreparedStatements +

(int) Property not used.

+
+ +
+ +
Tomcat JDBC Enhanced Attributes
+ +
AttributeDescription
initSQL +

(String) A custom query to be run when a connection is first created. + The default value is null.

+
jdbcInterceptors +

(String) A semicolon separated list of classnames extending + org.apache.tomcat.jdbc.pool.JdbcInterceptor class. + See Configuring JDBC interceptors + below for more detailed description of syntax and examples. +

+

+ These interceptors will be inserted as an interceptor into the chain + of operations on a java.sql.Connection object. + The default value is null. +

+

+ Predefined interceptors:
+ org.apache.tomcat.jdbc.pool.interceptor.
ConnectionState
+ - keeps track of auto commit, read only, catalog and transaction isolation level.
+ org.apache.tomcat.jdbc.pool.interceptor.
StatementFinalizer
+ - keeps track of opened statements, and closes them when the connection is returned to the pool. +

+

+ More predefined interceptors are described in detail in the + JDBC Interceptors section. +

+
validationInterval +

(long) avoid excess validation, only run validation at most at this frequency - time in milliseconds. + If a connection is due for validation, but has been validated previously within this interval, it will not be validated again. + The default value is 3000 (3 seconds).

+
jmxEnabled +

(boolean) Register the pool with JMX or not. + The default value is true.

+
fairQueue +

(boolean) Set to true if you wish that calls to getConnection should be treated + fairly in a true FIFO fashion. This uses the org.apache.tomcat.jdbc.pool.FairBlockingQueue + implementation for the list of the idle connections. The default value is true. + This flag is required when you want to use asynchronous connection retrieval.
+ Setting this flag ensures that threads receive connections in the order they arrive.
+ During performance tests, there is a very large difference in how locks + and lock waiting is implemented. When fairQueue=true + there is a decision making process based on what operating system the system is running. + If the system is running on Linux (property os.name=Linux. + To disable this Linux specific behavior and still use the fair queue, simply add the property + org.apache.tomcat.jdbc.pool.FairBlockingQueue.ignoreOS=true to your system properties + before the connection pool classes are loaded. +

+
abandonWhenPercentageFull +

(int) Connections that have been abandoned (timed out) wont get closed and reported up unless + the number of connections in use are above the percentage defined by abandonWhenPercentageFull. + The value should be between 0-100. + The default value is 0, which implies that connections are eligible for closure as soon + as removeAbandonedTimeout has been reached.

+
maxAge +

(long) Time in milliseconds to keep this connection. When a connection is returned to the pool, + the pool will check to see if the now - time-when-connected > maxAge has been reached, + and if so, it closes the connection rather than returning it to the pool. + The default value is 0, which implies that connections will be left open and no age check + will be done upon returning the connection to the pool.

+
useEquals +

(boolean) Set to true if you wish the ProxyConnection class to use String.equals and set to false + when you wish to use == when comparing method names. This property does not apply to added interceptors as those are configured individually. + The default value is true. +

+
suspectTimeout +

(int) Timeout value in seconds. Default value is 0.
+ Similar to to the removeAbandonedTimeout value but instead of treating the connection + as abandoned, and potentially closing the connection, this simply logs the warning if + logAbandoned is set to true. If this value is equal or less than 0, no suspect + checking will be performed. Suspect checking only takes place if the timeout value is larger than 0 and + the connection was not abandoned or if abandon check is disabled. If a connection is suspect a WARN message gets + logged and a JMX notification gets sent once. +

+
rollbackOnReturn +

(boolean) If autoCommit==false then the pool can terminate the transaction by calling rollback on the connection as it is returned to the pool + Default value is false.
+

+
commitOnReturn +

(boolean) If autoCommit==false then the pool can complete the transaction by calling commit on the connection as it is returned to the pool + If rollbackOnReturn==true then this attribute is ignored. + Default value is false.
+

+
alternateUsernameAllowed +

(boolean) By default, the jdbc-pool will ignore the + DataSource.getConnection(username,password) + call, and simply return a previously pooled connection under the globally configured properties username and password, for performance reasons. +

+

+ The pool can however be configured to allow use of different credentials + each time a connection is requested. To enable the functionality described in the + DataSource.getConnection(username,password) + call, simply set the property alternateUsernameAllowed + to true.
+ Should you request a connection with the credentials user1/password1 and the connection + was previously connected using different user2/password2, the connection will be closed, + and reopened with the requested credentials. This way, the pool size is still managed + on a global level, and not on a per schema level.
+ The default value is false.
+ This property was added as an enhancement to bug 50025. +

+
dataSource +

(javax.sql.DataSource) Inject a data source to the connection pool, and the pool will use the data source to retrieve connections instead of establishing them using the java.sql.Driver interface. + This is useful when you wish to pool XA connections or connections established using a data source instead of a connection string. Default value is null +

+
dataSourceJNDI +

(String) The JNDI name for a data source to be looked up in JNDI and then used to establish connections to the database. See the dataSource attribute. Default value is null +

+
useDisposableConnectionFacade +

(boolean) Set this to true if you wish to put a facade on your connection so that it cannot be reused after it has been closed. This prevents a thread holding on to a + reference of a connection it has already called closed on, to execute queries on it. Default value is true. +

+
logValidationErrors +

(boolean) Set this to true to log errors during the validation phase to the log file. If set to true, errors will be logged as SEVERE. Default value is false for backwards compatibility. +

+
propagateInterruptState +

(boolean) Set this to true to propagate the interrupt state for a thread that has been interrupted (not clearing the interrupt state). Default value is false for backwards compatibility. +

+
ignoreExceptionOnPreLoad +

(boolean) Flag whether ignore error of connection creation while initializing the pool. + Set to true if you want to ignore error of connection creation while initializing the pool. + Set to false if you want to fail the initialization of the pool by throwing exception. + The default value is false. +

+
useStatementFacade +

(boolean) Set this to true if you wish to wrap statements in order to + enable equals() and hashCode() methods to be + called on the closed statements if any statement proxy is set. + Default value is true. +

+
+
+
Advanced usage
+
JDBC interceptors
+

To see an example of how to use an interceptor, take a look at + org.apache.tomcat.jdbc.pool.interceptor.ConnectionState. + This simple interceptor is a cache of three attributes, transaction isolation level, auto commit and read only state, + in order for the system to avoid not needed roundtrips to the database. +

+

Further interceptors will be added to the core of the pool as the need arises. Contributions are always welcome!

+

Interceptors are of course not limited to just java.sql.Connection but can be used to wrap any + of the results from a method invocation as well. You could build query performance analyzer that provides JMX notifications when a + query is running longer than the expected time.

+
+
Configuring JDBC interceptors
+

Configuring JDBC interceptors is done using the jdbcInterceptors property. + The property contains a list of semicolon separated class names. If the + classname is not fully qualified it will be prefixed with the + org.apache.tomcat.jdbc.pool.interceptor. prefix. +

+

Example:
+ + jdbcInterceptors="org.apache.tomcat.jdbc.pool.interceptor.ConnectionState; + org.apache.tomcat.jdbc.pool.interceptor.StatementFinalizer" + +
+ is the same as +
+ jdbcInterceptors="ConnectionState;StatementFinalizer" +

+

+ Interceptors can have properties as well. Properties for an interceptor + are specified within parentheses after the class name. Several properties + are separated by commas. +

+

Example:
+ + jdbcInterceptors="ConnectionState;StatementFinalizer(useEquals=true)" + +

+

+ Extra whitespace characters around class names, property names and values + are ignored. +

+
+
org.apache.tomcat.jdbc.pool.JdbcInterceptor
+

Abstract base class for all interceptors, can not be instantiated.

+
AttributeDescription
useEquals +

(boolean) Set to true if you wish the ProxyConnection class to use String.equals and set to false + when you wish to use == when comparing method names. + The default value is true. +

+
+
+
org.apache.tomcat.jdbc.pool.interceptor.ConnectionState
+

Caches the connection for the following attributes autoCommit, readOnly, + transactionIsolation and catalog. + It is a performance enhancement to avoid roundtrip to the database when getters are called or setters are called with an already set value. +

+
AttributeDescription
+
+
org.apache.tomcat.jdbc.pool.interceptor.StatementFinalizer
+

Keeps track of all statements created using createStatement, prepareStatement or prepareCall + and closes these statements when the connection is returned to the pool. +

+
AttributeDescription
+
+
org.apache.tomcat.jdbc.pool.interceptor.StatementCache
+

Caches PreparedStatement and/or CallableStatement + instances on a connection. +

+

The statements are cached per connection. + The count limit is counted globally for all connections that belong to + the same pool. Once the count reaches max, subsequent + statements are not returned to the cache and are closed immediately. +

+
AttributeDescription
prepared +

(boolean as String) Enable caching of PreparedStatement + instances created using prepareStatement calls. + The default value is true. +

+
callable +

(boolean as String) Enable caching of CallableStatement + instances created using prepareCall calls. + The default value is false. +

+
max +

(int as String) Limit on the count of cached statements across + the connection pool. + The default value is 50. +

+
+
+
org.apache.tomcat.jdbc.pool.interceptor.StatementDecoratorInterceptor
+

See 48392. Interceptor to wrap statements and result sets in order to prevent access to the actual connection + using the methods ResultSet.getStatement().getConnection() and Statement.getConnection() +

+
AttributeDescription
+
+
org.apache.tomcat.jdbc.pool.interceptor.QueryTimeoutInterceptor
+

Automatically calls java.sql.Statement.setQueryTimeout(seconds) when a new statement is created. + The pool itself doesn't timeout the query, it is still up to the JDBC driver to enforce query timeouts. +

+
AttributeDescription
queryTimeout +

(int as String) The number of seconds to set for the query timeout. + A value less than or equal to zero will disable this feature. + The default value is 1 seconds. +

+
+
+
org.apache.tomcat.jdbc.pool.interceptor.SlowQueryReport
+

Keeps track of query performance and issues log entries when queries exceed a time threshold of fail. + The log level used is WARN +

+
AttributeDescription
threshold +

(int as String) The number of milliseconds a query has to exceed before issuing a log alert. + The default value is 1000 milliseconds. +

+
maxQueries +

(int as String) The maximum number of queries to keep track of in order to preserve memory space. + A value less than or equal to 0 will disable this feature. + The default value is 1000. +

+
+
+
org.apache.tomcat.jdbc.pool.interceptor.SlowQueryReportJmx
+

Extends the SlowQueryReport and in addition to log entries it issues JMX notification + for monitoring tools to react to. Inherits all the attributes from its parent class. + This class uses Tomcat's JMX engine so it wont work outside of the Tomcat container. + By default, JMX notifications are sent through the ConnectionPool mbean if it is enabled. + The SlowQueryReportJmx can also register an MBean if notifyPool=false +

+
AttributeDescription
notifyPool +

(boolean as String) Set to false if you want JMX notifications to go to the SlowQueryReportJmx MBean + The default value is true. +

+
objectName +

(String) Define a valid javax.management.ObjectName string that will be used to register this object with the platform mbean server + The default value is null and the object will be registered using + tomcat.jdbc:type=org.apache.tomcat.jdbc.pool.interceptor.SlowQueryReportJmx,name=the-name-of-the-pool +

+
+
+
org.apache.tomcat.jdbc.pool.interceptor.ResetAbandonedTimer
+

+ The abandoned timer starts when a connection is checked out from the pool. + This means if you have a 30second timeout and run 10x10second queries using the connection + it will be marked abandoned and potentially reclaimed depending on the abandonWhenPercentageFull + attribute. + Using this interceptor it will reset the checkout timer every time you perform an operation on the connection or execute a + query successfully. +

+
AttributeDescription
+
+
Code Example
+

Other examples of Tomcat configuration for JDBC usage can be found in the Tomcat documentation.

+
Plain Ol' Java
+

Here is a simple example of how to create and use a data source.

+
  import java.sql.Connection;
+  import java.sql.ResultSet;
+  import java.sql.Statement;
+
+  import org.apache.tomcat.jdbc.pool.DataSource;
+  import org.apache.tomcat.jdbc.pool.PoolProperties;
+
+  public class SimplePOJOExample {
+
+      public static void main(String[] args) throws Exception {
+          PoolProperties p = new PoolProperties();
+          p.setUrl("jdbc:mysql://localhost:3306/mysql");
+          p.setDriverClassName("com.mysql.jdbc.Driver");
+          p.setUsername("root");
+          p.setPassword("password");
+          p.setJmxEnabled(true);
+          p.setTestWhileIdle(false);
+          p.setTestOnBorrow(true);
+          p.setValidationQuery("SELECT 1");
+          p.setTestOnReturn(false);
+          p.setValidationInterval(30000);
+          p.setTimeBetweenEvictionRunsMillis(30000);
+          p.setMaxActive(100);
+          p.setInitialSize(10);
+          p.setMaxWait(10000);
+          p.setRemoveAbandonedTimeout(60);
+          p.setMinEvictableIdleTimeMillis(30000);
+          p.setMinIdle(10);
+          p.setLogAbandoned(true);
+          p.setRemoveAbandoned(true);
+          p.setJdbcInterceptors(
+            "org.apache.tomcat.jdbc.pool.interceptor.ConnectionState;"+
+            "org.apache.tomcat.jdbc.pool.interceptor.StatementFinalizer");
+          DataSource datasource = new DataSource();
+          datasource.setPoolProperties(p);
+
+          Connection con = null;
+          try {
+            con = datasource.getConnection();
+            Statement st = con.createStatement();
+            ResultSet rs = st.executeQuery("select * from user");
+            int cnt = 1;
+            while (rs.next()) {
+                System.out.println((cnt++)+". Host:" +rs.getString("Host")+
+                  " User:"+rs.getString("User")+" Password:"+rs.getString("Password"));
+            }
+            rs.close();
+            st.close();
+          } finally {
+            if (con!=null) try {con.close();}catch (Exception ignore) {}
+          }
+      }
+
+  }
+
+
As a Resource
+

And here is an example on how to configure a resource for JNDI lookups

+
<Resource name="jdbc/TestDB"
+          auth="Container"
+          type="javax.sql.DataSource"
+          factory="org.apache.tomcat.jdbc.pool.DataSourceFactory"
+          testWhileIdle="true"
+          testOnBorrow="true"
+          testOnReturn="false"
+          validationQuery="SELECT 1"
+          validationInterval="30000"
+          timeBetweenEvictionRunsMillis="30000"
+          maxActive="100"
+          minIdle="10"
+          maxWait="10000"
+          initialSize="10"
+          removeAbandonedTimeout="60"
+          removeAbandoned="true"
+          logAbandoned="true"
+          minEvictableIdleTimeMillis="30000"
+          jmxEnabled="true"
+          jdbcInterceptors="org.apache.tomcat.jdbc.pool.interceptor.ConnectionState;
+            org.apache.tomcat.jdbc.pool.interceptor.StatementFinalizer"
+          username="root"
+          password="password"
+          driverClassName="com.mysql.jdbc.Driver"
+          url="jdbc:mysql://localhost:3306/mysql"/>
+ +
+
Asynchronous Connection Retrieval
+

The Tomcat JDBC connection pool supports asynchronous connection retrieval without adding additional threads to the + pool library. It does this by adding a method to the data source called Future<Connection> getConnectionAsync(). + In order to use the async retrieval, two conditions must be met: +

+
    +
  1. You must configure the fairQueue property to be true.
  2. +
  3. You will have to cast the data source to org.apache.tomcat.jdbc.pool.DataSource
  4. +
+ An example of using the async feature is show below. +
  Connection con = null;
+  try {
+    Future<Connection> future = datasource.getConnectionAsync();
+    while (!future.isDone()) {
+      System.out.println("Connection is not yet available. Do some background work");
+      try {
+        Thread.sleep(100); //simulate work
+      }catch (InterruptedException x) {
+        Thread.currentThread().interrupt();
+      }
+    }
+    con = future.get(); //should return instantly
+    Statement st = con.createStatement();
+    ResultSet rs = st.executeQuery("select * from user");
+ +
+
Interceptors
+

Interceptors are a powerful way to enable, disable or modify functionality on a specific connection or its sub components. + There are many different use cases for when interceptors are useful. By default, and for performance reasons, the connection pool is stateless. + The only state the pool itself inserts are defaultAutoCommit, defaultReadOnly, defaultTransactionIsolation, defaultCatalog if + these are set. These 4 properties are only set upon connection creation. Should these properties be modified during the usage of the connection, + the pool itself will not reset them.

+

An interceptor has to extend the org.apache.tomcat.jdbc.pool.JdbcInterceptor class. This class is fairly simple, + You will need to have a no arg constructor

+
  public JdbcInterceptor() {
+  }
+

+ When a connection is borrowed from the pool, the interceptor can initialize or in some other way react to the event by implementing the +

+
  public abstract void reset(ConnectionPool parent, PooledConnection con);
+

+ method. This method gets called with two parameters, a reference to the connection pool itself ConnectionPool parent + and a reference to the underlying connection PooledConnection con. +

+

+ When a method on the java.sql.Connection object is invoked, it will cause the +

+
  public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
+

+ method to get invoked. The Method method is the actual method invoked, and Object[] args are the arguments. + To look at a very simple example, where we demonstrate how to make the invocation to java.sql.Connection.close() a noop + if the connection has been closed +

+
  if (CLOSE_VAL==method.getName()) {
+      if (isClosed()) return null; //noop for already closed.
+  }
+  return super.invoke(proxy,method,args);
+

+ There is an observation being made. It is the comparison of the method name. One way to do this would be to do + "close".equals(method.getName()). + Above we see a direct reference comparison between the method name and static final String reference. + According to the JVM spec, method names and static final String end up in a shared constant pool, so the reference comparison should work. + One could of course do this as well: +

+
  if (compare(CLOSE_VAL,method)) {
+      if (isClosed()) return null; //noop for already closed.
+  }
+  return super.invoke(proxy,method,args);
+

+ The compare(String,Method) will use the useEquals flag on an interceptor and do either reference comparison or + a string value comparison when the useEquals=true flag is set. +

+

Pool start/stop
+ When the connection pool is started or closed, you can be notified. You will only be notified once per interceptor class + even though it is an instance method. and you will be notified using an interceptor currently not attached to a pool. +

+
  public void poolStarted(ConnectionPool pool) {
+  }
+
+  public void poolClosed(ConnectionPool pool) {
+  }
+

+ When overriding these methods, don't forget to call super if you are extending a class other than JdbcInterceptor +

+

Configuring interceptors
+ Interceptors are configured using the jdbcInterceptors property or the setJdbcInterceptors method. + An interceptor can have properties, and would be configured like this +

+
  String jdbcInterceptors=
+    "org.apache.tomcat.jdbc.pool.interceptor.ConnectionState(useEquals=true,fast=yes)"
+ +

Interceptor properties
+ Since interceptors can have properties, you need to be able to read the values of these properties within your + interceptor. Taking an example like the one above, you can override the setProperties method. +

+
  public void setProperties(Map<String, InterceptorProperty> properties) {
+     super.setProperties(properties);
+     final String myprop = "myprop";
+     InterceptorProperty p1 = properties.get(myprop);
+     if (p1!=null) {
+         setMyprop(Long.parseLong(p1.getValue()));
+     }
+  }
+ +
+
Getting the actual JDBC connection
+

Connection pools create wrappers around the actual connection in order to properly pool them. + We also create interceptors in these wrappers to be able to perform certain functions. + If there is a need to retrieve the actual connection, one can do so using the javax.sql.PooledConnection + interface. +

+
  Connection con = datasource.getConnection();
+  Connection actual = ((javax.sql.PooledConnection)con).getConnection();
+ +
+ +
Building
+

We build the JDBC pool code with 1.6, but it is backwards compatible down to 1.5 for runtime environment. For unit test, we use 1.6 and higher

+

Other examples of Tomcat configuration for JDBC usage can be found in the Tomcat documentation.

+
Building from source
+

Building is pretty simple. The pool has a dependency on tomcat-juli.jar and in case you want the SlowQueryReportJmx

+
  javac -classpath tomcat-juli.jar \
+        -d . \
+        org/apache/tomcat/jdbc/pool/*.java \
+        org/apache/tomcat/jdbc/pool/interceptor/*.java \
+        org/apache/tomcat/jdbc/pool/jmx/*.java
+

+ A build file can be found in the Tomcat source repository. +

+

+ As a convenience, a build file is also included where a simple build command will generate all files needed. +

+
  ant download  (downloads dependencies)
+  ant build     (compiles and generates .jar files)
+  ant dist      (creates a release package)
+  ant test      (runs tests, expects a test database to be setup)
+ +

+ The system is structured for a Maven build, but does generate release artifacts. Just the library itself. +

+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jndi-datasource-examples-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jndi-datasource-examples-howto.html new file mode 100644 index 0000000..f449c34 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jndi-datasource-examples-howto.html @@ -0,0 +1,709 @@ +Apache Tomcat 7 (7.0.108) - JNDI Datasource HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

JNDI Datasource HOW-TO

Table of Contents
+ +
Introduction
+ +

JNDI Datasource configuration is covered extensively in the +JNDI-Resources-HOWTO. However, feedback from tomcat-user has +shown that specifics for individual configurations can be rather tricky.

+ +

Here then are some example configurations that have been posted to +tomcat-user for popular databases and some general tips for db usage.

+ +

You should be aware that since these notes are derived from configuration +and/or feedback posted to tomcat-user YMMV :-). Please let us +know if you have any other tested configurations that you feel may be of use +to the wider audience, or if you feel we can improve this section in anyway.

+ +

+Please note that JNDI resource configuration changed somewhat between +Tomcat 5.0.x and Tomcat 5.5.x. You will most likely need to modify older +JNDI resource configurations to match the syntax in the example below in order +to make them work in Tomcat 7.x.x. +

+ +

+Also, please note that JNDI DataSource configuration in general, and this +tutorial in particular, assumes that you have read and understood the +Context and +Host configuration references, including +the section about Automatic Application Deployment in the latter reference. +

+
DriverManager, the service provider mechanism and memory leaks
+ +

java.sql.DriverManager supports the +service +provider mechanism. This feature is that all the available JDBC drivers +that announce themselves by providing a META-INF/services/java.sql.Driver +file are automatically discovered, loaded and registered, +relieving you from the need to load the database driver explicitly before +you create a JDBC connection. +However, the implementation is fundamentally broken in all Java versions for +a servlet container environment. The problem is that +java.sql.DriverManager will scan for the drivers only once.

+ +

The JRE Memory Leak Prevention Listener +that is included with Apache Tomcat solves this by triggering the driver scan +during Tomcat startup. This is enabled by default. It means that only +libraries visible to the common class loader and its parents will be scanned for +database drivers. This include drivers in $CATALINA_HOME/lib, +$CATALINA_BASE/lib, the class path and (where the JRE supports it) +the endorsed directory. Drivers packaged in web applications (in +WEB-INF/lib) and in the shared class loader (where configured) will +not be visible and will not be loaded automatically. If you are considering +disabling this feature, note that the scan would be triggered by the first web +application that is using JDBC, leading to failures when this web application is +reloaded and for other web applications that rely on this feature. +

+ +

Thus, the web applications that have database drivers in their +WEB-INF/lib directory cannot rely on the service provider +mechanism and should register the drivers explicitly.

+ +

The list of drivers in java.sql.DriverManager is also +a known source of memory leaks. Any Drivers registered +by a web application must be deregistered when the web application stops. +Tomcat will attempt to automatically discover and deregister any +JDBC drivers loaded by the web application class loader when the web +application stops. +However, it is expected that applications do this for themselves via +a ServletContextListener. +

+ +
Database Connection Pool (DBCP 1.x) Configurations
+ +

The default database connection pool implementation in Apache Tomcat +relies on the libraries from the +Apache Commons project. +The following libraries are used: +

+ +
    +
  • Commons DBCP 1.x
  • +
  • Commons Pool 1.x
  • +
+ +

+These libraries are located in a single JAR at +$CATALINA_HOME/lib/tomcat-dbcp.jar. However, +only the classes needed for connection pooling have been included, and the +packages have been renamed to avoid interfering with applications. +

+ +

DBCP 1.4 provides support for JDBC 4.0.

+ +
Installation
+ +

See the +DBCP 1.x documentation for a complete list of configuration parameters. +

+ +
+ +
Preventing database connection pool leaks
+ +

+A database connection pool creates and manages a pool of connections +to a database. Recycling and reusing already existing connections +to a database is more efficient than opening a new connection. +

+ +

+There is one problem with connection pooling. A web application has +to explicitly close ResultSet's, Statement's, and Connection's. +Failure of a web application to close these resources can result in +them never being available again for reuse, a database connection pool "leak". +This can eventually result in your web application database connections failing +if there are no more available connections.

+ +

+There is a solution to this problem. The Apache Commons DBCP 1.x can be +configured to track and recover these abandoned database connections. Not +only can it recover them, but also generate a stack trace for the code +which opened these resources and never closed them.

+ +

+To configure a DBCP 1.x DataSource so that abandoned database connections are +removed and recycled add the following attribute to the +Resource configuration for your DBCP 1.x DataSource: +

+ +
removeAbandoned="true"
+ +

+When available database connections run low DBCP 1.x will recover and recycle +any abandoned database connections it finds. The default is false. +

+ +

+Use the removeAbandonedTimeout attribute to set the number +of seconds a database connection has been idle before it is considered abandoned. +

+ +
removeAbandonedTimeout="60"
+ +

+The default timeout for removing abandoned connections is 300 seconds. +

+ +

+The logAbandoned attribute can be set to true +if you want DBCP 1.x to log a stack trace of the code which abandoned the +database connection resources. +

+
logAbandoned="true"
+

+The default is false. +

+ +
+ +
MySQL DBCP 1.x Example
+ +
0. Introduction
+

Versions of MySQL and JDBC +drivers that have been reported to work: +

+
    +
  • MySQL 3.23.47, MySQL 3.23.47 using InnoDB,, MySQL 3.23.58, MySQL 4.0.1alpha
  • +
  • Connector/J 3.0.11-stable (the official JDBC Driver)
  • +
  • mm.mysql 2.0.14 (an old 3rd party JDBC Driver)
  • +
+ +

Before you proceed, don't forget to copy the JDBC Driver's jar into $CATALINA_HOME/lib.

+ +
1. MySQL configuration
+

+Ensure that you follow these instructions as variations can cause problems. +

+ +

Create a new test user, a new database and a single test table. +Your MySQL user must have a password assigned. The driver +will fail if you try to connect with an empty password. +

+
mysql> GRANT ALL PRIVILEGES ON *.* TO javauser@localhost
+    ->   IDENTIFIED BY 'javadude' WITH GRANT OPTION;
+mysql> create database javatest;
+mysql> use javatest;
+mysql> create table testdata (
+    ->   id int not null auto_increment primary key,
+    ->   foo varchar(25),
+    ->   bar int);
+
+Note: the above user should be removed once testing is +complete! +
+ +

Next insert some test data into the testdata table. +

+
mysql> insert into testdata values(null, 'hello', 12345);
+Query OK, 1 row affected (0.00 sec)
+
+mysql> select * from testdata;
++----+-------+-------+
+| ID | FOO   | BAR   |
++----+-------+-------+
+|  1 | hello | 12345 |
++----+-------+-------+
+1 row in set (0.00 sec)
+
+mysql>
+ +
2. Context configuration
+

Configure the JNDI DataSource in Tomcat by adding a declaration for your +resource to your Context.

+

For example:

+
<Context>
+
+    <!-- maxActive: Maximum number of database connections in pool. Make sure you
+         configure your mysqld max_connections large enough to handle
+         all of your db connections. Set to -1 for no limit.
+         -->
+
+    <!-- maxIdle: Maximum number of idle database connections to retain in pool.
+         Set to -1 for no limit.  See also the DBCP 1.x documentation on this
+         and the minEvictableIdleTimeMillis configuration parameter.
+         -->
+
+    <!-- maxWait: Maximum time to wait for a database connection to become available
+         in ms, in this example 10 seconds. An Exception is thrown if
+         this timeout is exceeded.  Set to -1 to wait indefinitely.
+         -->
+
+    <!-- username and password: MySQL username and password for database connections  -->
+
+    <!-- driverClassName: Class name for the old mm.mysql JDBC driver is
+         org.gjt.mm.mysql.Driver - we recommend using Connector/J though.
+         Class name for the official MySQL Connector/J driver is com.mysql.jdbc.Driver.
+         -->
+
+    <!-- url: The JDBC connection url for connecting to your MySQL database.
+         -->
+
+  <Resource name="jdbc/TestDB" auth="Container" type="javax.sql.DataSource"
+               maxActive="100" maxIdle="30" maxWait="10000"
+               username="javauser" password="javadude" driverClassName="com.mysql.jdbc.Driver"
+               url="jdbc:mysql://localhost:3306/javatest"/>
+
+</Context>
+ +
3. web.xml configuration
+ +

Now create a WEB-INF/web.xml for this test application.

+
<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
+http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
+    version="2.4">
+  <description>MySQL Test App</description>
+  <resource-ref>
+      <description>DB Connection</description>
+      <res-ref-name>jdbc/TestDB</res-ref-name>
+      <res-type>javax.sql.DataSource</res-type>
+      <res-auth>Container</res-auth>
+  </resource-ref>
+</web-app>
+ +
4. Test code
+

Now create a simple test.jsp page for use later.

+
<%@ taglib uri="http://java.sun.com/jsp/jstl/sql" prefix="sql" %>
+<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
+
+<sql:query var="rs" dataSource="jdbc/TestDB">
+select id, foo, bar from testdata
+</sql:query>
+
+<html>
+  <head>
+    <title>DB Test</title>
+  </head>
+  <body>
+
+  <h2>Results</h2>
+
+<c:forEach var="row" items="${rs.rows}">
+    Foo ${row.foo}<br/>
+    Bar ${row.bar}<br/>
+</c:forEach>
+
+  </body>
+</html>
+ +

That JSP page makes use of +JSTL's +SQL and Core taglibs. You can get it from +Apache Tomcat Taglibs - Standard Tag Library +project — just make sure you get a 1.1.x or later release. Once you have +JSTL, copy jstl.jar and standard.jar to your web app's +WEB-INF/lib directory. + +

+ +

Finally deploy your web app into $CATALINA_BASE/webapps either +as a warfile called DBTest.war or into a sub-directory called +DBTest

+

Once deployed, point a browser at +http://localhost:8080/DBTest/test.jsp to view the fruits of +your hard work.

+ +
+ +
Oracle 8i, 9i & 10g
+
0. Introduction
+ +

Oracle requires minimal changes from the MySQL configuration except for the +usual gotchas :-)

+

Drivers for older Oracle versions may be distributed as *.zip files rather +than *.jar files. Tomcat will only use *.jar files installed in +$CATALINA_HOME/lib. Therefore classes111.zip +or classes12.zip will need to be renamed with a .jar +extension. Since jarfiles are zipfiles, there is no need to unzip and jar these +files - a simple rename will suffice.

+ +

For Oracle 9i onwards you should use oracle.jdbc.OracleDriver +rather than oracle.jdbc.driver.OracleDriver as Oracle have stated +that oracle.jdbc.driver.OracleDriver is deprecated and support +for this driver class will be discontinued in the next major release. +

+ +
1. Context configuration
+

In a similar manner to the mysql config above, you will need to define your +Datasource in your Context. Here we define a +Datasource called myoracle using the thin driver to connect as user scott, +password tiger to the sid called mysid. (Note: with the thin driver this sid is +not the same as the tnsname). The schema used will be the default schema for the +user scott.

+ +

Use of the OCI driver should simply involve a changing thin to oci in the URL string. +

+
<Resource name="jdbc/myoracle" auth="Container"
+              type="javax.sql.DataSource" driverClassName="oracle.jdbc.OracleDriver"
+              url="jdbc:oracle:thin:@127.0.0.1:1521:mysid"
+              username="scott" password="tiger" maxActive="20" maxIdle="10"
+              maxWait="-1"/>
+ +
2. web.xml configuration
+

You should ensure that you respect the element ordering defined by the DTD when you +create you applications web.xml file.

+
<resource-ref>
+ <description>Oracle Datasource example</description>
+ <res-ref-name>jdbc/myoracle</res-ref-name>
+ <res-type>javax.sql.DataSource</res-type>
+ <res-auth>Container</res-auth>
+</resource-ref>
+
3. Code example
+

You can use the same example application as above (assuming you create the required DB +instance, tables etc.) replacing the Datasource code with something like

+
Context initContext = new InitialContext();
+Context envContext  = (Context)initContext.lookup("java:/comp/env");
+DataSource ds = (DataSource)envContext.lookup("jdbc/myoracle");
+Connection conn = ds.getConnection();
+//etc.
+
+ + +
PostgreSQL
+
0. Introduction
+

PostgreSQL is configured in a similar manner to Oracle.

+ +
1. Required files
+

+Copy the Postgres JDBC jar to $CATALINA_HOME/lib. As with Oracle, the +jars need to be in this directory in order for DBCP 1.x's Classloader to find +them. This has to be done regardless of which configuration step you take next. +

+ +
2. Resource configuration
+ +

+You have two choices here: define a datasource that is shared across all Tomcat +applications, or define a datasource specifically for one application. +

+ +
2a. Shared resource configuration
+

+Use this option if you wish to define a datasource that is shared across +multiple Tomcat applications, or if you just prefer defining your datasource +in this file. +

+

This author has not had success here, although others have reported so. +Clarification would be appreciated here.

+ +
<Resource name="jdbc/postgres" auth="Container"
+          type="javax.sql.DataSource" driverClassName="org.postgresql.Driver"
+          url="jdbc:postgresql://127.0.0.1:5432/mydb"
+          username="myuser" password="mypasswd" maxActive="20" maxIdle="10" maxWait="-1"/>
+
2b. Application-specific resource configuration
+ +

+Use this option if you wish to define a datasource specific to your application, +not visible to other Tomcat applications. This method is less invasive to your +Tomcat installation. +

+ +

+Create a resource definition for your Context. +The Context element should look something like the following. +

+ +
<Context>
+
+<Resource name="jdbc/postgres" auth="Container"
+          type="javax.sql.DataSource" driverClassName="org.postgresql.Driver"
+          url="jdbc:postgresql://127.0.0.1:5432/mydb"
+          username="myuser" password="mypasswd" maxActive="20" maxIdle="10"
+maxWait="-1"/>
+</Context>
+ +
3. web.xml configuration
+
<resource-ref>
+ <description>postgreSQL Datasource example</description>
+ <res-ref-name>jdbc/postgres</res-ref-name>
+ <res-type>javax.sql.DataSource</res-type>
+ <res-auth>Container</res-auth>
+</resource-ref>
+ +
4. Accessing the datasource
+

+When accessing the datasource programmatically, remember to prepend +java:/comp/env to your JNDI lookup, as in the following snippet of +code. Note also that "jdbc/postgres" can be replaced with any value you prefer, provided +you change it in the above resource definition file as well. +

+ +
InitialContext cxt = new InitialContext();
+if ( cxt == null ) {
+   throw new Exception("Uh oh -- no context!");
+}
+
+DataSource ds = (DataSource) cxt.lookup( "java:/comp/env/jdbc/postgres" );
+
+if ( ds == null ) {
+   throw new Exception("Data source not found!");
+}
+ +
+
Non-DBCP Solutions
+

+These solutions either utilise a single connection to the database (not recommended for anything other +than testing!) or some other pooling technology. +

+
Oracle 8i with OCI client
+
Introduction
+

Whilst not strictly addressing the creation of a JNDI DataSource using the OCI client, these notes can be combined with the +Oracle and DBCP 1.x solution above.

+

+In order to use OCI driver, you should have an Oracle client installed. You should have installed +Oracle8i(8.1.7) client from cd, and download the suitable JDBC/OCI +driver(Oracle8i 8.1.7.1 JDBC/OCI Driver) from otn.oracle.com. +

+

+After renaming classes12.zip file to classes12.jar +for Tomcat, copy it into $CATALINA_HOME/lib. +You may also have to remove the javax.sql.* classes +from this file depending upon the version of Tomcat and JDK you are using. +

+
+ +
Putting it all together
+

+Ensure that you have the ocijdbc8.dll or .so in your $PATH or LD_LIBRARY_PATH + (possibly in $ORAHOME\bin) and also confirm that the native library can be loaded by a simple test program +using System.loadLibrary("ocijdbc8"); +

+

+You should next create a simple test servlet or jsp that has these +critical lines: +

+
DriverManager.registerDriver(new
+oracle.jdbc.driver.OracleDriver());
+conn =
+DriverManager.getConnection("jdbc:oracle:oci8:@database","username","password");
+

+where database is of the form host:port:SID Now if you try to access the URL of your +test servlet/jsp and what you get is a +ServletException with a root cause of java.lang.UnsatisfiedLinkError:get_env_handle. +

+

+First, the UnsatisfiedLinkError indicates that you have +

+
    +
  • a mismatch between your JDBC classes file and +your Oracle client version. The giveaway here is the message stating that a needed library file cannot be +found. For example, you may be using a classes12.zip file from Oracle Version 8.1.6 with a Version 8.1.5 +Oracle client. The classesXXX.zip file and Oracle client software versions must match. +
  • +
  • A $PATH, LD_LIBRARY_PATH problem.
  • +
  • It has been reported that ignoring the driver you have downloaded from otn and using +the classes12.zip file from the directory $ORAHOME\jdbc\lib will also work. +
  • +
+

+Next you may experience the error ORA-06401 NETCMN: invalid driver designator +

+

+The Oracle documentation says : "Cause: The login (connect) string contains an invalid +driver designator. Action: Correct the string and re-submit." + +Change the database connect string (of the form host:port:SID) with this one: +(description=(address=(host=myhost)(protocol=tcp)(port=1521))(connect_data=(sid=orcl))) +

+

+Ed. Hmm, I don't think this is really needed if you sort out your TNSNames - but I'm not an Oracle DBA :-) +

+
+
Common Problems
+

Here are some common problems encountered with a web application which +uses a database and tips for how to solve them.

+ +
Intermittent Database Connection Failures
+

+Tomcat runs within a JVM. The JVM periodically performs garbage collection +(GC) to remove java objects which are no longer being used. When the JVM +performs GC execution of code within Tomcat freezes. If the maximum time +configured for establishment of a database connection is less than the amount +of time garbage collection took you can get a database connection failure. +

+ +

To collect data on how long garbage collection is taking add the +-verbose:gc argument to your CATALINA_OPTS +environment variable when starting Tomcat. When verbose gc is enabled +your $CATALINA_BASE/logs/catalina.out log file will include +data for every garbage collection including how long it took.

+ +

When your JVM is tuned correctly 99% of the time a GC will take less +than one second. The remainder will only take a few seconds. Rarely, +if ever should a GC take more than 10 seconds.

+ +

Make sure that the db connection timeout is set to 10-15 seconds. +For the DBCP 1.x you set this using the parameter maxWait.

+ +
+ +
Random Connection Closed Exceptions
+

+These can occur when one request gets a db connection from the connection +pool and closes it twice. When using a connection pool, closing the +connection just returns it to the pool for reuse by another request, +it doesn't close the connection. And Tomcat uses multiple threads to +handle concurrent requests. Here is an example of the sequence +of events which could cause this error in Tomcat: +

+
+  Request 1 running in Thread 1 gets a db connection.
+
+  Request 1 closes the db connection.
+
+  The JVM switches the running thread to Thread 2
+
+  Request 2 running in Thread 2 gets a db connection
+  (the same db connection just closed by Request 1).
+
+  The JVM switches the running thread back to Thread 1
+
+  Request 1 closes the db connection a second time in a finally block.
+
+  The JVM switches the running thread back to Thread 2
+
+  Request 2 Thread 2 tries to use the db connection but fails
+  because Request 1 closed it.
+
+

+Here is an example of properly written code to use a database connection +obtained from a connection pool: +

+
  Connection conn = null;
+  Statement stmt = null;  // Or PreparedStatement if needed
+  ResultSet rs = null;
+  try {
+    conn = ... get connection from connection pool ...
+    stmt = conn.createStatement("select ...");
+    rs = stmt.executeQuery();
+    ... iterate through the result set ...
+    rs.close();
+    rs = null;
+    stmt.close();
+    stmt = null;
+    conn.close(); // Return to connection pool
+    conn = null;  // Make sure we don't close it twice
+  } catch (SQLException e) {
+    ... deal with errors ...
+  } finally {
+    // Always make sure result sets and statements are closed,
+    // and the connection is returned to the pool
+    if (rs != null) {
+      try { rs.close(); } catch (SQLException e) { ; }
+      rs = null;
+    }
+    if (stmt != null) {
+      try { stmt.close(); } catch (SQLException e) { ; }
+      stmt = null;
+    }
+    if (conn != null) {
+      try { conn.close(); } catch (SQLException e) { ; }
+      conn = null;
+    }
+  }
+ +
+ +
Context versus GlobalNamingResources
+

+ Please note that although the above instructions place the JNDI declarations in a Context + element, it is possible and sometimes desirable to place these declarations in the + GlobalNamingResources section of the server + configuration file. A resource placed in the GlobalNamingResources section will be shared + among the Contexts of the server. +

+
+ +
JNDI Resource Naming and Realm Interaction
+

+ In order to get Realms to work, the realm must refer to the datasource as + defined in the <GlobalNamingResources> or <Context> section, not a datasource as renamed + using <ResourceLink>. +

+
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jndi-resources-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jndi-resources-howto.html new file mode 100644 index 0000000..fd1106f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jndi-resources-howto.html @@ -0,0 +1,1091 @@ +Apache Tomcat 7 (7.0.108) - JNDI Resources HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

JNDI Resources HOW-TO

Table of Contents
+ +
Introduction
+ +

Tomcat provides a JNDI InitialContext implementation +instance for each web application running under it, in a manner that is +compatible with those provided by a + +Java Enterprise Edition application server. The Java EE standard provides +a standard set of elements in the /WEB-INF/web.xml file to +reference/define resources.

+ +

See the following Specifications for more information about programming APIs +for JNDI, and for the features supported by Java Enterprise Edition (Java EE) +servers, which Tomcat emulates for the services that it provides:

+ + +
web.xml configuration
+ +

The following elements may be used in the web application deployment +descriptor (/WEB-INF/web.xml) of your web application to define +resources:

+
    +
  • <env-entry> - Environment entry, a + single-value parameter that can be used to configure how the application + will operate.
  • +
  • <resource-ref> - Resource reference, + which is typically to an object factory for resources such as a JDBC + DataSource, a JavaMail Session, or custom + object factories configured into Tomcat.
  • +
  • <resource-env-ref> - Resource + environment reference, a new variation of resource-ref + added in Servlet 2.4 that is simpler to configure for resources + that do not require authentication information.
  • +
+ +

Providing that Tomcat is able to identify an appropriate resource factory to +use to create the resource and that no further configuration information is +required, Tomcat will use the information in /WEB-INF/web.xml to +create the resource.

+ +

Tomcat provides a number of Tomcat specific options for JNDI resources that +cannot be specified in web.xml. These include closeMethod that +enables faster cleaning-up of JNDI resources when a web application stops and +singleton that controls whether or not a new instance of the +resource is created for every JNDI lookup. To use these configuration options +the resource must be specified in a web application's +<Context> element or in the + +<GlobalNamingResources> element of +$CATALINA_BASE/conf/server.xml.

+ +
context.xml configuration
+ +

If Tomcat is unable to identify the appropriate resource factory and/or +additional configuration information is required, additional Tomcat specific +configuration must be specified before Tomcat can create the resource. +Tomcat specific resource configuration is entered in +the <Context> elements that +can be specified in either $CATALINA_BASE/conf/server.xml or, +preferably, the per-web-application context XML file +(META-INF/context.xml).

+ +

Tomcat specific resource configuration is performed using the following +elements in the <Context> +element:

+ +
    +
  • <Environment> - + Configure names and values for scalar environment entries that will be + exposed to the web application through the JNDI + InitialContext (equivalent to the inclusion of an + <env-entry> element in the web application + deployment descriptor).
  • +
  • <Resource> - + Configure the name and data type of a resource made available to the + application (equivalent to the inclusion of a + <resource-ref> element in the web application + deployment descriptor).
  • +
  • <ResourceLink> - + Add a link to a resource defined in the global JNDI context. Use resource + links to give a web application access to a resource defined in + the <GlobalNamingResources> + child element of the <Server> + element.
  • +
  • <Transaction> - + Add a resource factory for instantiating the UserTransaction object + instance that is available at java:comp/UserTransaction.
  • + +
+ +

Any number of these elements may be nested inside a +<Context> element and will +be associated only with that particular web application.

+ +

If a resource has been defined in a +<Context> element it is not +necessary for that resource to be defined in /WEB-INF/web.xml. +However, it is recommended to keep the entry in /WEB-INF/web.xml +to document the resource requirements for the web application.

+ +

Where the same resource name has been defined for a +<env-entry> element included in the web application +deployment descriptor (/WEB-INF/web.xml) and in an +<Environment> element as part of the +<Context> element for the +web application, the values in the deployment descriptor will take precedence +only if allowed by the corresponding +<Environment> element (by setting the override +attribute to "true").

+ +
Global configuration
+ +

Tomcat maintains a separate namespace of global resources for the +entire server. These are configured in the + +<GlobalNamingResources> element of +$CATALINA_BASE/conf/server.xml. You may expose these resources to +web applications by using a +<ResourceLink> to +include it in the per-web-application context.

+ +

If a resource has been defined using a +<ResourceLink>, it is not +necessary for that resource to be defined in /WEB-INF/web.xml. +However, it is recommended to keep the entry in /WEB-INF/web.xml +to document the resource requirements for the web application.

+ +
Using resources
+ +

The InitialContext is configured as a web application is +initially deployed, and is made available to web application components (for +read-only access). All configured entries and resources are placed in +the java:comp/env portion of the JNDI namespace, so a typical +access to a resource - in this case, to a JDBC DataSource - +would look something like this:

+ +
// Obtain our environment naming context
+Context initCtx = new InitialContext();
+Context envCtx = (Context) initCtx.lookup("java:comp/env");
+
+// Look up our data source
+DataSource ds = (DataSource)
+  envCtx.lookup("jdbc/EmployeeDB");
+
+// Allocate and use a connection from the pool
+Connection conn = ds.getConnection();
+... use this connection to access the database ...
+conn.close();
+ +
Tomcat Standard Resource Factories
+ +

Tomcat includes a series of standard resource factories that can + provide services to your web applications, but give you configuration + flexibility (via the + <Context> element) + without modifying the web application or the deployment descriptor. Each + subsection below details the configuration and usage of the standard resource + factories.

+ +

See Adding Custom + Resource Factories for information about how to create, install, + configure, and use your own custom resource factory classes with + Tomcat.

+ +

NOTE - Of the standard resource factories, only the + "JDBC Data Source" and "User Transaction" factories are mandated to + be available on other platforms, and then they are required only if + the platform implements the Java Enterprise Edition (Java EE) specs. + All other standard resource factories, plus custom resource factories + that you write yourself, are specific to Tomcat and cannot be assumed + to be available on other containers.

+ +
Generic JavaBean Resources
+ +
0. Introduction
+ +

This resource factory can be used to create objects of any + Java class that conforms to standard JavaBeans naming conventions (i.e. + it has a zero-arguments constructor, and has property setters that + conform to the setFoo() naming pattern. The resource factory will + only create a new instance of the appropriate bean class every time a + lookup() for this entry is made if the singleton + attribute of the factory is set to false.

+ +

The steps required to use this facility are described below.

+ +
1. Create Your JavaBean Class
+ +

Create the JavaBean class which will be instantiated each time + that the resource factory is looked up. For this example, assume + you create a class com.mycompany.MyBean, which looks + like this:

+ +
package com.mycompany;
+
+public class MyBean {
+
+  private String foo = "Default Foo";
+
+  public String getFoo() {
+    return (this.foo);
+  }
+
+  public void setFoo(String foo) {
+    this.foo = foo;
+  }
+
+  private int bar = 0;
+
+  public int getBar() {
+    return (this.bar);
+  }
+
+  public void setBar(int bar) {
+    this.bar = bar;
+  }
+
+
+}
+ +
2. Declare Your Resource Requirements
+ +

Next, modify your web application deployment descriptor + (/WEB-INF/web.xml) to declare the JNDI name under which + you will request new instances of this bean. The simplest approach is + to use a <resource-env-ref> element, like this:

+ +
<resource-env-ref>
+  <description>
+    Object factory for MyBean instances.
+  </description>
+  <resource-env-ref-name>
+    bean/MyBeanFactory
+  </resource-env-ref-name>
+  <resource-env-ref-type>
+    com.mycompany.MyBean
+  </resource-env-ref-type>
+</resource-env-ref>
+ +

WARNING - Be sure you respect the element ordering + that is required by the DTD for web application deployment descriptors! + See the + Servlet + Specification for details.

+ +
3. Code Your Application's Use Of This Resource
+ +

A typical use of this resource environment reference might look + like this:

+ +
Context initCtx = new InitialContext();
+Context envCtx = (Context) initCtx.lookup("java:comp/env");
+MyBean bean = (MyBean) envCtx.lookup("bean/MyBeanFactory");
+
+writer.println("foo = " + bean.getFoo() + ", bar = " +
+               bean.getBar());
+ +
4. Configure Tomcat's Resource Factory
+ +

To configure Tomcat's resource factory, add an element like this to the + <Context> element for + this web application.

+ +
<Context ...>
+  ...
+  <Resource name="bean/MyBeanFactory" auth="Container"
+            type="com.mycompany.MyBean"
+            factory="org.apache.naming.factory.BeanFactory"
+            bar="23"/>
+  ...
+</Context>
+ +

Note that the resource name (here, bean/MyBeanFactory + must match the value specified in the web application deployment + descriptor. We are also initializing the value of the bar + property, which will cause setBar(23) to be called before + the new bean is returned. Because we are not initializing the + foo property (although we could have), the bean will + contain whatever default value is set up by its constructor.

+ +

Some beans have properties with types that can not automatically be + converted from a string value. Setting such properties using the Tomcat + BeanFactory will fail with a NamingException. In cases were those beans + provide methods to set the properties from a string value, the Tomcat + BeanFactory can be configured to use these methods. The configuration is + done with the forceString attribute.

+ +

Assume our bean looks like this:

+ +
package com.mycompany;
+
+import java.net.InetAddress;
+import java.net.UnknownHostException;
+
+public class MyBean2 {
+
+  private InetAddress local = null;
+
+  public InetAddress getLocal() {
+    return local;
+  }
+
+  public void setLocal(InetAddress ip) {
+    local = ip;
+  }
+
+  public void setLocal(String localHost) {
+    try {
+      local = InetAddress.getByName(localHost);
+    } catch (UnknownHostException ex) {
+    }
+  }
+
+  private InetAddress remote = null;
+
+  public InetAddress getRemote() {
+    return remote;
+  }
+
+  public void setRemote(InetAddress ip) {
+    remote = ip;
+  }
+
+  public void host(String remoteHost) {
+    try {
+      remote = InetAddress.getByName(remoteHost);
+    } catch (UnknownHostException ex) {
+    }
+  }
+
+}
+ +

The bean has two properties, both are of type InetAddress. + The first property local has an additional setter taking a + string argument. By default the Tomcat BeanFactory would try to use the + automatically detected setter with the same argument type as the property + type and then throw a NamingException, because it is not prepared to convert + the given string attribute value to InetAddress. + We can tell the Tomcat BeanFactory to use the other setter like that:

+ +
<Context ...>
+  ...
+  <Resource name="bean/MyBeanFactory" auth="Container"
+            type="com.mycompany.MyBean2"
+            factory="org.apache.naming.factory.BeanFactory"
+            forceString="local"
+            local="localhost"/>
+  ...
+</Context>
+ +

The bean property remote can also be set from a string, + but one has to use the non-standard method name host. + To set local and remote use the following + configuration:

+ +
<Context ...>
+  ...
+  <Resource name="bean/MyBeanFactory" auth="Container"
+            type="com.mycompany.MyBean2"
+            factory="org.apache.naming.factory.BeanFactory"
+            forceString="local,remote=host"
+            local="localhost"
+            remote="tomcat.apache.org"/>
+  ...
+</Context>
+ +

Multiple property descriptions can be combined in + forceString by concatenation with comma as a separator. + Each property description consists of either only the property name + in which case the BeanFactory calls the setter method. Or it consist + of name=method in which case the property named + name is set by calling method method. + For properties of types String or of primitive type + or of their associated primitive wrapper classes using + forceString is not needed. The correct setter will be + automatically detected and argument conversion will be applied.

+ +
+ + +
UserDatabase Resources
+ +
0. Introduction
+ +

UserDatabase resources are typically configured as global resources for + use by a UserDatabase realm. Tomcat includes a UserDatabaseFactory that + creates UserDatabase resources backed by an XML file - usually + tomcat-users.xml

+ +

The steps required to set up a global UserDatabase resource are described + below.

+ +
1. Create/edit the XML file
+ +

The XML file is typically located at + $CATALINA_BASE/conf/tomcat-users.xml however, you are free to + locate the file anywhere on the file system. It is recommended that the XML + files are placed in $CATALINA_BASE/conf. A typical XML would + look like:

+ +
<?xml version='1.0' encoding='utf-8'?>
+<tomcat-users>
+  <role rolename="tomcat"/>
+  <role rolename="role1"/>
+  <user username="tomcat" password="tomcat" roles="tomcat"/>
+  <user username="both" password="tomcat" roles="tomcat,role1"/>
+  <user username="role1" password="tomcat" roles="role1"/>
+</tomcat-users>
+ +
2. Declare Your Resource
+ +

Next, modify $CATALINA_BASE/conf/server.xml to create the + UserDatabase resource based on your XML file. It should look something like + this:

+ +
<Resource name="UserDatabase"
+          auth="Container"
+          type="org.apache.catalina.UserDatabase"
+          description="User database that can be updated and saved"
+          factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
+          pathname="conf/tomcat-users.xml"
+          readonly="false" />
+ +

The pathname attribute can be a URL, an absolute path or a + relative path. If relative, it is relative to $CATALINA_BASE. +

+ +

The readonly attribute is optional and defaults to + true if not supplied. If the XML is writeable then it will be + written to when Tomcat starts. WARNING: When the file is + written it will inherit the default file permissions for the user Tomcat + is running as. Ensure that these are appropriate to maintain the security + of your installation.

+ +
3. Configure the Realm
+ +

Configure a UserDatabase Realm to use this resource as described in the + Realm configuration documentation.

+ +
+ + +
JavaMail Sessions
+ +
0. Introduction
+ +

In many web applications, sending electronic mail messages is a + required part of the system's functionality. The + Java Mail API + makes this process relatively straightforward, but requires many + configuration details that the client application must be aware of + (including the name of the SMTP host to be used for message sending).

+ +

Tomcat includes a standard resource factory that will create + javax.mail.Session session instances for you, already + configured to connect to an SMTP server. + In this way, the application is totally insulated from changes in the + email server configuration environment - it simply asks for, and receives, + a preconfigured session whenever needed.

+ +

The steps required for this are outlined below.

+ +
1. Declare Your Resource Requirements
+ +

The first thing you should do is modify the web application deployment + descriptor (/WEB-INF/web.xml) to declare the JNDI name under + which you will look up preconfigured sessions. By convention, all such + names should resolve to the mail subcontext (relative to the + standard java:comp/env naming context that is the root of + all provided resource factories. A typical web.xml entry + might look like this:

+
<resource-ref>
+  <description>
+    Resource reference to a factory for javax.mail.Session
+    instances that may be used for sending electronic mail
+    messages, preconfigured to connect to the appropriate
+    SMTP server.
+  </description>
+  <res-ref-name>
+    mail/Session
+  </res-ref-name>
+  <res-type>
+    javax.mail.Session
+  </res-type>
+  <res-auth>
+    Container
+  </res-auth>
+</resource-ref>
+ +

WARNING - Be sure you respect the element ordering + that is required by the DTD for web application deployment descriptors! + See the + Servlet + Specification for details.

+ +
2. Code Your Application's Use Of This Resource
+ +

A typical use of this resource reference might look like this:

+
Context initCtx = new InitialContext();
+Context envCtx = (Context) initCtx.lookup("java:comp/env");
+Session session = (Session) envCtx.lookup("mail/Session");
+
+Message message = new MimeMessage(session);
+message.setFrom(new InternetAddress(request.getParameter("from")));
+InternetAddress to[] = new InternetAddress[1];
+to[0] = new InternetAddress(request.getParameter("to"));
+message.setRecipients(Message.RecipientType.TO, to);
+message.setSubject(request.getParameter("subject"));
+message.setContent(request.getParameter("content"), "text/plain");
+Transport.send(message);
+ +

Note that the application uses the same resource reference name + that was declared in the web application deployment descriptor. This + is matched up against the resource factory that is configured in the + <Context> element + for the web application as described below.

+ +
3. Configure Tomcat's Resource Factory
+ +

To configure Tomcat's resource factory, add an elements like this to the + <Context> element for + this web application.

+ +
<Context ...>
+  ...
+  <Resource name="mail/Session" auth="Container"
+            type="javax.mail.Session"
+            mail.smtp.host="localhost"/>
+  ...
+</Context>
+ +

Note that the resource name (here, mail/Session) must + match the value specified in the web application deployment descriptor. + Customize the value of the mail.smtp.host parameter to + point at the server that provides SMTP service for your network.

+ +

Additional resource attributes and values will be converted to properties + and values and passed to + javax.mail.Session.getInstance(java.util.Properties) as part of + the java.util.Properties collection. In addition to the + properties defined in Annex A of the JavaMail specification, individual + providers may also support additional properties. +

+ +

If the resource is configured with a password attribute and + either a mail.smtp.user or mail.user attribute + then Tomcat's resource factory will configure and add a + javax.mail.Authenticator to the mail session.

+ +
4. Install the JavaMail libraries
+ +

+ Download the JavaMail API.

+ +

Unpackage the distribution and place mail.jar into $CATALINA_HOME/lib so + that it is available to Tomcat during the initialization of the mail Session + Resource. Note: placing this jar in both $CATALINA_HOME/lib + and a web application's lib folder will cause an error, so ensure you have + it in the $CATALINA_HOME/lib location only. +

+ +
5. Restart Tomcat
+ +

For the additional JAR to be visible to Tomcat, it is necessary for the + Tomcat instance to be restarted.

+ + +
Example Application
+ +

The /examples application included with Tomcat contains + an example of utilizing this resource factory. It is accessed via the + "JSP Examples" link. The source code for the servlet that actually + sends the mail message is in + /WEB-INF/classes/SendMailServlet.java.

+ +

WARNING - The default configuration assumes that there + is an SMTP server listing on port 25 on localhost. If this is + not the case, edit the + <Context> element for + this web application and modify the parameter value for the + mail.smtp.host parameter to be the host name of an SMTP server + on your network.

+ +
+ +
JDBC Data Sources
+ +
0. Introduction
+ +

Many web applications need to access a database via a JDBC driver, + to support the functionality required by that application. The Java EE + Platform Specification requires Java EE Application Servers to make + available a DataSource implementation (that is, a connection + pool for JDBC connections) for this purpose. Tomcat offers exactly + the same support, so that database-based applications you develop on + Tomcat using this service will run unchanged on any Java EE server.

+ +

For information about JDBC, you should consult the following:

+ + +

NOTE - The default data source support in Tomcat + is based on the DBCP 1.x connection pool from the + Commons + project. However, it is possible to use any other connection pool + that implements javax.sql.DataSource, by writing your + own custom resource factory, as described + below.

+ +
1. Install Your JDBC Driver
+ +

Use of the JDBC Data Sources JNDI Resource Factory requires + that you make an appropriate JDBC driver available to both Tomcat internal + classes and to your web application. This is most easily accomplished by + installing the driver's JAR file(s) into the + $CATALINA_HOME/lib directory, which makes the driver + available both to the resource factory and to your application.

+ +
2. Declare Your Resource Requirements
+ +

Next, modify the web application deployment descriptor + (/WEB-INF/web.xml) to declare the JNDI name under + which you will look up preconfigured data source. By convention, all such + names should resolve to the jdbc subcontext (relative to the + standard java:comp/env naming context that is the root of + all provided resource factories. A typical web.xml entry + might look like this:

+
<resource-ref>
+  <description>
+    Resource reference to a factory for java.sql.Connection
+    instances that may be used for talking to a particular
+    database that is configured in the <Context>
+    configuration for the web application.
+  </description>
+  <res-ref-name>
+    jdbc/EmployeeDB
+  </res-ref-name>
+  <res-type>
+    javax.sql.DataSource
+  </res-type>
+  <res-auth>
+    Container
+  </res-auth>
+</resource-ref>
+ +

WARNING - Be sure you respect the element ordering + that is required by the DTD for web application deployment descriptors! + See the + Servlet + Specification for details.

+ +
3. Code Your Application's Use Of This Resource
+ +

A typical use of this resource reference might look like this:

+
Context initCtx = new InitialContext();
+Context envCtx = (Context) initCtx.lookup("java:comp/env");
+DataSource ds = (DataSource)
+  envCtx.lookup("jdbc/EmployeeDB");
+
+Connection conn = ds.getConnection();
+... use this connection to access the database ...
+conn.close();
+ +

Note that the application uses the same resource reference name that was + declared in the web application deployment descriptor. This is matched up + against the resource factory that is configured in the + <Context> element for + the web application as described below.

+ +
4. Configure Tomcat's Resource Factory
+ +

To configure Tomcat's resource factory, add an element like this to the + <Context> element for + the web application.

+ +
<Context ...>
+  ...
+  <Resource name="jdbc/EmployeeDB"
+            auth="Container"
+            type="javax.sql.DataSource"
+            username="dbusername"
+            password="dbpassword"
+            driverClassName="org.hsql.jdbcDriver"
+            url="jdbc:HypersonicSQL:database"
+            maxActive="8"
+            maxIdle="4"/>
+  ...
+</Context>
+ +

Note that the resource name (here, jdbc/EmployeeDB) must + match the value specified in the web application deployment descriptor.

+ +

This example assumes that you are using the HypersonicSQL database + JDBC driver. Customize the driverClassName and + driverName parameters to match your actual database's + JDBC driver and connection URL.

+ +

The configuration properties for Tomcat's standard data source + resource factory + (org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory) are + as follows:

+
    +
  • driverClassName - Fully qualified Java class name + of the JDBC driver to be used.
  • +
  • username - Database username to be passed to our + JDBC driver.
  • +
  • password - Database password to be passed to our + JDBC driver.
  • +
  • url - Connection URL to be passed to our JDBC driver. + (For backwards compatibility, the property driverName + is also recognized.)
  • +
  • initialSize - The initial number of connections + that will be created in the pool during pool initialization. Default: 0
  • +
  • maxActive - The maximum number of connections + that can be allocated from this pool at the same time. Default: 8
  • +
  • minIdle - The minimum number of connections that + will sit idle in this pool at the same time. Default: 0
  • +
  • maxIdle - The maximum number of connections that + can sit idle in this pool at the same time. Default: 8
  • +
  • maxWait - The maximum number of milliseconds that the + pool will wait (when there are no available connections) for a + connection to be returned before throwing an exception. Default: -1 (infinite)
  • +
+

Some additional properties handle connection validation:

+
    +
  • validationQuery - SQL query that can be used by the + pool to validate connections before they are returned to the + application. If specified, this query MUST be an SQL SELECT + statement that returns at least one row.
  • +
  • validationQueryTimeout - Timeout in seconds + for the validation query to return. Default: -1 (infinite)
  • +
  • testOnBorrow - true or false: whether a connection + should be validated using the validation query each time it is + borrowed from the pool. Default: true
  • +
  • testOnReturn - true or false: whether a connection + should be validated using the validation query each time it is + returned to the pool. Default: false
  • +
+

The optional evictor thread is responsible for shrinking the pool + by removing any connections which are idle for a long time. The evictor + does not respect minIdle. Note that you do not need to + activate the evictor thread if you only want the pool to shrink according + to the configured maxIdle property.

+

The evictor is disabled by default and can be configured using + the following properties:

+
    +
  • timeBetweenEvictionRunsMillis - The number of + milliseconds between consecutive runs of the evictor. + Default: -1 (disabled)
  • +
  • numTestsPerEvictionRun - The number of connections + that will be checked for idleness by the evictor during each + run of the evictor. Default: 3
  • +
  • minEvictableIdleTimeMillis - The idle time in + milliseconds after which a connection can be removed from the pool + by the evictor. Default: 30*60*1000 (30 minutes)
  • +
  • testWhileIdle - true or false: whether a connection + should be validated by the evictor thread using the validation query + while sitting idle in the pool. Default: false
  • +
+

Another optional feature is the removal of abandoned connections. + A connection is called abandoned if the application does not return it + to the pool for a long time. The pool can close such connections + automatically and remove them from the pool. This is a workaround + for applications leaking connections.

+

The abandoning feature is disabled by default and can be configured + using the following properties:

+
    +
  • removeAbandoned - true or false: whether to + remove abandoned connections from the pool. Default: false
  • +
  • removeAbandonedTimeout - The number of + seconds after which a borrowed connection is assumed to be abandoned. + Default: 300
  • +
  • logAbandoned - true or false: whether to log + stack traces for application code which abandoned a statement + or connection. This adds serious overhead. Default: false
  • +
+

Finally there are various properties that allow further fine tuning + of the pool behaviour:

+
    +
  • defaultAutoCommit - true or false: default + auto-commit state of the connections created by this pool. + Default: true
  • +
  • defaultReadOnly - true or false: default + read-only state of the connections created by this pool. + Default: false
  • +
  • defaultTransactionIsolation - This sets the + default transaction isolation level. Can be one of + NONE, READ_COMMITTED, + READ_UNCOMMITTED, REPEATABLE_READ, + SERIALIZABLE. Default: no default set
  • +
  • poolPreparedStatements - true or false: whether to + pool PreparedStatements and CallableStatements. Default: false
  • +
  • maxOpenPreparedStatements - The maximum number of open + statements that can be allocated from the statement pool at the same time. + Default: -1 (unlimited)
  • +
  • defaultCatalog - The name of the default catalog. + Default: not set
  • +
  • connectionInitSqls - A list of SQL statements + run once after a Connection is created. Separate multiple statements + by semicolons (;). Default: no statement
  • +
  • connectionProperties - A list of driver specific + properties passed to the driver for creating connections. Each + property is given as name=value, multiple properties + are separated by semicolons (;). Default: no properties
  • +
  • accessToUnderlyingConnectionAllowed - true or false: whether + accessing the underlying connections is allowed. Default: false
  • +
+

For more details, please refer to the commons-dbcp documentation.

+ +
+ +
Adding Custom Resource Factories
+ +

If none of the standard resource factories meet your needs, you can write + your own factory and integrate it into Tomcat, and then configure the use + of this factory in the + <Context> element for + the web application. In the example below, we will create a factory that only + knows how to create com.mycompany.MyBean beans from the + Generic JavaBean Resources example + above.

+ +

1. Write A Resource Factory Class

+ +

You must write a class that implements the JNDI service provider + javax.naming.spi.ObjectFactory interface. Every time your + web application calls lookup() on a context entry that is + bound to this factory (assuming that the factory is configured with + singleton="false"), the + getObjectInstance() method is called, with the following + arguments:

+
    +
  • Object obj - The (possibly null) object containing + location or reference information that can be used in creating an object. + For Tomcat, this will always be an object of type + javax.naming.Reference, which contains the class name of + this factory class, as well as the configuration properties (from the + <Context> for the + web application) to use in creating objects to be returned.
  • +
  • Name name - The name to which this factory is bound + relative to nameCtx, or null if no name + is specified.
  • +
  • Context nameCtx - The context relative to which the + name parameter is specified, or null if + name is relative to the default initial context.
  • +
  • Hashtable environment - The (possibly null) + environment that is used in creating this object. This is generally + ignored in Tomcat object factories.
  • +
+ +

To create a resource factory that knows how to produce MyBean + instances, you might create a class like this:

+ +
package com.mycompany;
+
+import java.util.Enumeration;
+import java.util.Hashtable;
+import javax.naming.Context;
+import javax.naming.Name;
+import javax.naming.NamingException;
+import javax.naming.RefAddr;
+import javax.naming.Reference;
+import javax.naming.spi.ObjectFactory;
+
+public class MyBeanFactory implements ObjectFactory {
+
+  public Object getObjectInstance(Object obj,
+      Name name2, Context nameCtx, Hashtable environment)
+      throws NamingException {
+
+      // Acquire an instance of our specified bean class
+      MyBean bean = new MyBean();
+
+      // Customize the bean properties from our attributes
+      Reference ref = (Reference) obj;
+      Enumeration addrs = ref.getAll();
+      while (addrs.hasMoreElements()) {
+          RefAddr addr = (RefAddr) addrs.nextElement();
+          String name = addr.getType();
+          String value = (String) addr.getContent();
+          if (name.equals("foo")) {
+              bean.setFoo(value);
+          } else if (name.equals("bar")) {
+              try {
+                  bean.setBar(Integer.parseInt(value));
+              } catch (NumberFormatException e) {
+                  throw new NamingException("Invalid 'bar' value " + value);
+              }
+          }
+      }
+
+      // Return the customized instance
+      return (bean);
+
+  }
+
+}
+ +

In this example, we are unconditionally creating a new instance of + the com.mycompany.MyBean class, and populating its properties + based on the parameters included in the <ResourceParams> + element that configures this factory (see below). You should note that any + parameter named factory should be skipped - that parameter is + used to specify the name of the factory class itself (in this case, + com.mycompany.MyBeanFactory) rather than a property of the + bean being configured.

+ +

For more information about ObjectFactory, see the + + JNDI Service Provider Interface (SPI) Specification.

+ +

You will need to compile this class against a class path that includes + all of the JAR files in the $CATALINA_HOME/lib directory. When you are through, + place the factory class (and the corresponding bean class) unpacked under + $CATALINA_HOME/lib, or in a JAR file inside + $CATALINA_HOME/lib. In this way, the required class + files are visible to both Catalina internal resources and your web + application.

+ +

2. Declare Your Resource Requirements

+ +

Next, modify your web application deployment descriptor + (/WEB-INF/web.xml) to declare the JNDI name under which + you will request new instances of this bean. The simplest approach is + to use a <resource-env-ref> element, like this:

+ +
<resource-env-ref>
+  <description>
+    Object factory for MyBean instances.
+  </description>
+  <resource-env-ref-name>
+    bean/MyBeanFactory
+  </resource-env-ref-name>
+  <resource-env-ref-type>
+    com.mycompany.MyBean
+  </resource-env-ref-type>
+</resource-env-ref>
+ +

WARNING - Be sure you respect the element ordering + that is required by the DTD for web application deployment descriptors! + See the + Servlet + Specification for details.

+ +

3. Code Your Application's Use Of This Resource

+ +

A typical use of this resource environment reference might look + like this:

+ +
Context initCtx = new InitialContext();
+Context envCtx = (Context) initCtx.lookup("java:comp/env");
+MyBean bean = (MyBean) envCtx.lookup("bean/MyBeanFactory");
+
+writer.println("foo = " + bean.getFoo() + ", bar = " +
+               bean.getBar());
+ +

4. Configure Tomcat's Resource Factory

+ +

To configure Tomcat's resource factory, add an elements like this to the + <Context> element for + this web application.

+ +
<Context ...>
+  ...
+  <Resource name="bean/MyBeanFactory" auth="Container"
+            type="com.mycompany.MyBean"
+            factory="com.mycompany.MyBeanFactory"
+            singleton="false"
+            bar="23"/>
+  ...
+</Context>
+ +

Note that the resource name (here, bean/MyBeanFactory + must match the value specified in the web application deployment + descriptor. We are also initializing the value of the bar + property, which will cause setBar(23) to be called before + the new bean is returned. Because we are not initializing the + foo property (although we could have), the bean will + contain whatever default value is set up by its constructor.

+ +

You will also note that, from the application developer's perspective, + the declaration of the resource environment reference, and the programming + used to request new instances, is identical to the approach used for the + Generic JavaBean Resources example. This illustrates one of the + advantages of using JNDI resources to encapsulate functionality - you can + change the underlying implementation without necessarily having to + modify applications using the resources, as long as you maintain + compatible APIs.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jspapi/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jspapi/index.html new file mode 100644 index 0000000..019128c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/jspapi/index.html @@ -0,0 +1,34 @@ + + + + + + API docs + + + + +The JSP Javadoc is not installed by default. Download and install +the "fulldocs" package to get it. + +You can also access the javadoc online in the Tomcat + +documentation bundle. + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/logging.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/logging.html new file mode 100644 index 0000000..8aa7980 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/logging.html @@ -0,0 +1,650 @@ +Apache Tomcat 7 (7.0.108) - Logging in Tomcat

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Logging in Tomcat

Table of Contents
+ +
Introduction
+

+ Logging in Apache Tomcat is implemented with the help of + Apache Commons Logging + library. That library is a thin wrapper above different logging + frameworks. It provides Tomcat with the ability to log + hierarchically across various log levels without the need to rely on a + particular logging implementation. +

+ +

+ Since Tomcat 6.0, Tomcat uses a private package-renamed implementation of + Apache Commons Logging, to allow web applications to use their own + independent copies of the original Apache Commons Logging library. + In the default distribution this private copy of the library + is simplified and hardcoded to use the java.util.logging framework. +

+ +

+ To configure Tomcat to use alternative logging frameworks for its internal + logging, one has to replace the logging library with the one that is built + with the full implementation. Such library is provided as an extras + component. Instructions on how to configure Tomcat to use Log4j framework + for its internal logging may be found below. +

+ +

+ A web application running on Apache Tomcat can: +

+
    +
  • + Use system logging API, java.util.logging. +
  • +
  • + Use the logging API provided by the Java Servlets specification, + javax.servlet.ServletContext.log(...) +
  • +
  • + Use any logging framework of its choice. +
  • +
+ +

+ The logging frameworks used by different web applications run independently + of each other. See class loading + for more details. + The exception to this rule is java.util.logging, if it used + directly or indirectly by your logging library. That is because it is loaded + by the system and is shared across web applications. +

+ +
Java logging API — java.util.logging
+ +

+ Apache Tomcat has its own implementation of several key elements of + java.util.logging API. This implementation is called "JULI". + The key component there is a custom LogManager implementation, + that is aware of different web applications running on Tomcat (and + their different class loaders). It supports private per-application + logging configurations. It is also notified by Tomcat when a web application + is unloaded from memory, so that the references to its classes can be + cleared, preventing memory leaks. +

+ +

+ This java.util.logging implementation is enabled by providing + certain system properties when starting Java. The Apache Tomcat startup + scripts do this for you, but if you are using different tools to run + Tomcat (such as jsvc, or running Tomcat from within an IDE), you should + take care of them by yourself. +

+ +

+ More details about java.util.logging may be found in the documentation + for your JDK and on its Javadoc pages for the java.util.logging + package. +

+ +

+ More details about Tomcat JULI may be found below. +

+ +
+ +
Servlets logging API
+ +

+ The calls to javax.servlet.ServletContext.log(...) to write + log messages are handled by internal Tomcat logging. Such messages are + logged to the category named +

+
org.apache.catalina.core.ContainerBase.[${engine}].[${host}].[${context}]
+

+ This logging is performed according to the Tomcat logging configuration. You + cannot overwrite it in a web application. +

+ +

+ The Servlets logging API predates the java.util.logging API + that is now provided by Java. As such, it does not offer you much options. + E.g., you cannot control the log levels. It can be noted, though, that + in Apache Tomcat implementation the calls to ServletContext.log(String) + or GenericServlet.log(String) are logged at the INFO level. + The calls to ServletContext.log(String, Throwable) or + GenericServlet.log(String, Throwable) + are logged at the SEVERE level. +

+ +
+ +
Console
+ +

+ When running Tomcat on unixes, the console output is usually redirected + to the file named catalina.out. The name is configurable + using an environment variable. (See the startup scripts). + Whatever is written to System.err/out will be caught into + that file. That may include: +

+ +
    +
  • Uncaught exceptions printed by java.lang.ThreadGroup.uncaughtException(..)
  • +
  • Thread dumps, if you requested them via a system signal
  • +
+ +

+ When running as a service on Windows, the console output is also caught + and redirected, but the file names are different. +

+ +

+ The default logging configuration in Apache Tomcat writes the same + messages to the console and to a log file. This is great when using + Tomcat for development, but usually is not needed in production. +

+ +

+ Old applications that still use System.out or System.err + can be tricked by setting swallowOutput attribute on a + Context. If the attribute is set to + true, the calls to System.out/err during request + processing will be intercepted, and their output will be fed to the + logging subsystem using the + javax.servlet.ServletContext.log(...) calls.
+ Note, that the swallowOutput feature is + actually a trick, and it has its limitations. + It works only with direct calls to System.out/err, + and only during request processing cycle. It may not work in other + threads that might be created by the application. It cannot be used to + intercept logging frameworks that themselves write to the system streams, + as those start early and may obtain a direct reference to the streams + before the redirection takes place. +

+ +
+ +
Access logging
+ +

+ Access logging is a related but different feature, which is + implemented as a Valve. It uses self-contained + logic to write its log files. The essential requirement for + access logging is to handle a large continuous stream of data + with low overhead, so it only uses Apache Commons Logging for + its own debug messages. This implementation approach avoids + additional overhead and potentially complex configuration. + Please refer to the Valves + documentation for more details on its configuration, including + the various report formats. +

+ +
+ +
Using java.util.logging (default)
+ +

+ The default implementation of java.util.logging provided in the JDK is too + limited to be useful. A limitation of JDK Logging appears to be the + inability to have per-web application logging, as the configuration is + per-VM. As a result, Tomcat will, in the default configuration, replace the + default LogManager implementation with a container friendly implementation + called JULI, which addresses these shortcomings. It supports the same + configuration mechanisms as the standard JDK java.util.logging, using either + a programmatic approach, or properties files. The main difference is that + per-classloader properties files can be set (which enables easy redeployment + friendly webapp configuration), and the properties files support slightly + extended constructs which allows more freedom for defining handlers and + assigning them to loggers. +

+

+ JULI is enabled by default, and supports per classloader configuration, in + addition to the regular global java.util.logging configuration. This means + that logging can be configured at the following layers: +

+
    +
  • Globally. That is usually done in the + ${catalina.base}/conf/logging.properties file. + The file is specified by the java.util.logging.config.file + System property which is set by the startup scripts. + If it is not readable or is not configured, the default is to use the + ${java.home}/lib/logging.properties file in the JRE. +
  • +
  • In the web application. The file will be + WEB-INF/classes/logging.properties +
  • +
+

+ The default logging.properties in the JRE specifies a + ConsoleHandler that routes logging to System.err. + The default conf/logging.properties in Apache Tomcat also + adds several FileHandlers that write to files. +

+

+ A handler's log level threshold is INFO by default and can be set using + SEVERE, WARNING, INFO, CONFIG, FINE, FINER, FINEST or ALL. + You can also target specific packages to collect logging from and specify + a level. +

+

+ Here is how you would set debugging from Tomcat. You would need to ensure the + ConsoleHandler's (or FileHandler's') level is also set to collect this threshold, + so FINEST or ALL should be set. Please refer to java.util.logging + documentation in the JDK for the complete details: +

+
org.apache.catalina.level=FINEST
+

+ The configuration used by JULI is extremely similar to the one supported by + plain java.util.logging, but uses a few + extensions to allow better flexibility in assigning loggers. The main + differences are: +

+
    +
  • A prefix may be added to handler names, so that multiple handlers of a + single class may be instantiated. A prefix is a String which starts with a + digit, and ends with '.'. For example, 22foobar. is a valid + prefix.
  • +
  • System property replacement is performed for property values which + contain ${systemPropertyName}.
  • +
  • As in Java 6, loggers can define a list of handlers using the + loggerName.handlers property.
  • +
  • By default, loggers will not delegate to their parent if they have + associated handlers. This may be changed per logger using the + loggerName.useParentHandlers property, which accepts a + boolean value.
  • +
  • The root logger can define its set of handlers using the + .handlers property.
  • +
  • By default the log files will be kept on the file system forever. + This may be changed per handler using the + handlerName.maxDays property. If the specified value for the + property is <=0 then the log files will be kept on the + file system forever, otherwise they will be kept the specified maximum + days.
  • +
+

+ There are several additional implementation classes, that can be used + together with the ones provided by Java. The notable one is + org.apache.juli.FileHandler. +

+

+ org.apache.juli.FileHandler supports buffering of the + logs. The buffering is not enabled by default. To configure it, use the + bufferSize property of a handler. The value of 0 + uses system default buffering (typically an 8K buffer will be used). A + value of <0 forces a writer flush upon each log write. A + value >0 uses a BufferedOutputStream with the defined + value but note that the system default buffering will also be + applied. +

+

+ Example logging.properties file to be placed in $CATALINA_BASE/conf: +

+
handlers = 1catalina.org.apache.juli.FileHandler, \
+           2localhost.org.apache.juli.FileHandler, \
+           3manager.org.apache.juli.FileHandler, \
+           java.util.logging.ConsoleHandler
+
+.handlers = 1catalina.org.apache.juli.FileHandler, java.util.logging.ConsoleHandler
+
+############################################################
+# Handler specific properties.
+# Describes specific configuration info for Handlers.
+############################################################
+
+1catalina.org.apache.juli.FileHandler.level = FINE
+1catalina.org.apache.juli.FileHandler.directory = ${catalina.base}/logs
+1catalina.org.apache.juli.FileHandler.prefix = catalina.
+1catalina.org.apache.juli.FileHandler.maxDays = 90
+1catalina.org.apache.juli.FileHandler.encoding = UTF-8
+
+2localhost.org.apache.juli.FileHandler.level = FINE
+2localhost.org.apache.juli.FileHandler.directory = ${catalina.base}/logs
+2localhost.org.apache.juli.FileHandler.prefix = localhost.
+2localhost.org.apache.juli.FileHandler.maxDays = 90
+2localhost.org.apache.juli.FileHandler.encoding = UTF-8
+
+3manager.org.apache.juli.FileHandler.level = FINE
+3manager.org.apache.juli.FileHandler.directory = ${catalina.base}/logs
+3manager.org.apache.juli.FileHandler.prefix = manager.
+3manager.org.apache.juli.FileHandler.bufferSize = 16384
+3manager.org.apache.juli.FileHandler.maxDays = 90
+3manager.org.apache.juli.FileHandler.encoding = UTF-8
+
+java.util.logging.ConsoleHandler.level = FINE
+java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
+java.util.logging.ConsoleHandler.encoding = UTF-8
+
+############################################################
+# Facility specific properties.
+# Provides extra control for each logger.
+############################################################
+
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].level = INFO
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].handlers = \
+   2localhost.org.apache.juli.FileHandler
+
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].level = INFO
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].handlers = \
+   3manager.org.apache.juli.FileHandler
+
+# For example, set the org.apache.catalina.util.LifecycleBase logger to log
+# each component that extends LifecycleBase changing state:
+#org.apache.catalina.util.LifecycleBase.level = FINE
+ +

+ Example logging.properties for the servlet-examples web application to be + placed in WEB-INF/classes inside the web application: +

+
handlers = org.apache.juli.FileHandler, java.util.logging.ConsoleHandler
+
+############################################################
+# Handler specific properties.
+# Describes specific configuration info for Handlers.
+############################################################
+
+org.apache.juli.FileHandler.level = FINE
+org.apache.juli.FileHandler.directory = ${catalina.base}/logs
+org.apache.juli.FileHandler.prefix = servlet-examples.
+
+java.util.logging.ConsoleHandler.level = FINE
+java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
+ + +
Documentation references
+

See the following resources for additional information:

+ +
+ +
Considerations for productive usage
+

You may want to take note of the following:

+
    +
  • Consider removing ConsoleHandler from configuration.

    +

    By default (thanks to the .handlers setting) logging goes + both to a FileHandler and to a ConsoleHandler. + The output of the latter one is usually captured into a file, such as + catalina.out. Thus you end up with two copies of the same + messages.

    +
  • +
  • Consider removing FileHandlers for the applications + that you do not use. E.g., the one for host-manager.

  • +
  • The handlers by default use the system default encoding to write + the log files. It can be configured with encoding property. + See Javadoc for details.

  • +
  • Consider configuring an + Access log.

  • +
+
+ +
Using Log4j
+

+ This section explains how to configure Tomcat to use + log4j rather than + java.util.logging for all Tomcat's internal logging. +

+

Note: The steps described in this section are needed + when you want to reconfigure Tomcat to use Apache log4j for its own + logging. These steps are not needed if you just want + to use log4j in your own web application. — In that case, just + put log4j.jar and log4j.properties into + WEB-INF/lib and WEB-INF/classes + of your web application. +

+

+ The following steps describe configuring log4j to output Tomcat's + internal logging. +

+ +
    +
  1. Create a file called log4j.properties with the + following content and save it into $CATALINA_BASE/lib
  2. +
+

+log4j.rootLogger = INFO, CATALINA
+
+# Define all the appenders
+log4j.appender.CATALINA = org.apache.log4j.DailyRollingFileAppender
+log4j.appender.CATALINA.File = ${catalina.base}/logs/catalina
+log4j.appender.CATALINA.Append = true
+log4j.appender.CATALINA.Encoding = UTF-8
+# Roll-over the log once per day
+log4j.appender.CATALINA.DatePattern = '.'yyyy-MM-dd'.log'
+log4j.appender.CATALINA.layout = org.apache.log4j.PatternLayout
+log4j.appender.CATALINA.layout.ConversionPattern = %d [%t] %-5p %c- %m%n
+
+log4j.appender.LOCALHOST = org.apache.log4j.DailyRollingFileAppender
+log4j.appender.LOCALHOST.File = ${catalina.base}/logs/localhost
+log4j.appender.LOCALHOST.Append = true
+log4j.appender.LOCALHOST.Encoding = UTF-8
+log4j.appender.LOCALHOST.DatePattern = '.'yyyy-MM-dd'.log'
+log4j.appender.LOCALHOST.layout = org.apache.log4j.PatternLayout
+log4j.appender.LOCALHOST.layout.ConversionPattern = %d [%t] %-5p %c- %m%n
+
+log4j.appender.MANAGER = org.apache.log4j.DailyRollingFileAppender
+log4j.appender.MANAGER.File = ${catalina.base}/logs/manager
+log4j.appender.MANAGER.Append = true
+log4j.appender.MANAGER.Encoding = UTF-8
+log4j.appender.MANAGER.DatePattern = '.'yyyy-MM-dd'.log'
+log4j.appender.MANAGER.layout = org.apache.log4j.PatternLayout
+log4j.appender.MANAGER.layout.ConversionPattern = %d [%t] %-5p %c- %m%n
+
+log4j.appender.HOST-MANAGER = org.apache.log4j.DailyRollingFileAppender
+log4j.appender.HOST-MANAGER.File = ${catalina.base}/logs/host-manager
+log4j.appender.HOST-MANAGER.Append = true
+log4j.appender.HOST-MANAGER.Encoding = UTF-8
+log4j.appender.HOST-MANAGER.DatePattern = '.'yyyy-MM-dd'.log'
+log4j.appender.HOST-MANAGER.layout = org.apache.log4j.PatternLayout
+log4j.appender.HOST-MANAGER.layout.ConversionPattern = %d [%t] %-5p %c- %m%n
+
+log4j.appender.CONSOLE = org.apache.log4j.ConsoleAppender
+log4j.appender.CONSOLE.Encoding = UTF-8
+log4j.appender.CONSOLE.layout = org.apache.log4j.PatternLayout
+log4j.appender.CONSOLE.layout.ConversionPattern = %d [%t] %-5p %c- %m%n
+
+# Configure which loggers log to which appenders
+log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost] = INFO, LOCALHOST
+log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager] =\
+  INFO, MANAGER
+log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager] =\
+  INFO, HOST-MANAGER
+
    +
  1. Download Log4J + (Tomcat requires v1.2.x).
  2. + +
  3. Download or build tomcat-juli.jar and + tomcat-juli-adapters.jar that are available as an "extras" + component for Tomcat. See Additional Components + documentation for details.

    +

    This tomcat-juli.jar differs from the default one. It + contains the full Apache Commons Logging implementation and thus is + able to discover the presence of log4j and configure itself.

    +
  4. + +
  5. If you want to configure Tomcat to use log4j globally:

    +
      +
    • Put log4j.jar and + tomcat-juli-adapters.jar from "extras" into + $CATALINA_HOME/lib.
    • +
    • Replace $CATALINA_HOME/bin/tomcat-juli.jar with + tomcat-juli.jar from "extras".
    • +
    +
  6. + +
  7. If you are running Tomcat with separate $CATALINA_HOME and + $CATALINA_BASE and want to configure to use log4j in a single + $CATALINA_BASE only:

    +
      +
    • Create $CATALINA_BASE/bin and + $CATALINA_BASE/lib directories if they do not exist. +
    • +
    • Put log4j.jar and + tomcat-juli-adapters.jar from "extras" into + $CATALINA_BASE/lib
    • +
    • Put tomcat-juli.jar from "extras" as + $CATALINA_BASE/bin/tomcat-juli.jar
    • +
    • If you are running with a + security manager, you + would need to edit the + $CATALINA_BASE/conf/catalina.policy file to adjust + it to using a different copy of tomcat-juli.jar.
    • +
    +
  8. + +
  9. Delete $CATALINA_BASE/conf/logging.properties to + prevent java.util.logging generating zero length log files.

  10. + +
  11. Start Tomcat

  12. +
+ +

+ This log4j configuration mirrors the default java.util.logging setup + that ships with Tomcat: both the manager and host-manager apps get an + individual log file, and everything else goes to the "catalina.log" log + file. Each file is rolled-over once per day. +

+ +

+ You can (and should) be more picky about which packages to include + in the logging. Tomcat defines loggers by Engine and Host names. + For example, for a more detailed Catalina localhost log, add this to the + end of the log4j.properties above. Note that there are known issues with + using this naming convention (with square brackets) in log4j XML based + configuration files, so we recommend you use a properties file as + described until a future version of log4j allows this convention. +

+
log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost]=DEBUG
+log4j.logger.org.apache.catalina.core=DEBUG
+log4j.logger.org.apache.catalina.session=DEBUG
+ +

+ Be warned: a level of DEBUG will produce megabytes of logging and slow + startup of Tomcat. This level should be used sparingly when debugging of + internal Tomcat operations is required. +

+ +

+ Your web applications should certainly use their own log4j configuration. + This is valid with the above configuration. You would place a + similar log4j.properties file in your web application's WEB-INF/classes + directory, and log4jx.y.z.jar into WEB-INF/lib. Then specify your package + level logging. This is a basic setup of log4j which does *not* require + Commons-Logging, and you should consult the + log4j + documentation for more options. This page is intended only as a + bootstrapping guide. +

+ +

Additional notes

+
    +
  • This exposes log4j libraries to the web applications through the + Common classloader. See class loading + documentation for details.

    +

    Because of that, the web applications and libraries using + Apache Commons Logging + library are likely to automatically choose log4j as the underlying + logging implementation.

  • + +
  • The java.util.logging API is still available for + those web applications that use it directly. The + ${catalina.base}/conf/logging.properties file is still + referenced by Tomcat startup scripts. For more information, see the + subsections of the Introduction to + this page.

    +

    Removal of ${catalina.base}/conf/logging.properties + file, mentioned as one of the steps above, causes + java.util.logging to fallback to the default + configuration for the JRE, which is to use a ConsoleHandler + and therefore not create any standard log files. You should + confirm that all your log files are being created by log4j + before disabling the standard mechanism.

  • + +
  • The Access Log Valve and + ExtendedAccessLogValve use their own self-contained + logging implementation, so they + cannot be configured to use log4j. + Refer to Valves + for specific configuration details.

  • +
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/manager-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/manager-howto.html new file mode 100644 index 0000000..0d263a4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/manager-howto.html @@ -0,0 +1,1401 @@ +Apache Tomcat 7 (7.0.108) - Manager App HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Manager App HOW-TO

Table of Contents
+ +
Introduction
+ +

In many production environments, it is very useful to have the capability +to deploy a new web application, or undeploy an existing one, without having +to shut down and restart the entire container. In addition, you can request +an existing application to reload itself, even if you have not declared it +to be reloadable in the Tomcat server +configuration file.

+ +

To support these capabilities, Tomcat includes a web application +(installed by default on context path /manager) that supports +the following functions:

+
    +
  • Deploy a new web application from the uploaded contents of a WAR file.
  • +
  • Deploy a new web application, on a specified context path, from the + server file system.
  • +
  • List the currently deployed web applications, as well as the + sessions that are currently active for those web apps.
  • +
  • Reload an existing web application, to reflect changes in the + contents of /WEB-INF/classes or /WEB-INF/lib. +
  • +
  • List the OS and JVM property values.
  • +
  • List the available global JNDI resources, for use in deployment + tools that are preparing <ResourceLink> elements + nested in a <Context> deployment description.
  • +
  • Start a stopped application (thus making it available again).
  • +
  • Stop an existing application (so that it becomes unavailable), but + do not undeploy it.
  • +
  • Undeploy a deployed web application and delete its document base + directory (unless it was deployed from file system).
  • +
+ +

A default Tomcat installation includes an instance of the Manager application +configured for the default virtual host. If you create additional virtual hosts, +you may wish to add an instance of the Manager application to one or more of +those Hosts. To add an instance of the Manager web application +Context to a new host install the manager.xml context +configuration file in the +$CATALINA_BASE/conf/[enginename]/[hostname] folder. Here is an +example:

+
<Context privileged="true" antiResourceLocking="false"
+         docBase="${catalina.home}/webapps/manager">
+  <CookieProcessor className="org.apache.tomcat.util.http.Rfc6265CookieProcessor"
+                   sameSiteCookies="strict" />
+  <Valve className="org.apache.catalina.valves.RemoteAddrValve"
+         allow="127\.\d+\.\d+\.\d+|::1|0:0:0:0:0:0:0:1" />
+  <Manager sessionAttributeValueClassNameFilter="java\.lang\.(?:Boolean|Integer|Long|Number|String)|org\.apache\.catalina\.filters\.CsrfPreventionFilter\$LruCache(?:\$1)?|java\.util\.(?:Linked)?HashMap"/>
+</Context>
+ +

There are three ways to use the Manager web application.

+
    +
  • As an application with a user interface you use in your browser. +Here is an example URL where you can replace localhost with +your website host name: http://localhost:8080/manager/html .
  • +
  • A minimal version using HTTP requests only which is suitable for use +by scripts setup by system administrators. Commands are given as part of the +request URI, and responses are in the form of simple text that can be easily +parsed and processed. See +Supported Manager Commands for more information.
  • +
  • A convenient set of task definitions for the Ant +(version 1.4 or later) build tool. See +Executing Manager Commands +With Ant for more information.
  • +
+ +
Configuring Manager Application Access
+ + +

The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+ + +

It would be quite unsafe to ship Tomcat with default settings that allowed +anyone on the Internet to execute the Manager application on your server. +Therefore, the Manager application is shipped with the requirement that anyone +who attempts to use it must authenticate themselves, using a username and +password that have one of manager-xxx roles associated with +them (the role name depends on what functionality is required). +Further, there is no username in the default users file +($CATALINA_BASE/conf/tomcat-users.xml) that is assigned to those +roles. Therefore, access to the Manager application is completely disabled +by default.

+ +

You can find the role names in the web.xml file of the Manager +web application. The available roles are:

+ +
    +
  • manager-gui — Access to the HTML interface.
  • +
  • manager-status — Access to the "Server Status" + page only.
  • +
  • manager-script — Access to the tools-friendly + plain text interface that is described in this document, + and to the "Server Status" page.
  • +
  • manager-jmx — Access to JMX proxy interface + and to the "Server Status" page.
  • +
+ +

The HTML interface is protected against CSRF (Cross-Site Request Forgery) +attacks, but the text and JMX interfaces cannot be protected. It means that +users who are allowed access to the text and JMX interfaces have to be cautious +when accessing the Manager application with a web browser. +To maintain the CSRF protection:

+ +
    +
  • If you use web browser to access the Manager application using + a user that has either manager-script or + manager-jmx roles (for example for testing + the plain text or JMX interfaces), you MUST close all windows + of the browser afterwards to terminate the session. + If you do not close the browser and visit other sites, you may become + victim of a CSRF attack.
  • +
  • It is recommended to never grant + the manager-script or manager-jmx + roles to users that have the manager-gui role.
  • +
+ +

Note that JMX proxy interface is effectively low-level root-like +administrative interface of Tomcat. One can do a lot, if he knows +what commands to call. You should be cautious when enabling the +manager-jmx role.

+ +

To enable access to the Manager web application, you must either create +a new username/password combination and associate one of the +manager-xxx roles with it, or add a +manager-xxx role +to some existing username/password combination. +As the majority of this document describes the using the text interface, this +example will use the role name manager-script. +Exactly how the usernames/passwords are configured depends on which +Realm implementation you are using:

+
    +
  • UserDatabaseRealm plus MemoryUserDatabase, or MemoryRealm + — The UserDatabaseRealm and MemoryUserDatabase are + configured in the default $CATALINA_BASE/conf/server.xml. + Both MemoryUserDatabase and MemoryRealm read an + XML-format file by default stored at + $CATALINA_BASE/conf/tomcat-users.xml, which can be + edited with any text editor. This file contains an XML + <user> for each individual user, which might + look something like this: +
    <user username="craigmcc" password="secret" roles="standard,manager-script" />
    + which defines the username and password used by this individual to + log on, and the role names he or she is associated with. You can + add the manager-script role to the comma-delimited + roles attribute for one or more existing users, and/or + create new users with that assigned role.
  • +
  • DataSourceRealm or JDBCRealm + — Your user and role information is stored in + a database accessed via JDBC. Add the manager-script role + to one or more existing users, and/or create one or more new users + with this role assigned, following the standard procedures for your + environment.
  • +
  • JNDIRealm — Your user and role information is stored in + a directory server accessed via LDAP. Add the + manager-script role to one or more existing users, + and/or create one or more new users with this role assigned, following + the standard procedures for your environment.
  • +
+ +

The first time you attempt to issue one of the Manager commands +described in the next section, you will be challenged to log on using +BASIC authentication. The username and password you enter do not matter, +as long as they identify a valid user in the users database who possesses +the role manager-script.

+ +

In addition to the password restrictions, access to the Manager web +application can be restricted by the remote IP address or host +by adding a RemoteAddrValve or RemoteHostValve. +See valves documentation +for details. Here is +an example of restricting access to the localhost by IP address:

+
<Context privileged="true">
+         <Valve className="org.apache.catalina.valves.RemoteAddrValve"
+                allow="127\.0\.0\.1"/>
+</Context>
+ +
HTML User-friendly Interface
+ +

The user-friendly HTML interface of Manager web application is located at

+ +
http://{host}:{port}/manager/html
+ +

As has already been mentioned above, you need manager-gui +role to be allowed to access it. There is a separate document that provides +help on this interface. See:

+ + + +

The HTML interface is protected against CSRF (Cross-Site Request Forgery) +attacks. Each access to the HTML pages generates a random token, which is +stored in your session and is included in all links on the page. If your next +action does not have correct value of the token, the action will be denied. +If the token has expired you can start again from the main page or +List Applications page of Manager.

+ +
Supported Manager Commands
+ +

All commands that the Manager application knows how to process are +specified in a single request URI like this:

+
http://{host}:{port}/manager/text/{command}?{parameters}
+

where {host} and {port} represent the hostname +and port number on which Tomcat is running, {command} +represents the Manager command you wish to execute, and +{parameters} represents the query parameters +that are specific to that command. In the illustrations below, customize +the host and port appropriately for your installation.

+ +

The commands are usually executed by HTTP GET requests. The +/deploy command has a form that is executed by an HTTP PUT request.

+ +
Common Parameters
+ +

Most commands accept one or more of the following query parameters:

+
    +
  • path - The context path (including the leading slash) + of the web application you are dealing with. To select the ROOT web + application, specify "/". NOTE: + It is not possible to perform administrative commands on the + Manager application itself.
  • +
  • version - The version of this web application as used by + the parallel deployment feature. If you + use parallel deployment wherever a path is required you must specify a + version in addition to the path and it is the combination of path and + version that must be unique rather than just the path.
  • +
  • war - URL of a web application archive (WAR) file, or + pathname of a directory which contains the web application, or a + Context configuration ".xml" file. You can use URLs in any of the + following formats: +
      +
    • file:/absolute/path/to/a/directory - The absolute + path of a directory that contains the unpacked version of a web + application. This directory will be attached to the context path + you specify without any changes.
    • +
    • file:/absolute/path/to/a/webapp.war - The absolute + path of a web application archive (WAR) file. This is valid + only for the /deploy command, and is + the only acceptable format to that command.
    • +
    • file:/absolute/path/to/a/context.xml - The + absolute path of a web application Context configuration ".xml" + file which contains the Context configuration element.
    • +
    • directory - The directory name for the web + application context in the Host's application base directory.
    • +
    • webapp.war - The name of a web application war file + located in the Host's application base directory.
    • +
  • +
+ +

Each command will return a response in text/plain format +(i.e. plain ASCII with no HTML markup), making it easy for both humans and +programs to read). The first line of the response will begin with either +OK or FAIL, indicating whether the requested +command was successful or not. In the case of failure, the rest of the first +line will contain a description of the problem that was encountered. Some +commands include additional lines of information as described below.

+ +

Internationalization Note - The Manager application looks up +its message strings in resource bundles, so it is possible that the strings +have been translated for your platform. The examples below show the English +version of the messages.

+ +
+ +
Deploy A New Application Archive (WAR) Remotely
+ +
http://localhost:8080/manager/text/deploy?path=/foo
+ +

Upload the web application archive (WAR) file that is specified as the +request data in this HTTP PUT request, install it into the appBase +directory of our corresponding virtual host, and start, deriving the name for +the WAR file added to the appBase from the specified path. The +application can later be undeployed (and the corresponding WAR file removed) by +use of the /undeploy command.

+ +

This command is executed by an HTTP PUT request.

+ +

The .WAR file may include Tomcat specific deployment configuration, by +including a Context configuration XML file in +/META-INF/context.xml.

+ +

URL parameters include:

+
    +
  • update: When set to true, any existing update will be + undeployed first. The default value is set to false.
  • +
  • tag: Specifying a tag name, this allows associating the + deployed webapp with a tag or label. If the web application is undeployed, + it can be later redeployed when needed using only the tag.
  • +
+ +

NOTE - This command is the logical +opposite of the /undeploy command.

+ +

If installation and startup is successful, you will receive a response +like this:

+
OK - Deployed application at context path /foo
+ +

Otherwise, the response will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Application already exists at path /foo +

    The context paths for all currently running web applications must be + unique. Therefore, you must undeploy the existing web + application using this context path, or choose a different context path + for the new one. The update parameter may be specified as + a parameter on the URL, with a value of true to avoid this + error. In that case, an undeploy will be performed on an existing + application before performing the deployment.

    +
  • +
  • Encountered exception +

    An exception was encountered trying to start the new web application. + Check the Tomcat logs for the details, but likely explanations include + problems parsing your /WEB-INF/web.xml file, or missing + classes encountered when initializing application event listeners and + filters.

    +
  • +
+ +
+ +
Deploy A New Application from a Local Path
+ +

Deploy and start a new web application, attached to the specified context +path (which must not be in use by any other web application). +This command is the logical opposite of the /undeploy command.

+ +

This command is executed by an HTTP GET request. +There are a number of different ways the deploy command can be used.

+ +
Deploy a previously deployed webapp
+ +
http://localhost:8080/manager/text/deploy?path=/footoo&tag=footag
+ +

This can be used to deploy a previously deployed web application, which +has been deployed using the tag attribute. Note that the work +directory of the Manager webapp will contain the previously deployed WARs; +removing it would make the deployment fail.

+ +
+ +
Deploy a Directory or WAR by URL
+ +

Deploy a web application directory or ".war" file located on the Tomcat +server. If no path is specified, the path and version are derived +from the directory name or the war file name. The war parameter +specifies a URL (including the file: scheme) for either +a directory or a web application archive (WAR) file. The supported syntax for +a URL referring to a WAR file is described on the Javadocs page for the +java.net.JarURLConnection class. Use only URLs that refer to +the entire WAR file.

+ +

In this example the web application located in the directory +/path/to/foo on the Tomcat server is deployed as the +web application context named /footoo.

+
http://localhost:8080/manager/text/deploy?path=/footoo&war=file:/path/to/foo
+ + +

In this example the ".war" file /path/to/bar.war on the +Tomcat server is deployed as the web application context named +/bar. Notice that there is no path parameter +so the context path defaults to the name of the web application archive +file without the ".war" extension.

+
http://localhost:8080/manager/text/deploy?war=file:/path/to/bar.war
+ +
+ +
Deploy a Directory or War from the Host appBase
+ +

Deploy a web application directory or ".war" file located in your Host +appBase directory. The path and optional version are derived from the directory +or war file name.

+ +

In this example the web application located in a sub directory named +foo in the Host appBase directory of the Tomcat server is +deployed as the web application context named /foo. Notice +that the context path used is the name of the web application directory.

+
http://localhost:8080/manager/text/deploy?war=foo
+ + +

In this example the ".war" file bar.war located in your +Host appBase directory on the Tomcat server is deployed as the web +application context named /bar.

+
http://localhost:8080/manager/text/deploy?war=bar.war
+ +
+ +
Deploy using a Context configuration ".xml" file
+ +

If the Host deployXML flag is set to true you can deploy a web +application using a Context configuration ".xml" file and an optional +".war" file or web application directory. The context path +is not used when deploying a web application using a context ".xml" +configuration file.

+ +

A Context configuration ".xml" file can contain valid XML for a +web application Context just as if it were configured in your +Tomcat server.xml configuration file. Here is an +example:

+
<Context path="/foobar" docBase="/path/to/application/foobar">
+</Context>
+ + +

When the optional war parameter is set to the URL +for a web application ".war" file or directory it overrides any +docBase configured in the context configuration ".xml" file.

+ +

Here is an example of deploying an application using a Context +configuration ".xml" file.

+
http://localhost:8080/manager/text/deploy?config=file:/path/context.xml
+ + +

Here is an example of deploying an application using a Context +configuration ".xml" file and a web application ".war" file located +on the server.

+
http://localhost:8080/manager/text/deploy
+ ?config=file:/path/context.xml&war=file:/path/bar.war
+ +
+ +
Deployment Notes
+ +

If the Host is configured with unpackWARs=true and you deploy a war +file, the war will be unpacked into a directory in your Host appBase +directory.

+ +

If the application war or directory is installed in your Host appBase +directory and either the Host is configured with autoDeploy=true or the +Context path must match the directory name or war file name without the +".war" extension.

+ +

For security when untrusted users can manage web applications, the +Host deployXML flag can be set to false. This prevents untrusted users +from deploying web applications using a configuration XML file and +also prevents them from deploying application directories or ".war" +files located outside of their Host appBase.

+ +
+ +
Deploy Response
+ +

If installation and startup is successful, you will receive a response +like this:

+
OK - Deployed application at context path /foo
+ +

Otherwise, the response will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Application already exists at path /foo +

    The context paths for all currently running web applications must be + unique. Therefore, you must undeploy the existing web + application using this context path, or choose a different context path + for the new one. The update parameter may be specified as + a parameter on the URL, with a value of true to avoid this + error. In that case, an undeploy will be performed on an existing + application before performing the deployment.

    +
  • +
  • Document base does not exist or is not a readable directory +

    The URL specified by the war parameter must identify a + directory on this server that contains the "unpacked" version of a + web application, or the absolute URL of a web application archive (WAR) + file that contains this application. Correct the value specified by + the war parameter.

    +
  • +
  • Encountered exception +

    An exception was encountered trying to start the new web application. + Check the Tomcat logs for the details, but likely explanations include + problems parsing your /WEB-INF/web.xml file, or missing + classes encountered when initializing application event listeners and + filters.

    +
  • +
  • Invalid application URL was specified +

    The URL for the directory or web application that you specified + was not valid. Such URLs must start with file:, and URLs + for a WAR file must end in ".war".

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character. To reference the + ROOT web application use "/".

    +
  • +
  • Context path must match the directory or WAR file name: +

    If the application war or directory is installed in your Host appBase + directory and either the Host is configured with autoDeploy=true the + Context path must match the directory name or war file name without + the ".war" extension.

    +
  • +
  • Only web applications in the Host web application directory can + be installed +

    + If the Host deployXML flag is set to false this error will happen + if an attempt is made to deploy a web application directory or + ".war" file outside of the Host appBase directory. +

  • +
+ +
+
+ +
List Currently Deployed Applications
+ +
http://localhost:8080/manager/text/list
+ +

List the context paths, current status (running or +stopped), and number of active sessions for all currently +deployed web applications. A typical response immediately +after starting Tomcat might look like this:

+
OK - Listed applications for virtual host localhost
+/webdav:running:0:webdav
+/examples:running:0:examples
+/manager:running:0:manager
+/:running:0:ROOT
+/test:running:0:test##2
+/test:running:0:test##1
+ +
+ +
Reload An Existing Application
+ +
http://localhost:8080/manager/text/reload?path=/examples
+ +

Signal an existing application to shut itself down and reload. This can +be useful when the web application context is not reloadable and you have +updated classes or property files in the /WEB-INF/classes +directory or when you have added or updated jar files in the +/WEB-INF/lib directory. +

+ +

If this command succeeds, you will see a response like this:

+
OK - Reloaded application at context path /examples
+ +

Otherwise, the response will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to restart the web application. + Check the Tomcat logs for the details.

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character. To reference the + ROOT web application use "/".

    +
  • +
  • No context exists for path /foo +

    There is no deployed application on the context path + that you specified.

    +
  • +
  • No context path was specified +

    + The path parameter is required. +

  • +
  • Reload not supported on WAR deployed at path /foo +

    + Currently, application reloading (to pick up changes to the classes or + web.xml file) is not supported when a web application is + deployed directly from a WAR file. It only works when the web application + is deployed from an unpacked directory. If you are using a WAR file, + you should undeploy and then deploy or + deploy with the update parameter the + application again to pick up your changes. +

  • +
+ +
+ +
List OS and JVM Properties
+ +
http://localhost:8080/manager/text/serverinfo
+ +

Lists information about the Tomcat version, OS, and JVM properties.

+ +

If an error occurs, the response will start with FAIL and +include an error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to enumerate the system properties. + Check the Tomcat logs for the details.

    +
  • +
+ +
+ +
List Available Global JNDI Resources
+ +
http://localhost:8080/manager/text/resources[?type=xxxxx]
+ +

List the global JNDI resources that are available for use in resource +links for context configuration files. If you specify the type +request parameter, the value must be the fully qualified Java class name of +the resource type you are interested in (for example, you would specify +javax.sql.DataSource to acquire the names of all available +JDBC data sources). If you do not specify the type request +parameter, resources of all types will be returned.

+ +

Depending on whether the type request parameter is specified +or not, the first line of a normal response will be:

+
OK - Listed global resources of all types
+

or

+
OK - Listed global resources of type xxxxx
+

followed by one line for each resource. Each line is composed of fields +delimited by colon characters (":"), as follows:

+
    +
  • Global Resource Name - The name of this global JNDI resource, + which would be used in the global attribute of a + <ResourceLink> element.
  • +
  • Global Resource Type - The fully qualified Java class name of + this global JNDI resource.
  • +
+ +

If an error occurs, the response will start with FAIL and +include an error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to enumerate the global JNDI + resources. Check the Tomcat logs for the details.

    +
  • +
  • No global JNDI resources are available +

    The Tomcat server you are running has been configured without + global JNDI resources.

    +
  • +
+ + +
+ +
Session Statistics
+ +
http://localhost:8080/manager/text/sessions?path=/examples
+ +

Display the default session timeout for a web application, and the +number of currently active sessions that fall within one-minute ranges of +their actual timeout times. For example, after restarting Tomcat and then +executing one of the JSP samples in the /examples web app, +you might get something like this:

+ +
OK - Session information for application at context path /examples
+Default maximum session inactive interval 30 minutes
+<1 minutes: 1 sessions
+1 - <2 minutes: 1 sessions
+ +
+ +
Expire Sessions
+ +
http://localhost:8080/manager/text/expire?path=/examples&idle=num
+ +

Display the session statistics (like the above /sessions +command) and expire sessions that are idle for longer than num +minutes. To expire all sessions, use &idle=0 .

+ +
OK - Session information for application at context path /examples
+Default maximum session inactive interval 30 minutes
+1 - <2 minutes: 1 sessions
+3 - <4 minutes: 1 sessions
+>0 minutes: 2 sessions were expired
+ +

Actually /sessions and /expire are synonyms for +the same command. The difference is in the presence of idle +parameter.

+ +
+ +
Start an Existing Application
+ +
http://localhost:8080/manager/text/start?path=/examples
+ +

Signal a stopped application to restart, and make itself available again. +Stopping and starting is useful, for example, if the database required by +your application becomes temporarily unavailable. It is usually better to +stop the web application that relies on this database rather than letting +users continuously encounter database exceptions.

+ +

If this command succeeds, you will see a response like this:

+
OK - Started application at context path /examples
+ +

Otherwise, the response will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to start the web application. + Check the Tomcat logs for the details.

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character. To reference the + ROOT web application use "/".

    +
  • +
  • No context exists for path /foo +

    There is no deployed application on the context path + that you specified.

    +
  • +
  • No context path was specified +

    + The path parameter is required. +

  • +
+ +
+ +
Stop an Existing Application
+ +
http://localhost:8080/manager/text/stop?path=/examples
+ +

Signal an existing application to make itself unavailable, but leave it +deployed. Any request that comes in while an application is +stopped will see an HTTP error 404, and this application will show as +"stopped" on a list applications command.

+ +

If this command succeeds, you will see a response like this:

+
OK - Stopped application at context path /examples
+ +

Otherwise, the response will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to stop the web application. + Check the Tomcat logs for the details.

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character. To reference the + ROOT web application use "/".

    +
  • +
  • No context exists for path /foo +

    There is no deployed application on the context path + that you specified.

    +
  • +
  • No context path was specified + The path parameter is required. +
  • +
+ +
+ + +
Undeploy an Existing Application
+ +
http://localhost:8080/manager/text/undeploy?path=/examples
+ +

WARNING - This command will delete any web +application artifacts that exist within appBase directory +(typically "webapps") for this virtual host. +This will delete the application .WAR, if present, +the application directory resulting either from a deploy in unpacked form +or from .WAR expansion as well as the XML Context definition from +$CATALINA_BASE/conf/[enginename]/[hostname]/ directory. +If you simply want to take an application +out of service, you should use the /stop command instead.

+ +

Signal an existing application to gracefully shut itself down, and +remove it from Tomcat (which also makes this context path available for +reuse later). In addition, the document root directory is removed, if it +exists in the appBase directory (typically "webapps") for +this virtual host. This command is the logical opposite of the +/deploy command.

+ +

If this command succeeds, you will see a response like this:

+
OK - Undeployed application at context path /examples
+ +

Otherwise, the response will start with FAIL and include an +error message. Possible causes for problems include:

+
    +
  • Encountered exception +

    An exception was encountered trying to undeploy the web application. + Check the Tomcat logs for the details.

    +
  • +
  • Invalid context path was specified +

    The context path must start with a slash character. To reference the + ROOT web application use "/".

    +
  • +
  • No context exists named /foo +

    There is no deployed application with the name that you specified.

    +
  • +
  • No context path was specified + The path parameter is required. +
  • +
+ +
+ +
Finding memory leaks
+ +
http://localhost:8080/manager/text/findleaks[?statusLine=[true|false]]
+ +

The find leaks diagnostic triggers a full garbage collection. It +should be used with extreme caution on production systems.

+ +

The find leaks diagnostic attempts to identify web applications that have +caused memory leaks when they were stopped, reloaded or undeployed. Results +should always be confirmed +with a profiler. The diagnostic uses additional functionality provided by the +StandardHost implementation. It will not work if a custom host is used that +does not extend StandardHost.

+ +

Explicitly triggering a full garbage collection from Java code is documented +to be unreliable. Furthermore, depending on the JVM used, there are options to +disable explicit GC triggering, like -XX:+DisableExplicitGC. +If you want to make sure, that the diagnostics were successfully running a full +GC, you will need to check using tools like GC logging, JConsole or similar.

+ +

If this command succeeds, you will see a response like this:

+
/leaking-webapp
+ +

If you wish to see a status line included in the response then include the +statusLine query parameter in the request with a value of +true.

+ +

Each context path for a web application that was stopped, reloaded or +undeployed, but which classes from the previous runs are still loaded in memory, +thus causing a memory leak, will be listed on a new line. If an application +has been reloaded several times, it may be listed several times.

+ +

If the command does not succeed, the response will start with +FAIL and include an error message.

+ +
+ +
Thread Dump
+ +
http://localhost:8080/manager/text/threaddump
+ +

Write a JVM thread dump.

+ +

The response will look something like this:

+
OK - JVM thread dump
+2014-12-08 07:24:40.080
+Full thread dump Java HotSpot(TM) Client VM (25.25-b02 mixed mode):
+
+"http-nio-8080-exec-2" Id=26 cpu=46800300 ns usr=46800300 ns blocked 0 for -1 ms waited 0 for -1 ms
+   java.lang.Thread.State: RUNNABLE
+        locks java.util.concurrent.ThreadPoolExecutor$Worker@1738ad4
+        at sun.management.ThreadImpl.dumpThreads0(Native Method)
+        at sun.management.ThreadImpl.dumpAllThreads(ThreadImpl.java:446)
+        at org.apache.tomcat.util.Diagnostics.getThreadDump(Diagnostics.java:440)
+        at org.apache.tomcat.util.Diagnostics.getThreadDump(Diagnostics.java:409)
+        at org.apache.catalina.manager.ManagerServlet.threadDump(ManagerServlet.java:557)
+        at org.apache.catalina.manager.ManagerServlet.doGet(ManagerServlet.java:371)
+        at javax.servlet.http.HttpServlet.service(HttpServlet.java:618)
+        at javax.servlet.http.HttpServlet.service(HttpServlet.java:725)
+...
+
+ +
+ +
VM Info
+ +
http://localhost:8080/manager/text/vminfo
+ +

Write some diagnostic information about Java Virtual Machine.

+ +

The response will look something like this:

+
OK - VM info
+2014-12-08 07:27:32.578
+Runtime information:
+  vmName: Java HotSpot(TM) Client VM
+  vmVersion: 25.25-b02
+  vmVendor: Oracle Corporation
+  specName: Java Virtual Machine Specification
+  specVersion: 1.8
+  specVendor: Oracle Corporation
+  managementSpecVersion: 1.2
+  name: ...
+  startTime: 1418012458849
+  uptime: 393855
+  isBootClassPathSupported: true
+
+OS information:
+...
+
+ +
+ +
Server Status
+ +

From the following links you can view Status information about the server. +Any one of manager-xxx roles allows access to this page.

+ +
http://localhost:8080/manager/status
+http://localhost:8080/manager/status/all
+ +

Displays server status information in HTML format.

+ +
http://localhost:8080/manager/status?XML=true
+http://localhost:8080/manager/status/all?XML=true
+ +

Displays server status information in XML format.

+ +

First, you have the server and JVM version number, JVM provider, OS name +and number followed by the architecture type.

+ +

Second, there is information about the memory usage of the JVM.

+ +

Then, there is information about the Tomcat AJP and HTTP connectors. +The same information is available for both of them : +

+
    +
  • Threads information : Max threads, min and max spare threads, + current thread count and current thread busy.

  • +
  • Request information : Max processing time and processing time, + request and error count, bytes received and sent.

  • +
  • A table showing Stage, Time, Bytes Sent, Bytes Receive, Client, + VHost and Request. All existing threads are listed in the table. + Here is the list of the possible thread stages :

    +
      +
    • "Parse and Prepare Request" : The request headers are + being parsed or the necessary preparation to read the request body (if + a transfer encoding has been specified) is taking place.

    • +
    • "Service" : The thread is processing a request and + generating the response. This stage follows the "Parse and Prepare + Request" stage and precedes the "Finishing" stage. There is always at + least one thread in this stage (the server-status page).

    • +
    • "Finishing" : The end of the request processing. Any + remainder of the response still in the output buffers is sent to the + client. This stage is followed by "Keep-Alive" if it is appropriate to + keep the connection alive or "Ready" if "Keep-Alive" is not + appropriate.

    • +
    • "Keep-Alive" : The thread keeps the connection open to + the client in case the client sends another request. If another request + is received, the next stage will be "Parse and Prepare Request". If no + request is received before the keep alive times out, the connection will + be closed and the next stage will be "Ready".

    • +
    • "Ready" : The thread is at rest and ready to be + used.

    • +
    +
  • +
+ +

If you are using /status/all command, additional information +on each of deployed web applications will be available.

+ +
Using the JMX Proxy Servlet
+ +
What is JMX Proxy Servlet
+ The JMX Proxy Servlet is a lightweight proxy to get and set the + tomcat internals. (Or any class that has been exposed via an MBean) + Its usage is not very user friendly but the UI is + extremely helpful for integrating command line scripts for monitoring + and changing the internals of tomcat. You can do two things with the proxy: + get information and set information. For you to really understand the + JMX Proxy Servlet, you should have a general understanding of JMX. + If you don't know what JMX is, then prepare to be confused. +
+ +
JMX Query command
+

This takes the form:

+
http://webserver/manager/jmxproxy/?qry=STUFF
+

Where STUFF is the JMX query you wish to perform. For example, + here are some queries you might wish to run:

+
    +
  • + qry=*%3Atype%3DRequestProcessor%2C* --> + type=RequestProcessor which will locate all + workers which can process requests and report + their state. +
  • +
  • + qry=*%3Aj2eeType=Servlet%2c* --> + j2eeType=Servlet which return all loaded servlets. +
  • +
  • + qry=Catalina%3Atype%3DEnvironment%2Cresourcetype%3DGlobal%2Cname%3DsimpleValue --> + Catalina:type=Environment,resourcetype=Global,name=simpleValue + which look for a specific MBean by the given name. +
  • +
+

+ You'll need to experiment with this to really understand its capabilities + If you provide no qry parameter, then all of the MBeans will + be displayed. We really recommend looking at the tomcat source code and + understand the JMX spec to get a better understanding of all the queries + you may run. +

+
+ +
JMX Get command
+

+ The JXMProxyServlet also supports a "get" command that you can use to + fetch the value of a specific MBean's attribute. The general form of + the get command is: +

+ +
http://webserver/manager/jmxproxy/?get=BEANNAME&att=MYATTRIBUTE&key=MYKEY
+ +

You must provide the following parameters:

+
    +
  1. get: The full bean name
  2. +
  3. att: The attribute you wish to fetch
  4. +
  5. key: (optional) The key into a CompositeData MBean attribute
  6. +
+

+ If all goes well, then it will say OK, otherwise an error message will + be shown. For example, let's say we wish to fetch the current heap memory + data: +

+ +
http://webserver/manager/jmxproxy/?get=java.lang:type=Memory&att=HeapMemoryUsage
+ +

Or, if you only want the "used" key:

+ +
http://webserver/manager/jmxproxy/
+ ?get=java.lang:type=Memory&att=HeapMemoryUsage&key=used
+
+ +
JMX Set command
+

+ Now that you can query an MBean, its time to muck with Tomcat's internals! + The general form of the set command is : +

+
http://webserver/manager/jmxproxy/?set=BEANNAME&att=MYATTRIBUTE&val=NEWVALUE
+

So you need to provide 3 request parameters:

+
    +
  1. set: The full bean name
  2. +
  3. att: The attribute you wish to alter
  4. +
  5. val: The new value
  6. +
+

+ If all goes ok, then it will say OK, otherwise an error message will be + shown. For example, lets say we wish to turn up debugging on the fly for the + ErrorReportValve. The following will set debugging to 10. +

+
http://localhost:8080/manager/jmxproxy/
+ ?set=Catalina%3Atype%3DValve%2Cname%3DErrorReportValve%2Chost%3Dlocalhost
+ &att=debug&val=10
+

and my result is (YMMV):

+
Result: ok
+ +

Here is what I see if I pass in a bad value. Here is the URL I used, + I try set debugging equal to 'cow':

+
http://localhost:8080/manager/jmxproxy/
+ ?set=Catalina%3Atype%3DValve%2Cname%3DErrorReportValve%2Chost%3Dlocalhost
+ &att=debug&val=cow
+

When I try that, my result is

+
Error: java.lang.NumberFormatException: For input string: "cow"
+
+ +
JMX Invoke command
+

The invoke command enables methods to be called on MBeans. The + general form of the command is:

+
http://webserver/manager/jmxproxy/
+ ?invoke=BEANNAME&op=METHODNAME&ps=COMMASEPARATEDPARAMETERS
+

For example, to call the findConnectors() method of the + Service use:

+
http://localhost:8080/manager/jmxproxy/
+ ?invoke=Catalina%3Atype%3DService&op=findConnectors&ps=
+
+ +
Executing Manager Commands With Ant
+ +

In addition to the ability to execute Manager commands via HTTP requests, +as documented above, Tomcat includes a convenient set of Task definitions +for the Ant (version 1.4 or later) build tool. In order to use these +commands, you must perform the following setup operations:

+
    +
  • Download the binary distribution of Ant from + https://ant.apache.org. + You must use version 1.4 or later.
  • +
  • Install the Ant distribution in a convenient directory (called + ANT_HOME in the remainder of these instructions).
  • +
  • Add the $ANT_HOME/bin directory to your PATH + environment variable.
  • +
  • Configure at least one username/password combination in your Tomcat + user database that includes the manager-script role.
  • +
+ +

To use custom tasks within Ant, you must declare them first with an +<import> element. Therefore, your build.xml +file might look something like this:

+ +
<project name="My Application" default="compile" basedir=".">
+
+  <!-- Configure the directory into which the web application is built -->
+  <property name="build"    value="${basedir}/build"/>
+
+  <!-- Configure the context path for this application -->
+  <property name="path"     value="/myapp"/>
+
+  <!-- Configure properties to access the Manager application -->
+  <property name="url"      value="http://localhost:8080/manager/text"/>
+  <property name="username" value="myusername"/>
+  <property name="password" value="mypassword"/>
+
+  <!-- Configure the path to the Tomcat installation -->
+  <property name="catalina.home" value="/usr/local/apache-tomcat"/>
+
+  <!-- Configure the custom Ant tasks for the Manager application -->
+  <import file="${catalina.home}/bin/catalina-tasks.xml"/>
+
+  <!-- Executable Targets -->
+  <target name="compile" description="Compile web application">
+    <!-- ... construct web application in ${build} subdirectory, and
+            generated a ${path}.war ... -->
+  </target>
+
+  <target name="deploy" description="Install web application"
+          depends="compile">
+    <deploy url="${url}" username="${username}" password="${password}"
+            path="${path}" war="file:${build}${path}.war"/>
+  </target>
+
+  <target name="reload" description="Reload web application"
+          depends="compile">
+    <reload  url="${url}" username="${username}" password="${password}"
+            path="${path}"/>
+  </target>
+
+  <target name="undeploy" description="Remove web application">
+    <undeploy url="${url}" username="${username}" password="${password}"
+            path="${path}"/>
+  </target>
+
+</project>
+ +

Note: The definition of the resources task via the import above will override +the resources datatype added in Ant 1.7. If you wish to use the resources +datatype you will need to use Ant's namespace support to modify +catalina-tasks.xml to assign the Tomcat tasks to their own +namespace.

+ +

Now, you can execute commands like ant deploy to deploy the +application to a running instance of Tomcat, or ant reload to +tell Tomcat to reload it. Note also that most of the interesting values in +this build.xml file are defined as replaceable properties, so +you can override their values from the command line. For example, you might +consider it a security risk to include the real manager password in your +build.xml file's source code. To avoid this, omit the password +property, and specify it from the command line:

+
ant -Dpassword=secret deploy
+ +
Tasks output capture
+ +

Using Ant version 1.6.2 or later, +the Catalina tasks offer the option to capture their output in +properties or external files. They support directly the following subset of the +<redirector> type attributes: +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionRequired
outputName of a file to which to write the output. If +the error stream is not also redirected to a file or property, it will +appear in this output.No
errorThe file to which the standard error of the +command should be redirected.No
logErrorThis attribute is used when you wish to see +error output in Ant's log and you are redirecting output to a +file/property. The error output will not be included in the output +file/property. If you redirect error with the error or errorProperty +attributes, this will have no effect.No
appendWhether output and error files should be +appended to or overwritten. Defaults to false.No
createemptyfilesWhether output and error files should be created +even when empty. Defaults to true.No
outputpropertyThe name of a property in which the output of +the command should be stored. Unless the error stream is redirected to +a separate file or stream, this property will include the error output.No
errorpropertyThe name of a property in which the standard +error of the command should be stored.No
+ +

A couple of additional attributes can also be specified: +

+ + + + + + + + + + + + + + + + +
AttributeDescriptionRequired
alwaysLogThis attribute is used when you wish to see the +output you are capturing, appearing also in the Ant's log. It must not be +used unless you are capturing task output. +Defaults to false. +This attribute will be supported directly by <redirector> +in Ant 1.6.3No
failonerrorThis attribute is used when you wish to avoid that +any manager command processing error terminates the ant execution. Defaults to true. +It must be set to false, if you want to capture error output, +otherwise execution will terminate before anything can be captured. +
+This attribute acts only on manager command execution, +any wrong or missing command attribute will still cause Ant execution termination. +
No
+ +

They also support the embedded <redirector> element +in which you can specify +its full set of attributes, but input, inputstring and +inputencoding that, even if accepted, are not used because they have +no meaning in this context. +Refer to ant manual for details on +<redirector> element attributes. +

+ +

+Here is a sample build file extract that shows how this output redirection support +can be used: +

+ +
    <target name="manager.deploy"
+        depends="context.status"
+        if="context.notInstalled">
+        <deploy url="${mgr.url}"
+            username="${mgr.username}"
+            password="${mgr.password}"
+            path="${mgr.context.path}"
+            config="${mgr.context.descriptor}"/>
+    </target>
+
+    <target name="manager.deploy.war"
+        depends="context.status"
+        if="context.deployable">
+        <deploy url="${mgr.url}"
+            username="${mgr.username}"
+            password="${mgr.password}"
+            update="${mgr.update}"
+            path="${mgr.context.path}"
+            war="${mgr.war.file}"/>
+    </target>
+
+    <target name="context.status">
+        <property name="running" value="${mgr.context.path}:running"/>
+        <property name="stopped" value="${mgr.context.path}:stopped"/>
+
+        <list url="${mgr.url}"
+            outputproperty="ctx.status"
+            username="${mgr.username}"
+            password="${mgr.password}">
+        </list>
+
+        <condition property="context.running">
+            <contains string="${ctx.status}" substring="${running}"/>
+        </condition>
+        <condition property="context.stopped">
+            <contains string="${ctx.status}" substring="${stopped}"/>
+        </condition>
+        <condition property="context.notInstalled">
+            <and>
+                <isfalse value="${context.running}"/>
+                <isfalse value="${context.stopped}"/>
+            </and>
+        </condition>
+        <condition property="context.deployable">
+            <or>
+                <istrue value="${context.notInstalled}"/>
+                <and>
+                    <istrue value="${context.running}"/>
+                    <istrue value="${mgr.update}"/>
+                </and>
+                <and>
+                    <istrue value="${context.stopped}"/>
+                    <istrue value="${mgr.update}"/>
+                </and>
+            </or>
+        </condition>
+        <condition property="context.undeployable">
+            <or>
+                <istrue value="${context.running}"/>
+                <istrue value="${context.stopped}"/>
+            </or>
+        </condition>
+    </target>
+ +

WARNING: even if it doesn't make many sense, and is always a bad idea, +calling a Catalina task more than once, +badly set Ant tasks depends chains may cause that a task be called +more than once in the same Ant run, even if not intended to. A bit of caution should be exercised when you are +capturing output from that task, because this could lead to something unexpected:

+
    +
  • when capturing in a property you will find in it only the output from the first call, because +Ant properties are immutable and once set they cannot be changed, +
  • +
  • when capturing in a file, each run will overwrite it and you will find in it only the last call +output, unless you are using the append="true" attribute, in which case you will +see the output of each task call appended to the file. +
  • +
+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/maven-jars.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/maven-jars.html new file mode 100644 index 0000000..f10ab05 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/maven-jars.html @@ -0,0 +1,100 @@ +Apache Tomcat 7 (7.0.108) - Apache Tomcat - Using Tomcat libraries with Maven

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Apache Tomcat - Using Tomcat libraries with Maven

Table of Contents
+ +
Using Tomcat libraries With Maven
+
Tomcat Snapshots
+ Tomcat snapshots are located in the + Apache Snapshot Repository. + The official URL is
https://repository.apache.org/content/repositories/snapshots/org/apache/tomcat/
+ Snapshots are done periodically, not on a regular basis, but when changes happen and the Tomcat team deems a new snapshot might + useful. +
+
Tomcat Releases
+ Stable releases are published to the + Central + Maven Repositories. The URL for this is +
https://repo2.maven.org/maven2/org/apache/tomcat/
+
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/mbeans-descriptors-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/mbeans-descriptors-howto.html new file mode 100644 index 0000000..9a27e20 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/mbeans-descriptors-howto.html @@ -0,0 +1,129 @@ +Apache Tomcat 7 (7.0.108) - MBeans Descriptors How To

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

MBeans Descriptors How To

Table of Contents
+ +
Introduction
+ +

Tomcat uses JMX MBeans as the technology for implementing +manageability of Tomcat.

+ +

The descriptions of JMX MBeans for Catalina are in the mbeans-descriptors.xml +file in each package.

+ +

You will need to add MBean descriptions for your custom components +in order to avoid a "ManagedBean is not found" exception.

+ +
Adding MBean descriptions
+ +

You may also add MBean descriptions for custom components in +an mbeans-descriptors.xml file, located in the same package as the class files +it describes.

+ +

The permitted syntax for the mbeans-descriptors.xml is defined by +the DTD file.

+ +

The entries for a custom LDAP authentication Realm may look like this:

+ +
  <mbean         name="LDAPRealm"
+            className="org.apache.catalina.mbeans.ClassNameMBean"
+          description="Custom LDAPRealm"
+               domain="Catalina"
+                group="Realm"
+                 type="com.myfirm.mypackage.LDAPRealm">
+
+    <attribute   name="className"
+          description="Fully qualified class name of the managed object"
+                 type="java.lang.String"
+            writeable="false"/>
+
+    <attribute   name="debug"
+          description="The debugging detail level for this component"
+                 type="int"/>
+    .
+    .
+    .
+
+  </mbean>
+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/mbeans-descriptors.dtd b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/mbeans-descriptors.dtd new file mode 100644 index 0000000..dc9fe59 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/mbeans-descriptors.dtd @@ -0,0 +1,247 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/monitoring.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/monitoring.html new file mode 100644 index 0000000..bd7b618 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/monitoring.html @@ -0,0 +1,1206 @@ +Apache Tomcat 7 (7.0.108) - Monitoring and Managing Tomcat

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Monitoring and Managing Tomcat

Table of Contents
+ +
Introduction
+ +

Monitoring is a key aspect of system administration. Looking inside a + running server, obtaining some statistics or reconfiguring some aspects of + an application are all daily administration tasks.

+ +
Enabling JMX Remote
+ +

Note: This configuration is needed only if you are + going to monitor Tomcat remotely. It is not needed if you are going + to monitor it locally, using the same user that Tomcat runs with.

+ +

The Oracle website includes the list of options and how to configure + JMX Remote on Java 8: + + http://docs.oracle.com/javase/6/docs/technotes/guides/management/agent.html. +

+

The following is a quick configuration guide for Java 8:

+

Add the following parameters to setenv.bat script of your + Tomcat (see RUNNING.txt for details).
+ Note: This syntax is for Microsoft Windows. The command has + to be on the same line. It is wrapped to be more readable. If Tomcat is + running as a Windows service, use its configuration dialog to set + java options for the service. + For Linux, MacOS, etc, remove "set " from beginning of the + line. +

+
set CATALINA_OPTS=-Dcom.sun.management.jmxremote.port=%my.jmx.port%
+  -Dcom.sun.management.jmxremote.rmi.port=%my.rmi.port%
+  -Dcom.sun.management.jmxremote.ssl=false
+  -Dcom.sun.management.jmxremote.authenticate=false
+

If you don't set com.sun.management.jmxremote.rmi.port then the +JSR 160 JMX-Adaptor will select a port at random which will may it difficult to +configure a firewall to allow access.

+ +

If you require TLS:

+
    +
  1. change and add this: +
      -Dcom.sun.management.jmxremote.ssl=true
    +  -Dcom.sun.management.jmxremote.registry.ssl=true
    +
  2. +
  3. to configure the protocols and/or cipher suites use: +
      -Dcom.sun.management.jmxremote.ssl.enabled.protocols=%my.jmx.ssl.protocols%
    +  -Dcom.sun.management.jmxremote.ssl.enabled.cipher.suites=%my.jmx.cipher.suites%
    +
  4. +
  5. to client certificate authentication use: +
      -Dcom.sun.management.jmxremote.ssl.need.client.auth=%my.jmx.ssl.clientauth%
  6. +
+

If you require authorization (it is strongly recommended that TLS is always +used with authentication):

+
    +
  1. change and add this: +
      -Dcom.sun.management.jmxremote.authenticate=true
    +  -Dcom.sun.management.jmxremote.password.file=../conf/jmxremote.password
    +  -Dcom.sun.management.jmxremote.access.file=../conf/jmxremote.access
    +
  2. +
  3. edit the access authorization file $CATALINA_BASE/conf/jmxremote.access: +
    monitorRole readonly
    +controlRole readwrite
    +
  4. +
  5. edit the password file $CATALINA_BASE/conf/jmxremote.password: +
    monitorRole tomcat
    +controlRole tomcat
    + Tip: The password file should be read-only and only accessible by the + operating system user Tomcat is running as. +
  6. +
  7. Alterantively, you can configure a JAAS login module with: +
      -Dcom.sun.management.jmxremote.login.config=%login.module.name%
  8. +
+ +

If you need to specify a host name to be used in the RMI stubs sent to the +client (e.g. because the public host name that must be used to connect is not +the same as the local host name) then you can set:

+
set CATALINA_OPTS=-Djava.rmi.server.hostname
+ +

If you need to specify a specific interface for the JMX service to bind to +then you can set:

+
set CATALINA_OPTS=-Dcom.sun.management.jmxremote.host
+ +
Manage Tomcat with JMX remote Ant Tasks
+

To simplify JMX usage with Ant, a set of tasks is provided that may + be used with antlib.

+

antlib: Copy your catalina-ant.jar from $CATALINA_HOME/lib to $ANT_HOME/lib.

+

The following example shows the JMX Accessor usage:
+ Note: The name attribute value was wrapped here to be + more readable. It has to be all on the same line, without spaces.

+ + +
+<project name="Catalina Ant JMX"
+      xmlns:jmx="antlib:org.apache.catalina.ant.jmx"
+      default="state"
+      basedir=".">
+  <property name="jmx.server.name" value="localhost" />
+  <property name="jmx.server.port" value="9012" />
+  <property name="cluster.server.address" value="192.168.1.75" />
+  <property name="cluster.server.port" value="9025" />
+
+  <target name="state" description="Show JMX Cluster state">
+    <jmx:open
+      host="${jmx.server.name}"
+      port="${jmx.server.port}"
+      username="controlRole"
+      password="tomcat"/>
+    <jmx:get
+      name=
+"Catalina:type=IDataSender,host=localhost,
+senderAddress=${cluster.server.address},senderPort=${cluster.server.port}"
+      attribute="connected"
+      resultproperty="IDataSender.backup.connected"
+      echo="false"
+    />
+    <jmx:get
+      name="Catalina:type=ClusterSender,host=localhost"
+      attribute="senderObjectNames"
+      resultproperty="senderObjectNames"
+      echo="false"
+    />
+    <!-- get current maxActiveSession from ClusterTest application
+       echo it to Ant output and store at
+       property <em>clustertest.maxActiveSessions.orginal</em>
+    -->
+    <jmx:get
+      name="Catalina:type=Manager,context=/ClusterTest,host=localhost"
+      attribute="maxActiveSessions"
+      resultproperty="clustertest.maxActiveSessions.orginal"
+      echo="true"
+    />
+    <!-- set maxActiveSession to 100
+    -->
+    <jmx:set
+      name="Catalina:type=Manager,context=/ClusterTest,host=localhost"
+      attribute="maxActiveSessions"
+      value="100"
+      type="int"
+    />
+    <!-- get all sessions and split result as delimiter <em>SPACE</em> for easy
+       access all session ids directly with Ant property sessions.[0..n].
+    -->
+    <jmx:invoke
+      name="Catalina:type=Manager,context=/ClusterTest,host=localhost"
+      operation="listSessionIds"
+      resultproperty="sessions"
+      echo="false"
+      delimiter=" "
+    />
+    <!-- Access session attribute <em>Hello</em> from first session.
+    -->
+    <jmx:invoke
+      name="Catalina:type=Manager,context=/ClusterTest,host=localhost"
+      operation="getSessionAttribute"
+      resultproperty="Hello"
+      echo="false"
+    >
+      <arg value="${sessions.0}"/>
+      <arg value="Hello"/>
+    </jmx:invoke>
+    <!-- Query for all application manager.of the server from all hosts
+       and bind all attributes from all found manager MBeans.
+    -->
+    <jmx:query
+      name="Catalina:type=Manager,*"
+      resultproperty="manager"
+      echo="true"
+      attributebinding="true"
+    />
+    <!-- echo the create properties -->
+<echo>
+senderObjectNames: ${senderObjectNames.0}
+IDataSender.backup.connected: ${IDataSender.backup.connected}
+session: ${sessions.0}
+manager.length: ${manager.length}
+manager.0.name: ${manager.0.name}
+manager.1.name: ${manager.1.name}
+hello: ${Hello}
+manager.ClusterTest.0.name: ${manager.ClusterTest.0.name}
+manager.ClusterTest.0.activeSessions: ${manager.ClusterTest.0.activeSessions}
+manager.ClusterTest.0.counterSend_EVT_SESSION_EXPIRED:
+ ${manager.ClusterTest.0.counterSend_EVT_SESSION_EXPIRED}
+manager.ClusterTest.0.counterSend_EVT_GET_ALL_SESSIONS:
+ ${manager.ClusterTest.0.counterSend_EVT_GET_ALL_SESSIONS}
+</echo>
+
+  </target>
+
+</project>
+
+
+

import: Import the JMX Accessor Project with + <import file="${CATALINA.HOME}/bin/catalina-tasks.xml" /> and + reference the tasks with jmxOpen, jmxSet, jmxGet, + jmxQuery, jmxInvoke, jmxEquals and jmxCondition.

+ +
JMXAccessorOpenTask - JMX open connection task
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
urlSet JMX connection URL - service:jmx:rmi:///jndi/rmi://localhost:8050/jmxrmi +
hostSet the host, shortcut the very long URL syntax. + localhost
portSet the remote connection port + 8050
usernameremote JMX connection user name. +
passwordremote JMX connection password. +
refName of the internal connection reference. With this attribute you can + configure more the one connection inside the same Ant project. + jmx.server
echoEcho the command usage (for access analysis or debugging) + false
ifOnly execute if a property of the given name exists in the current project. +
unlessOnly execute if a property of the given name not exists in the current project. +
+

+

+Example to open a new JMX connection
+


+  <jmx:open
+    host="${jmx.server.name}"
+    port="${jmx.server.port}"
+  />
+
+

+

+Example to open a JMX connection from URL, with authorization and +store at other reference
+


+  <jmx:open
+    url="service:jmx:rmi:///jndi/rmi://localhost:9024/jmxrmi"
+    ref="jmx.server.9024"
+    username="controlRole"
+    password="tomcat"
+  />
+
+

+ +

+Example to open a JMX connection from URL, with authorization and +store at other reference, but only when property jmx.if exists and +jmx.unless not exists
+


+  <jmx:open
+    url="service:jmx:rmi:///jndi/rmi://localhost:9024/jmxrmi"
+    ref="jmx.server.9024"
+    username="controlRole"
+    password="tomcat"
+    if="jmx.if"
+    unless="jmx.unless"
+  />
+
+

+

Note: All properties from jmxOpen task also exists at all +other tasks and conditions. +

+ +
JMXAccessorGetTask: get attribute value Ant task
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
nameFull qualified JMX ObjectName -- Catalina:type=Server +
attributeExisting MBean attribute (see Tomcat MBean description above) +
refJMX Connection reference + jmx.server
echoEcho command usage (access and result) + false
resultpropertySave result at this project property +
delimiterSplit result with delimiter (java.util.StringTokenizer) + and use resultproperty as prefix to store tokens. +
separatearrayresultsWhen return value is an array, save result as property list + ($resultproperty.[0..N] and $resultproperty.length) + true
+

+

+Example to get remote MBean attribute from default JMX connection
+


+  <jmx:get
+    name="Catalina:type=Manager,context=/servlets-examples,host=localhost"
+    attribute="maxActiveSessions"
+    resultproperty="servlets-examples.maxActiveSessions"
+  />
+
+

+

+Example to get and result array and split it at separate properties
+


+  <jmx:get
+      name="Catalina:type=ClusterSender,host=localhost"
+      attribute="senderObjectNames"
+      resultproperty="senderObjectNames"
+  />
+
+Access the senderObjectNames properties with: +

+  ${senderObjectNames.length} give the number of returned sender list.
+  ${senderObjectNames.[0..N]} found all sender object names
+
+

+ +

+Example to get IDataSender attribute connected only when cluster is configured.
+Note: The name attribute value was wrapped here to be +more readable. It has to be all on the same line, without spaces. +

+

+  <jmx:query
+    failonerror="false"
+    name="Catalina:type=Cluster,host=${tomcat.application.host}"
+    resultproperty="cluster"
+  />
+  <jmx:get
+    name=
+"Catalina:type=IDataSender,host=${tomcat.application.host},
+senderAddress=${cluster.backup.address},senderPort=${cluster.backup.port}"
+    attribute="connected"
+    resultproperty="datasender.connected"
+    if="cluster.0.name" />
+
+ +
JMXAccessorSetTask: set attribute value Ant task
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
nameFull qualified JMX ObjectName -- Catalina:type=Server +
attributeExisting MBean attribute (see Tomcat MBean description above) +
valuevalue that set to attribute +
typetype of the attribute. + java.lang.String
refJMX Connection reference + jmx.server
echoEcho command usage (access and result) + false
+

+

+Example to set remote MBean attribute value
+


+  <jmx:set
+    name="Catalina:type=Manager,context=/servlets-examples,host=localhost"
+    attribute="maxActiveSessions"
+    value="500"
+    type="int"
+  />
+
+

+ +
JMXAccessorInvokeTask: invoke MBean operation Ant task
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
nameFull qualified JMX ObjectName -- Catalina:type=Server +
operationExisting MBean operation +
refJMX Connection reference + jmx.server
echoEcho command usage (access and result) + false
resultpropertySave result at this project property +
delimiterSplit result with delimiter (java.util.StringTokenizer) + and use resultproperty as prefix to store tokens. +
separatearrayresultsWhen return value is an array, save result as property list + ($resultproperty.[0..N] and $resultproperty.length) + true
+

+

+stop an application
+


+  <jmx:invoke
+    name="Catalina:type=Manager,context=/servlets-examples,host=localhost"
+    operation="stop"/>
+
+Now you can find the sessionid at ${sessions.[0..N} properties and access the count +with ${sessions.length} property. +

+

+Example to get all sessionids
+


+  <jmx:invoke
+    name="Catalina:type=Manager,context=/servlets-examples,host=localhost"
+    operation="listSessionIds"
+    resultproperty="sessions"
+    delimiter=" "
+  />
+
+Now you can find the sessionid at ${sessions.[0..N} properties and access the count +with ${sessions.length} property. +

+

+Example to get remote MBean session attribute from session ${sessionid.0}
+


+  <jmx:invoke
+    name="Catalina:type=Manager,context=/ClusterTest,host=localhost"
+    operation="getSessionAttribute"
+    resultproperty="hello">
+     <arg value="${sessionid.0}"/>
+     <arg value="Hello" />
+  </jmx:invoke>
+
+

+

+Example to create a new access logger valve at vhost localhost +


+ <jmx:invoke
+         name="Catalina:type=MBeanFactory"
+         operation="createAccessLoggerValve"
+         resultproperty="accessLoggerObjectName"
+ >
+     <arg value="Catalina:type=Host,host=localhost"/>
+ </jmx:invoke>
+
+Now you can find new MBean with name stored at ${accessLoggerObjectName} +property. +

+ +
JMXAccessorQueryTask: query MBean Ant task
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
nameJMX ObjectName query string -- Catalina:type=Manager,* +
refJMX Connection reference + jmx.server
echoEcho command usage (access and result) + false
resultpropertyPrefix project property name to all founded MBeans (mbeans.[0..N].objectname) +
attributebindingbind ALL MBean attributes in addition to name + false
delimiterSplit result with delimiter (java.util.StringTokenizer) + and use resultproperty as prefix to store tokens. +
separatearrayresultsWhen return value is an array, save result as property list + ($resultproperty.[0..N] and $resultproperty.length) + true
+

+

+Get all Manager ObjectNames from all services and Hosts
+


+  <jmx:query
+    name="Catalina:type=Manager,*
+    resultproperty="manager" />
+
+Now you can find the Session Manager at ${manager.[0..N].name} +properties and access the result object counter with ${manager.length} property. +

+

+Example to get the Manager from servlet-examples application an bind all MBean properties
+


+  <jmx:query
+    name="Catalina:type=Manager,context=/servlet-examples,host=localhost*"
+    attributebinding="true"
+    resultproperty="manager.servletExamples" />
+
+Now you can find the manager at ${manager.servletExamples.0.name} property +and can access all properties from this manager with ${manager.servletExamples.0.[manager attribute names]}. +The result object counter from MBeans is stored ad ${manager.length} property. +

+ +

+Example to get all MBeans from a server and store inside an external XML property file
+


+<project name="jmx.query"
+            xmlns:jmx="antlib:org.apache.catalina.ant.jmx"
+            default="query-all" basedir=".">
+<property name="jmx.host" value="localhost"/>
+<property name="jmx.port" value="8050"/>
+<property name="jmx.username" value="controlRole"/>
+<property name="jmx.password" value="tomcat"/>
+
+<target name="query-all" description="Query all MBeans of a server">
+  <!-- Configure connection -->
+  <jmx:open
+    host="${jmx.host}"
+    port="${jmx.port}"
+    ref="jmx.server"
+    username="${jmx.username}"
+    password="${jmx.password}"/>
+
+  <!-- Query MBean list -->
+  <jmx:query
+    name="*:*"
+    resultproperty="mbeans"
+    attributebinding="false"/>
+
+  <echoproperties
+    destfile="mbeans.properties"
+    prefix="mbeans."
+    format="xml"/>
+
+  <!-- Print results -->
+  <echo message=
+    "Number of MBeans in server ${jmx.host}:${jmx.port} is ${mbeans.length}"/>
+</target>
+</project>
+
+Now you can find all MBeans inside the file mbeans.properties. +

+ +
JMXAccessorCreateTask: remote create MBean Ant task
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
nameFull qualified JMX ObjectName -- Catalina:type=MBeanFactory +
classNameExisting MBean full qualified class name (see Tomcat MBean description above) +
classLoaderObjectName of server or web application classloader
+ ( Catalina:type=ServerClassLoader,name=[server,common,shared] or
+ Catalina:type=WebappClassLoader,context=/myapps,host=localhost) +
refJMX Connection reference + jmx.server
echoEcho command usage (access and result) + false
+

+

+Example to create remote MBean
+


+  <jmx:create
+    ref="${jmx.reference}"
+    name="Catalina:type=MBeanFactory"
+    className="org.apache.commons.modeler.BaseModelMBean"
+    classLoader="Catalina:type=ServerClassLoader,name=server">
+    <arg value="org.apache.catalina.mbeans.MBeanFactory" />
+  </jmx:create>
+
+

+

+ Warning: Many Tomcat MBeans can't be linked to their parent once
+ created. The Valve, Cluster and Realm MBeans are not automatically
+ connected with their parent. Use the MBeanFactory create
+ operation instead. +

+ +
JMXAccessorUnregisterTask: remote unregister MBean Ant task
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
nameFull qualified JMX ObjectName -- Catalina:type=MBeanFactory +
refJMX Connection reference + jmx.server
echoEcho command usage (access and result) + false
+

+

+Example to unregister remote MBean
+


+  <jmx:unregister
+    name="Catalina:type=MBeanFactory"
+  />
+
+

+

+ Warning: A lot of Tomcat MBeans can't be unregister.
+ The MBeans are not unlinked from their parent. Use MBeanFactory
+ remove operation instead. +

+ +
JMXAccessorCondition: express condition
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
urlSet JMX connection URL - service:jmx:rmi:///jndi/rmi://localhost:8050/jmxrmi +
hostSet the host, shortcut the very long URL syntax. + localhost
portSet the remote connection port + 8050
usernameremote JMX connection user name. +
passwordremote JMX connection password. +
refName of the internal connection reference. With this attribute you can + configure more the one connection inside the same Ant project. + jmx.server
nameFull qualified JMX ObjectName -- Catalina:type=Server +
echoEcho condition usage (access and result) + false
ifOnly execute if a property of the given name exists in the current project. +
unlessOnly execute if a property of the given name not exists in the current project. +
value (required)Second arg for operation +
typeValue type to express operation (support long and double) + long
operation express one +
    +
  • == equals
  • +
  • != not equals
  • +
  • > greater than (&gt;)
  • +
  • >= greater than or equals (&gt;=)
  • +
  • < lesser than (&lt;)
  • +
  • <= lesser than or equals (&lt;=)
  • +
+
==
+

+

+Wait for server connection and that cluster backup node is accessible
+


+<target name="wait">
+  <waitfor maxwait="${maxwait}" maxwaitunit="second" timeoutproperty="server.timeout" >
+    <and>
+      <socket server="${server.name}" port="${server.port}"/>
+      <http url="${url}"/>
+      <jmx:condition
+        operation="=="
+        host="localhost"
+        port="9014"
+        username="controlRole"
+        password="tomcat"
+        name=
+"Catalina:type=IDataSender,host=localhost,senderAddress=192.168.111.1,senderPort=9025"
+        attribute="connected"
+        value="true"
+      />
+    </and>
+  </waitfor>
+  <fail if="server.timeout" message="Server ${url} don't answer inside ${maxwait} sec" />
+  <echo message="Server ${url} alive" />
+</target>
+
+

+ +
JMXAccessorEqualsCondition: equals MBean Ant condition
+

+List of Attributes
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
AttributeDescriptionDefault value
urlSet JMX connection URL - service:jmx:rmi:///jndi/rmi://localhost:8050/jmxrmi +
hostSet the host, shortcut the very long URL syntax. + localhost
portSet the remote connection port + 8050
usernameremote JMX connection user name. +
passwordremote JMX connection password. +
refName of the internal connection reference. With this attribute you can + configure more the one connection inside the same Ant project. + jmx.server
nameFull qualified JMX ObjectName -- Catalina:type=Server +
echoEcho condition usage (access and result) + false
+

+

+Wait for server connection and that cluster backup node is accessible
+


+<target name="wait">
+  <waitfor maxwait="${maxwait}" maxwaitunit="second" timeoutproperty="server.timeout" >
+    <and>
+      <socket server="${server.name}" port="${server.port}"/>
+      <http url="${url}"/>
+      <jmx:equals
+        host="localhost"
+        port="9014"
+        username="controlRole"
+        password="tomcat"
+        name=
+"Catalina:type=IDataSender,host=localhost,senderAddress=192.168.111.1,senderPort=9025"
+        attribute="connected"
+        value="true"
+      />
+    </and>
+  </waitfor>
+  <fail if="server.timeout" message="Server ${url} don't answer inside ${maxwait} sec" />
+  <echo message="Server ${url} alive" />
+</target>
+
+

+ +
Using the JMXProxyServlet
+ +

+ Tomcat offers an alternative to using remote (or even local) JMX + connections while still giving you access to everything JMX has to offer: + Tomcat's + JMXProxyServlet. +

+ +

+ The JMXProxyServlet allows a client to issue JMX queries via an HTTP + interface. This technique offers the following advantages over using + JMX directly from a client program: +

+ +
    +
  • You don't have to launch a full JVM and make a remote JMX connection + just to ask for one small piece of data from a running server
  • +
  • You don't have to know how to work with JMX connections
  • +
  • You don't need any of the complex configuration covered in the rest + of this page
  • +
  • Your client program does not have to be written in Java
  • +
+ +

+ A perfect example of JMX overkill can be seen in the case of popular + server-monitoring software such as Nagios or Icinga: if you want to + monitor 10 items via JMX, you will have to launch 10 JVMs, make 10 JMX + connections, and then shut them all down every few minutes. With the + JMXProxyServlet, you can make 10 HTTP connections and be done with it. +

+ +

+ You can find out more information about the JMXProxyServlet in the + documentation for the + Tomcat + manager. +

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/proxy-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/proxy-howto.html new file mode 100644 index 0000000..3abcf07 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/proxy-howto.html @@ -0,0 +1,196 @@ +Apache Tomcat 7 (7.0.108) - Proxy Support HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Proxy Support HOW-TO

Table of Contents
+ +
Introduction
+ +

Using standard configurations of Tomcat, web applications can ask for +the server name and port number to which the request was directed for +processing. When Tomcat is running standalone with the +HTTP/1.1 Connector, it will generally +report the server name specified in the request, and the port number on +which the Connector is listening. The servlet API +calls of interest, for this purpose, are:

+
    +
  • ServletRequest.getServerName(): Returns the host name of the server to which the request was sent.
  • +
  • ServletRequest.getServerPort(): Returns the port number of the server to which the request was sent.
  • +
  • ServletRequest.getLocalName(): Returns the host name of the Internet Protocol (IP) interface on which the request was received.
  • +
  • ServletRequest.getLocalPort(): Returns the Internet Protocol (IP) port number of the interface on which the request was received.
  • +
+ +

When you are running behind a proxy server (or a web server that is +configured to behave like a proxy server), you will sometimes prefer to +manage the values returned by these calls. In particular, you will +generally want the port number to reflect that specified in the original +request, not the one on which the Connector itself is +listening. You can use the proxyName and proxyPort +attributes on the <Connector> element to configure +these values.

+ +

Proxy support can take many forms. The following sections describe +proxy configurations for several common cases.

+ +
Apache 1.3 Proxy Support
+ +

Apache 1.3 supports an optional module (mod_proxy) that +configures the web server to act as a proxy server. This can be used to +forward requests for a particular web application to a Tomcat instance, +without having to configure a web connector such as mod_jk. +To accomplish this, you need to perform the following tasks:

+
    +
  1. Configure your copy of Apache so that it includes the + mod_proxy module. If you are building from source, + the easiest way to do this is to include the + --enable-module=proxy directive on the + ./configure command line.
  2. +
  3. If not already added for you, make sure that you are loading the + mod_proxy module at Apache startup time, by using the + following directives in your httpd.conf file: +
    
    +LoadModule proxy_module  {path-to-modules}/mod_proxy.so
    +AddModule  mod_proxy.c
    +
  4. +
  5. Include two directives in your httpd.conf file for + each web application that you wish to forward to Tomcat. For + example, to forward an application at context path /myapp: +
    
    +ProxyPass         /myapp  http://localhost:8081/myapp
    +ProxyPassReverse  /myapp  http://localhost:8081/myapp
    +
    + which tells Apache to forward URLs of the form + http://localhost/myapp/* to the Tomcat connector + listening on port 8081.
  6. +
  7. Configure your copy of Tomcat to include a special + <Connector> element, with appropriate + proxy settings, for example: +
    
    +<Connector port="8081" ...
    +              proxyName="www.mycompany.com"
    +              proxyPort="80"/>
    +
    + which will cause servlets inside this web application to think that + all proxied requests were directed to www.mycompany.com + on port 80.
  8. +
  9. It is legal to omit the proxyName attribute from the + <Connector> element. If you do so, the value + returned by request.getServerName() will by the host + name on which Tomcat is running. In the example above, it would be + localhost.
  10. +
  11. If you also have a <Connector> listening on port + 8080 (nested within the same Service + element), the requests to either port will share the same set of + virtual hosts and web applications.
  12. +
  13. You might wish to use the IP filtering features of your operating + system to restrict connections to port 8081 (in this example) to + be allowed only from the server that is running + Apache.
  14. +
  15. Alternatively, you can set up a series of web applications that are + only available via proxying, as follows: +
      +
    • Configure another <Service> that contains + only a <Connector> for the proxy port.
    • +
    • Configure appropriate Engine, + Host, and + Context elements for the virtual hosts + and web applications accessible via proxying.
    • +
    • Optionally, protect port 8081 with IP filters as described + earlier.
    • +
  16. +
  17. When requests are proxied by Apache, the web server will be recording + these requests in its access log. Therefore, you will generally want to + disable any access logging performed by Tomcat itself.
  18. +
+ +

When requests are proxied in this manner, all requests +for the configured web applications will be processed by Tomcat (including +requests for static content). You can improve performance by using the +mod_jk web connector instead of mod_proxy. +mod_jk can be configured so that the web server serves static +content that is not processed by filters or security constraints defined +within the web application's deployment descriptor +(/WEB-INF/web.xml).

+ +
Apache 2.0 Proxy Support
+The same instructions hold true as for 1.3. (Except in Apache 2.0, +you may omit AddModule mod_proxy.c) +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/realm-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/realm-howto.html new file mode 100644 index 0000000..8f34ece --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/realm-howto.html @@ -0,0 +1,1258 @@ +Apache Tomcat 7 (7.0.108) - Realm Configuration HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Realm Configuration HOW-TO

Table of Contents
+ +
Quick Start
+ +

This document describes how to configure Tomcat to support container +managed security, by connecting to an existing "database" of usernames, +passwords, and user roles. You only need to care about this if you are using +a web application that includes one or more +<security-constraint> elements, and a +<login-config> element defining how users are required +to authenticate themselves. If you are not utilizing these features, you can +safely skip this document.

+ +

For fundamental background information about container managed security, +see the Servlet +Specification (Version 2.4), Section 12.

+ +

For information about utilizing the Single Sign On feature of +Tomcat (allowing a user to authenticate themselves once across the entire +set of web applications associated with a virtual host), see +here.

+ +
Overview
+ + +
What is a Realm?
+ +

A Realm is a "database" of usernames and passwords that +identify valid users of a web application (or set of web applications), plus +an enumeration of the list of roles associated with each valid user. +You can think of roles as similar to groups in Unix-like operating +systems, because access to specific web application resources is granted to +all users possessing a particular role (rather than enumerating the list of +associated usernames). A particular user can have any number of roles +associated with their username.

+ +

Although the Servlet Specification describes a portable mechanism for +applications to declare their security requirements (in the +web.xml deployment descriptor), there is no portable API +defining the interface between a servlet container and the associated user +and role information. In many cases, however, it is desirable to "connect" +a servlet container to some existing authentication database or mechanism +that already exists in the production environment. Therefore, Tomcat +defines a Java interface (org.apache.catalina.Realm) that +can be implemented by "plug in" components to establish this connection. +Six standard plug-ins are provided, supporting connections to various +sources of authentication information:

+
    +
  • JDBCRealm - Accesses authentication information + stored in a relational database, accessed via a JDBC driver.
  • +
  • DataSourceRealm - Accesses authentication + information stored in a relational database, accessed via a named JNDI + JDBC DataSource.
  • +
  • JNDIRealm - Accesses authentication information + stored in an LDAP based directory server, accessed via a JNDI provider. +
  • +
  • UserDatabaseRealm - Accesses authentication + information stored in an UserDatabase JNDI resource, which is typically + backed by an XML document (conf/tomcat-users.xml).
  • +
  • MemoryRealm - Accesses authentication + information stored in an in-memory object collection, which is initialized + from an XML document (conf/tomcat-users.xml).
  • +
  • JAASRealm - Accesses authentication information + through the Java Authentication & Authorization Service (JAAS) + framework.
  • +
+ +

It is also possible to write your own Realm implementation, +and integrate it with Tomcat. To do so, you need to: +

    +
  • Implement org.apache.catalina.Realm,
  • +
  • Place your compiled realm in $CATALINA_HOME/lib,
  • +
  • Declare your realm as described in the "Configuring a Realm" section below,
  • +
  • Declare your realm to the MBeans Descriptors.
  • +
+

+ +
+ + +
Configuring a Realm
+ +

Before getting into the details of the standard Realm implementations, it is +important to understand, in general terms, how a Realm is configured. In +general, you will be adding an XML element to your conf/server.xml +configuration file, that looks something like this:

+ +

+<Realm className="... class name for this implementation"
+       ... other attributes for this implementation .../>
+
+ +

The <Realm> element can be nested inside any one of +of the following Container elements. The location of the +Realm element has a direct impact on the "scope" of that Realm +(i.e. which web applications will share the same authentication information): +

+
    +
  • Inside an <Engine> element - This Realm will be shared + across ALL web applications on ALL virtual hosts, UNLESS it is overridden + by a Realm element nested inside a subordinate <Host> + or <Context> element.
  • +
  • Inside a <Host> element - This Realm will be shared across + ALL web applications for THIS virtual host, UNLESS it is overridden + by a Realm element nested inside a subordinate <Context> + element.
  • +
  • Inside a <Context> element - This Realm will be used ONLY + for THIS web application.
  • +
+ + +
+ + +
Common Features
+ + +
Digested Passwords
+ +

For each of the standard Realm implementations, the +user's password (by default) is stored in clear text. In many +environments, this is undesirable because casual observers of the +authentication data can collect enough information to log on +successfully, and impersonate other users. To avoid this problem, the +standard implementations support the concept of digesting +user passwords. This allows the stored version of the passwords to be +encoded (in a form that is not easily reversible), but that the +Realm implementation can still utilize for +authentication.

+ +

When a standard realm authenticates by retrieving the stored +password and comparing it with the value presented by the user, you +can select digested passwords by specifying the digest +attribute on your <Realm> element. The value for +this attribute must be one of the digest algorithms supported by the +java.security.MessageDigest class (SHA, MD2, or MD5). +When you select this option, the contents of the password that is +stored in the Realm must be the cleartext version of the +password, as digested by the specified algorithm.

+ +

When the authenticate() method of the Realm is called, the +(cleartext) password specified by the user is itself digested by the same +algorithm, and the result is compared with the value returned by the +Realm. An equal match implies that the cleartext version of the +original password is the same as the one presented by the user, so that this +user should be authorized.

+ +

To calculate the digested value of a cleartext password, two convenience +techniques are supported:

+
    +
  • If you are writing an application that needs to calculate digested + passwords dynamically, call the static Digest() method of the + org.apache.catalina.realm.RealmBase class, passing the + cleartext password and the digest algorithm name as arguments. This + method will return the digested password.
  • +
  • If you want to execute a command line utility to calculate the digested + password, simply execute +
    CATALINA_HOME/bin/digest.[bat|sh] -a {algorithm} {cleartext-password}
    +
    + and the digested version of this cleartext password will be returned to + standard output.
  • +
+ +

If using digested passwords with DIGEST authentication, the cleartext used + to generate the digest is different and the digest must use the MD5 + algorithm. In the examples above {cleartext-password} must be + replaced with {username}:{realm}:{cleartext-password}. For + example, in a development environment this might take the form + testUser:Authentication required:testPassword. The value for + {realm} is taken from the <realm-name> + element of the web application's <login-config>. If + not specified in web.xml, the default value of Authentication + required is used.

+ +

Non-ASCII usernames and/or passwords are supported using +

CATALINA_HOME/bin/digest.[bat|sh] -a {algorithm} -e {encoding} {input}
+
+but care is required to ensure that the non-ASCII input is +correctly passed to the digester. +The digester returns {input}:{digest}. If the input appears +corrupted in the return, the digest will be invalid.

+ +
+ + + +
Example Application
+ +

The example application shipped with Tomcat includes an area that is +protected by a security constraint, utilizing form-based login. To access it, +point your browser at +http://localhost:8080/examples/jsp/security/protected/ +and log on with one of the usernames and passwords described for the default +UserDatabaseRealm.

+ +
+ + +
Manager Application
+ +

If you wish to use the Manager Application +to deploy and undeploy applications in a running Tomcat installation, you +MUST add the "manager-gui" role to at least one username in your selected +Realm implementation. This is because the manager web application itself uses a +security constraint that requires role "manager-gui" to access ANY request URI +within the HTML interface of that application.

+ +

For security reasons, no username in the default Realm (i.e. using +conf/tomcat-users.xml is assigned the "manager-gui" role. +Therefore, no one will be able to utilize the features of this application +until the Tomcat administrator specifically assigns this role to one or more +users.

+ +
+ +
Realm Logging
+ +

Debugging and exception messages logged by a Realm will + be recorded by the logging configuration associated with the container + for the realm: its surrounding Context, + Host, or + Engine.

+ +
+ +
Standard Realm Implementations
+ +
DataSourceRealm
+ +

Introduction

+ +

DataSourceRealm is an implementation of the Tomcat +Realm interface that looks up users in a relational database +accessed via a JNDI named JDBC DataSource. There is substantial configuration +flexibility that lets you adapt to existing table and column names, as long +as your database structure conforms to the following requirements:

+
    +
  • There must be a table, referenced below as the users table, + that contains one row for every valid user that this Realm + should recognize.
  • +
  • The users table must contain at least two columns (it may + contain more if your existing applications required it): +
      +
    • Username to be recognized by Tomcat when the user logs in.
    • +
    • Password to be recognized by Tomcat when the user logs in. + This value may in cleartext or digested - see below for more + information.
    • +
  • +
  • There must be a table, referenced below as the user roles table, + that contains one row for every valid role that is assigned to a + particular user. It is legal for a user to have zero, one, or more than + one valid role.
  • +
  • The user roles table must contain at least two columns (it may + contain more if your existing applications required it): +
      +
    • Username to be recognized by Tomcat (same value as is specified + in the users table).
    • +
    • Role name of a valid role associated with this user.
    • +
  • +
+ +

Quick Start

+ +

To set up Tomcat to use DataSourceRealm, you will need to follow these steps:

+
    +
  1. If you have not yet done so, create tables and columns in your database + that conform to the requirements described above.
  2. +
  3. Configure a database username and password for use by Tomcat, that has + at least read only access to the tables described above. (Tomcat will + never attempt to write to these tables.)
  4. +
  5. Configure a JNDI named JDBC DataSource for your database. Refer to the + JNDI DataSource Example + HOW-TO for information on how to configure a JNDI named JDBC DataSource. + Be sure to set the Realm's localDataSource + attribute appropriately, depending on where the JNDI DataSource is + defined.
  6. +
  7. Set up a <Realm> element, as described below, in your + $CATALINA_BASE/conf/server.xml file.
  8. +
  9. Restart Tomcat if it is already running.
  10. +
+ +

Realm Element Attributes

+ +

To configure DataSourceRealm, you will create a <Realm> +element and nest it in your $CATALINA_BASE/conf/server.xml file, +as described above. The attributes for the +DataSourceRealm are defined in the Realm +configuration documentation.

+ +

Example

+ +

An example SQL script to create the needed tables might look something +like this (adapt the syntax as required for your particular database):

+

+create table users (
+  user_name         varchar(15) not null primary key,
+  user_pass         varchar(15) not null
+);
+
+create table user_roles (
+  user_name         varchar(15) not null,
+  role_name         varchar(15) not null,
+  primary key (user_name, role_name)
+);
+
+ +

Here is an example for using a MySQL database called "authority", configured +with the tables described above, and accessed with the JNDI JDBC DataSource with +name "java:/comp/env/jdbc/authority".

+

+<Realm className="org.apache.catalina.realm.DataSourceRealm"
+   dataSourceName="jdbc/authority"
+   userTable="users" userNameCol="user_name" userCredCol="user_pass"
+   userRoleTable="user_roles" roleNameCol="role_name"/>
+
+ +

Additional Notes

+ +

DataSourceRealm operates according to the following rules:

+
    +
  • When a user attempts to access a protected resource for the first time, + Tomcat will call the authenticate() method of this + Realm. Thus, any changes you have made to the database + directly (new users, changed passwords or roles, etc.) will be immediately + reflected.
  • +
  • Once a user has been authenticated, the user (and his or her associated + roles) are cached within Tomcat for the duration of the user's login. + (For FORM-based authentication, that means until the session times out or + is invalidated; for BASIC authentication, that means until the user + closes their browser). The cached user is not saved and + restored across sessions serialisations. Any changes to the database + information for an already authenticated user will not be + reflected until the next time that user logs on again.
  • +
  • Administering the information in the users and user roles + table is the responsibility of your own applications. Tomcat does not + provide any built-in capabilities to maintain users and roles.
  • +
+ +
+ + +
JNDIRealm
+ +

Introduction

+ +

JNDIRealm is an implementation of the Tomcat +Realm interface that looks up users in an LDAP directory +server accessed by a JNDI provider (typically, the standard LDAP +provider that is available with the JNDI API classes). The realm +supports a variety of approaches to using a directory for +authentication.

+ +

Connecting to the directory

+ +

The realm's connection to the directory is defined by the +connectionURL configuration attribute. This is a URL +whose format is defined by the JNDI provider. It is usually an LDAP +URL that specifies the domain name of the directory server to connect +to, and optionally the port number and distinguished name (DN) of the +required root naming context.

+ +

If you have more than one provider you can configure an +alternateURL. If a socket connection can not be +made to the provider at the connectionURL an +attempt will be made to use the alternateURL.

+ +

When making a connection in order to search the directory and +retrieve user and role information, the realm authenticates itself to +the directory with the username and password specified by the +connectionName and +connectionPassword properties. If these properties +are not specified the connection is anonymous. This is sufficient in +many cases. +

+ + +

Selecting the user's directory entry

+ +

Each user that can be authenticated must be represented in the +directory by an individual entry that corresponds to an element in the +initial DirContext defined by the +connectionURL attribute. This user entry must have an +attribute containing the username that is presented for +authentication.

+ +

Often the distinguished name of the user's entry contains the +username presented for authentication but is otherwise the same for +all users. In this case the userPattern attribute may +be used to specify the DN, with "{0}" marking where +the username should be substituted.

+ +

Otherwise the realm must search the directory to find a unique entry +containing the username. The following attributes configure this +search: + +

    +
  • userBase - the entry that is the base of + the subtree containing users. If not specified, the search + base is the top-level context.
  • + +
  • userSubtree - the search scope. Set to + true if you wish to search the entire subtree + rooted at the userBase entry. The default value + of false requests a single-level search + including only the top level.
  • + +
  • userSearch - pattern specifying the LDAP + search filter to use after substitution of the username.
  • + +
+

+ + +

Authenticating the user

+ +
    +
  • +

    Bind mode

    + +

    By default the realm authenticates a user by binding to +the directory with the DN of the entry for that user and the password +presented by the user. If this simple bind succeeds the user is considered to +be authenticated.

    + +

    For security reasons a directory may store a digest of the user's +password rather than the clear text version (see Digested Passwords for more information). In that case, +as part of the simple bind operation the directory automatically +computes the correct digest of the plaintext password presented by the +user before validating it against the stored value. In bind mode, +therefore, the realm is not involved in digest processing. The +digest attribute is not used, and will be ignored if +set.

    +
  • + +
  • +

    Comparison mode

    +

    Alternatively, the realm may retrieve the stored +password from the directory and compare it explicitly with the value +presented by the user. This mode is configured by setting the +userPassword attribute to the name of a directory +attribute in the user's entry that contains the password.

    + +

    Comparison mode has some disadvantages. First, the +connectionName and +connectionPassword attributes must be configured to +allow the realm to read users' passwords in the directory. For +security reasons this is generally undesirable; indeed many directory +implementations will not allow even the directory manager to read +these passwords. In addition, the realm must handle password digests +itself, including variations in the algorithms used and ways of +representing password hashes in the directory. However, the realm may +sometimes need access to the stored password, for example to support +HTTP Digest Access Authentication (RFC 2069). (Note that HTTP digest +authentication is different from the storage of password digests in +the repository for user information as discussed above). +

    +
  • +
+ +

Assigning roles to the user

+ +

The directory realm supports two approaches to the representation +of roles in the directory:

+ +
    +
  • +

    Roles as explicit directory entries

    + +

    Roles may be represented by explicit directory entries. A role +entry is usually an LDAP group entry with one attribute +containing the name of the role and another whose values are the +distinguished names or usernames of the users in that role. The +following attributes configure a directory search to +find the names of roles associated with the authenticated user:

    + +
      +
    • roleBase - the base entry for the role search. + If not specified, the search base is the top-level directory + context.
    • + +
    • roleSubtree - the search + scope. Set to true if you wish to search the entire + subtree rooted at the roleBase entry. The default + value of false requests a single-level search + including the top level only.
    • + +
    • roleSearch - the LDAP search filter for + selecting role entries. It optionally includes pattern + replacements "{0}" for the distinguished name and/or "{1}" for the + username and/or "{2}" for an attribute from user's directory entry, + of the authenticated user. Use userRoleAttribute to + specify the name of the attribute that provides the value for "{2}".
    • + +
    • roleName - the attribute in a role entry + containing the name of that role.
    • + +
    • roleNested - enable nested roles. Set to + true if you want to nest roles in roles. If configured, then + every newly found roleName and distinguished + Name will be recursively tried for a new role search. + The default value is false.
    • + +
    + +
  • +
+ +
    +
  • +

    Roles as an attribute of the user entry

    + +

    Role names may also be held as the values of an attribute in the +user's directory entry. Use userRoleName to specify +the name of this attribute.

    + +
  • +
+

A combination of both approaches to role representation may be used.

+ +

Quick Start

+ +

To set up Tomcat to use JNDIRealm, you will need to follow these steps:

+
    +
  1. Make sure your directory server is configured with a schema that matches + the requirements listed above.
  2. +
  3. If required, configure a username and password for use by Tomcat, that has + read only access to the information described above. (Tomcat will + never attempt to modify this information.)
  4. +
  5. Set up a <Realm> element, as described below, in your + $CATALINA_BASE/conf/server.xml file.
  6. +
  7. Restart Tomcat if it is already running.
  8. +
+ +

Realm Element Attributes

+ +

To configure JNDIRealm, you will create a <Realm> +element and nest it in your $CATALINA_BASE/conf/server.xml file, +as described above. The attributes for the +JNDIRealm are defined in the Realm configuration +documentation.

+ +

Example

+ +

Creation of the appropriate schema in your directory server is beyond the +scope of this document, because it is unique to each directory server +implementation. In the examples below, we will assume that you are using a +distribution of the OpenLDAP directory server (version 2.0.11 or later), which +can be downloaded from +https://www.openldap.org. Assume that +your slapd.conf file contains the following settings +(among others):

+

+database ldbm
+suffix dc="mycompany",dc="com"
+rootdn "cn=Manager,dc=mycompany,dc=com"
+rootpw secret
+
+ +

We will assume for connectionURL that the directory +server runs on the same machine as Tomcat. See +http://docs.oracle.com/javase/7/docs/technotes/guides/jndi/index.html +for more information about configuring and using the JNDI LDAP +provider.

+ +

Next, assume that this directory server has been populated with elements +as shown below (in LDIF format):

+ +

+
+# Define top-level entry
+dn: dc=mycompany,dc=com
+objectClass: dcObject
+dc:mycompany
+
+# Define an entry to contain people
+# searches for users are based on this entry
+dn: ou=people,dc=mycompany,dc=com
+objectClass: organizationalUnit
+ou: people
+
+# Define a user entry for Janet Jones
+dn: uid=jjones,ou=people,dc=mycompany,dc=com
+objectClass: inetOrgPerson
+uid: jjones
+sn: jones
+cn: janet jones
+mail: j.jones@mycompany.com
+userPassword: janet
+
+# Define a user entry for Fred Bloggs
+dn: uid=fbloggs,ou=people,dc=mycompany,dc=com
+objectClass: inetOrgPerson
+uid: fbloggs
+sn: bloggs
+cn: fred bloggs
+mail: f.bloggs@mycompany.com
+userPassword: fred
+
+# Define an entry to contain LDAP groups
+# searches for roles are based on this entry
+dn: ou=groups,dc=mycompany,dc=com
+objectClass: organizationalUnit
+ou: groups
+
+# Define an entry for the "tomcat" role
+dn: cn=tomcat,ou=groups,dc=mycompany,dc=com
+objectClass: groupOfUniqueNames
+cn: tomcat
+uniqueMember: uid=jjones,ou=people,dc=mycompany,dc=com
+uniqueMember: uid=fbloggs,ou=people,dc=mycompany,dc=com
+
+# Define an entry for the "role1" role
+dn: cn=role1,ou=groups,dc=mycompany,dc=com
+objectClass: groupOfUniqueNames
+cn: role1
+uniqueMember: uid=fbloggs,ou=people,dc=mycompany,dc=com
+
+ +

An example Realm element for the OpenLDAP directory +server configured as described above might look like this, assuming +that users use their uid (e.g. jjones) to login to the +application and that an anonymous connection is sufficient to search +the directory and retrieve role information:

+ +

+<Realm   className="org.apache.catalina.realm.JNDIRealm"
+     connectionURL="ldap://localhost:389"
+       userPattern="uid={0},ou=people,dc=mycompany,dc=com"
+          roleBase="ou=groups,dc=mycompany,dc=com"
+          roleName="cn"
+        roleSearch="(uniqueMember={0})"
+/>
+
+ +

With this configuration, the realm will determine the user's +distinguished name by substituting the username into the +userPattern, authenticate by binding to the directory +with this DN and the password received from the user, and search the +directory to find the user's roles.

+ +

Now suppose that users are expected to enter their email address +rather than their userid when logging in. In this case the realm must +search the directory for the user's entry. (A search is also necessary +when user entries are held in multiple subtrees corresponding perhaps +to different organizational units or company locations).

+ +

Further, suppose that in addition to the group entries you want to +use an attribute of the user's entry to hold roles. Now the entry for +Janet Jones might read as follows:

+ +

+dn: uid=jjones,ou=people,dc=mycompany,dc=com
+objectClass: inetOrgPerson
+uid: jjones
+sn: jones
+cn: janet jones
+mail: j.jones@mycompany.com
+memberOf: role2
+memberOf: role3
+userPassword: janet
+
+ +

This realm configuration would satisfy the new requirements:

+ +

+<Realm   className="org.apache.catalina.realm.JNDIRealm"
+     connectionURL="ldap://localhost:389"
+          userBase="ou=people,dc=mycompany,dc=com"
+        userSearch="(mail={0})"
+      userRoleName="memberOf"
+          roleBase="ou=groups,dc=mycompany,dc=com"
+          roleName="cn"
+        roleSearch="(uniqueMember={0})"
+/>
+
+ +

Now when Janet Jones logs in as "j.jones@mycompany.com", the realm +searches the directory for a unique entry with that value as its mail +attribute and attempts to bind to the directory as +uid=jjones,ou=people,dc=mycompany,dc=com with the given +password. If authentication succeeds, she is assigned three roles: +"role2" and "role3", the values of the "memberOf" attribute in her +directory entry, and "tomcat", the value of the "cn" attribute in the +only group entry of which she is a member.

+ +

Finally, to authenticate the user by retrieving +the password from the directory and making a local comparison in the +realm, you might use a realm configuration like this:

+ +

+<Realm   className="org.apache.catalina.realm.JNDIRealm"
+    connectionName="cn=Manager,dc=mycompany,dc=com"
+connectionPassword="secret"
+     connectionURL="ldap://localhost:389"
+      userPassword="userPassword"
+       userPattern="uid={0},ou=people,dc=mycompany,dc=com"
+          roleBase="ou=groups,dc=mycompany,dc=com"
+          roleName="cn"
+        roleSearch="(uniqueMember={0})"
+/>
+
+ +

However, as discussed above, the default bind mode for +authentication is usually to be preferred.

+ +

Additional Notes

+ +

JNDIRealm operates according to the following rules:

+
    +
  • When a user attempts to access a protected resource for the first time, + Tomcat will call the authenticate() method of this + Realm. Thus, any changes you have made to the directory + (new users, changed passwords or roles, etc.) will be immediately + reflected.
  • +
  • Once a user has been authenticated, the user (and his or her associated + roles) are cached within Tomcat for the duration of the user's login. + (For FORM-based authentication, that means until the session times out or + is invalidated; for BASIC authentication, that means until the user + closes their browser). The cached user is not saved and + restored across sessions serialisations. Any changes to the directory + information for an already authenticated user will not be + reflected until the next time that user logs on again.
  • +
  • Administering the information in the directory server + is the responsibility of your own applications. Tomcat does not + provide any built-in capabilities to maintain users and roles.
  • +
+ +
+ + +
UserDatabaseRealm
+ +

Introduction

+ +

UserDatabaseRealm is an implementation of the Tomcat +Realm interface that uses a JNDI resource to store user +information. By default, the JNDI resource is backed by an XML file. It is not +designed for large-scale production use. At startup time, the UserDatabaseRealm +loads information about all users, and their corresponding roles, from an XML +document (by default, this document is loaded from +$CATALINA_BASE/conf/tomcat-users.xml). The users, their passwords +and their roles may all be editing dynamically, typically via JMX. Changes may +be saved and will be reflected in the XML file.

+ +

Realm Element Attributes

+ +

To configure UserDatabaseRealm, you will create a <Realm> +element and nest it in your $CATALINA_BASE/conf/server.xml file, +as described above. The attributes for the +UserDatabaseRealm are defined in the Realm +configuration documentation.

+ +

User File Format

+ +

The users file uses the same format as the +MemoryRealm.

+ +

Example

+ +

The default installation of Tomcat is configured with a UserDatabaseRealm +nested inside the <Engine> element, so that it applies +to all virtual hosts and web applications. The default contents of the +conf/tomcat-users.xml file is:

+

+<tomcat-users>
+  <user name="tomcat" password="tomcat" roles="tomcat" />
+  <user name="role1"  password="tomcat" roles="role1"  />
+  <user name="both"   password="tomcat" roles="tomcat,role1" />
+</tomcat-users>
+
+ +

Additional Notes

+ +

UserDatabaseRealm operates according to the following rules:

+
    +
  • When Tomcat first starts up, it loads all defined users and their + associated information from the users file. Changes made to the data in + this file will not be recognized until Tomcat is + restarted. Changes may be made via the UserDatabase resource. Tomcat + provides MBeans that may be accessed via JMX for this purpose.
  • +
  • When a user attempts to access a protected resource for the first time, + Tomcat will call the authenticate() method of this + Realm.
  • +
  • Once a user has been authenticated, the user (and his or her associated + roles) are cached within Tomcat for the duration of the user's login. + (For FORM-based authentication, that means until the session times out or + is invalidated; for BASIC authentication, that means until the user + closes their browser). The cached user is not saved and + restored across sessions serialisations.
  • +
+ + +
+ + +
MemoryRealm
+ +

Introduction

+ +

MemoryRealm is a simple demonstration implementation of the +Tomcat Realm interface. It is not designed for production use. +At startup time, MemoryRealm loads information about all users, and their +corresponding roles, from an XML document (by default, this document is loaded +from $CATALINA_BASE/conf/tomcat-users.xml). Changes to the data +in this file are not recognized until Tomcat is restarted.

+ +

Realm Element Attributes

+ +

To configure MemoryRealm, you will create a <Realm> +element and nest it in your $CATALINA_BASE/conf/server.xml file, +as described above. The attributes for the +MemoryRealm are defined in the Realm +configuration documentation.

+ +

User File Format

+ +

The users file (by default, conf/tomcat-users.xml must be an +XML document, with a root element <tomcat-users>. Nested +inside the root element will be a <user> element for each +valid user, consisting of the following attributes:

+
    +
  • name - Username this user must log on with.
  • +
  • password - Password this user must log on with (in + clear text if the digest attribute was not set on the + <Realm> element, or digested appropriately as + described here otherwise).
  • +
  • roles - Comma-delimited list of the role names + associated with this user.
  • +
+ +

Additional Notes

+ +

MemoryRealm operates according to the following rules:

+
    +
  • When Tomcat first starts up, it loads all defined users and their + associated information from the users file. Changes to the data in + this file will not be recognized until Tomcat is + restarted.
  • +
  • When a user attempts to access a protected resource for the first time, + Tomcat will call the authenticate() method of this + Realm.
  • +
  • Once a user has been authenticated, the user (and his or her associated + roles) are cached within Tomcat for the duration of the user's login. + (For FORM-based authentication, that means until the session times out or + is invalidated; for BASIC authentication, that means until the user + closes their browser). The cached user is not saved and + restored across sessions serialisations.
  • +
  • Administering the information in the users file is the responsibility + of your application. Tomcat does not + provide any built-in capabilities to maintain users and roles.
  • +
+ + +
+ + +
JAASRealm
+ +

Introduction

+ +

JAASRealm is an implementation of the Tomcat +Realm interface that authenticates users through the Java +Authentication & Authorization Service (JAAS) framework which is now +provided as part of the standard Java SE API.

+

Using JAASRealm gives the developer the ability to combine +practically any conceivable security realm with Tomcat's CMA.

+

JAASRealm is prototype for Tomcat of the JAAS-based +J2EE authentication framework for J2EE v1.4, based on the JCP Specification +Request 196 to enhance container-managed security and promote +'pluggable' authentication mechanisms whose implementations would be +container-independent. +

+

Based on the JAAS login module and principal (see javax.security.auth.spi.LoginModule +and javax.security.Principal), you can develop your own +security mechanism or wrap another third-party mechanism for +integration with the CMA as implemented by Tomcat. +

+ +

Quick Start

+

To set up Tomcat to use JAASRealm with your own JAAS login module, + you will need to follow these steps:

+
    +
  1. Write your own LoginModule, User and Role classes based +on JAAS (see + +the JAAS Authentication Tutorial and + +the JAAS Login Module Developer's Guide) to be managed by the JAAS Login +Context (javax.security.auth.login.LoginContext) +When developing your LoginModule, note that JAASRealm's built-in CallbackHandler +only recognizes the NameCallback and PasswordCallback at present. +
  2. +
  3. Although not specified in JAAS, you should create +separate classes to distinguish between users and roles, extending javax.security.Principal, +so that Tomcat can tell which Principals returned from your login +module are users and which are roles (see org.apache.catalina.realm.JAASRealm). +Regardless, the first Principal returned is always treated as the user Principal. +
  4. +
  5. Place the compiled classes on Tomcat's classpath +
  6. +
  7. Set up a login.config file for Java (see +JAAS LoginConfig file) and tell Tomcat where to find it by specifying +its location to the JVM, for instance by setting the environment +variable: JAVA_OPTS=$JAVA_OPTS -Djava.security.auth.login.config==$CATALINA_BASE/conf/jaas.config
  8. + +
  9. Configure your security-constraints in your web.xml for +the resources you want to protect
  10. +
  11. Configure the JAASRealm module in your server.xml
  12. +
  13. Restart Tomcat if it is already running.
  14. +
+

Realm Element Attributes

+

To configure JAASRealm as for step 6 above, you create +a <Realm> element and nest it in your +$CATALINA_BASE/conf/server.xml +file within your <Engine> node. The attributes for the +JAASRealm are defined in the Realm +configuration documentation.

+ +

Example

+ +

Here is an example of how your server.xml snippet should look.

+ +

+<Realm className="org.apache.catalina.realm.JAASRealm"
+                appName="MyFooRealm"
+    userClassNames="org.foobar.realm.FooUser"
+     roleClassNames="org.foobar.realm.FooRole"/>
+
+ +

It is the responsibility of your login module to create and save User and +Role objects representing Principals for the user +(javax.security.auth.Subject). If your login module doesn't +create a user object but also doesn't throw a login exception, then the +Tomcat CMA will break and you will be left at the +http://localhost:8080/myapp/j_security_check URI or at some other +unspecified location.

+ +

The flexibility of the JAAS approach is two-fold:

+
    +
  • you can carry out whatever processing you require behind +the scenes in your own login module.
  • +
  • you can plug in a completely different LoginModule by changing the configuration +and restarting the server, without any code changes to your application.
  • +
+ +

Additional Notes

+
    +
  • When a user attempts to access a protected resource for + the first time, Tomcat will call the authenticate() + method of this Realm. Thus, any changes you have made in + the security mechanism directly (new users, changed passwords or + roles, etc.) will be immediately reflected.
  • +
  • Once a user has been authenticated, the user (and his or + her associated roles) are cached within Tomcat for the duration of + the user's login. For FORM-based authentication, that means until + the session times out or is invalidated; for BASIC authentication, + that means until the user closes their browser. Any changes to the + security information for an already authenticated user will not + be reflected until the next time that user logs on again.
  • +
  • As with other Realm implementations, digested passwords + are supported if the <Realm> element in server.xml + contains a digest attribute; JAASRealm's CallbackHandler + will digest the password prior to passing it back to the LoginModule
  • +
+ +
+ + +
CombinedRealm
+ +

Introduction

+ +

CombinedRealm is an implementation of the Tomcat + Realm interface that authenticates users through one or more + sub-Realms.

+ +

Using CombinedRealm gives the developer the ability to combine multiple + Realms of the same or different types. This can be used to authenticate + against different sources, provide fall back in case one Realm fails or for + any other purpose that requires multiple Realms.

+ +

Sub-realms are defined by nesting Realm elements inside the + Realm element that defines the CombinedRealm. Authentication + will be attempted against each Realm in the order they are + listed. Authentication against any Realm will be sufficient to authenticate + the user.

+ +

Realm Element Attributes

+

To configure a CombinedRealm, you create a <Realm> + element and nest it in your $CATALINA_BASE/conf/server.xml + file within your <Engine> or <Host>. + You can also nest inside a <Context> node in a + context.xml file.

+ +

Example

+ +

Here is an example of how your server.xml snippet should look to use a +UserDatabase Realm and a DataSource Realm.

+ +

+<Realm className="org.apache.catalina.realm.CombinedRealm" >
+   <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
+             resourceName="UserDatabase"/>
+   <Realm className="org.apache.catalina.realm.DataSourceRealm"
+             dataSourceName="jdbc/authority"
+             userTable="users" userNameCol="user_name" userCredCol="user_pass"
+             userRoleTable="user_roles" roleNameCol="role_name"/>
+</Realm>
+
+ +
+ +
LockOutRealm
+ +

Introduction

+ +

LockOutRealm is an implementation of the Tomcat + Realm interface that extends the CombinedRealm to provide lock + out functionality to provide a user lock out mechanism if there are too many + failed authentication attempts in a given period of time.

+ +

To ensure correct operation, there is a reasonable degree of + synchronisation in this Realm.

+ +

This Realm does not require modification to the underlying Realms or the + associated user storage mechanisms. It achieves this by recording all failed + logins, including those for users that do not exist. To prevent a DOS by + deliberating making requests with invalid users (and hence causing this + cache to grow) the size of the list of users that have failed authentication + is limited.

+ +

Sub-realms are defined by nesting Realm elements inside the + Realm element that defines the LockOutRealm. Authentication + will be attempted against each Realm in the order they are + listed. Authentication against any Realm will be sufficient to authenticate + the user.

+ +

Realm Element Attributes

+

To configure a LockOutRealm, you create a <Realm> + element and nest it in your $CATALINA_BASE/conf/server.xml + file within your <Engine> or <Host>. + You can also nest inside a <Context> node in a + context.xml file. The attributes for the + LockOutRealm are defined in the Realm + configuration documentation.

+ +

Example

+ +

Here is an example of how your server.xml snippet should look to add lock out +functionality to a UserDatabase Realm.

+ +

+<Realm className="org.apache.catalina.realm.LockOutRealm" >
+   <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
+             resourceName="UserDatabase"/>
+</Realm>
+
+ +
+ +
JDBCRealm
+ +

Introduction

+ +

The JDBC Database Realm has been deprecated and will be removed +in Tomcat 10 onwards. Use the DataSourceRealm instead.

+ +

JDBCRealm is an implementation of the Tomcat +Realm interface that looks up users in a relational database +accessed via a JDBC driver. There is substantial configuration flexibility +that lets you adapt to existing table and column names, as long as your +database structure conforms to the following requirements:

+
    +
  • There must be a table, referenced below as the users table, + that contains one row for every valid user that this Realm + should recognize.
  • +
  • The users table must contain at least two columns (it may + contain more if your existing applications required it): +
      +
    • Username to be recognized by Tomcat when the user logs in.
    • +
    • Password to be recognized by Tomcat when the user logs in. + This value may in cleartext or digested - see below for more + information.
    • +
  • +
  • There must be a table, referenced below as the user roles table, + that contains one row for every valid role that is assigned to a + particular user. It is legal for a user to have zero, one, or more than + one valid role.
  • +
  • The user roles table must contain at least two columns (it may + contain more if your existing applications required it): +
      +
    • Username to be recognized by Tomcat (same value as is specified + in the users table).
    • +
    • Role name of a valid role associated with this user.
    • +
  • +
+ +

Quick Start

+ +

To set up Tomcat to use JDBCRealm, you will need to follow these steps:

+
    +
  1. If you have not yet done so, create tables and columns in your database + that conform to the requirements described above.
  2. +
  3. Configure a database username and password for use by Tomcat, that has + at least read only access to the tables described above. (Tomcat will + never attempt to write to these tables.)
  4. +
  5. Place a copy of the JDBC driver you will be using inside the + $CATALINA_HOME/lib directory. + Note that only JAR files are recognized!
  6. +
  7. Set up a <Realm> element, as described below, in your + $CATALINA_BASE/conf/server.xml file.
  8. +
  9. Restart Tomcat if it is already running.
  10. +
+ +

Realm Element Attributes

+ +

To configure JDBCRealm, you will create a <Realm> +element and nest it in your $CATALINA_BASE/conf/server.xml file, +as described above. The attributes for the +JDBCRealm are defined in the Realm configuration +documentation.

+ +

Example

+ +

An example SQL script to create the needed tables might look something +like this (adapt the syntax as required for your particular database):

+

+create table users (
+  user_name         varchar(15) not null primary key,
+  user_pass         varchar(15) not null
+);
+
+create table user_roles (
+  user_name         varchar(15) not null,
+  role_name         varchar(15) not null,
+  primary key (user_name, role_name)
+);
+
+ +

Example Realm elements are included (commented out) in the +default $CATALINA_BASE/conf/server.xml file. Here's an example +for using a MySQL database called "authority", configured with the tables +described above, and accessed with username "dbuser" and password "dbpass":

+

+<Realm className="org.apache.catalina.realm.JDBCRealm"
+      driverName="org.gjt.mm.mysql.Driver"
+   connectionURL="jdbc:mysql://localhost/authority?user=dbuser&amp;password=dbpass"
+       userTable="users" userNameCol="user_name" userCredCol="user_pass"
+   userRoleTable="user_roles" roleNameCol="role_name"/>
+
+ +

Additional Notes

+ +

JDBCRealm operates according to the following rules:

+
    +
  • When a user attempts to access a protected resource for the first time, + Tomcat will call the authenticate() method of this + Realm. Thus, any changes you have made to the database + directly (new users, changed passwords or roles, etc.) will be immediately + reflected.
  • +
  • Once a user has been authenticated, the user (and his or her associated + roles) are cached within Tomcat for the duration of the user's login. + (For FORM-based authentication, that means until the session times out or + is invalidated; for BASIC authentication, that means until the user + closes their browser). The cached user is not saved and + restored across sessions serialisations. Any changes to the database + information for an already authenticated user will not be + reflected until the next time that user logs on again.
  • +
  • Administering the information in the users and user roles + table is the responsibility of your own applications. Tomcat does not + provide any built-in capabilities to maintain users and roles.
  • +
+ +
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/security-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/security-howto.html new file mode 100644 index 0000000..9446264 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/security-howto.html @@ -0,0 +1,586 @@ +Apache Tomcat 7 (7.0.108) - Security Considerations

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Security Considerations

Table of Contents
+ +
Introduction
+

Tomcat is configured to be reasonably secure for most use cases by + default. Some environments may require more, or less, secure configurations. + This page is to provide a single point of reference for configuration + options that may impact security and to offer some commentary on the + expected impact of changing those options. The intention is to provide a + list of configuration options that should be considered when assessing the + security of a Tomcat installation.

+ +

Note: Reading this page is not a substitute for reading + and understanding the detailed configuration documentation. Fuller + descriptions of these attributes may be found in the relevant documentation + pages.

+
Non-Tomcat settings
+

Tomcat configuration should not be the only line of defense. The other + components in the system (operating system, network, database, etc.) should + also be secured.

+

Tomcat should not be run under the root user. Create a dedicated user for + the Tomcat process and provide that user with the minimum necessary + permissions for the operating system. For example, it should not be possible + to log on remotely using the Tomcat user.

+

File permissions should also be suitably restricted. In the + .tar.gz distribution, files and directories are not world + readable and the group does not have write access. On Unix like operating + systems, Tomcat runs with a default umask of 0027 to maintain + these permissions for files created while Tomcat is running (e.g. log files, + expanded WARs, etc.).

+

Taking the Tomcat instances at the ASF as an example (where + auto-deployment is disabled and web applications are deployed as exploded + directories), the standard configuration is to have all Tomcat files owned + by root with group Tomcat and whilst owner has read/write privileges, group + only has read and world has no permissions. The exceptions are the logs, + temp and work directory that are owned by the Tomcat user rather than root. + This means that even if an attacker compromises the Tomcat process, they + can't change the Tomcat configuration, deploy new web applications or + modify existing web applications. The Tomcat process runs with a umask of + 007 to maintain these permissions.

+

At the network level, consider using a firewall to limit both incoming + and outgoing connections to only those connections you expect to be + present.

+ +
JMX
+

The security of the JMX connection is dependent on the implementation + provided by the JRE and therefore falls outside the control of Tomcat.

+ +

Typically, access control is very limited (either read-only to + everything or read-write to everything). Tomcat exposes a large amount + of internal information and control via JMX to aid debugging, monitoring + and management. Given the limited access control available, JMX access + should be treated as equivalent to local root/admin access and restricted + accordingly.

+ +

The JMX access control provided by most (all?) JRE vendors does not + log failed authentication attempts, nor does it provide an account + lock-out feature after repeated failed authentications. This makes a + brute force attack easy to mount and difficult to detect.

+ +

Given all of the above, care should be taken to ensure that, if used, + the JMX interface is appropriately secured. Options you may wish to + consider to secure the JMX interface include:

+ +
    +
  • configuring a strong password for all JMX users;
  • +
  • binding the JMX listener only to an internal network;
  • +
  • limiting network access to the JMX port to trusted clients; and
  • +
  • providing an application specific health page for use by external + monitoring systems.
  • +
+
+ +
Default web applications
+ +
General
+

Tomcat ships with a number of web applications that are enabled by + default. Vulnerabilities have been discovered in these applications in the + past. Applications that are not required should be removed so the system + will not be at risk if another vulnerability is discovered.

+
+ +
ROOT
+

The ROOT web application presents a very low security risk but it does + include the version of Tomcat that is being used. The ROOT web application + should normally be removed from a publicly accessible Tomcat instance, not + for security reasons, but so that a more appropriate default page is shown + to users.

+
+ +
Documentation
+

The documentation web application presents a very low security risk but + it does identify the version of Tomcat that is being used. It should + normally be removed from a publicly accessible Tomcat instance.

+
+ +
Examples
+

The examples web application should always be removed from any security + sensitive installation. While the examples web application does not + contain any known vulnerabilities, it is known to contain features + (particularly the cookie examples that display the contents of all + received and allow new cookies to be set) that may be used by an attacker + in conjunction with a vulnerability in another application deployed on the + Tomcat instance to obtain additional information that would otherwise be + unavailable.

+
+ +
Manager
+

The Manager application allows the remote deployment of web + applications and is frequently targeted by attackers due to the widespread + use of weak passwords and publicly accessible Tomcat instances with the + Manager application enabled. The Manager application is not accessible by + default as no users are configured with the necessary access. If the + Manager application is enabled then guidance in the section + Securing Management Applications section should be + followed.

+
+ +
Host Manager
+

The Host Manager application allows the creation and management of + virtual hosts - including the enabling of the Manager application for a + virtual host. The Host Manager application is not accessible by default + as no users are configured with the necessary access. If the Host Manager + application is enabled then guidance in the section Securing + Management Applications section should be followed.

+
+ +
Securing Management Applications
+

When deploying a web application that provides management functions for + the Tomcat instance, the following guidelines should be followed:

+
    +
  • Ensure that any users permitted to access the management application + have strong passwords.
  • +
  • Do not remove the use of the LockOutRealm + which prevents brute force attacks against user passwords.
  • +
  • Uncomment the RemoteAddrValve + in /META-INF/context.xml which limits access to + localhost. If remote access is required, limit it to specific IP + addresses using this valve.
  • +
+
+
Security manager
+

Enabling the security manager causes web applications to be run in a + sandbox, significantly limiting a web application's ability to perform + malicious actions such as calling System.exit(), establishing network + connections or accessing the file system outside of the web application's + root and temporary directories. However, it should be noted that there are + some malicious actions, such as triggering high CPU consumption via an + infinite loop, that the security manager cannot prevent.

+ +

Enabling the security manager is usually done to limit the potential + impact, should an attacker find a way to compromise a trusted web + application . A security manager may also be used to reduce the risks of + running untrusted web applications (e.g. in hosting environments) but it + should be noted that the security manager only reduces the risks of + running untrusted web applications, it does not eliminate them. If running + multiple untrusted web applications, it is recommended that each web + application is deployed to a separate Tomcat instance (and ideally separate + hosts) to reduce the ability of a malicious web application impacting the + availability of other applications.

+ +

Tomcat is tested with the security manager enabled; but the majority of + Tomcat users do not run with a security manager, so Tomcat is not as well + user-tested in this configuration. There have been, and continue to be, + bugs reported that are triggered by running under a security manager.

+ +

The restrictions imposed by a security manager are likely to break most + applications if the security manager is enabled. The security manager should + not be used without extensive testing. Ideally, the use of a security + manager should be introduced at the start of the development cycle as it can + be time-consuming to track down and fix issues caused by enabling a security + manager for a mature application.

+ +

Enabling the security manager changes the defaults for the following + settings:

+
    +
  • The default value for the deployXML attribute of the + Host element is changed to false.
  • +
+
server.xml
+
General
+

The default server.xml contains a large number of comments, including + some example component definitions that are commented out. Removing these + comments makes it considerably easier to read and comprehend + server.xml.

+

If a component type is not listed, then there are no settings for that + type that directly impact security.

+
+ +
Server
+

Setting the port attribute to -1 disables + the shutdown port.

+

If the shutdown port is not disabled, a strong password should be + configured for shutdown.

+
+ +
Listeners
+

The APR Lifecycle Listener is not stable if compiled on Solaris using + gcc. If using the APR/native connector on Solaris, compile it with the + Sun Studio compiler.

+

The JNI Library Loading Listener may be used to load native code. It should + only be used to load trusted libraries.

+

The Security Lifecycle Listener should be enabled and configured as appropriate. +

+
+ +
Connectors
+

By default, a non-TLS, HTTP/1.1 connector is configured on port 8080. + Connectors that will not be used should be removed from server.xml.

+ +

The address attribute may be used to control which IP + address a connector listens on for connections. By default, a connector + listens on all configured IP addresses.

+ +

The allowTrace attribute may be used to enable TRACE + requests which can be useful for debugging. Due to the way some browsers + handle the response from a TRACE request (which exposes the browser to an + XSS attack), support for TRACE requests is disabled by default.

+ +

The discardFacades attribute set to true + will cause a new facade object to be created for each request. This + reduces the chances of a bug in an application exposing data from one + request to another.

+ +

The encodedSolidusHandling attribute allows + non-standard parsing of the request URI. Setting this attribute to a + non-default value when behind a reverse proxy may enable an attacker to + bypass any security constraints enforced by the proxy.

+ +

The maxPostSize attribute controls the maximum size + of a POST request that will be parsed for parameters. The parameters are + cached for the duration of the request so this is limited to 2MB by + default to reduce exposure to a DOS attack.

+ +

The maxSavePostSize attribute controls the saving of + POST requests during FORM and CLIENT-CERT authentication. The parameters + are cached for the duration of the authentication (which may be many + minutes) so this is limited to 4KB by default to reduce exposure to a DOS + attack.

+ +

The maxParameterCount attribute controls the + maximum number of parameter and value pairs (GET plus POST) that can + be parsed and stored in the request. Excessive parameters are ignored. + If you want to reject such requests, configure a + FailedRequestFilter.

+ +

The xpoweredBy attribute controls whether or not the + X-Powered-By HTTP header is sent with each request. If sent, the value of + the header contains the Servlet and JSP specification versions, the full + Tomcat version (e.g. Apache Tomcat/7.0), the name of + the JVM vendor and + the version of the JVM. This header is disabled by default. This header + can provide useful information to both legitimate clients and attackers. +

+ +

The server attribute controls the value of the Server + HTTP header. The default value of this header for Tomcat 4.1.x to + 8.0.x is Apache-Coyote/1.1. From 8.5.x onwards this header is not set by + default. This header can provide limited information to both legitimate + clients and attackers.

+ +

The SSLEnabled, scheme and + secure attributes may all be independently set. These are + normally used when Tomcat is located behind a reverse proxy and the proxy + is connecting to Tomcat via HTTP or HTTPS. They allow Tomcat to see the + SSL attributes of the connections between the client and the proxy rather + than the proxy and Tomcat. For example, the client may connect to the + proxy over HTTPS but the proxy connects to Tomcat using HTTP. If it is + necessary for Tomcat to be able to distinguish between secure and + non-secure connections received by a proxy, the proxy must use separate + connectors to pass secure and non-secure requests to Tomcat. If the + proxy uses AJP then the SSL attributes of the client connection are + passed via the AJP protocol and separate connectors are not needed.

+ +

The tomcatAuthentication and + tomcatAuthorization attributes are used with the + AJP connectors to determine if Tomcat should handle all authentication and + authorisation or if authentication should be delegated to the reverse + proxy (the authenticated user name is passed to Tomcat as part of the AJP + protocol) with the option for Tomcat to still perform authorization.

+ +

The allowUnsafeLegacyRenegotiation attribute provides + a workaround for + + CVE-2009-3555, a TLS man in the middle attack. This workaround applies + to the BIO connector. It is only necessary if the underlying SSL + implementation is vulnerable to CVE-2009-3555. For more information on the + current state of this vulnerability and the work-arounds available see the + Tomcat 7 security + page.

+ +

The requiredSecret attribute in AJP connectors + configures shared secret between Tomcat and reverse proxy in front of + Tomcat. It is used to prevent unauthorized connections over AJP protocol.

+
+ +
Host
+

The host element controls deployment. Automatic deployment allows for + simpler management but also makes it easier for an attacker to deploy a + malicious application. Automatic deployment is controlled by the + autoDeploy and deployOnStartup + attributes. If both are false, only Contexts defined in + server.xml will be deployed and any changes will require a Tomcat restart. +

+ +

In a hosted environment where web applications may not be trusted, set + the deployXML attribute to false to ignore + any context.xml packaged with the web application that may try to assign + increased privileges to the web application. Note that if the security + manager is enabled that the deployXML attribute will + default to false.

+
+ +
Context
+

This applies to Context + elements in all places where they can be defined: + server.xml file, + default context.xml file, + per-host context.xml.default file, + web application context file in per-host configuration directory + or inside the web application.

+ +

The crossContext attribute controls if a context is + allowed to access the resources of another context. It is + false by default and should only be changed for trusted web + applications.

+ +

The privileged attribute controls if a context is + allowed to use container provided servlets like the Manager servlet. It is + false by default and should only be changed for trusted web + applications.

+ +

The allowLinking attribute controls if a context is + allowed to use linked files. If enabled and the context is undeployed, the + links will be followed when deleting the context resources. To avoid this + behaviour, use the aliases attribute. Changing this + setting from the default of false on case insensitive + operating systems (this includes Windows) will disable a number of + security measures and allow, among other things, direct access to the + WEB-INF directory.

+ +

The sessionCookiePathUsesTrailingSlash can be used to + work around a bug in a number of browsers (Internet Explorer, Safari and + Edge) to prevent session cookies being exposed across applications when + applications share a common path prefix. However, enabling this option + can create problems for applications with Servlets mapped to + /*. It should also be noted the RFC6265 section 8.5 makes it + clear that different paths should not be considered sufficient to isolate + cookies from other applications.

+
+ +
Valves
+

It is strongly recommended that an AccessLogValve is configured. The + default Tomcat configuration includes an AccessLogValve. These are + normally configured per host but may also be configured per engine or per + context as required.

+ +

Any administrative application should be protected by a + RemoteAddrValve (this Valve is also available as a Filter). + The allow attribute should be used to limit access to a + set of known trusted hosts.

+ +

The default ErrorReportValve includes the Tomcat version number in the + response sent to clients. To avoid this, custom error handling can be + configured within each web application. Alternatively, you can explicitly + configure an ErrorReportValve and set its + showServerInfo attribute to false. + Alternatively, the version number can be changed by creating the file + CATALINA_BASE/lib/org/apache/catalina/util/ServerInfo.properties with + content as follows:

+
server.info=Apache Tomcat/7.0.x
+

Modify the values as required. Note that this will also change the version + number reported in some of the management tools and may make it harder to + determine the real version installed. The CATALINA_HOME/bin/version.bat|sh + script will still report the correct version number.

+ +

The default ErrorReportValve can display stack traces and/or JSP + source code to clients when an error occurs. To avoid this, custom error + handling can be configured within each web application. Alternatively, you + can explicitly configure an ErrorReportValve + and set its showReport attribute to false.

+
+ +
Realms
+

The MemoryRealm is not intended for production use as any changes to + tomcat-users.xml require a restart of Tomcat to take effect.

+ +

The JDBCRealm is not recommended for production use as it is single + threaded for all authentication and authorization options. Use the + DataSourceRealm instead.

+ +

The UserDatabaseRealm is not intended for large-scale installations. It + is intended for small-scale, relatively static environments.

+ +

The JAASRealm is not widely used and therefore the code is not as + mature as the other realms. Additional testing is recommended before using + this realm.

+ +

By default, the realms do not implement any form of account lock-out. + This means that brute force attacks can be successful. To prevent a brute + force attack, the chosen realm should be wrapped in a LockOutRealm.

+
+ +
Manager
+

The manager component is used to generate session IDs.

+ +

The class used to generate random session IDs may be changed with + the randomClass attribute.

+ +

The length of the session ID may be changed with the + sessionIdLength attribute.

+ +

The persistAuthentication controls whether the + authenticated Principal associated with the session (if any) is included + when the session is persisted during a restart or to a Store.

+
+ +
Cluster
+

The cluster implementation is written on the basis that a secure, + trusted network is used for all of the cluster related network traffic. It + is not safe to run a cluster on a insecure, untrusted network.

+
+
System Properties
+

The + org.apache.catalina.connector.CoyoteAdapter.ALLOW_BACKSLASH and + org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH + system properties allow non-standard parsing of the request URI. Using + these options when behind a reverse proxy may enable an attacker to bypass + any security constraints enforced by the proxy.

+ +

The + org.apache.catalina.connector.Response.ENFORCE_ENCODING_IN_GET_WRITER + system property has security implications if disabled. Many user + agents, in breach of RFC2616, try to guess the character encoding of text + media types when the specification-mandated default of ISO-8859-1 should be + used. Some browsers will interpret as UTF-7 a response containing characters + that are safe for ISO-8859-1 but trigger an XSS vulnerability if interpreted + as UTF-7.

+
web.xml
+

This applies to the default conf/web.xml file and + WEB-INF/web.xml files in web applications if they define + the components mentioned here.

+ +

The DefaultServlet is configured + with readonly set to + true. Changing this to false allows clients to + delete or modify static resources on the server and to upload new + resources. This should not normally be changed without requiring + authentication.

+ +

The DefaultServlet is configured with listings set to + false. This isn't because allowing directory listings is + considered unsafe but because generating listings of directories with + thousands of files can consume significant CPU leading to a DOS attack. +

+ +

The DefaultServlet is configured with showServerInfo + set to true. When the directory listings is enabled the Tomcat + version number is included in the response sent to clients. To avoid this, + you can explicitly configure a DefaultServlet and set its + showServerInfo attribute to false. + Alternatively, the version number can be changed by creating the file + CATALINA_BASE/lib/org/apache/catalina/util/ServerInfo.properties with + content as follows:

+
server.info=Apache Tomcat/7.0.x
+

Modify the values as required. Note that this will also change the version + number reported in some of the management tools and may make it harder to + determine the real version installed. The CATALINA_HOME/bin/version.bat|sh + script will still report the correct version number. +

+ +

The CGI Servlet is disabled by default. If enabled, the debug + initialisation parameter should not be set to 10 or higher on a + production system because the debug page is not secure.

+ +

When using the CGI Servlet on Windows with + enableCmdLineArguments enabled, review the setting of + cmdLineArgumentsDecoded carefully and ensure that it is + appropriate for your environment. The default value is secure. Insecure + configurations may expose the server to remote code execution. Further + information on the potential risks and mitigations may be found by + following the links in the CGI How To.

+ +

FailedRequestFilter + can be configured and used to reject requests that had errors during + request parameter parsing. Without the filter the default behaviour is + to ignore invalid or excessive parameters.

+ +

HttpHeaderSecurityFilter can be + used to add headers to responses to improve security. If clients access + Tomcat directly, then you probably want to enable this filter and all the + headers it sets unless your application is already setting them. If Tomcat + is accessed via a reverse proxy, then the configuration of this filter needs + to be co-ordinated with any headers that the reverse proxy sets.

+
General
+

BASIC and FORM authentication pass user names and passwords in clear + text. Web applications using these authentication mechanisms with clients + connecting over untrusted networks should use SSL.

+ +

The session cookie for a session with an authenticated user are nearly + as useful as the user's password to an attacker and in nearly all + circumstances should be afforded the same level of protection as the + password itself. This usually means authenticating over SSL and continuing + to use SSL until the session ends.

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/security-manager-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/security-manager-howto.html new file mode 100644 index 0000000..4c9140e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/security-manager-howto.html @@ -0,0 +1,570 @@ +Apache Tomcat 7 (7.0.108) - Security Manager HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Security Manager HOW-TO

Table of Contents
+ +
Background
+ +

The Java SecurityManager is what allows a web browser + to run an applet in its own sandbox to prevent untrusted code from + accessing files on the local file system, connecting to a host other + than the one the applet was loaded from, and so on. In the same way + the SecurityManager protects you from an untrusted applet running in + your browser, use of a SecurityManager while running Tomcat can protect + your server from trojan servlets, JSPs, JSP beans, and tag libraries. + Or even inadvertent mistakes.

+ +

Imagine if someone who is authorized to publish JSPs on your site + inadvertently included the following in their JSP:

+

+<% System.exit(1); %>
+
+ +

Every time this JSP was executed by Tomcat, Tomcat would exit. + Using the Java SecurityManager is just one more line of defense a + system administrator can use to keep the server secure and reliable.

+ +

WARNING - A security audit + have been conducted using the Tomcat codebase. Most of the critical + package have been protected and a new security package protection mechanism + has been implemented. Still, make sure that you are satisfied with your SecurityManager + configuration before allowing untrusted users to publish web applications, + JSPs, servlets, beans, or tag libraries. However, running with a + SecurityManager is definitely better than running without one.

+ +
Permissions
+ +

Permission classes are used to define what Permissions a class loaded + by Tomcat will have. There are a number of Permission classes that are + a standard part of the JDK, and you can create your own Permission class + for use in your own web applications. Both techniques are used in + Tomcat.

+ + +
Standard Permissions
+ +

This is just a short summary of the standard system SecurityManager + Permission classes applicable to Tomcat. See + + http://docs.oracle.com/javase/7/docs/technotes/guides/security/ + for more information.

+ +
    +
  • java.util.PropertyPermission - Controls read/write + access to JVM properties such as java.home.
  • +
  • java.lang.RuntimePermission - Controls use of + some System/Runtime functions like exit() and + exec(). Also control the package access/definition.
  • +
  • java.io.FilePermission - Controls read/write/execute + access to files and directories.
  • +
  • java.net.SocketPermission - Controls use of + network sockets.
  • +
  • java.net.NetPermission - Controls use of + multicast network connections.
  • +
  • java.lang.reflect.ReflectPermission - Controls + use of reflection to do class introspection.
  • +
  • java.security.SecurityPermission - Controls access + to Security methods.
  • +
  • java.security.AllPermission - Allows access to all + permissions, just as if you were running Tomcat without a + SecurityManager.
  • +
+ +
+ + +
Tomcat Custom Permissions
+ +

Tomcat utilizes a custom permission class called + org.apache.naming.JndiPermission. This permission + controls read access to JNDI named file based resources. The permission + name is the JNDI name and there are no actions. A trailing "*" can be + used to do wild card matching for a JNDI named file resource when + granting permission. For example, you might include the following + in your policy file:

+

+permission  org.apache.naming.JndiPermission  "jndi://localhost/examples/*";
+
+ +

A Permission entry like this is generated dynamically for each web + application that is deployed, to allow it to read its own static resources + but disallow it from using file access to read any other files (unless + permissions for those files are explicitly granted).

+ +

Also, Tomcat always dynamically creates the following file permissions:

+

+permission java.io.FilePermission "** your application context**", "read";
+
+permission java.io.FilePermission
+  "** application working directory**", "read,write";
+permission java.io.FilePermission
+  "** application working directory**/-", "read,write,delete";
+
+

Where **your application context** equals the folder (or WAR file) under which + your application has been deployed and **application working directory** is the + temporary directory provided to your application as required by the + Servlet Specification.

+ +
+ + +
Configuring Tomcat With A SecurityManager
+ +

Policy File Format

+ +

The security policies implemented by the Java SecurityManager are + configured in the $CATALINA_BASE/conf/catalina.policy file. + This file completely replaces the java.policy file present + in your JDK system directories. The catalina.policy file + can be edited by hand, or you can use the + policytool + application that comes with Java 1.2 or later.

+ +

Entries in the catalina.policy file use the standard + java.policy file format, as follows:

+

+// Example policy file entry
+
+grant [signedBy <signer>,] [codeBase <code source>] {
+  permission  <class>  [<name> [, <action list>]];
+};
+
+ +

The signedBy and codeBase entries are + optional when granting permissions. Comment lines begin with "//" and + end at the end of the current line. The codeBase is in the + form of a URL, and for a file URL can use the ${java.home} + and ${catalina.home} properties (which are expanded out to + the directory paths defined for them by the JAVA_HOME, + CATALINA_HOME and CATALINA_BASE environment + variables).

+ +

The Default Policy File

+ +

The default $CATALINA_BASE/conf/catalina.policy file + looks like this:

+ + +
// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// ============================================================================
+// catalina.policy - Security Policy Permissions for Tomcat 7
+//
+// This file contains a default set of security policies to be enforced (by the
+// JVM) when Catalina is executed with the "-security" option.  In addition
+// to the permissions granted here, the following additional permissions are
+// granted to each web application:
+//
+// * Read access to the web application's document root directory
+// * Read, write and delete access to the web application's working directory
+// ============================================================================
+
+
+// ========== SYSTEM CODE PERMISSIONS =========================================
+
+
+// These permissions apply to javac
+grant codeBase "file:${java.home}/lib/-" {
+        permission java.security.AllPermission;
+};
+
+// These permissions apply to all shared system extensions
+grant codeBase "file:${java.home}/jre/lib/ext/-" {
+        permission java.security.AllPermission;
+};
+
+// These permissions apply to javac when ${java.home} points at $JAVA_HOME/jre
+grant codeBase "file:${java.home}/../lib/-" {
+        permission java.security.AllPermission;
+};
+
+// These permissions apply to all shared system extensions when
+// ${java.home} points at $JAVA_HOME/jre
+grant codeBase "file:${java.home}/lib/ext/-" {
+        permission java.security.AllPermission;
+};
+
+
+// ========== CATALINA CODE PERMISSIONS =======================================
+
+
+// These permissions apply to the daemon code
+grant codeBase "file:${catalina.home}/bin/commons-daemon.jar" {
+        permission java.security.AllPermission;
+};
+
+// These permissions apply to the logging API
+// Note: If tomcat-juli.jar is in ${catalina.base} and not in ${catalina.home},
+// update this section accordingly.
+//  grant codeBase "file:${catalina.base}/bin/tomcat-juli.jar" {..}
+grant codeBase "file:${catalina.home}/bin/tomcat-juli.jar" {
+        permission java.io.FilePermission
+         "${java.home}${file.separator}lib${file.separator}logging.properties", "read";
+
+        permission java.io.FilePermission
+         "${catalina.base}${file.separator}conf${file.separator}logging.properties", "read";
+        permission java.io.FilePermission
+         "${catalina.base}${file.separator}logs", "read, write";
+        permission java.io.FilePermission
+         "${catalina.base}${file.separator}logs${file.separator}*", "read, write, delete";
+
+        permission java.lang.RuntimePermission "shutdownHooks";
+        permission java.lang.RuntimePermission "getClassLoader";
+        permission java.lang.RuntimePermission "setContextClassLoader";
+
+        permission java.util.logging.LoggingPermission "control";
+
+        permission java.util.PropertyPermission "java.util.logging.config.class", "read";
+        permission java.util.PropertyPermission "java.util.logging.config.file", "read";
+        permission java.util.PropertyPermission "org.apache.juli.ClassLoaderLogManager.debug", "read";
+        permission java.util.PropertyPermission "catalina.base", "read";
+
+        // Note: To enable per context logging configuration, permit read access to
+        // the appropriate file. Be sure that the logging configuration is
+        // secure before enabling such access.
+        // E.g. for the examples web application (uncomment and unwrap
+        // the following to be on a single line):
+        // permission java.io.FilePermission "${catalina.base}${file.separator}
+        //  webapps${file.separator}examples${file.separator}WEB-INF
+        //  ${file.separator}classes${file.separator}logging.properties", "read";
+};
+
+// These permissions apply to the server startup code
+grant codeBase "file:${catalina.home}/bin/bootstrap.jar" {
+        permission java.security.AllPermission;
+};
+
+// These permissions apply to the servlet API classes
+// and those that are shared across all class loaders
+// located in the "lib" directory
+grant codeBase "file:${catalina.home}/lib/-" {
+        permission java.security.AllPermission;
+};
+
+
+// If using a per instance lib directory, i.e. ${catalina.base}/lib,
+// then the following permission will need to be uncommented
+// grant codeBase "file:${catalina.base}/lib/-" {
+//         permission java.security.AllPermission;
+// };
+
+
+// ========== WEB APPLICATION PERMISSIONS =====================================
+
+
+// These permissions are granted by default to all web applications
+// In addition, a web application will be given a read FilePermission
+// and JndiPermission for all files and directories in its document root.
+grant {
+    // Required for JNDI lookup of named JDBC DataSource's and
+    // javamail named MimePart DataSource used to send mail
+    permission java.util.PropertyPermission "java.home", "read";
+    permission java.util.PropertyPermission "java.naming.*", "read";
+    permission java.util.PropertyPermission "javax.sql.*", "read";
+
+    // OS Specific properties to allow read access
+    permission java.util.PropertyPermission "os.name", "read";
+    permission java.util.PropertyPermission "os.version", "read";
+    permission java.util.PropertyPermission "os.arch", "read";
+    permission java.util.PropertyPermission "file.separator", "read";
+    permission java.util.PropertyPermission "path.separator", "read";
+    permission java.util.PropertyPermission "line.separator", "read";
+
+    // JVM properties to allow read access
+    permission java.util.PropertyPermission "java.version", "read";
+    permission java.util.PropertyPermission "java.vendor", "read";
+    permission java.util.PropertyPermission "java.vendor.url", "read";
+    permission java.util.PropertyPermission "java.class.version", "read";
+    permission java.util.PropertyPermission "java.specification.version", "read";
+    permission java.util.PropertyPermission "java.specification.vendor", "read";
+    permission java.util.PropertyPermission "java.specification.name", "read";
+
+    permission java.util.PropertyPermission "java.vm.specification.version", "read";
+    permission java.util.PropertyPermission "java.vm.specification.vendor", "read";
+    permission java.util.PropertyPermission "java.vm.specification.name", "read";
+    permission java.util.PropertyPermission "java.vm.version", "read";
+    permission java.util.PropertyPermission "java.vm.vendor", "read";
+    permission java.util.PropertyPermission "java.vm.name", "read";
+
+    // Required for OpenJMX
+    permission java.lang.RuntimePermission "getAttribute";
+
+    // Allow read of JAXP compliant XML parser debug
+    permission java.util.PropertyPermission "jaxp.debug", "read";
+
+    // All JSPs need to be able to read this package
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.tomcat";
+
+    // Precompiled JSPs need access to these packages.
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.jasper.el";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.jasper.runtime";
+    permission java.lang.RuntimePermission
+     "accessClassInPackage.org.apache.jasper.runtime.*";
+
+    // Precompiled JSPs need access to these system properties.
+
+    // The following two permissions are no longer needed since Tomcat 7.0.88
+    // They are here for historic reasons. There is no harm in keeping them.
+    permission java.util.PropertyPermission
+     "org.apache.jasper.runtime.BodyContentImpl.LIMIT_BUFFER", "read";
+    permission java.util.PropertyPermission
+     "org.apache.el.parser.COERCE_TO_ZERO", "read";
+
+    // The cookie code needs these.
+    permission java.util.PropertyPermission
+     "org.apache.catalina.STRICT_SERVLET_COMPLIANCE", "read";
+    permission java.util.PropertyPermission
+     "org.apache.tomcat.util.http.ServerCookie.STRICT_NAMING", "read";
+    permission java.util.PropertyPermission
+     "org.apache.tomcat.util.http.ServerCookie.FWD_SLASH_IS_SEPARATOR", "read";
+
+    // Applications using Comet need to be able to access this package
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.comet";
+
+    // Applications using the legacy WebSocket implementation need to be able to access this package
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.websocket";
+
+    // Applications using the JSR-356 WebSocket implementation need to be able to access these packages
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.tomcat.websocket";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.tomcat.websocket.server";
+};
+
+
+// The Manager application needs access to the following packages to support the
+// session display functionality. It also requires the custom Tomcat
+// DeployXmlPermission to enable the use of META-INF/context.xml
+// These settings support the following configurations:
+// - default CATALINA_HOME == CATALINA_BASE
+// - CATALINA_HOME != CATALINA_BASE, per instance Manager in CATALINA_BASE
+// - CATALINA_HOME != CATALINA_BASE, shared Manager in CATALINA_HOME
+grant codeBase "file:${catalina.base}/webapps/manager/-" {
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.ha.session";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.manager";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.manager.util";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.util";
+    permission org.apache.catalina.security.DeployXmlPermission "manager";
+};
+grant codeBase "file:${catalina.home}/webapps/manager/-" {
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.ha.session";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.manager";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.manager.util";
+    permission java.lang.RuntimePermission "accessClassInPackage.org.apache.catalina.util";
+    permission org.apache.catalina.security.DeployXmlPermission "manager";
+};
+
+// The Host Manager application needs the custom Tomcat DeployXmlPermission to
+// enable the use of META-INF/context.xml
+// These settings support the following configurations:
+// - default CATALINA_HOME == CATALINA_BASE
+// - CATALINA_HOME != CATALINA_BASE, per instance Host Manager in CATALINA_BASE
+// - CATALINA_HOME != CATALINA_BASE, shared Host Manager in CATALINA_HOME
+grant codeBase "file:${catalina.base}/webapps/host-manager/-" {
+    permission org.apache.catalina.security.DeployXmlPermission "host-manager";
+};
+grant codeBase "file:${catalina.home}/webapps/host-manager/-" {
+    permission org.apache.catalina.security.DeployXmlPermission "host-manager";
+};
+
+
+// You can assign additional permissions to particular web applications by
+// adding additional "grant" entries here, based on the code base for that
+// application, /WEB-INF/classes/, or /WEB-INF/lib/ jar files.
+//
+// Different permissions can be granted to JSP pages, classes loaded from
+// the /WEB-INF/classes/ directory, all jar files in the /WEB-INF/lib/
+// directory, or even to individual jar files in the /WEB-INF/lib/ directory.
+//
+// For instance, assume that the standard "examples" application
+// included a JDBC driver that needed to establish a network connection to the
+// corresponding database and used the scrape taglib to get the weather from
+// the NOAA web server.  You might create a "grant" entries like this:
+//
+// The permissions granted to the context root directory apply to JSP pages.
+// grant codeBase "file:${catalina.base}/webapps/examples/-" {
+//      permission java.net.SocketPermission "dbhost.mycompany.com:5432", "connect";
+//      permission java.net.SocketPermission "*.noaa.gov:80", "connect";
+// };
+//
+// The permissions granted to the context WEB-INF/classes directory
+// grant codeBase "file:${catalina.base}/webapps/examples/WEB-INF/classes/-" {
+// };
+//
+// The permission granted to your JDBC driver
+// grant codeBase "jar:file:${catalina.base}/webapps/examples/WEB-INF/lib/driver.jar!/-" {
+//      permission java.net.SocketPermission "dbhost.mycompany.com:5432", "connect";
+// };
+// The permission granted to the scrape taglib
+// grant codeBase "jar:file:${catalina.base}/webapps/examples/WEB-INF/lib/scrape.jar!/-" {
+//      permission java.net.SocketPermission "*.noaa.gov:80", "connect";
+// };
+
+
+ +

Starting Tomcat With A SecurityManager

+ +

Once you have configured the catalina.policy file for use + with a SecurityManager, Tomcat can be started with a SecurityManager in + place by using the "-security" option:

+

+$CATALINA_HOME/bin/catalina.sh start -security    (Unix)
+%CATALINA_HOME%\bin\catalina start -security      (Windows)
+
+ +
Configuring Package Protection in Tomcat
+

Starting with Tomcat 5, it is now possible to configure which Tomcat + internal package are protected against package definition and access. See + + http://www.oracle.com/technetwork/java/seccodeguide-139067.html + for more information.

+ + +

WARNING: Be aware that removing the default package protection + could possibly open a security hole

+ +

The Default Properties File

+ +

The default $CATALINA_BASE/conf/catalina.properties file + looks like this:

+

+#
+# List of comma-separated packages that start with or equal this string
+# will cause a security exception to be thrown when
+# passed to checkPackageAccess unless the
+# corresponding RuntimePermission ("accessClassInPackage."+package) has
+# been granted.
+package.access=sun.,org.apache.catalina.,org.apache.coyote.,org.apache.tomcat.,
+org.apache.jasper.
+#
+# List of comma-separated packages that start with or equal this string
+# will cause a security exception to be thrown when
+# passed to checkPackageDefinition unless the
+# corresponding RuntimePermission ("defineClassInPackage."+package) has
+# been granted.
+#
+# by default, no packages are restricted for definition, and none of
+# the class loaders supplied with the JDK call checkPackageDefinition.
+#
+package.definition=sun.,java.,org.apache.catalina.,org.apache.coyote.,
+org.apache.tomcat.,org.apache.jasper.
+
+

Once you have configured the catalina.properties file for use + with a SecurityManager, remember to re-start Tomcat.

+
Troubleshooting
+ +

If your web application attempts to execute an operation that is + prohibited by lack of a required Permission, it will throw an + AccessControLException or a SecurityException + when the SecurityManager detects the violation. Debugging the permission + that is missing can be challenging, and one option is to turn on debug + output of all security decisions that are made during execution. This + is done by setting a system property before starting Tomcat. The easiest + way to do this is via the CATALINA_OPTS environment variable. + Execute this command:

+

+export CATALINA_OPTS=-Djava.security.debug=all    (Unix)
+set CATALINA_OPTS=-Djava.security.debug=all       (Windows)
+
+ +

before starting Tomcat.

+ +

WARNING - This will generate many megabytes + of output! However, it can help you track down problems by searching + for the word "FAILED" and determining which permission was being checked + for. See the Java security documentation for more options that you can + specify here as well.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/servletapi/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/servletapi/index.html new file mode 100644 index 0000000..d7a148f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/servletapi/index.html @@ -0,0 +1,34 @@ + + + + + + API docs + + + + +The Servlet Javadoc is not installed by default. Download and install +the "fulldocs" package to get it. + +You can also access the javadoc online in the Tomcat + +documentation bundle. + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/setup.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/setup.html new file mode 100644 index 0000000..4fe4ed4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/setup.html @@ -0,0 +1,243 @@ +Apache Tomcat 7 (7.0.108) - Tomcat Setup

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Tomcat Setup

Table of Contents
+ +
Introduction
+

+ There are several ways to set up Tomcat for running on different + platforms. The main documentation for this is a file called + RUNNING.txt. We encourage you to refer to that + file if the information below does not answer some of your questions. +

+
Windows
+ +

+ Installing Tomcat on Windows can be done easily using the Windows + installer. Its interface and functionality is similar to other wizard + based installers, with only a few items of interest. +

+ +

+

    +
  • Installation as a service: Tomcat will be + installed as a Windows service no matter what setting is selected. + Using the checkbox on the component page sets the service as "auto" + startup, so that Tomcat is automatically started when Windows + starts. For optimal security, the service should be run as a + separate user, with reduced permissions (see the Windows Services + administration tool and its documentation).
  • +
  • Java location: The installer will provide a default + JRE to use to run the service. The installer uses the registry to + determine the base path of a Java 6 or later JRE, + including the JRE installed as part of the full JDK. When running on + a 64-bit operating system, the installer will first look for a + 64-bit JRE and only look for a 32-bit JRE if a 64-bit JRE is not + found. If a JRE cannot be found when running on a 64-bit operating + system, the installer will look for a 64-bit JDK. Finally, if a JRE + or JDK has not been found, the installer will try to use the + JAVA_HOME environment variable. It is not mandatory to + use the default JRE detected by the installer. Any installed Java + 6 or later JRE (32-bit or 64-bit) may be + used.
  • +
  • Tray icon: When Tomcat is run as a service, there + will not be any tray icon present when Tomcat is running. Note that + when choosing to run Tomcat at the end of installation, the tray + icon will be used even if Tomcat was installed as a service.
  • +
  • Defaults: The defaults used by the installer may be + overridden by use of the /C=<config file> command + line argument. The configuration file uses the format + name=value with each pair on a separate line. The names + of the available configuration options are: +
      +
    • JavaHome
    • +
    • TomcatPortShutdown
    • +
    • TomcatPortHttp
    • +
    • TomcatMenuEntriesEnable
    • +
    • TomcatShortcutAllUsers
    • +
    • TomcatServiceDefaultName
    • +
    • TomcatServiceName
    • +
    • TomcatServiceFileName
    • +
    • TomcatServiceManagerFileName
    • +
    • TomcatAdminEnable
    • +
    • TomcatAdminUsername
    • +
    • TomcatAdminPassword
    • +
    • TomcatAdminRoles
    • +
    + By using /C=... along with /S and + /D= it is possible to perform fully configured + unattended installs of Apache Tomact. +
  • +
  • Refer to the + Windows Service HOW-TO + for information on how to manage Tomcat as a Windows service. +
  • +
+

+ +

The installer will create shortcuts allowing starting and configuring + Tomcat. It is important to note that the Tomcat administration web + application can only be used when Tomcat is running.

+ +
Unix daemon
+ +

Tomcat can be run as a daemon using the jsvc tool from the + commons-daemon project. Source tarballs for jsvc are included with the + Tomcat binaries, and need to be compiled. Building jsvc requires + a C ANSI compiler (such as GCC), GNU Autoconf, and a JDK.

+ +

Before running the script, the JAVA_HOME environment + variable should be set to the base path of the JDK. Alternately, when + calling the ./configure script, the path of the JDK may + be specified using the --with-java parameter, such as + ./configure --with-java=/usr/java.

+ +

Using the following commands should result in a compiled jsvc binary, + located in the $CATALINA_HOME/bin folder. This assumes + that GNU TAR is used, and that CATALINA_HOME is an + environment variable pointing to the base path of the Tomcat + installation.

+ +

Please note that you should use the GNU make (gmake) instead of + the native BSD make on FreeBSD systems.

+ +
cd $CATALINA_HOME/bin
+tar xvfz commons-daemon-native.tar.gz
+cd commons-daemon-1.1.x-native-src/unix
+./configure
+make
+cp jsvc ../..
+cd ../..
+
+ +

Tomcat can then be run as a daemon using the following commands.

+ +
CATALINA_BASE=$CATALINA_HOME
+cd $CATALINA_HOME
+./bin/jsvc \
+    -classpath $CATALINA_HOME/bin/bootstrap.jar:$CATALINA_HOME/bin/tomcat-juli.jar \
+    -outfile $CATALINA_BASE/logs/catalina.out \
+    -errfile $CATALINA_BASE/logs/catalina.err \
+    -Dcatalina.home=$CATALINA_HOME \
+    -Dcatalina.base=$CATALINA_BASE \
+    -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager \
+    -Djava.util.logging.config.file=$CATALINA_BASE/conf/logging.properties \
+    org.apache.catalina.startup.Bootstrap
+
+ +

When runnong on Java 9 you will need to additionally specify the + following when starting jsvc to avoid warnings on shutdown.

+
...
+--add-opens=java.base/java.lang=ALL-UNNAMED \
+--add-opens=java.base/java.io=ALL-UNNAMED \
+--add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED \
+...
+
+ +

You may also need to specify -jvm server if the JVM defaults + to using a server VM rather than a client VM. This has been observed on + OSX.

+ +

jsvc has other useful parameters, such as -user which + causes it to switch to another user after the daemon initialization is + complete. This allows, for example, running Tomcat as a non privileged + user while still being able to use privileged ports. Note that if you + use this option and start Tomcat as root, you'll need to disable the + org.apache.catalina.security.SecurityListener check that + prevents Tomcat starting when running as root.

+ +

jsvc --help will return the full jsvc usage + information. In particular, the -debug option is useful + to debug issues running jsvc.

+ +

The file $CATALINA_HOME/bin/daemon.sh can be used as a + template for starting Tomcat automatically at boot time from + /etc/init.d with jsvc.

+ +

Note that the Commons-Daemon JAR file must be on your runtime classpath + to run Tomcat in this manner. The Commons-Daemon JAR file is in the + Class-Path entry of the bootstrap.jar manifest, but if you get a + ClassNotFoundException or a NoClassDefFoundError for a Commons-Daemon + class, add the Commons-Daemon JAR to the -cp argument when launching + jsvc.

+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/ssi-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/ssi-howto.html new file mode 100644 index 0000000..8323b97 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/ssi-howto.html @@ -0,0 +1,474 @@ +Apache Tomcat 7 (7.0.108) - SSI How To

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

SSI How To

Table of Contents
+ +
Introduction
+ +

SSI (Server Side Includes) are directives that are placed in HTML pages, +and evaluated on the server while the pages are being served. They let you +add dynamically generated content to an existing HTML page, without having +to serve the entire page via a CGI program, or other dynamic technology. +

+ +

Within Tomcat SSI support can be added when using Tomcat as your +HTTP server and you require SSI support. Typically this is done +during development when you don't want to run a web server like Apache.

+ +

Tomcat SSI support implements the same SSI directives as Apache. See the + +Apache Introduction to SSI for information on using SSI directives.

+ +

SSI support is available as a servlet and as a filter. You should use one +or the other to provide SSI support but not both.

+ +

Servlet based SSI support is implemented using the class +org.apache.catalina.ssi.SSIServlet. Traditionally, this servlet +is mapped to the URL pattern "*.shtml".

+ +

Filter based SSI support is implemented using the class +org.apache.catalina.ssi.SSIFilter. Traditionally, this filter +is mapped to the URL pattern "*.shtml", though it can be mapped to "*" as +it will selectively enable/disable SSI processing based on mime types. The +contentType init param allows you to apply SSI processing to JSP pages, +javascript, or any other content you wish.

+

By default SSI support is disabled in Tomcat.

+
Installation
+ +

CAUTION - SSI directives can be used to execute programs +external to the Tomcat JVM. If you are using the Java SecurityManager this +will bypass your security policy configuration in catalina.policy. +

+ +

To use the SSI servlet, remove the XML comments from around the SSI servlet +and servlet-mapping configuration in +$CATALINA_BASE/conf/web.xml.

+ +

To use the SSI filter, remove the XML comments from around the SSI filter +and filter-mapping configuration in +$CATALINA_BASE/conf/web.xml.

+ +

Only Contexts which are marked as privileged may use SSI features (see the +privileged property of the Context element).

+ +
Servlet Configuration
+ +

There are several servlet init parameters which can be used to +configure the behaviour of the SSI servlet. +

    +
  • buffered - Should output from this servlet be buffered? +(0=false, 1=true) Default 0 (false).
  • +
  • debug - Debugging detail level for messages logged +by this servlet. Default 0.
  • +
  • expires - The number of seconds before a page with SSI +directives will expire. Default behaviour is for all SSI directives to be +evaluated for every request.
  • +
  • isVirtualWebappRelative - Should "virtual" SSI directive +paths be interpreted as relative to the context root, instead of the server +root? Default false.
  • +
  • inputEncoding - The encoding to be assumed for SSI +resources if one cannot be determined from the resource itself. Default is +the default platform encoding.
  • +
  • outputEncoding - The encoding to be used for the result +of the SSI processing. Default is UTF-8.
  • +
  • allowExec - Is the exec command enabled? Default is +false.
  • +
+

+ +
Filter Configuration
+ +

There are several filter init parameters which can be used to +configure the behaviour of the SSI filter. +

    +
  • contentType - A regex pattern that must be matched before +SSI processing is applied. When crafting your own pattern, don't forget that a +mime content type may be followed by an optional character set in the form +"mime/type; charset=set" that you must take into account. Default is +"text/x-server-parsed-html(;.*)?".
  • +
  • debug - Debugging detail level for messages logged +by this servlet. Default 0.
  • +
  • expires - The number of seconds before a page with SSI +directives will expire. Default behaviour is for all SSI directives to be +evaluated for every request.
  • +
  • isVirtualWebappRelative - Should "virtual" SSI directive +paths be interpreted as relative to the context root, instead of the server +root? Default false.
  • +
  • allowExec - Is the exec command enabled? Default is +false.
  • +
+

+ +
Directives
+

Server Side Includes are invoked by embedding SSI directives in an HTML document + whose type will be processed by the SSI servlet. The directives take the form of an HTML + comment. The directive is replaced by the results of interpreting it before sending the + page to the client. The general form of a directive is:

+

<!--#directive [parm=value] -->

+

The directives are: +

    +
  • +config - <!--#config errmsg="Error occurred" sizefmt="abbrev" +timefmt="%B %Y" --> +Used to set SSI error message, the format of dates and file sizes processed by SSI.
    +All are optional but at least one must be used. The available options are as follows: +
    +errmsg - error message used for SSI errors
    +sizefmt - format used for sizes in the fsize directive
    +timefmt - format used for timestamps in the flastmod directive
    +
  • +
  • +echo - <!--#echo var="VARIABLE_NAME" encoding="entity" --> +will be replaced by the value of the variable. +
    +The optional encoding parameter specifies the type of encoding to use. +Valid values are entity (default), url or none. +NOTE: Using an encoding other than entity can lead to security issues. +
  • +
  • +exec - <!--#exec cmd="file-name" --> +Used to run commands on the host system. +
  • +
  • +exec - <!--#exec cgi="file-name" --> +This acts the same as the include virtual directive, and doesn't actually execute any commands. +
  • +
  • +include - <!--#include file="file-name" --> +inserts the contents. The path is interpreted relative to the document where this directive +is being used, and IS NOT a "virtual" path relative to either the context root or the server root. +
  • +
  • +include - <!--#include virtual="file-name" --> +inserts the contents. The path is interpreted as a "virtual" path which is +relative to either the context root or the server root (depending on the isVirtualWebappRelative +parameter). +
  • +
  • +flastmod - <!--#flastmod file="filename.shtml" --> +Returns the time that a file was last modified. The path is interpreted relative to the document where this directive +is being used, and IS NOT a "virtual" path relative to either the context root or the server root. +
  • +
  • +flastmod - <!--#flastmod virtual="filename.shtml" --> +Returns the time that a file was last modified. The path is interpreted as a "virtual" path which is +relative to either the context root or the server root (depending on the isVirtualWebappRelative +parameter). +
  • +
  • +fsize - <!--#fsize file="filename.shtml" --> +Returns the size of a file. The path is interpreted relative to the document where this directive +is being used, and IS NOT a "virtual" path relative to either the context root or the server root. +
  • +
  • +fsize - <!--#fsize virtual="filename.shtml" --> +Returns the size of a file. The path is interpreted as a "virtual" path which is +relative to either the context root or the server root (depending on the isVirtualWebappRelative +parameter). +
  • +
  • +printenv - <!--#printenv --> +Returns the list of all the defined variables. +
  • +
  • +set - <!--#set var="foo" value="Bar" --> +is used to assign a value to a user-defined variable. +
  • +
  • +if elif endif else - Used to create conditional sections. For example:
  • +<!--#config timefmt="%A" -->
    + <!--#if expr="$DATE_LOCAL = /Monday/" -->
    + <p>Meeting at 10:00 on Mondays</p>
    + <!--#elif expr="$DATE_LOCAL = /Friday/" -->
    + <p>Turn in your time card</p>
    + <!--#else -->
    + <p>Yoga class at noon.</p>
    + <!--#endif -->
    +
+

+See the +

+Apache Introduction to SSI for more information on using SSI directives.

+
Variables
+

+SSI variables are implemented via request attributes on the javax.servlet.ServletRequest object +and are not limited to the SSI servlet. Variables starting with the names +"java.", "javax.", "sun" or "org.apache.catalina.ssi.SSIMediator." are reserved +and cannot be used. +

+

The SSI servlet currently implements the following variables: +

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Variable NameDescription
AUTH_TYPE + The type of authentication used for this user: BASIC, FORM, etc.
CONTENT_LENGTH + The length of the data (in bytes or the number of + characters) passed from a form.
CONTENT_TYPE + The MIME type of the query data, such as "text/html".
DATE_GMT +Current date and time in GMT
DATE_LOCAL +Current date and time in the local time zone
DOCUMENT_NAME +The current file
DOCUMENT_URI +Virtual path to the file
GATEWAY_INTERFACE + The revision of the Common Gateway Interface that the + server uses if enabled: "CGI/1.1".
HTTP_ACCEPT + A list of the MIME types that the client can accept.
HTTP_ACCEPT_ENCODING + A list of the compression types that the client can accept.
HTTP_ACCEPT_LANGUAGE + A list of the languages that the client can accept.
HTTP_CONNECTION + The way that the connection from the client is being managed: + "Close" or "Keep-Alive".
HTTP_HOST + The web site that the client requested.
HTTP_REFERER + The URL of the document that the client linked from.
HTTP_USER_AGENT + The browser the client is using to issue the request.
LAST_MODIFIED +Last modification date and time for current file
PATH_INFO + Extra path information passed to a servlet.
PATH_TRANSLATED + The translated version of the path given by the + variable PATH_INFO.
QUERY_STRING +The query string that follows the "?" in the URL. +
QUERY_STRING_UNESCAPED +Undecoded query string with all shell metacharacters escaped +with "\"
REMOTE_ADDR + The remote IP address of the user making the request.
REMOTE_HOST + The remote hostname of the user making the request.
REMOTE_PORT + The port number at remote IP address of the user making the request.
REMOTE_USER + The authenticated name of the user.
REQUEST_METHOD + The method with which the information request was + issued: "GET", "POST" etc.
REQUEST_URI + The web page originally requested by the client.
SCRIPT_FILENAME + The location of the current web page on the server.
SCRIPT_NAME + The name of the web page.
SERVER_ADDR + The server's IP address.
SERVER_NAME + The server's hostname or IP address.
SERVER_PORT + The port on which the server received the request.
SERVER_PROTOCOL + The protocol used by the server. E.g. "HTTP/1.1".
SERVER_SOFTWARE + The name and version of the server software that is + answering the client request.
UNIQUE_ID + A token used to identify the current session if one + has been established.
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/ssl-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/ssl-howto.html new file mode 100644 index 0000000..8eb3933 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/ssl-howto.html @@ -0,0 +1,719 @@ +Apache Tomcat 7 (7.0.108) - SSL/TLS Configuration HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

SSL/TLS Configuration HOW-TO

Table of Contents
+ +
Quick Start
+ +
+

The description below uses the variable name $CATALINA_BASE to refer the + base directory against which most relative paths are resolved. If you have + not configured Tomcat for multiple instances by setting a CATALINA_BASE + directory, then $CATALINA_BASE will be set to the value of $CATALINA_HOME, + the directory into which you have installed Tomcat.

+
+ +

To install and configure SSL/TLS support on Tomcat, you need to follow +these simple steps. For more information, read the rest of this HOW-TO.

+
    +
  1. Create a keystore file to store the server's private key and +self-signed certificate by executing the following command: +

    Windows:

    +
    "%JAVA_HOME%\bin\keytool" -genkey -alias tomcat -keyalg RSA
    +

    Unix:

    +
    $JAVA_HOME/bin/keytool -genkey -alias tomcat -keyalg RSA
    + +

    and specify a password value of "changeit".

  2. +
  3. Uncomment the "SSL HTTP/1.1 Connector" entry in + $CATALINA_BASE/conf/server.xml and modify as described in + the Configuration section below.

  4. +
+ + +
Introduction to SSL/TLS
+ +

Transport Layer Security (TLS) and its predecessor, Secure Sockets Layer +(SSL), are technologies which allow web browsers and web servers to communicate +over a secured connection. This means that the data being sent is encrypted by +one side, transmitted, then decrypted by the other side before processing. +This is a two-way process, meaning that both the server AND the browser encrypt +all traffic before sending out data.

+ +

Another important aspect of the SSL/TLS protocol is Authentication. This means +that during your initial attempt to communicate with a web server over a secure +connection, that server will present your web browser with a set of +credentials, in the form of a "Certificate", as proof the site is who and what +it claims to be. In certain cases, the server may also request a Certificate +from your web browser, asking for proof that you are who you claim +to be. This is known as "Client Authentication," although in practice this is +used more for business-to-business (B2B) transactions than with individual +users. Most SSL-enabled web servers do not request Client Authentication.

+ +
SSL/TLS and Tomcat
+ +

It is important to note that configuring Tomcat to take advantage of +secure sockets is usually only necessary when running it as a stand-alone +web server. Details can be found in the +Security Considerations Document. +When running Tomcat primarily as a Servlet/JSP container behind +another web server, such as Apache or Microsoft IIS, it is usually necessary +to configure the primary web server to handle the SSL connections from users. +Typically, this server will negotiate all SSL-related functionality, then +pass on any requests destined for the Tomcat container only after decrypting +those requests. Likewise, Tomcat will return cleartext responses, that will +be encrypted before being returned to the user's browser. In this environment, +Tomcat knows that communications between the primary web server and the +client are taking place over a secure connection (because your application +needs to be able to ask about this), but it does not participate in the +encryption or decryption itself.

+ +
Certificates
+ +

In order to implement SSL, a web server must have an associated Certificate +for each external interface (IP address) that accepts secure connections. +The theory behind this design is that a server should provide some kind of +reasonable assurance that its owner is who you think it is, particularly +before receiving any sensitive information. While a broader explanation of +Certificates is beyond the scope of this document, think of a Certificate as a +"digital passport" for an Internet address. It states which organisation the +site is associated with, along with some basic contact information about the +site owner or administrator.

+ +

This certificate is cryptographically signed by its owner, and is +therefore extremely difficult for anyone else to forge. For the certificate to +work in the visitors browsers without warnings, it needs to be signed by a +trusted third party. These are called Certificate Authorities (CAs). To +obtain a signed certificate, you need to choose a CA and follow the instructions +your chosen CA provides to obtain your certificate. A range of CAs is available +including some that offer certificates at no cost.

+ +

Java provides a relatively simple command-line tool, called +keytool, which can easily create a "self-signed" Certificate. +Self-signed Certificates are simply user generated Certificates which have not +been signed by a well-known CA and are, therefore, not really guaranteed to be +authentic at all. While self-signed certificates can be useful for some testing +scenarios, they are not suitable for any form of production use.

+ +
General Tips on Running SSL
+ +

When securing a website with SSL it's important to make sure that all assets +that the site uses are served over SSL, so that an attacker can't bypass +the security by injecting malicious content in a javascript file or similar. To +further enhance the security of your website, you should evaluate to use the +HSTS header. It allows you to communicate to the browser that your site should +always be accessed over https.

+ +

Using name-based virtual hosts on a secured connection requires careful +configuration of the names specified in a single certificate or Tomcat 8.5 +onwards where Server Name Indication (SNI) support is available. SNI allows +multiple certificates with different names to be associated with a single TLS +connector.

+ +
Configuration
+ +
Prepare the Certificate Keystore
+ +

Tomcat currently operates only on JKS, PKCS11 or +PKCS12 format keystores. The JKS format +is Java's standard "Java KeyStore" format, and is the format created by the +keytool command-line utility. This tool is included in the JDK. +The PKCS12 format is an internet standard, and can be manipulated +via (among other things) OpenSSL and Microsoft's Key-Manager. +

+ +

Each entry in a keystore is identified by an alias string. Whilst many +keystore implementations treat aliases in a case insensitive manner, case +sensitive implementations are available. The PKCS11 specification, +for example, requires that aliases are case sensitive. To avoid issues related +to the case sensitivity of aliases, it is not recommended to use aliases that +differ only in case. +

+ +

To import an existing certificate into a JKS keystore, please read the +documentation (in your JDK documentation package) about keytool. +Note that OpenSSL often adds readable comments before the key, but +keytool does not support that. So if your certificate has +comments before the key data, remove them before importing the certificate with +keytool. +

+

To import an existing certificate signed by your own CA into a PKCS12 +keystore using OpenSSL you would execute a command like:

+
openssl pkcs12 -export -in mycert.crt -inkey mykey.key
+                        -out mycert.p12 -name tomcat -CAfile myCA.crt
+                        -caname root -chain
+

For more advanced cases, consult the +OpenSSL documentation.

+ +

To create a new JKS keystore from scratch, containing a single +self-signed Certificate, execute the following from a terminal command line:

+

Windows:

+
"%JAVA_HOME%\bin\keytool" -genkey -alias tomcat -keyalg RSA
+

Unix:

+
$JAVA_HOME/bin/keytool -genkey -alias tomcat -keyalg RSA
+ +

(The RSA algorithm should be preferred as a secure algorithm, and this +also ensures general compatibility with other servers and components.)

+ +

This command will create a new file, in the home directory of the user +under which you run it, named ".keystore". To specify a +different location or filename, add the -keystore parameter, +followed by the complete pathname to your keystore file, +to the keytool command shown above. You will also need to +reflect this new location in the server.xml configuration file, +as described later. For example:

+

Windows:

+
"%JAVA_HOME%\bin\keytool" -genkey -alias tomcat -keyalg RSA
+  -keystore \path\to\my\keystore
+

Unix:

+
$JAVA_HOME/bin/keytool -genkey -alias tomcat -keyalg RSA
+  -keystore /path/to/my/keystore
+ +

After executing this command, you will first be prompted for the keystore +password. The default password used by Tomcat is "changeit" +(all lower case), although you can specify a custom password if you like. +You will also need to specify the custom password in the +server.xml configuration file, as described later.

+ +

Next, you will be prompted for general information about this Certificate, +such as company, contact name, and so on. This information will be displayed +to users who attempt to access a secure page in your application, so make +sure that the information provided here matches what they will expect.

+ +

Finally, you will be prompted for the key password, which is the +password specifically for this Certificate (as opposed to any other +Certificates stored in the same keystore file). The keytool prompt +will tell you that pressing the ENTER key automatically uses the same password +for the key as the keystore. You are free to use the same password or to select +a custom one. If you select a different password to the keystore password, you +will also need to specify the custom password in the server.xml +configuration file.

+ +

If everything was successful, you now have a keystore file with a +Certificate that can be used by your server.

+ +
+ +
Edit the Tomcat Configuration File
+

+Tomcat can use two different implementations of SSL: +

    +
  • the JSSE implementation provided as part of the Java runtime (since 1.4)
  • +
  • the APR implementation, which uses the OpenSSL engine by default.
  • +
+The exact configuration details depend on which implementation is being used. +If you configured Connector by specifying generic +protocol="HTTP/1.1" then the implementation used by Tomcat is +chosen automatically. If the installation uses APR +- i.e. you have installed the Tomcat native library - +then it will use the APR SSL implementation, otherwise it will use the Java +JSSE implementation. +

+ +

+As configuration attributes for SSL support significantly differ between +APR vs. JSSE implementations, it is recommended to +avoid auto-selection of implementation. It is done by specifying a classname +in the protocol attribute of the Connector.

+ +

To define a Java (JSSE) connector, regardless of whether the APR library is +loaded or not, use one of the following:

+
<!-- Define an HTTP/1.1 Connector on port 8443, JSSE NIO implementation -->
+<Connector protocol="org.apache.coyote.http11.Http11NioProtocol"
+           port="8443" .../>
+
+<!-- Define a HTTP/1.1 Connector on port 8443, JSSE BIO implementation -->
+<Connector protocol="org.apache.coyote.http11.Http11Protocol"
+           port="8443" .../>
+

Alternatively, to specify an APR connector (the APR library must be available) use:

+
<!-- Define an HTTP/1.1 Connector on port 8443, APR implementation -->
+<Connector protocol="org.apache.coyote.http11.Http11AprProtocol"
+           port="8443" .../>
+ +

If you are using APR, you have the option of configuring an alternative engine to OpenSSL. +


+<Listener className="org.apache.catalina.core.AprLifecycleListener"
+          SSLEngine="someengine" SSLRandomSeed="somedevice" />
+
+The default value is +

+<Listener className="org.apache.catalina.core.AprLifecycleListener"
+          SSLEngine="on" SSLRandomSeed="builtin" />
+
+So to use SSL under APR, make sure the SSLEngine attribute is set to something other than off. +The default value is on and if you specify another value, it has to be a valid engine name. +

+ +

+SSLRandomSeed allows to specify a source of entropy. Productive system needs a reliable source of entropy +but entropy may need a lot of time to be collected therefore test systems could use no blocking entropy +sources like "/dev/urandom" that will allow quicker starts of Tomcat. + +

+ +

The final step is to configure the Connector in the +$CATALINA_BASE/conf/server.xml file, where +$CATALINA_BASE represents the base directory for the +Tomcat instance. An example <Connector> element +for an SSL connector is included in the default server.xml +file installed with Tomcat. To configure an SSL connector that uses JSSE, you +will need to remove the comments and edit it so it looks something like +this:

+

+<!-- Define an SSL Coyote HTTP/1.1 Connector on port 8443 -->
+<Connector
+           protocol="org.apache.coyote.http11.Http11NioProtocol"
+           port="8443" maxThreads="200"
+           scheme="https" secure="true" SSLEnabled="true"
+           keystoreFile="${user.home}/.keystore" keystorePass="changeit"
+           clientAuth="false" sslProtocol="TLS"/>
+
+

+ The APR connector uses different attributes for many SSL settings, + particularly keys and certificates. An example of an APR configuration is: +


+<!-- Define an SSL Coyote HTTP/1.1 Connector on port 8443 -->
+<Connector
+           protocol="org.apache.coyote.http11.Http11AprProtocol"
+           port="8443" maxThreads="200"
+           scheme="https" secure="true" SSLEnabled="true"
+           SSLCertificateFile="/usr/local/ssl/server.crt"
+           SSLCertificateKeyFile="/usr/local/ssl/server.pem"
+           SSLVerifyClient="optional" SSLProtocol="TLSv1+TLSv1.1+TLSv1.2"/>
+
+

+ +

The configuration options and information on which attributes +are mandatory, are documented in the SSL Support section of the +HTTP connector configuration +reference. Make sure that you use the correct attributes for the connector you +are using. The BIO and NIO connectors use JSSE whereas the APR/native connector +uses APR.

+ +

The port attribute is the TCP/IP +port number on which Tomcat will listen for secure connections. You can +change this to any port number you wish (such as to the default port for +https communications, which is 443). However, special setup +(outside the scope of this document) is necessary to run Tomcat on port +numbers lower than 1024 on many operating systems.

+ +
+

If you change the port number here, you should also change the + value specified for the redirectPort attribute on the + non-SSL connector. This allows Tomcat to automatically redirect + users who attempt to access a page with a security constraint specifying + that SSL is required, as required by the Servlet Specification.

+
+ +

After completing these configuration changes, you must restart Tomcat as +you normally do, and you should be in business. You should be able to access +any web application supported by Tomcat via SSL. For example, try:

+
https://localhost:8443/
+

and you should see the usual Tomcat splash page (unless you have modified +the ROOT web application). If this does not work, the following section +contains some troubleshooting tips.

+ +
+ +
Installing a Certificate from a Certificate Authority
+

To obtain and install a Certificate from a Certificate Authority (like verisign.com, thawte.com +or trustcenter.de), read the previous section and then follow these instructions:

+ +
Create a local Certificate Signing Request (CSR)
+

In order to obtain a Certificate from the Certificate Authority of your choice +you have to create a so called Certificate Signing Request (CSR). That CSR will be used +by the Certificate Authority to create a Certificate that will identify your website +as "secure". To create a CSR follow these steps:

+
    +
  • Create a local self-signed Certificate (as described in the previous section): +
    keytool -genkey -alias tomcat -keyalg RSA
    +    -keystore <your_keystore_filename>
    + Note: In some cases you will have to enter the domain of your website (i.e. www.myside.org) + in the field "first- and lastname" in order to create a working Certificate. +
  • +
  • The CSR is then created with: +
    keytool -certreq -keyalg RSA -alias tomcat -file certreq.csr
    +    -keystore <your_keystore_filename>
    +
  • +
+

Now you have a file called certreq.csr that you can submit to the Certificate Authority (look at the +documentation of the Certificate Authority website on how to do this). In return you get a Certificate.

+
+ +
Importing the Certificate
+

Now that you have your Certificate you can import it into you local keystore. +First of all you have to import a so called Chain Certificate or Root Certificate into your keystore. +After that you can proceed with importing your Certificate.

+ +
    +
  • Download a Chain Certificate from the Certificate Authority you obtained the Certificate from.
    + For Verisign.com commercial certificates go to: + http://www.verisign.com/support/install/intermediate.html
    + For Verisign.com trial certificates go to: + http://www.verisign.com/support/verisign-intermediate-ca/Trial_Secure_Server_Root/index.html
    + For Trustcenter.de go to: + http://www.trustcenter.de/certservices/cacerts/en/en.htm#server
    + For Thawte.com go to: + http://www.thawte.com/certs/trustmap.html
    +
  • +
  • Import the Chain Certificate into your keystore +
    keytool -import -alias root -keystore <your_keystore_filename>
    +    -trustcacerts -file <filename_of_the_chain_certificate>
    +
  • +
  • And finally import your new Certificate +
    keytool -import -alias tomcat -keystore <your_keystore_filename>
    +    -file <your_certificate_filename>
    +
  • +
+ +

Each Certificate Authority tends to differ slightly from the others. They may +require slightly different information and/or provide the certificate and +associated certificate chain in different formats. Additionally, the rules that +the Certificate Authorities use for issuing certifcates change over time. As a +result you may find that the commands given above may need to be modified. If +you require assitance then help is available via the +Apache Tomcat users +mailing list.

+ +
+
Using OCSP Certificates
+

To use Online Certificate Status Protocol (OCSP) with Apache Tomcat, ensure + you have downloaded, installed, and configured the + + Tomcat Native Connector. +Furthermore, if you use the Windows platform, ensure you download the +ocsp-enabled connector.

+

To use OCSP, you require the following:

+ +
    +
  • OCSP-enabled certificates
  • +
  • Tomcat with SSL APR connector
  • +
  • Configured OCSP responder
  • +
+ +
Generating OCSP-Enabled Certificates
+

Apache Tomcat requires the OCSP-enabled certificate to have the OCSP + responder location encoded in the certificate. The basic OCSP-related + certificate authority settings in the openssl.cnf file could look + as follows:

+ +

+#... omitted for brevity
+
+[x509]
+x509_extensions = v3_issued
+
+[v3_issued]
+subjectKeyIdentifier=hash
+authorityKeyIdentifier=keyid,issuer
+# The address of your responder
+authorityInfoAccess = OCSP;URI:http://127.0.0.1:8088
+keyUsage = critical,digitalSignature,nonRepudiation,keyEncipherment,dataEncipherment,keyAgreement,keyCertSign,cRLSign,encipherOnly,decipherOnly
+basicConstraints=critical,CA:FALSE
+nsComment="Testing OCSP Certificate"
+
+#... omitted for brevity
+
+ +

The settings above encode the OCSP responder address + 127.0.0.1:8088 into the certificate. Note that for the following + steps, you must have openssl.cnf and other configuration of + your CA ready. To generate an OCSP-enabled certificate:

+ +
    +
  • + Create a private key: +
    openssl genrsa -aes256 -out ocsp-cert.key 4096
    +
  • +
  • + Create a signing request (CSR): +
    openssl req -config openssl.cnf -new -sha256 \
    +  -key ocsp-cert.key -out ocsp-cert.csr
  • +
  • + Sign the CSR: +
    openssl ca -openssl.cnf -extensions ocsp -days 375 -notext \
    +  -md sha256 -in ocsp-cert.csr -out ocsp-cert.crt
    +
  • +
  • + You may verify the certificate: +
    openssl x509 -noout -text -in ocsp-cert.crt
    +
  • +
+
+ +
Configuring OCSP Connector
+ +

To configure the OCSP connector, first verify that you are loading the Tomcat + APR library. Check the + Apache Portable Runtime (APR) based Native library for Tomcat +for more information about installation of APR. A basic OCSP-enabled connector + definition in the server.xml file looks as follows:

+

+<Connector port="8443"
+   protocol="org.apache.coyote.http11.Http11AprProtocol"
+   secure="true" scheme="https"
+   SSLEnabled="true" SSLCertificateFile="/path/to/ocsp-cert.crt"
+   SSLCertificateKeyFile="/path/to/ocsp-cert.key"
+   SSLCACertificateFile="/path/to/ca.pem"
+   SSLVerifyClient="require"
+   SSLVerifyDepth="10"
+   clientAuth="true"/>
+
+
+ +
Starting OCSP Responder
+

Apache Tomcat will query an OCSP responder server to get the certificate + status. When testing, an easy way to create an OCSP responder is by executing + the following: +

openssl ocsp -port 127.0.0.1:8088 \
+    -text -sha256 -index index.txt \
+    -CA ca-chain.cert.pem -rkey ocsp-cert.key \
+    -rsigner ocsp-cert.crt

+ +

Do note that when using OCSP, the responder encoded in the connector + certificate must be running. For further information, see + + OCSP documentation + . +

+ +
+ +
Troubleshooting
+ +

Here is a list of common problems that you may encounter when setting up +SSL communications, and what to do about them.

+ +
    + +
  • When Tomcat starts up, I get an exception like + "java.io.FileNotFoundException: {some-directory}/{some-file} not found". +
    +

    A likely explanation is that Tomcat cannot find the keystore file + where it is looking. By default, Tomcat expects the keystore file to + be named .keystore in the user home directory under which + Tomcat is running (which may or may not be the same as yours :-). If + the keystore file is anywhere else, you will need to add a + keystoreFile attribute to the <Connector> + element in the Tomcat + configuration file.

    +
  • + +
  • When Tomcat starts up, I get an exception like + "java.io.FileNotFoundException: Keystore was tampered with, or + password was incorrect". +
    +

    Assuming that someone has not actually tampered with + your keystore file, the most likely cause is that Tomcat is using + a different password than the one you used when you created the + keystore file. To fix this, you can either go back and + recreate the keystore + file, or you can add or update the keystorePass + attribute on the <Connector> element in the + Tomcat configuration + file. REMINDER - Passwords are case sensitive!

    +
  • + +
  • When Tomcat starts up, I get an exception like + "java.net.SocketException: SSL handshake error javax.net.ssl.SSLException: No + available certificate or key corresponds to the SSL cipher suites which are + enabled." +
    +

    A likely explanation is that Tomcat cannot find the alias for the server + key within the specified keystore. Check that the correct + keystoreFile and keyAlias are specified in the + <Connector> element in the + Tomcat configuration file. + REMINDER - keyAlias values may be case + sensitive!

    +
  • + +
  • My Java-based client aborts handshakes with exceptions such as + "java.lang.RuntimeException: Could not generate DH keypair" and + "java.security.InvalidAlgorithmParameterException: Prime size must be multiple + of 64, and can only range from 512 to 1024 (inclusive)" + +

    If you are using the APR/native connector, starting with version 1.1.34 + it will determine the strength of ephemeral DH keys from the key size of + your RSA certificate. For example a 2048 bit RSA key will result in + using a 2048 bit primefor the DH keys. Unfortunately Java 6 only supports + 768 bit and Java 7 only supports 1024 bit. So if your certificate has a + stronger key, old Java clients might produce such handshake failures. + As a mitigation you can either try to force them to use another cipher by + configuring an appropriate SSLCipherSuite and activate + SSLHonorCipherOrder, or embed weak DH params in your + certificate file. The latter approach is not recommended because it weakens + the SSL security (logjam attack).

    +
  • + +
+ +

If you are still having problems, a good source of information is the +TOMCAT-USER mailing list. You can find pointers to archives +of previous messages on this list, as well as subscription and unsubscription +information, at +https://tomcat.apache.org/lists.html.

+ +
Using the SSL for session tracking in your application
+

This is a new feature in the Servlet 3.0 specification. Because it uses the + SSL session ID associated with the physical client-server connection there + are some limitations. They are: +

    +
  • Tomcat must have a connector with the attribute + isSecure set to true.
  • +
  • If SSL connections are managed by a proxy or a hardware accelerator + they must populate the SSL request headers (see the + SSLValve) so that + the SSL session ID is visible to Tomcat.
  • +
  • If Tomcat terminates the SSL connection, it will not be possible to use + session replication as the SSL session IDs will be different on each + node.
  • +
+

+ +

+ To enable SSL session tracking you need to use a context listener to set the + tracking mode for the context to be just SSL (if any other tracking mode is + enabled, it will be used in preference). It might look something like: +


+package org.apache.tomcat.example;
+
+import java.util.EnumSet;
+
+import javax.servlet.ServletContext;
+import javax.servlet.ServletContextEvent;
+import javax.servlet.ServletContextListener;
+import javax.servlet.SessionTrackingMode;
+
+public class SessionTrackingModeListener implements ServletContextListener {
+
+    @Override
+    public void contextDestroyed(ServletContextEvent event) {
+        // Do nothing
+    }
+
+    @Override
+    public void contextInitialized(ServletContextEvent event) {
+        ServletContext context = event.getServletContext();
+        EnumSet<SessionTrackingMode> modes =
+            EnumSet.of(SessionTrackingMode.SSL);
+
+        context.setSessionTrackingModes(modes);
+    }
+
+}
+    
+

+

Note: SSL session tracking is implemented for the BIO and NIO connectors. + It is not yet implemented for the APR connector.

+ +
Miscellaneous Tips and Bits
+ +

To access the SSL session ID from the request, use:
+ + + String sslID = (String)request.getAttribute("javax.servlet.request.ssl_session_id"); + +
+For additional discussion on this area, please see +Bugzilla. +

+ +

To terminate an SSL session, use: +


+// Standard HTTP session invalidation
+session.invalidate();
+
+// Invalidate the SSL Session
+org.apache.tomcat.util.net.SSLSessionManager mgr =
+    (org.apache.tomcat.util.net.SSLSessionManager)
+    request.getAttribute("javax.servlet.request.ssl_session_mgr");
+mgr.invalidateSession();
+
+// Close the connection since the SSL session will be active until the connection
+// is closed
+response.setHeader("Connection", "close");
+    
+ Note that this code is Tomcat specific due to the use of the + SSLSessionManager class. This is currently only available for the BIO and + NIO connectors, not the APR/native connector. +

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/developers.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/developers.html new file mode 100644 index 0000000..06e393a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/developers.html @@ -0,0 +1,83 @@ +Apache Tribes - The Tomcat Cluster Communication Module (7.0.108) - Apache Tribes - Developers
Apache Tomcat

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tribes Development

Apache Tribes - Developers

Developers
+

TODO

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/faq.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/faq.html new file mode 100644 index 0000000..56e7c71 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/faq.html @@ -0,0 +1,83 @@ +Apache Tribes - The Tomcat Cluster Communication Module (7.0.108) - Apache Tribes - Frequently Asked Questions
Apache Tomcat

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tribes Development

Apache Tribes - Frequently Asked Questions

Frequently Asked Questions
+

TODO

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/interceptors.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/interceptors.html new file mode 100644 index 0000000..ecb9ed5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/interceptors.html @@ -0,0 +1,83 @@ +Apache Tribes - The Tomcat Cluster Communication Module (7.0.108) - Apache Tribes - Interceptors
Apache Tomcat

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tribes Development

Apache Tribes - Interceptors

Interceptors
+

TODO

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/introduction.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/introduction.html new file mode 100644 index 0000000..d2f93c9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/introduction.html @@ -0,0 +1,307 @@ +Apache Tribes - The Tomcat Cluster Communication Module (7.0.108) - Apache Tribes - Introduction
Apache Tomcat

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tribes Development

Apache Tribes - Introduction

Table of Contents
+ +
Quick Start
+ +

Apache Tribes is a group or peer-to-peer communication framework that enables you to easily connect + your remote objects to communicate with each other. +

+
    +
  • Import: org.apache.catalina.tribes.Channel
  • +
  • Import: org.apache.catalina.tribes.Member
  • +
  • Import: org.apache.catalina.tribes.MembershipListener
  • +
  • Import: org.apache.catalina.tribes.ChannelListener
  • +
  • Import: org.apache.catalina.tribes.group.GroupChannel
  • +
  • Create a class that implements: org.apache.catalina.tribes.ChannelListener
  • +
  • Create a class that implements: org.apache.catalina.tribes.MembershipListener
  • +
  • Simple class to demonstrate how to send a message: +
    
    +        //create a channel
    +        Channel myChannel = new GroupChannel();
    +
    +        //create my listeners
    +        ChannelListener msgListener = new MyMessageListener();
    +        MembershipListener mbrListener = new MyMemberListener();
    +
    +        //attach the listeners to the channel
    +        myChannel.addMembershipListener(mbrListener);
    +        myChannel.addChannelListener(msgListener);
    +
    +        //start the channel
    +        myChannel.start(Channel.DEFAULT);
    +
    +        //create a message to be sent, message must implement java.io.Serializable
    +        //for performance reasons you probably want them to implement java.io.Externalizable
    +        Serializable myMsg = new MyMessage();
    +
    +        //retrieve my current members
    +        Member[] group = myChannel.getMembers();
    +
    +        //send the message
    +        myChannel.send(group,myMsg,Channel.SEND_OPTIONS_DEFAULT);
    +      
    +
  • +
+

+ Simple yeah? There is a lot more to Tribes than we have shown, hopefully the docs will be able + to explain more to you. Remember, that we are always interested in suggestions, improvements, bug fixes + and anything that you think would help this project. +

+
What is Tribes
+

+ Tribes is a messaging framework with group communication abilities. Tribes allows you to send and receive + messages over a network, it also allows for dynamic discovery of other nodes in the network.
+ And that is the short story, it really is as simple as that. What makes Tribes useful and unique will be + described in the section below.
+

+

+ The Tribes module was started early 2006 and a small part of the code base comes from the clustering module + that has been existing since 2003 or 2004. + The current cluster implementation has several short comings and many workarounds were created due + to the complexity in group communication. Long story short, what should have been two modules a long time + ago, will be now. Tribes takes out the complexity of messaging from the replication module and becomes + a fully independent and highly flexible group communication module.
+

+

+ In Tomcat the old modules/cluster has now become modules/groupcom(Tribes) and + modules/ha (replication). This will allow development to proceed and let the developers + focus on the issues they are actually working on rather than getting boggled down in details of a module + they are not interested in. The understanding is that both communication and replication are complex enough, + and when trying to develop them in the same module, well you know, it becomes a cluster :)
+

+

+ Tribes allows for guaranteed messaging, and can be customized in many ways. Why is this important?
+ Well, you as a developer want to know that the messages you are sending are reaching their destination. + More than that, if a message doesn't reach its destination, the application on top of Tribes will be notified + that the message was never sent, and what node it failed. +

+ +
Why another messaging framework
+

+ I am a big fan of reusing code and would never dream of developing something if someone else has already + done it and it was available to me and the community I try to serve.
+ When I did my research to improve the clustering module I was constantly faced with a few obstacles:
+ 1. The framework wasn't flexible enough
+ 2. The framework was licensed in a way that neither I nor the community could use it
+ 3. Several features that I needed were missing
+ 4. Messaging was guaranteed, but no feedback was reported to me
+ 5. The semantics of my message delivery had to be configured before runtime
+ And the list continues... +

+

+ So I came up with Tribes, to address these issues and other issues that came along. + When designing Tribes I wanted to make sure I didn't lose any of the flexibility and + delivery semantics that the existing frameworks already delivered. The goal was to create a framework + that could do everything that the others already did, but to provide more flexibility for the application + developer. In the next section will give you the high level overview of what features tribes offers or will offer. +

+
Feature Overview
+

+ To give you an idea of the feature set I will list it out here. + Some of the features are not yet completed, if that is the case they are marked accordingly. +

+

+ Pluggable modules
+ Tribes is built using interfaces. Any of the modules or components that are part of Tribes can be swapped out + to customize your own Tribes implementation. +

+

+ Guaranteed Messaging
+ In the default implementation of Tribes uses TCP or UDP for messaging. TCP already has guaranteed message delivery + and flow control built in. I believe that the performance of Java TCP, will outperform an implementation of + Java/UDP/flow-control/message guarantee since the logic happens further down the stack. UDP messaging has been added in for + sending messages over UDP instead of TCP when desired. The same guarantee scenarios as described below are still available + over UDP, however, when a UDP message is lost, it's considered failed.
+ Tribes supports both non-blocking and blocking IO operations. The recommended setting is to use non blocking + as it promotes better parallelism when sending and receiving messages. The blocking implementation is available + for those platforms where NIO is still a trouble child. +

+

+ Different Guarantee Levels
+ There are three different levels of delivery guarantee when a message is sent.
+

    +
  1. IO Based send guarantee. - fastest, least reliable
    + This means that Tribes considers the message transfer to be successful + if the message was sent to the socket send buffer and accepted.
    + On blocking IO, this would be socket.getOutputStream().write(msg)
    + On non blocking IO, this would be socketChannel.write(), and the buffer byte buffer gets emptied + followed by a socketChannel.read() to ensure the channel still open. + The read() has been added since write() will succeed if the connection has been "closed" + when using NIO. +
  2. +
  3. ACK based. - recommended, guaranteed delivery
    + When the message has been received on a remote node, an ACK is sent back to the sender, + indicating that the message was received successfully. +
  4. +
  5. SYNC_ACK based. - guaranteed delivery, guaranteed processed, slowest
    + When the message has been received on a remote node, the node will process + the message and if the message was processed successfully, an ACK is sent back to the sender + indicating that the message was received and processed successfully. + If the message was received, but processing it failed, an ACK_FAIL will be sent back + to the sender. This is a unique feature that adds an incredible amount value to the application + developer. Most frameworks here will tell you that the message was delivered, and the application + developer has to build in logic on whether the message was actually processed properly by the application + on the remote node. If configured, Tribes will throw an exception when it receives an ACK_FAIL + and associate that exception with the member that didn't process the message. +
  6. +
+ You can of course write even more sophisticated guarantee levels, and some of them will be mentioned later on + in the documentation. One mentionable level would be a 2-Phase-Commit, where the remote applications don't receive + the message until all nodes have received the message. Sort of like a all-or-nothing protocol. +

+

+ Per Message Delivery Attributes
+ Perhaps the feature that makes Tribes stand out from the crowd of group communication frameworks. + Tribes enables you to send to decide what delivery semantics a message transfer should have on a per + message basis. Meaning, that your messages are not delivered based on some static configuration + that remains fixed after the message framework has been started.
+ To give you an example of how powerful this feature is, I'll try to illustrate it with a simple example. + Imagine you need to send 10 different messages, you could send them the following way: +


+      Message_1 - asynchronous and fast, no guarantee required, fire and forget
+      Message_2 - all-or-nothing, either all receivers get it, or none.
+      Message_3 - encrypted and SYNC_ACK based
+      Message_4 - asynchronous, SYNC_ACK and call back when the message is processed on the remote nodes
+      Message_5 - totally ordered, this message should be received in the same order on all nodes that have been
+                  send totally ordered
+      Message_6 - asynchronous and totally ordered
+      Message_7 - RPC message, send a message, wait for all remote nodes to reply before returning
+      Message_8 - RPC message, wait for the first reply
+      Message_9 - RPC message, asynchronous, don't wait for a reply, collect them via a callback
+      Message_10- sent to a member that is not part of this group
+    
+ As you can imagine by now, these are just examples. The number of different semantics you can apply on a + per-message-basis is almost limitless. Tribes allows you to set up to 28 different on a message + and then configure Tribes to what flag results in what action on the message.
+ Imagine a shared transactional cache, probably >90% are reads, and the dirty reads should be completely + unordered and delivered as fast as possible. But transactional writes on the other hand, have to + be ordered so that no cache gets corrupted. With tribes you would send the write messages totally ordered, + while the read messages you simple fire to achieve highest throughput.
+ There are probably better examples on how this powerful feature can be used, so use your imagination and + your experience to think of how this could benefit you in your application. +

+

+ Interceptor based message processing
+ Tribes uses a customizable interceptor stack to process messages that are sent and received.
+ So what, all frameworks have this!
+ Yes, but in Tribes interceptors can react to a message based on the per-message-attributes + that are sent runtime. Meaning, that if you add a encryption interceptor that encrypts message + you can decide if this interceptor will encrypt all messages, or only certain messages that are decided + by the applications running on top of Tribes.
+ This is how Tribes is able to send some messages totally ordered and others fire and forget style + like the example above.
+ The number of interceptors that are available will keep growing, and we would appreciate any contributions + that you might have. +

+

+ Threadless Interceptor stack + The interceptor don't require any separate threads to perform their message manipulation.
+ Messages that are sent will piggy back on the thread that is sending them all the way through transmission. + The exception is the MessageDispatchInterceptor that will queue up the message + and send it on a separate thread for asynchronous message delivery. + Messages received are controlled by a thread pool in the receiver component.
+ The channel object can send a heartbeat() through the interceptor stack to allow + for timeouts, cleanup and other events.
+ The MessageDispatchInterceptor is the only interceptor that is configured by default. +

+

+ Parallel Delivery
+ Tribes support parallel delivery of messages. Meaning that node_A could send three messages to node_B in + parallel. This feature becomes useful when sending messages with different delivery semantics. + Otherwise if Message_1 was sent totally ordered, Message_2 would have to wait for that message to complete.
+ Through NIO, Tribes is also able to send a message to several receivers at the same time on the same thread. +

+

+ Silent Member Messaging
+ With Tribes you are able to send messages to members that are not in your group. + So by default, you can already send messages over a wide area network, even though the dynamic discover + module today is limited to local area networks by using multicast for dynamic node discovery. + Of course, the membership component will be expanded to support WAN memberships in the future. + But this is very useful, when you want to hide members from the rest of the group and only communicate with them +

+
Where can I get Tribes
+

+ Tribes ships as a module with Tomcat, and is released as part of the Apache Tomcat release. +

+ + +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/membership.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/membership.html new file mode 100644 index 0000000..95d6702 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/membership.html @@ -0,0 +1,83 @@ +Apache Tribes - The Tomcat Cluster Communication Module (7.0.108) - Apache Tribes - Membership
Apache Tomcat

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tribes Development

Apache Tribes - Membership

Membership
+

TODO

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/setup.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/setup.html new file mode 100644 index 0000000..298d5e9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/setup.html @@ -0,0 +1,83 @@ +Apache Tribes - The Tomcat Cluster Communication Module (7.0.108) - Apache Tribes - Configuration
Apache Tomcat

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tribes Development

Apache Tribes - Configuration

Configuration Overview
+

TODO

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/status.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/status.html new file mode 100644 index 0000000..2b4d403 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/status.html @@ -0,0 +1,83 @@ +Apache Tribes - The Tomcat Cluster Communication Module (7.0.108) - Apache Tribes - Status
Apache Tomcat

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tribes Development

Apache Tribes - Status

Status
+

TODO

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/transport.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/transport.html new file mode 100644 index 0000000..cbc54e9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/tribes/transport.html @@ -0,0 +1,83 @@ +Apache Tribes - The Tomcat Cluster Communication Module (7.0.108) - Apache Tribes - Transport
Apache Tomcat

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tribes Development

Apache Tribes - Transport

Transport
+

TODO

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/virtual-hosting-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/virtual-hosting-howto.html new file mode 100644 index 0000000..90e6960 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/virtual-hosting-howto.html @@ -0,0 +1,197 @@ +Apache Tomcat 7 (7.0.108) - Virtual Hosting and Tomcat

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Virtual Hosting and Tomcat

Table of Contents
+ +
Assumptions
+

+ For the sake of this how-to, assume you have a development host with two + host names, ren and stimpy. Let's also assume + one instance of Tomcat running, so $CATALINA_HOME refers to + wherever it's installed, perhaps /usr/local/tomcat. +

+

+ Also, this how-to uses Unix-style path separators and commands; if you're + on Windows modify accordingly. +

+
server.xml
+

+ At the simplest, edit the Engine portion + of your server.xml file to look like this: +

+

+<Engine name="Catalina" defaultHost="ren">
+    <Host name="ren"    appBase="renapps"/>
+    <Host name="stimpy" appBase="stimpyapps"/>
+</Engine>
+    
+

+ Note that the directory structures under the appBase for each host should + not overlap each other. +

+

+ Consult the configuration documentation for other attributes of the + Engine and + Host elements. +

+
Webapps Directory
+

+ Create directories for each of the virtual hosts: +

+

+mkdir $CATALINA_HOME/renapps
+mkdir $CATALINA_HOME/stimpyapps
+    
+
Configuring Your Contexts
+
General
+

Contexts are normally located underneath the appBase directory. For + example, to deploy the foobar context as a war file in + the ren host, use + $CATALINA_HOME/renapps/foobar.war. Note that the + default or ROOT context for ren would be deployed as + $CATALINA_HOME/renapps/ROOT.war (WAR) or + $CATALINA_HOME/renapps/ROOT (directory). +

+

NOTE: The docBase for a context should never be + the same as the appBase for a host. +

+
+
context.xml - approach #1
+

+ Within your Context, create a META-INF directory and then + place your Context definition in it in a file named + context.xml. i.e. + $CATALINA_HOME/renapps/ROOT/META-INF/context.xml + This makes deployment easier, particularly if you're distributing a WAR + file. +

+
+
context.xml - approach #2
+

+ Create a structure under $CATALINA_HOME/conf/Catalina + corresponding to your virtual hosts, e.g.: +

+

+mkdir $CATALINA_HOME/conf/Catalina/ren
+mkdir $CATALINA_HOME/conf/Catalina/stimpy
+      
+

+ Note that the ending directory name "Catalina" represents the + name attribute of the + Engine element as shown above. +

+

+ Now, for your default webapps, add: +

+

+$CATALINA_HOME/conf/Catalina/ren/ROOT.xml
+$CATALINA_HOME/conf/Catalina/stimpy/ROOT.xml
+      
+

+ If you want to use the Tomcat manager webapp for each host, you'll also + need to add it here: +

+

+cd $CATALINA_HOME/conf/Catalina
+cp localhost/manager.xml ren/
+cp localhost/manager.xml stimpy/
+      
+
+
Defaults per host
+

+ You can override the default values found in conf/context.xml + and conf/web.xml by specifying the new values in files + named context.xml.default and web.xml.default + from the host specific xml directory.

+

Following our previous example, you could use + $CATALINA_HOME/conf/Catalina/ren/web.xml.default + to customize the defaults for all webapps that are deployed in the virtual + host named ren. +

+
+
Further Information
+

+ Consult the configuration documentation for other attributes of the + Context element. +

+
+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/web-socket-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/web-socket-howto.html new file mode 100644 index 0000000..b427c4c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/web-socket-howto.html @@ -0,0 +1,249 @@ +Apache Tomcat 7 (7.0.108) - WebSocket How-To

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

WebSocket How-To

Table of Contents
+ +
Overview
+

Tomcat provides support for WebSocket as defined by + RFC 6455.

+
Application development
+

Tomcat implements the Java WebSocket 1.1 API defined by JSR-356.

+ +

There are several example applications that demonstrate how the WebSocket API + can be used. You will need to look at both the client side + HTML and the server side + code.

+
Production usage
+

Although the WebSocket implementation does work with any of the HTTP +connectors, it is not recommended to the WebSocket with the BIO HTTP connector +as the typical uses of WebSocket (large numbers of mostly idle connections) is +not a good fit for the HTTP BIO connector which requires that one thread is +allocated per connection regardless of whether or not the connection is idle. +

+ +

It has been reported (56304) that Linux can take large numbers of +minutes to report dropped connections. When using WebSocket with the BIO HTTP +connector this can result in threads blocking on writes for this period. This is +likely to be undesirable. The time taken for the connection to be reported as +dropped can be reduced by using the kernel network parameter +/proc/sys/net/ipv4/tcp_retries2. Alternatively, one of the other +HTTP connectors may be used as they utilise non-blocking IO enabling Tomcat to +implement its own timeout mechanism to handle these cases.

+
Tomcat WebSocket specific configuration
+

The JSR-356 Java WebSocket 1.1 implementation is only available when Tomcat + is running on Java 7 or later.

+ +

Tomcat provides a number of Tomcat specific configuration options for + WebSocket. It is anticipated that these will be absorbed into the WebSocket + specification over time.

+ +

The write timeout used when sending WebSocket messages in blocking mode + defaults to 20000 milliseconds (20 seconds). This may be changed by setting + the property org.apache.tomcat.websocket.BLOCKING_SEND_TIMEOUT + in the user properties collection attached to the WebSocket session. The + value assigned to this property should be a Long and represents + the timeout to use in milliseconds. For an infinite timeout, use + -1.

+ +

In addition to the Session.setMaxIdleTimeout(long) method which + is part of the Java WebSocket API, Tomcat provides greater control of the + timing out the session due to lack of activity. Setting the property + org.apache.tomcat.websocket.READ_IDLE_TIMEOUT_MS in the user + properties collection attached to the WebSocket session will trigger a + session timeout if no WebSocket message is received for the specified number + of milliseconds. Setting the property + org.apache.tomcat.websocket.WRITE_IDLE_TIMEOUT_MS will trigger a + session timeout if no WebSocket message is sent for the specified number of + milliseconds. These can be used separately or together, with or without + Session.setMaxIdleTimeout(long). If the associated property is + not specified, the read and/or write idle timeout will be applied.

+ +

If the application does not define a MessageHandler.Partial for + incoming binary messages, any incoming binary messages must be buffered so + the entire message can be delivered in a single call to the registered + MessageHandler.Whole for binary messages. The default buffer + size for binary messages is 8192 bytes. This may be changed for a web + application by setting the servlet context initialization parameter + org.apache.tomcat.websocket.binaryBufferSize to the desired + value in bytes.

+ +

If the application does not define a MessageHandler.Partial for + incoming text messages, any incoming text messages must be buffered so the + entire message can be delivered in a single call to the registered + MessageHandler.Whole for text messages. The default buffer size + for text messages is 8192 bytes. This may be changed for a web application by + setting the servlet context initialization parameter + org.apache.tomcat.websocket.textBufferSize to the desired value + in bytes.

+ +

The Java WebSocket specification 1.0 does not permit programmatic deployment + after the first endpoint has started a WebSocket handshake. By default, + Tomcat continues to permit additional programmatic deployment. This + behavior is controlled by the + org.apache.tomcat.websocket.noAddAfterHandshake servlet context + initialization parameter. The default may be changed by setting the + org.apache.tomcat.websocket.STRICT_SPEC_COMPLIANCE system + property to true but any explicit setting on the servlet context + will always take priority.

+ +

The Java WebSocket 1.0 specification requires that callbacks for + asynchronous writes are performed on a different thread to the thread that + initiated the write. Since the container thread pool is not exposed via the + Servlet API, the WebSocket implementation has to provide its own thread pool. + This thread pool is controlled by the following servlet context + initialization parameters:

+
    +
  • org.apache.tomcat.websocket.executorCoreSize: The core + size of the executor thread pool. If not set, the default of 0 (zero) + is used. Note that the maximum permitted size of the executor thread + pool is hard coded to Integer.MAX_VALUE which effectively + means it is unlimited.
  • +
  • org.apache.tomcat.websocket.executorKeepAliveTimeSeconds: + The maximum time an idle thread will remain in the executor thread pool + until it is terminated. If not specified, the default of 60 seconds is + used.
  • +
+ +

When using the WebSocket client to connect to server endpoints, the timeout + for IO operations while establishing the connection is controlled by the + userProperties of the provided + javax.websocket.ClientEndpointConfig. The property is + org.apache.tomcat.websocket.IO_TIMEOUT_MS and is the + timeout as a String in milliseconds. The default is 5000 (5 + seconds).

+ +

When using the WebSocket client to connect to secure server endpoints, the + client SSL configuration is controlled by the userProperties + of the provided javax.websocket.ClientEndpointConfig. The + following user properties are supported:

+
    +
  • org.apache.tomcat.websocket.SSL_CONTEXT
  • +
  • org.apache.tomcat.websocket.SSL_PROTOCOLS
  • +
  • org.apache.tomcat.websocket.SSL_TRUSTSTORE
  • +
  • org.apache.tomcat.websocket.SSL_TRUSTSTORE_PWD
  • +
+

The default truststore password is changeit.

+ +

If the org.apache.tomcat.websocket.SSL_CONTEXT property is + set then the org.apache.tomcat.websocket.SSL_TRUSTSTORE and + org.apache.tomcat.websocket.SSL_TRUSTSTORE_PWD properties + will be ignored.

+ +

For secure server end points, host name verification is enabled by default. + To bypass this verification (not recommended), it is necessary to provide a + custom SSLContext via the + org.apache.tomcat.websocket.SSL_CONTEXT user property. The + custom SSLContext must be configured with a custom + TrustManager that extends + javax.net.ssl.X509ExtendedTrustManager. The desired verification + (or lack of verification) can then be controlled by appropriate + implementations of the individual abstract methods.

+ +

When using the WebSocket client to connect to server endpoints, the number of + HTTP redirects that the client will follow is controlled by the + userProperties of the provided + javax.websocket.ClientEndpointConfig. The property is + org.apache.tomcat.websocket.MAX_REDIRECTIONS. The default value + is 20. Redirection support can be disabled by configuring a value of zero.

+ +
Deprecated proprietary API
+ +

Prior to the development of JRS-356, Tomcat provided a proprietary WebSocket + API. This API has been deprecated in Tomcat 7 and will be removed in Tomcat + 8. There is unlikely to be any further development of this proprietary API + apart from bug fixes.

+ +

For information on this API, please see the Javadoc for the + + org.apache.catalina.websocket package. The Javadoc + pages are not included with Tomcat binary distributions. To view them + locally you would have to download and install "Full documentation" + distribution, or build it from sources. You can + also read this on the Apache Tomcat web site. Start with the + + WebSocketServlet class.

+ +

There are also several example applications that demonstrate how the + WebSocket API can be used. You'll need to look at both the client side + HTML and the server side + code.

+

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/websocketapi/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/websocketapi/index.html new file mode 100644 index 0000000..6c19db7 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/websocketapi/index.html @@ -0,0 +1,34 @@ + + + + + + API docs + + + + +The WebSocket Javadoc is not installed by default. Download and install +the "fulldocs" package to get it. + +You can also access the javadoc online in the Tomcat + +documentation bundle. + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/windows-auth-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/windows-auth-howto.html new file mode 100644 index 0000000..8bef9c4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/windows-auth-howto.html @@ -0,0 +1,374 @@ +Apache Tomcat 7 (7.0.108) - Windows Authentication How-To

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Windows Authentication How-To

Table of Contents
+ +
Overview
+

Integrated Windows authentication is most frequently used within intranet +environments since it requires that the server performing the authentication and +the user being authenticated are part of the same domain. For the user to be +authenticated automatically, the client machine used by the user must also be +part of the domain.

+

There are several options for implementing integrated Windows authentication +with Apache Tomcat. They are: +

    +
  • Built-in Tomcat support.
  • +
  • Use a third party library such as Waffle.
  • +
  • Use a reverse proxy that supports Windows authentication to perform the +authentication step such as IIS or httpd.
  • +
+The configuration of each of these options is discussed in the following +sections.

+
Built-in Tomcat support
+

Kerberos (the basis for integrated Windows authentication) requires careful +configuration. If the steps in this guide are followed exactly, then a working +configuration will result. It is important that the steps below are followed +exactly. There is very little scope for flexibility in the configuration. From +the testing to date it is known that:

+
    +
  • The host name used to access the Tomcat server must match the host name in +the SPN exactly else authentication will fail. A checksum error may be reported +in the debug logs in this case.
  • +
  • The client must be of the view that the server is part of the local trusted +intranet.
  • +
  • The SPN must be HTTP/<hostname> and it must be exactly the same in all +the places it is used.
  • +
  • The port number must not be included in the SPN.
  • +
  • No more than one SPN may be mapped to a domain user.
  • +
  • Tomcat must run as the domain account with which the SPN has been associated +or as domain admin. It is NOT recommended to run Tomcat under a +domain admin user.
  • +
  • The domain name (DEV.LOCAL) is not case sensitive when used in +the ktpass command, nor when used in jaas.conf
  • +
  • The domain must be specified when using the ktpass command
  • +
+

There are four components to the configuration of the built-in Tomcat +support for Windows authentication. The domain controller, the server hosting +Tomcat, the web application wishing to use Windows authentication and the client +machine. The following sections describe the configuration required for each +component.

+

The names of the three machines used in the configuration examples below are +win-dc01.dev.local (the domain controller), win-tc01.dev.local (the Tomcat +instance) and win-pc01.dev.local (client). All are members of the DEV.LOCAL +domain.

+

Note: In order to use the passwords in the steps below, the domain password +policy had to be relaxed. This is not recommended for production environments. +

+ +
Domain Controller
+

These steps assume that the server has already been configured to act as a + domain controller. Configuration of a Windows server as a domain controller is + outside the scope of this how-to. The steps to configure the domain controller + to enable Tomcat to support Windows authentication are as follows: +

+
    +
  • Create a domain user that will be mapped to the service name used by the + Tomcat server. In this how-to, this user is called tc01 and has a + password of tc01pass.
  • +
  • Map the service principal name (SPN) to the user account. SPNs take the + form + <service class>/<host>:<port>/<service name>. + The SPN used in this how-to is HTTP/win-tc01.dev.local. To + map the user to the SPN, run the following: +
    setspn -A HTTP/win-tc01.dev.local tc01
    +
  • +
  • Generate the keytab file that the Tomcat server will use to authenticate + itself to the domain controller. This file contains the Tomcat private key for + the service provider account and should be protected accordingly. To generate + the file, run the following command (all on a single line): +
    ktpass /out c:\tomcat.keytab /mapuser tc01@DEV.LOCAL
    +          /princ HTTP/win-tc01.dev.local@DEV.LOCAL
    +          /pass tc01pass /kvno 0
  • +
  • Create a domain user to be used on the client. In this how-to the domain + user is test with a password of testpass.
  • +
+

The above steps have been tested on a domain controller running Windows + Server 2008 R2 64-bit Standard using the Windows Server 2003 functional level + for both the forest and the domain. +

+
+ +
Tomcat instance (Windows server)
+

These steps assume that Tomcat and a Java 6 JDK/JRE have already been + installed and configured and that Tomcat is running as the tc01@DEV.LOCAL + user. The steps to configure the Tomcat instance for Windows authentication + are as follows: +

+
    +
  • Copy the tomcat.keytab file created on the domain controller + to $CATALINA_BASE/conf/tomcat.keytab.
  • +
  • Create the kerberos configuration file + $CATALINA_BASE/conf/krb5.ini. The file used in this how-to + contained:
    [libdefaults]
    +default_realm = DEV.LOCAL
    +default_keytab_name = FILE:c:\apache-tomcat-7.0.x\conf\tomcat.keytab
    +default_tkt_enctypes = rc4-hmac,aes256-cts-hmac-sha1-96,aes128-cts-hmac-sha1-96
    +default_tgs_enctypes = rc4-hmac,aes256-cts-hmac-sha1-96,aes128-cts-hmac-sha1-96
    +forwardable=true
    +
    +[realms]
    +DEV.LOCAL = {
    +        kdc = win-dc01.dev.local:88
    +}
    +
    +[domain_realm]
    +dev.local= DEV.LOCAL
    +.dev.local= DEV.LOCAL
    + The location of this file can be changed by setting the + java.security.krb5.conf system property.
  • +
  • Create the JAAS login configuration file + $CATALINA_BASE/conf/jaas.conf. The file used in this how-to + contained:
    com.sun.security.jgss.krb5.initiate {
    +    com.sun.security.auth.module.Krb5LoginModule required
    +    doNotPrompt=true
    +    principal="HTTP/win-tc01.dev.local@DEV.LOCAL"
    +    useKeyTab=true
    +    keyTab="c:/apache-tomcat-7.0.x/conf/tomcat.keytab"
    +    storeKey=true;
    +};
    +
    +com.sun.security.jgss.krb5.accept {
    +    com.sun.security.auth.module.Krb5LoginModule required
    +    doNotPrompt=true
    +    principal="HTTP/win-tc01.dev.local@DEV.LOCAL"
    +    useKeyTab=true
    +    keyTab="c:/apache-tomcat-7.0.x/conf/tomcat.keytab"
    +    storeKey=true;
    +};
    + The location of this file can be changed by setting the + java.security.auth.login.config system property. The LoginModule + used is a JVM specific one so ensure that the LoginModule specified matches + the JVM being used. The name of the login configuration must match the + value used by the authentication + valve.
  • +
+

The SPNEGO authenticator will work with any + Realm but if used with the JNDI Realm, by default the JNDI Realm will use + the user's delegated credentials to connect to the Active Directory. +

+

The above steps have been tested on a Tomcat server running Windows Server + 2008 R2 64-bit Standard with an Oracle 1.6.0_24 64-bit JDK.

+
+ +
Tomcat instance (Linux server)
+

This was tested with:

+
    +
  • Java 1.7.0, update 45, 64-bit
  • +
  • Ubuntu Server 12.04.3 LTS 64-bit
  • +
  • Tomcat 8.0.x (r1546570)
  • +
+

It should work with any Tomcat 7 release from 7.0.12 onwards although it is + recommended that the latest stable release is used.

+

The configuration is the same as for Windows but with the following + changes:

+
    +
  • The Linux server does not have to be part of the Windows domain.
  • +
  • The path to the keytab file in krb5.ini and jaas.conf should be updated + to reflect the path to the keytab file on the Linux server using Linux + style file paths (e.g. /usr/local/tomcat/...).
  • +
+
+ +
Web application
+

The web application needs to be configured to the use Tomcat specific + authentication method of SPNEGO (rather than BASIC etc.) in + web.xml. As with the other authenticators, behaviour can be customised by + explicitly configuring the + authentication valve and setting attributes on the Valve.

+
+ +
Client
+

The client must be configured to use Kerberos authentication. For Internet + Explorer this means making sure that the Tomcat instance is in the "Local + intranet" security domain and that it is configured (Tools > Internet + Options > Advanced) with integrated Windows authentication enabled. Note that + this will not work if you use the same machine for the client + and the Tomcat instance as Internet Explorer will use the unsupported NTLM + protocol.

+
+ +
References
+

Correctly configuring Kerberos authentication can be tricky. The following + references may prove helpful. Advice is also always available from the + Tomcat users + mailing list.

+
    +
  1. + IIS and Kerberos
  2. +
  3. + SPNEGO project at SourceForge
  4. +
  5. + Oracle JGSS tutorial
  6. +
  7. + Geronimo configuration for Windows authentication
  8. +
  9. + Encryption Selection in Kerberos Exchanges
  10. +
  11. Supported Kerberos Cipher + Suites
  12. +
+
+ +
Third party libraries
+ +
Waffle
+

Full details of this solution can be found through the + Waffle web site. The + key features are:

+
    +
  • Drop-in solution
  • +
  • Simple configuration (no JAAS or Kerberos keytab configuration required) +
  • +
  • Uses a native library
  • +
+
+ +
Spring Security - Kerberos Extension
+

Full details of this solution can be found through the + Kerberos extension web site. The key features are:

+
    +
  • Extension to Spring Security
  • +
  • Requires a Kerberos keytab file to be generated
  • +
  • Pure Java solution
  • +
+
+ +
Jespa
+

Full details of this solution can be found through the + project web site. The key + features are:

+
    +
  • Pure Java solution
  • +
  • Advanced Active Directory integration
  • +
+
+ +
SPNEGO AD project at SourceForge
+

Full details of this solution can be found through the + project + site. The key features are:

+
    +
  • Pure Java solution
  • +
  • SPNEGO/Kerberos Authenticator
  • +
  • Active Directory Realm
  • +
+
+
Reverse proxies
+ +
Microsoft IIS
+

There are three steps to configuring IIS to provide Windows authentication. + They are:

+
    +
  1. Configure IIS as a reverse proxy for Tomcat (see the + + IIS Web Server How-To).
  2. +
  3. Configure IIS to use Windows authentication
  4. +
  5. Configure Tomcat to use the authentication user information from IIS by + setting the tomcatAuthentication attribute on the + AJP connector to false. Alternatively, set the + tomcatAuthorization attribute to true to allow IIS to + authenticate, while Tomcat performs the authorization.
  6. +
+
+ +
Apache httpd
+

Apache httpd does not support Windows authentication out of the box but + there are a number of third-party modules that can be used. These include:

+
    +
  1. mod_auth_sspi for use on Windows platforms.
  2. +
  3. mod_auth_ntlm_winbind for non-Windows platforms. Known to + work with httpd 2.0.x on 32-bit platforms. Some users have reported stability + issues with both httpd 2.2.x builds and 64-bit Linux builds.
  4. +
+

There are three steps to configuring httpd to provide Windows + authentication. They are:

+
    +
  1. Configure httpd as a reverse proxy for Tomcat (see the + + Apache httpd Web Server How-To).
  2. +
  3. Configure httpd to use Windows authentication
  4. +
  5. Configure Tomcat to use the authentication user information from httpd by + setting the tomcatAuthentication attribute on the + AJP connector to false.
  6. +
+
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/windows-service-howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/windows-service-howto.html new file mode 100644 index 0000000..a4e0fa0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/docs/windows-service-howto.html @@ -0,0 +1,526 @@ +Apache Tomcat 7 (7.0.108) - Windows service HOW-TO

+      The Apache Tomcat Servlet/JSP Container
+

Apache Tomcat 7

Version 7.0.108, Jan 28 2021
Apache Logo

Links

User Guide

Reference

Apache Tomcat Development

Windows service HOW-TO

Table of Contents
+ +
Tomcat service application
+

+ Tomcat7 is a service application for running Tomcat + 7 as a Windows service. +

+
Tomcat monitor application
+

+ Tomcat7w is a GUI application for monitoring and + configuring Tomcat services. +

+

The available command line options are:

+ + + + + + + + + + +
//ES//Edit service configurationThis is the default operation. It is called if the no option is + provided but the executable is renamed to servicenameW.exe
//MS//Monitor servicePut the icon in the system tray
+ +
Command line arguments
+

+ Each command line directive is in the form of //XX//ServiceName +

+

The available command line options are:

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
//TS//Run the service as console applicationThis is the default operation. It is called if the no option is + provided. The ServiceName is the name of the executable without + exe suffix, meaning Tomcat7
//RS//Run the serviceCalled only from ServiceManager
//SS//Stop the service
//US//Update service parameters
//IS//Install service
//DS//Delete serviceStops the service if running
+ +
Command line parameters
+

+ Each command line parameter is prefixed with --. If the command line + parameter is prefixed with ++ then it's value will be appended to the + existing option. + If the environment variable with the same name as command line parameter but + prefixed with PR_ exists it will take precedence. + For example:

+
set PR_CLASSPATH=xx.jar
+ +

is equivalent to providing

+
--Classpath=xx.jar
+

as command line parameter.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ParameterNameDefaultDescription
--DescriptionService name description (maximum 1024 characters)
--DisplayNameServiceNameService display name
--Installprocrun.exe //RS//ServiceNameInstall image
--StartupmanualService startup mode can be either auto or manual
--DependsOnList of services that this service depend on. Dependent services + are separated using either # or ; characters
--EnvironmentList of environment variables that will be provided to the service + in the form key=value. They are separated using either + # or ; characters. If you need to use either the # + or ; character within a value then the entire value must be + enclosed inside single quotes.
--UserUser account used for running executable. It is used only for + StartMode java or exe and enables running applications + as service under account without LogonAsService privilege.
--PasswordPassword for user account set by --User parameter
--JavaHomeJAVA_HOMESet a different JAVA_HOME than defined by JAVA_HOME environment + variable
--JvmautoUse either auto (i.e. find the JVM from the Windows registry) + or specify the full path to the jvm.dll. + You can use the environment variable expansion here.
--JvmOptions-XrsList of options in the form of -D or -X that will be + passed to the JVM. The options are separated using either + # or ; characters. If you need to embed either # or + ; characters, put them inside single quotes. (Not used in + exe mode.)
--JvmOptions9List of options in the form of -D or -X that will be + passed to the JVM when running on Java 9 or later. The options are + separated using either # or ; characters. If you need to + embed either # or ; characters, put them inside single + quotes. (Not used in exe mode.)
--ClasspathSet the Java classpath. (Not used in exe mode.)
--JvmMsInitial memory pool size in MB. (Not used in exe mode.)
--JvmMxMaximum memory pool size in MB. (Not used in exe mode.)
--JvmSsThread stack size in KB. (Not used in exe mode.)
--StartModeOne of jvm, Java or exe. The modes are: +
    +
  • jvm - start Java in-process. Depends on jvm.dll, see --Jvm.
  • +
  • Java - same as exe, but automatically uses the default Java + executable, i.e. %JAVA_HOME%\bin\java.exe. Make sure JAVA_HOME is set + correctly, or use --JavaHome to provide the correct location. + If neither is set, procrun will try to find the default JDK (not JRE) + from the Windows registry.
  • +
  • exe - run the image as a separate process
  • +
+
--StartImageExecutable that will be run. Only applies to exe mode.
--StartPathWorking path for the start image executable.
--StartClassMainClass that contains the startup method. Applies to the jvm and + Java modes. (Not used in exe mode.)
--StartMethodmainMethod name if differs then main
--StartParamsList of parameters that will be passed to either StartImage or + StartClass. Parameters are separated using either # or + ; character.
--StopModeOne of jvm, Java or exe. See --StartMode + for further details.
--StopImageExecutable that will be run on Stop service signal. Only applies to + exe mode.
--StopPathWorking path for the stop image executable. Does not apply to jvm + mode.
--StopClassMainClass that will be used on Stop service signal. Applies to the + jvm and Java modes.
--StopMethodmainMethod name if differs then main
--StopParamsList of parameters that will be passed to either StopImage or + StopClass. Parameters are separated using either # or + ; character.
--StopTimeoutNo TimeoutDefines the timeout in seconds that procrun waits for service to + exit gracefully.
--LogPath%SystemRoot%\System32\LogFiles\ApacheDefines the path for logging. Creates the directory if necessary.
--LogPrefixcommons-daemonDefines the service log filename prefix. The log file is created in the + LogPath directory with .YEAR-MONTH-DAY.log suffix
--LogLevelInfoDefines the logging level and can be either Error, + Info, Warn or Debug. (Case insensitive).
--StdOutputRedirected stdout filename. + If named auto then file is created inside LogPath with the + name service-stdout.YEAR-MONTH-DAY.log.
--StdErrorRedirected stderr filename. + If named auto then file is created inside LogPath with the + name service-stderr.YEAR-MONTH-DAY.log.
--PidFileDefines the file name for storing the running process id. Actual file is + created in the LogPath directory
+ +
Installing services
+

+The safest way to manually install the service is to use the provided +service.bat script. Administrator privileges are required to run this +script. If necessary, you can use the /user switch to specify +a user to use for the installation of the service. +

+

+NOTE: If User Account Control (UAC) is enabled you will be +asked for additional privileges when 'Tomcat7.exe' is launched by +the script.
+If you want to pass additional options to service installer as +PR_* environment variables, you have to either configure them +globally in OS, or launch the program that sets them with elevated privileges +(e.g. right-click on cmd.exe and select "Run as administrator"; on Windows 8 +(or later) or Windows Server 2012 (or later), you can open an elevated command +prompt for the current directory from the Explorer +by clicking on the "File" menu bar). See issue 56143 for details. +

+ +
Install the service named 'Tomcat7'
+C:\> service.bat install
+ +

There is a 2nd optional parameter that lets you specify the name of the +service, as displayed in Windows services.

+ +
Install the service named 'MyService'
+C:\> service.bat install MyService
+ +

When installing the service with a non-default name, +tomcat7.exe and tomcat7w.exe may be renamed to +match the chosen service name. To do this, use the --rename +option.

+ +
Install the service named 'MyService' with renaming
+C:\> service.bat install MyService --rename
+ +

+If using tomcat7.exe, you need to use the //IS// parameter.

+ +
Install the service named 'Tomcat7'
+C:\> tomcat7 //IS//Tomcat7 --DisplayName="Apache Tomcat 7" ^
+     --Install="C:\Program Files\Tomcat\bin\tomcat7.exe" --Jvm=auto ^
+     --StartMode=jvm --StopMode=jvm ^
+     --StartClass=org.apache.catalina.startup.Bootstrap --StartParams=start ^
+     --StopClass=org.apache.catalina.startup.Bootstrap --StopParams=stop
+ +
Updating services
+

+To update the service parameters, you need to use the //US// parameter. +

+ +
Update the service named 'Tomcat7'
+C:\> tomcat7 //US//Tomcat7 --Description="Apache Tomcat Server - https://tomcat.apache.org/ " ^
+     --Startup=auto --Classpath=%JAVA_HOME%\lib\tools.jar;%CATALINA_HOME%\bin\bootstrap.jar
+ +

If you gave the service an optional name, you need to specify it like this: +

+ +
Update the service named 'MyService'
+C:\> tomcat7 //US//MyService --Description="Apache Tomcat Server - https://tomcat.apache.org/ " ^
+     --Startup=auto --Classpath=%JAVA_HOME%\lib\tools.jar;%CATALINA_HOME%\bin\bootstrap.jar
+ +
Removing services
+

+To remove the service, you need to use the //DS// parameter.
+If the service is running it will be stopped and then deleted.

+ +
Remove the service named 'Tomcat7'
+C:\> tomcat7 //DS//Tomcat7
+ +

If you gave the service an optional name, you need to specify it like this: +

+ +
Remove the service named 'MyService'
+C:\> tomcat7 //DS//MyService
+ +
Debugging services
+

+To run the service in console mode, you need to use the //TS// parameter. +The service shutdown can be initiated by pressing CTRL+C or +CTRL+BREAK. +If you rename the tomcat7.exe to testservice.exe then you can just execute the +testservice.exe and this command mode will be executed by default.

+ +
Run the service named 'Tomcat7' in console mode
+C:\> tomcat7 //TS//Tomcat7 [additional arguments]
+Or simply execute:
+C:\> tomcat7
+ +
Multiple Instances
+

+Tomcat supports installation of multiple instances. You can have a single +installation of Tomcat with multiple instances running on different IP/port +combinations, or multiple Tomcat versions, each running one or more instances on +different IP/ports.

+

+Each instance folder will need the following structure: +

+
    +
  • conf
  • +
  • logs
  • +
  • temp
  • +
  • webapps
  • +
  • work
  • +
+

+At a minimum, conf should contain a copy of the following files from +CATALINA_HOME\conf\. Any files not copied and edited, will be picked up by +default from CATALINA_HOME\conf, i.e. CATALINA_BASE\conf files override defaults +from CATALINA_HOME\conf.

+
    +
  • server.xml
  • +
  • web.xml
  • +
+

+You must edit CATALINA_BASE\conf\server.xml to specify a unique IP/port for the +instance to listen on. Find the line that contains +<Connector port="8080" ... and add an address attribute and/or +update the port number so as to specify a unique IP/port combination.

+

+To install an instance, first set the CATALINA_HOME environment variable to the +name of the Tomcat installation directory. Then create a second environment +variable CATALINA_BASE and point this to the instance folder. Then run "service +install" command specifying a service name.

+ +
set CATALINA_HOME=c:\tomcat_7
+set CATALINA_BASE=c:\tomcat_7\instances\instance1
+service install instance1
+ +

+To modify the service settings, you can run tomcat7w //ES//instance1. +

+

+For additional instances, create additional instance folder, update the +CATALINA_BASE environment variable, and run the service install again.

+ +
set CATALINA_BASE=c:\tomcat_7\instances\instance2
+service install instance2
+ +

+ Copyright © 1999-2021, Apache Software Foundation +
\ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/CookieExample.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/CookieExample.class new file mode 100644 index 0000000..fd62a20 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/CookieExample.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/CookieExample.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/CookieExample.java new file mode 100644 index 0000000..afbf3e7 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/CookieExample.java @@ -0,0 +1,140 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import java.io.IOException; +import java.io.PrintWriter; +import java.util.ResourceBundle; + +import javax.servlet.ServletException; +import javax.servlet.http.Cookie; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import javax.servlet.http.HttpSession; + +import util.CookieFilter; +import util.HTMLFilter; + +/** + * Example servlet showing request headers + * + * @author James Duncan Davidson + */ + +public class CookieExample extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + public void doGet(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + ResourceBundle rb = ResourceBundle.getBundle("LocalStrings",request.getLocale()); + + String cookieName = request.getParameter("cookiename"); + String cookieValue = request.getParameter("cookievalue"); + Cookie aCookie = null; + if (cookieName != null && cookieValue != null) { + aCookie = new Cookie(cookieName, cookieValue); + aCookie.setPath(request.getContextPath() + "/"); + response.addCookie(aCookie); + } + + response.setContentType("text/html"); + response.setCharacterEncoding("UTF-8"); + + PrintWriter out = response.getWriter(); + out.println(""); + out.println(""); + out.println(""); + + String title = rb.getString("cookies.title"); + out.println("" + title + ""); + out.println(""); + out.println(""); + + // relative links + + // XXX + // making these absolute till we work out the + // addition of a PathInfo issue + + out.println(""); + out.println("\"view"); + out.println(""); + out.println("\"return\""); + + out.println("

" + title + "

"); + + Cookie[] cookies = request.getCookies(); + if ((cookies != null) && (cookies.length > 0)) { + HttpSession session = request.getSession(false); + String sessionId = null; + if (session != null) { + sessionId = session.getId(); + } + out.println(rb.getString("cookies.cookies") + "
"); + for (Cookie cookie : cookies) { + String cName = cookie.getName(); + String cValue = cookie.getValue(); + out.print("Cookie Name: " + HTMLFilter.filter(cName) + "
"); + out.println(" Cookie Value: " + + HTMLFilter.filter(CookieFilter.filter(cName, cValue, sessionId)) + + "

"); + } + } else { + out.println(rb.getString("cookies.no-cookies")); + } + + if (aCookie != null) { + out.println("

"); + out.println(rb.getString("cookies.set") + "
"); + out.print(rb.getString("cookies.name") + " " + + HTMLFilter.filter(cookieName) + "
"); + out.print(rb.getString("cookies.value") + " " + + HTMLFilter.filter(cookieValue)); + } + + out.println("

"); + out.println(rb.getString("cookies.make-cookie") + "
"); + out.print("

"); + out.print(rb.getString("cookies.name") + " "); + out.println("
"); + out.print(rb.getString("cookies.value") + " "); + out.println("
"); + out.println("
"); + + + out.println(""); + out.println(""); + } + + @Override + public void doPost(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + doGet(request, response); + } + +} + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/HelloWorldExample.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/HelloWorldExample.class new file mode 100644 index 0000000..5bc4ba4 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/HelloWorldExample.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/HelloWorldExample.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/HelloWorldExample.java new file mode 100644 index 0000000..4a75a4d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/HelloWorldExample.java @@ -0,0 +1,79 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +import java.io.IOException; +import java.io.PrintWriter; +import java.util.ResourceBundle; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +/** + * The simplest possible servlet. + * + * @author James Duncan Davidson + */ + +public class HelloWorldExample extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + public void doGet(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + ResourceBundle rb = + ResourceBundle.getBundle("LocalStrings",request.getLocale()); + response.setContentType("text/html"); + response.setCharacterEncoding("UTF-8"); + PrintWriter out = response.getWriter(); + + out.println(""); + out.println(""); + out.println(""); + + String title = rb.getString("helloworld.title"); + + out.println("" + title + ""); + out.println(""); + out.println(""); + + // note that all links are created to be relative. this + // ensures that we can move the web application that this + // servlet belongs to a different place in the url + // tree and not have any harmful side effects. + + // XXX + // making these absolute till we work out the + // addition of a PathInfo issue + + out.println(""); + out.println("\"view"); + out.println(""); + out.println("\"return\""); + out.println("

" + title + "

"); + out.println(""); + out.println(""); + } +} + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings.properties new file mode 100644 index 0000000..2791a66 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings.properties @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +cookies.cookies=Your browser is sending the following cookies: +cookies.make-cookie=Create a cookie to send to your browser +cookies.name=Name: +cookies.no-cookies=Your browser isn't sending any cookies +cookies.set=You just sent the following cookie to your browser: +cookies.title=Cookies Example +cookies.value=Value: + +helloworld.title=Hello World! + +requestheader.title=Request Header Example + +requestinfo.label.method=Method: +requestinfo.label.pathinfo=Path Info: +requestinfo.label.protocol=Protocol: +requestinfo.label.remoteaddr=Remote Address: +requestinfo.label.requesturi=Request URI: +requestinfo.title=Request Information Example + +requestparams.firstname=First Name: +requestparams.lastname=Last Name: +requestparams.no-params=No Parameters, Please enter some +requestparams.params-in-req=Parameters in this request: +requestparams.title=Request Parameters Example + +sessions.adddata=Add data to your session +sessions.created=Created: +sessions.data=The following data is in your session: +sessions.dataname=Name of Session Attribute: +sessions.datavalue=Value of Session Attribute: +sessions.id=Session ID: +sessions.lastaccessed=Last Accessed: +sessions.title=Sessions Example diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_de.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_de.properties new file mode 100644 index 0000000..697de27 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_de.properties @@ -0,0 +1,28 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +cookies.make-cookie=Erzeuge ein Cookie um es an deinen Browser zu senden +cookies.name=Name: + +requestheader.title=Request-Header Beispiel + +requestinfo.label.protocol=Protokoll: +requestinfo.label.requesturi=Anfrage-URI: + +requestparams.firstname=Vorname: +requestparams.no-params=Keine Parameter, bitte geben Sie welche ein +requestparams.title=Beispiel f\u00fcr Anfrageparameter + +sessions.title=Sessions-Beispiel diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_es.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_es.properties new file mode 100644 index 0000000..0cbe29b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_es.properties @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +cookies.cookies=Tu navegador est\u00e1 enviando los siguientes cookies: +cookies.make-cookie=Crea un cookie para enviarlo a tu navegador +cookies.name=Nombre: +cookies.no-cookies=Tu navegador no est\u00e1 enviando cookies +cookies.set=Acabas de enviar a tu navegador estos cookies: +cookies.title=Ejemplo de Cookies +cookies.value=Valor: + +helloworld.title=Hola Mundo! + +requestheader.title=Ejemplo de Cabecera de Requerimiento: + +requestinfo.label.method=M\u00e9todo: +requestinfo.label.pathinfo=Info de Ruta: +requestinfo.label.protocol=Protocolo: +requestinfo.label.remoteaddr=Direccion Remota: +requestinfo.label.requesturi=URI de Requerimiento: +requestinfo.title=Ejemplo de Informacion de Requerimiento: + +requestparams.firstname=Nombre: +requestparams.lastname=Apellidos: +requestparams.no-params=No hay p\u00e1rametro. Por favor, usa alguno +requestparams.params-in-req=Par\u00e1metros en este Request: +requestparams.title=Ejemplo de solicitud con par\u00e1metros: + +sessions.adddata=A\u00f1ade datos a tu sesi\u00f3n: +sessions.created=Creado: +sessions.data=Lo siguientes datos est\u00e1n en tu sesi\u00f3n: +sessions.dataname=Nombre del atributo de sesi\u00f3n: +sessions.datavalue=Valor del atributo de sesi\u00f3n: +sessions.id=ID de Sesi\u00f3n: +sessions.lastaccessed=Ultimo Acceso: +sessions.title=Ejemplo de Sesiones diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_fr.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_fr.properties new file mode 100644 index 0000000..f09c641 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_fr.properties @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +cookies.cookies=Votre navigateur retourne les cookies suivant : +cookies.make-cookie=Cr\u00e9ation d'un cookie \u00e0 retourner \u00e0 votre navigateur +cookies.name=Nom : +cookies.no-cookies=Votre navigateur ne retourne aucun cookie +cookies.set=Vous venez d'envoyer le cookie suivant \u00e0 votre navigateur : +cookies.title=Exemple d'utilisation de Cookies +cookies.value=Valeur : + +helloworld.title=Salut le Monde ! + +requestheader.title=Exemple d'information sur les ent\u00eates de requ\u00eate + +requestinfo.label.method=M\u00e9thode : +requestinfo.label.pathinfo=Info de chemin : +requestinfo.label.protocol=Protocole : +requestinfo.label.remoteaddr=Adresse distante : +requestinfo.label.requesturi=URI de requ\u00eate : +requestinfo.title=Exemple d'information sur la requ\u00eate + +requestparams.firstname=Pr\u00e9nom : +requestparams.lastname=Nom : +requestparams.no-params=Pas de param\u00eatre, merci d'en saisir quelques-uns +requestparams.params-in-req=Param\u00eatres dans la requ\u00eate : +requestparams.title=Exemple de Requ\u00eate avec Param\u00e8tres + +sessions.adddata=Ajouter des donn\u00e9es \u00e0 votre session +sessions.created=Cr\u00e9e le : +sessions.data=Les donn\u00e9es existantes dans votre session : +sessions.dataname=Nom de l'Attribut de Session : +sessions.datavalue=Valeur de l'Attribut de Session : +sessions.id=ID de Session : +sessions.lastaccessed=Dernier acc\u00e8s : +sessions.title=Exemple de Sessions diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ja.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ja.properties new file mode 100644 index 0000000..8e316c0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ja.properties @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +cookies.cookies=\u3042\u306a\u305f\u306e\u306e\u30d6\u30e9\u30a6\u30b6\u304b\u3089\u6b21\u306eCookie\u304c\u9001\u4fe1\u3055\u308c\u3066\u3044\u307e\u3059\uff1a +cookies.make-cookie=\u30d6\u30e9\u30a6\u30b6\u3078\u9001\u4fe1\u3059\u308b cookie \u3092\u4f5c\u6210\u3057\u307e\u3059\u3002 +cookies.name=Name: +cookies.no-cookies=\u3042\u306a\u305f\u306e\u30d6\u30e9\u30a6\u30b6\u306f\u30af\u30c3\u30ad\u30fc\u3092\u9001\u4fe1\u3057\u3066\u3044\u307e\u305b\u3093\u3002 +cookies.set=\u30d6\u30e9\u30a6\u30b6\u306b cookie \u3092\u9001\u4fe1\u3057\u307e\u3057\u305f\u3002 +cookies.title=Cookie \u4f8b +cookies.value=\u5024\uff1a + +helloworld.title=Hello World! + +requestheader.title=\u30ea\u30af\u30a8\u30b9\u30c8\u30d8\u30c3\u30c0\u4f8b + +requestinfo.label.method=\u30e1\u30bd\u30c3\u30c9\uff1a +requestinfo.label.pathinfo=\u30d1\u30b9\u60c5\u5831\uff1a +requestinfo.label.protocol=\u30d7\u30ed\u30c8\u30b3\u30eb\uff1a +requestinfo.label.remoteaddr=\u30ea\u30e2\u30fc\u30c8\u30a2\u30c9\u30ec\u30b9\uff1a +requestinfo.label.requesturi=Request URI: +requestinfo.title=\u30ea\u30af\u30a8\u30b9\u30c8\u60c5\u5831\u4f8b + +requestparams.firstname=First Name: +requestparams.lastname=Last Name: +requestparams.no-params=\u30d1\u30e9\u30e1\u30fc\u30bf\u304c\u3042\u308a\u307e\u305b\u3093\u3002\u4f55\u304b\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +requestparams.params-in-req=\u3053\u306e\u30ea\u30af\u30a8\u30b9\u30c8\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\uff1a +requestparams.title=\u30ea\u30af\u30a8\u30b9\u30c8\u30d1\u30e9\u30e1\u30fc\u30bf\u4f8b + +sessions.adddata=\u30bb\u30c3\u30b7\u30e7\u30f3\u306b\u30c7\u30fc\u30bf\u3092\u8ffd\u52a0\u3057\u307e\u3059 +sessions.created=\u4f5c\u6210\uff1a +sessions.data=\u3042\u306a\u305f\u306e\u30bb\u30c3\u30b7\u30e7\u30f3\u306b\u306f\u6b21\u306e\u30c7\u30fc\u30bf\u304c\u3042\u308a\u307e\u3059\uff1a +sessions.dataname=\u30bb\u30c3\u30b7\u30e7\u30f3\u5c5e\u6027\u540d\uff1a +sessions.datavalue=\u30bb\u30c3\u30b7\u30e7\u30f3\u5c5e\u6027\u306e\u5024\uff1a +sessions.id=\u30bb\u30c3\u30b7\u30e7\u30f3ID +sessions.lastaccessed=\u6700\u7d42\u30a2\u30af\u30bb\u30b9\uff1a +sessions.title=\u30bb\u30c3\u30b7\u30e7\u30f3\u4f8b diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ko.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ko.properties new file mode 100644 index 0000000..d781dce --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ko.properties @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +cookies.cookies=\uadc0\ud558\uc758 \ube0c\ub77c\uc6b0\uc800\uac00 \ub2e4\uc74c \ucfe0\ud0a4\ub4e4\uc744 \ubcf4\ub0c5\ub2c8\ub2e4. +cookies.make-cookie=\uadc0\ud558\uc758 \ube0c\ub77c\uc6b0\uc800\uc5d0 \uc804\uc1a1\ud558\uae30 \uc704\ud55c \ucfe0\ud0a4 \uc0dd\uc131 +cookies.name=\uc774\ub984: +cookies.no-cookies=\uadc0\ud558\uc758 \ube0c\ub77c\uc6b0\uc800\ub294 \uc5b4\ub5a4 \ucfe0\ud0a4\ub3c4 \uc804\uc1a1\ud558\uc9c0 \uc54a\uc2b5\ub2c8\ub2e4. +cookies.set=\uadc0\ud558\ub294 \ub2e4\uc74c \ucfe0\ud0a4\ub97c, \uadc0\ud558\uc758 \ube0c\ub77c\uc6b0\uc800\uc5d0 \uc804\uc1a1\ud588\uc2b5\ub2c8\ub2e4. +cookies.title=\ucfe0\ud0a4\ub4e4\uc758 \uc608\uc81c +cookies.value=\uac12: + +helloworld.title=\uc548\ub155 \uc138\uacc4\uc5ec! + +requestheader.title=\uc694\uccad\uc758 \ud5e4\ub354 \uc608\uc81c + +requestinfo.label.method=\uba54\uc18c\ub4dc: +requestinfo.label.pathinfo=\uacbd\ub85c \uc815\ubcf4: +requestinfo.label.protocol=\ud504\ub85c\ud1a0\ucf5c: +requestinfo.label.remoteaddr=\uc6d0\uaca9 \uc8fc\uc18c: +requestinfo.label.requesturi=\uc694\uccad URI: +requestinfo.title=\uc694\uccad \uc815\ubcf4 \uc608\uc81c + +requestparams.firstname=\uc774\ub984: +requestparams.lastname=\uc131 +requestparams.no-params=\ud30c\ub77c\ubbf8\ud130\ub4e4\uc774 \uc5c6\uc2b5\ub2c8\ub2e4. \ud30c\ub77c\ubbf8\ud130\ub4e4\uc744 \uc785\ub825\ud558\uc2ed\uc2dc\uc624. +requestparams.params-in-req=\uc774 \uc694\uccad\uc758 \ud30c\ub77c\ubbf8\ud130\ub4e4: +requestparams.title=\uc694\uccad \ud30c\ub77c\ubbf8\ud130\ub4e4\uc758 \uc608\uc81c + +sessions.adddata=\uadc0\ud558\uc758 \uc138\uc158\uc5d0 \ub370\uc774\ud130\ub97c \ucd94\uac00 +sessions.created=\uc0dd\uc131\uc2dc\uac04: +sessions.data=\uadc0\ud558\uc758 \uc138\uc158\uc5d0 \ub2e4\uc74c \ub370\uc774\ud130\uac00 \uc788\uc2b5\ub2c8\ub2e4: +sessions.dataname=\uc138\uc158 \uc18d\uc131 \uc774\ub984: +sessions.datavalue=\uc138\uc158 \uc18d\uc131 \uac12: +sessions.id=\uc138\uc158 ID: +sessions.lastaccessed=\ucd5c\uc885 \uc811\uadfc \uc2dc\uac04: +sessions.title=\uc138\uc158\ub4e4\uc758 \uc608\uc81c diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_pt.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_pt.properties new file mode 100644 index 0000000..b432741 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_pt.properties @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +cookies.cookies=O se browser esta a enviar os seguintes cookies: +cookies.make-cookie=Crie um cookie para enviar para o seu browser +cookies.name=Nome: +cookies.no-cookies=O seu browser nao esta a enviar nenhuns cookies +cookies.set=Acabou de enviar o seguinte cookie para o seu browser: +cookies.title=CExamplo de Cookies +cookies.value=Valor: + +helloworld.title=Ola Mundo! + +requestheader.title=Exemplo da Cebeceira do Pedido + +requestinfo.label.method=Metodo: +requestinfo.label.pathinfo=Informacao do Caminho: +requestinfo.label.protocol=Protocolo: +requestinfo.label.remoteaddr=Endereco Remoto: +requestinfo.label.requesturi=URI do Pedido: +requestinfo.title=Exemplo da Informacao do Pedido + +requestparams.firstname=Primeiro Nome: +requestparams.lastname=Apelido: +requestparams.no-params=Sem Parametros, Por favor entre alguns +requestparams.params-in-req=Parametros neste pedido: +requestparams.title=Examplo de Parametros do Pedido + +sessions.adddata=Adicione data a sua sessao +sessions.created=Criada: +sessions.data=Os seguintes dados fazem parte da sua sessao: +sessions.dataname=Nome do atributo da sessao: +sessions.datavalue=Valor do atributo da Sessao: +sessions.id=Identificador da Sessao: +sessions.lastaccessed=Ultima vez acedida: +sessions.title=Examplo de sessoes diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ru.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ru.properties new file mode 100644 index 0000000..45cc2ae --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_ru.properties @@ -0,0 +1,16 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +requestparams.title=\u041f\u0440\u0438\u043c\u0435\u0440 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_zh_CN.properties b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_zh_CN.properties new file mode 100644 index 0000000..978234d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/LocalStrings_zh_CN.properties @@ -0,0 +1,48 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +cookies.cookies=\u4f60\u7684\u6d4f\u89c8\u5668\u6b63\u5728\u53d1\u9001\u4e0b\u9762\u7684cookie\uff1a +cookies.make-cookie=\u521b\u5efa\u4e00\u4e2a\u53d1\u9001\u5230\u4f60\u7684\u6d4f\u89c8\u5668\u7684cookie +cookies.name=\u540d.\u79f0: +cookies.no-cookies=\u4f60\u7684\u6d4f\u89c8\u5668\u672a\u53d1\u9001\u4efb\u4f55cookie +cookies.set=\u4f60\u521a\u521a\u5c06\u4ee5\u4e0bcookie\u53d1\u9001\u5230\u4f60\u7684\u6d4f\u89c8\u5668\uff1a +cookies.title=cookie\u793a\u4f8b +cookies.value=\u503c\uff1a + +helloworld.title=\u4f60\u597d\uff0c\u4e16\u754c. + +requestheader.title=\u8bf7\u6c42 Header \u793a\u4f8b + +requestinfo.label.method=\u65b9\u6cd5\uff1a +requestinfo.label.pathinfo=\u8def\u5f84\u4fe1\u606f\uff1a +requestinfo.label.protocol=\u534f\u8bae\uff1a +requestinfo.label.remoteaddr=\u8fdc\u7a0b\u5730\u5740\uff1a +requestinfo.label.requesturi=\u8bf7\u6c42 URI (: +requestinfo.title=\u8bf7\u6c42\u4fe1\u606f\u8303\u4f8b + +requestparams.firstname=\u59d3\uff1a +requestparams.lastname=\u59d3\u6c0f\uff1a +requestparams.no-params=\u6ca1\u6709\u53c2\u6570\uff0c\u8bf7\u8f93\u5165\u4e00\u4e9b +requestparams.params-in-req=\u53c2\u6570\u5728\u8bf7\u6c42\u4e2d. +requestparams.title=\u8bf7\u6c42\u53c2\u6570\u793a\u4f8b + +sessions.adddata=\u5c06\u6570\u636e\u6dfb\u52a0\u5230\u4f60\u7684\u4f1a\u8bdd\u4e2d +sessions.created=\u5df2\u521b\u5efa\u7684\uff1a +sessions.data=\u4ee5\u4e0b\u6570\u636e\u5728\u60a8\u7684\u4f1a\u8bdd\u4e2d\uff1a +sessions.dataname=\u4f1a\u8bdd\u5c5e\u6027\u540d\uff1a +sessions.datavalue=\u4f1a\u8bdd\u5c5e\u6027\u503c\uff1a +sessions.id=\u4f1a\u8bddID\uff1a +sessions.lastaccessed=\u6700\u540e\u8bbf\u95ee\uff1a +sessions.title=\u4f1a\u8bdd.\u793a\u4f8b diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestHeaderExample.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestHeaderExample.class new file mode 100644 index 0000000..4c1b3c8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestHeaderExample.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestHeaderExample.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestHeaderExample.java new file mode 100644 index 0000000..6d8a442 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestHeaderExample.java @@ -0,0 +1,109 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import java.io.IOException; +import java.io.PrintWriter; +import java.util.Enumeration; +import java.util.Locale; +import java.util.ResourceBundle; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import javax.servlet.http.HttpSession; + +import util.CookieFilter; +import util.HTMLFilter; + +/** + * Example servlet showing request headers + * + * @author James Duncan Davidson + */ + +public class RequestHeaderExample extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + public void doGet(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + ResourceBundle rb = ResourceBundle.getBundle("LocalStrings",request.getLocale()); + + response.setContentType("text/html"); + response.setCharacterEncoding("UTF-8"); + + PrintWriter out = response.getWriter(); + out.println(""); + out.println(""); + out.println(""); + + String title = rb.getString("requestheader.title"); + out.println("" + title + ""); + out.println(""); + out.println(""); + + // all links relative + + // XXX + // making these absolute till we work out the + // addition of a PathInfo issue + + out.println(""); + out.println("\"view"); + out.println(""); + out.println("\"return\""); + + out.println("

" + title + "

"); + out.println(""); + Enumeration e = request.getHeaderNames(); + while (e.hasMoreElements()) { + String headerName = e.nextElement(); + String headerValue = request.getHeader(headerName); + out.println(""); + } + out.println("
"); + out.println(HTMLFilter.filter(headerName)); + out.println(""); + if (headerName.toLowerCase(Locale.ENGLISH).contains("cookie")) { + HttpSession session = request.getSession(false); + String sessionId = null; + if (session != null) { + sessionId = session.getId(); + } + out.println(HTMLFilter.filter(CookieFilter.filter(headerValue, sessionId))); + } else { + out.println(HTMLFilter.filter(headerValue)); + } + out.println("
"); + } + + @Override + public void doPost(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + doGet(request, response); + } + +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestInfoExample.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestInfoExample.class new file mode 100644 index 0000000..08a481c Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestInfoExample.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestInfoExample.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestInfoExample.java new file mode 100644 index 0000000..abc1366 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestInfoExample.java @@ -0,0 +1,118 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import java.io.IOException; +import java.io.PrintWriter; +import java.util.ResourceBundle; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import util.HTMLFilter; + +/** + * Example servlet showing request information. + * + * @author James Duncan Davidson + */ + +public class RequestInfoExample extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + public void doGet(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + ResourceBundle rb = ResourceBundle.getBundle("LocalStrings",request.getLocale()); + + response.setContentType("text/html"); + response.setCharacterEncoding("UTF-8"); + + PrintWriter out = response.getWriter(); + out.println(""); + out.println(""); + out.println(""); + + String title = rb.getString("requestinfo.title"); + out.println("" + title + ""); + out.println(""); + out.println(""); + + // img stuff not req'd for source code HTML showing + // all links relative! + + // XXX + // making these absolute till we work out the + // addition of a PathInfo issue + + out.println(""); + out.println("\"view"); + out.println(""); + out.println("\"return\""); + + out.println("

" + title + "

"); + out.println(""); + + String cipherSuite= + (String)request.getAttribute("javax.servlet.request.cipher_suite"); + if(cipherSuite!=null){ + out.println(""); + } + + out.println("
"); + out.println(rb.getString("requestinfo.label.method")); + out.println(""); + out.println(HTMLFilter.filter(request.getMethod())); + out.println("
"); + out.println(rb.getString("requestinfo.label.requesturi")); + out.println(""); + out.println(HTMLFilter.filter(request.getRequestURI())); + out.println("
"); + out.println(rb.getString("requestinfo.label.protocol")); + out.println(""); + out.println(HTMLFilter.filter(request.getProtocol())); + out.println("
"); + out.println(rb.getString("requestinfo.label.pathinfo")); + out.println(""); + out.println(HTMLFilter.filter(request.getPathInfo())); + out.println("
"); + out.println(rb.getString("requestinfo.label.remoteaddr")); + out.println(""); + out.println(HTMLFilter.filter(request.getRemoteAddr())); + out.println("
"); + out.println("SSLCipherSuite:"); + out.println(""); + out.println(HTMLFilter.filter(cipherSuite)); + out.println("
"); + } + + @Override + public void doPost(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + doGet(request, response); + } + +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestParamExample.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestParamExample.class new file mode 100644 index 0000000..54070fd Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestParamExample.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestParamExample.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestParamExample.java new file mode 100644 index 0000000..e551dc5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/RequestParamExample.java @@ -0,0 +1,111 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import java.io.IOException; +import java.io.PrintWriter; +import java.util.ResourceBundle; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import util.HTMLFilter; + +/** + * Example servlet showing request headers + * + * @author James Duncan Davidson + */ + +public class RequestParamExample extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + public void doGet(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + ResourceBundle rb = ResourceBundle.getBundle("LocalStrings",request.getLocale()); + + response.setContentType("text/html"); + response.setCharacterEncoding("UTF-8"); + + PrintWriter out = response.getWriter(); + out.println(""); + out.println(""); + out.println(""); + + String title = rb.getString("requestparams.title"); + out.println("" + title + ""); + out.println(""); + out.println(""); + + // img stuff not req'd for source code HTML showing + + // all links relative + + // XXX + // making these absolute till we work out the + // addition of a PathInfo issue + + out.println(""); + out.println("\"view"); + out.println(""); + out.println("\"return\""); + + out.println("

" + title + "

"); + String firstName = request.getParameter("firstname"); + String lastName = request.getParameter("lastname"); + out.println(rb.getString("requestparams.params-in-req") + "
"); + if (firstName != null || lastName != null) { + out.println(rb.getString("requestparams.firstname")); + out.println(" = " + HTMLFilter.filter(firstName) + "
"); + out.println(rb.getString("requestparams.lastname")); + out.println(" = " + HTMLFilter.filter(lastName)); + } else { + out.println(rb.getString("requestparams.no-params")); + } + out.println("

"); + out.print("

"); + out.println(rb.getString("requestparams.firstname")); + out.println(""); + out.println("
"); + out.println(rb.getString("requestparams.lastname")); + out.println(""); + out.println("
"); + out.println(""); + out.println("
"); + + out.println(""); + out.println(""); + } + + @Override + public void doPost(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + doGet(request, response); + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/ServletToJsp.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/ServletToJsp.class new file mode 100644 index 0000000..4432239 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/ServletToJsp.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/ServletToJsp.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/ServletToJsp.java new file mode 100644 index 0000000..53faba2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/ServletToJsp.java @@ -0,0 +1,39 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +public class ServletToJsp extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + public void doGet (HttpServletRequest request, + HttpServletResponse response) { + + try { + // Set the attribute and Forward to hello.jsp + request.setAttribute ("servletName", "servletToJsp"); + getServletConfig().getServletContext().getRequestDispatcher( + "/jsp/jsptoserv/hello.jsp").forward(request, response); + } catch (Exception ex) { + ex.printStackTrace (); + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/SessionExample.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/SessionExample.class new file mode 100644 index 0000000..87752ff Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/SessionExample.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/SessionExample.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/SessionExample.java new file mode 100644 index 0000000..c000e84 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/SessionExample.java @@ -0,0 +1,147 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import java.io.IOException; +import java.io.PrintWriter; +import java.util.Date; +import java.util.Enumeration; +import java.util.ResourceBundle; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import javax.servlet.http.HttpSession; + +import util.HTMLFilter; + +/** + * Example servlet showing request headers + * + * @author James Duncan Davidson + */ + +public class SessionExample extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + public void doGet(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + ResourceBundle rb = ResourceBundle.getBundle("LocalStrings",request.getLocale()); + + response.setContentType("text/html"); + response.setCharacterEncoding("UTF-8"); + + PrintWriter out = response.getWriter(); + out.println(""); + out.println(""); + out.println(""); + + + String title = rb.getString("sessions.title"); + out.println("" + title + ""); + out.println(""); + out.println(""); + + // img stuff not req'd for source code HTML showing + // relative links everywhere! + + // XXX + // making these absolute till we work out the + // addition of a PathInfo issue + + out.println(""); + out.println("\"view"); + out.println(""); + out.println("\"return\""); + + out.println("

" + title + "

"); + + HttpSession session = request.getSession(true); + out.println(rb.getString("sessions.id") + " " + session.getId()); + out.println("
"); + out.println(rb.getString("sessions.created") + " "); + out.println(new Date(session.getCreationTime()) + "
"); + out.println(rb.getString("sessions.lastaccessed") + " "); + out.println(new Date(session.getLastAccessedTime())); + + String dataName = request.getParameter("dataname"); + String dataValue = request.getParameter("datavalue"); + if (dataName != null && dataValue != null) { + session.setAttribute(dataName, dataValue); + } + + out.println("

"); + out.println(rb.getString("sessions.data") + "
"); + Enumeration names = session.getAttributeNames(); + while (names.hasMoreElements()) { + String name = names.nextElement(); + String value = session.getAttribute(name).toString(); + out.println(HTMLFilter.filter(name) + " = " + + HTMLFilter.filter(value) + "
"); + } + + out.println("

"); + out.print("

"); + out.println(rb.getString("sessions.dataname")); + out.println(""); + out.println("
"); + out.println(rb.getString("sessions.datavalue")); + out.println(""); + out.println("
"); + out.println(""); + out.println("
"); + + out.println("

GET based form:
"); + out.print("

"); + out.println(rb.getString("sessions.dataname")); + out.println(""); + out.println("
"); + out.println(rb.getString("sessions.datavalue")); + out.println(""); + out.println("
"); + out.println(""); + out.println("
"); + + out.print("

URL encoded "); + + out.println(""); + out.println(""); + } + + @Override + public void doPost(HttpServletRequest request, + HttpServletResponse response) + throws IOException, ServletException + { + doGet(request, response); + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0$1.class new file mode 100644 index 0000000..021733f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0.class new file mode 100644 index 0000000..16fde39 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0.java new file mode 100644 index 0000000..b9ecd25 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async0.java @@ -0,0 +1,67 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package async; + +import java.io.IOException; + +import javax.servlet.AsyncContext; +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import org.apache.juli.logging.Log; +import org.apache.juli.logging.LogFactory; + +public class Async0 extends HttpServlet { + + private static final long serialVersionUID = 1L; + + private static final Log log = LogFactory.getLog(Async0.class); + + @Override + protected void service(final HttpServletRequest req, final HttpServletResponse resp) throws ServletException, IOException { + if (Boolean.TRUE.equals(req.getAttribute("dispatch"))) { + log.info("Received dispatch, completing on the worker thread."); + log.info("After complete called started:"+req.isAsyncStarted()); + resp.getWriter().write("Async dispatch worked:+"+System.currentTimeMillis()+"\n"); + } else { + resp.setContentType("text/plain"); + final AsyncContext actx = req.startAsync(); + actx.setTimeout(Long.MAX_VALUE); + Runnable run = new Runnable() { + @Override + public void run() { + try { + req.setAttribute("dispatch", Boolean.TRUE); + Thread.currentThread().setName("Async0-Thread"); + log.info("Putting AsyncThread to sleep"); + Thread.sleep(2*1000); + log.info("Dispatching"); + actx.dispatch(); + }catch (InterruptedException x) { + log.error("Async1",x); + }catch (IllegalStateException x) { + log.error("Async1",x); + } + } + }; + Thread t = new Thread(run); + t.start(); + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1$1.class new file mode 100644 index 0000000..531cadb Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1.class new file mode 100644 index 0000000..eb85ea0 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1.java new file mode 100644 index 0000000..dc0dc59 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async1.java @@ -0,0 +1,62 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package async; + +import java.io.IOException; + +import javax.servlet.AsyncContext; +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import org.apache.juli.logging.Log; +import org.apache.juli.logging.LogFactory; + +public class Async1 extends HttpServlet { + + private static final long serialVersionUID = 1L; + + private static final Log log = LogFactory.getLog(Async1.class); + + @Override + protected void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { + final AsyncContext actx = req.startAsync(); + actx.setTimeout(30*1000); + Runnable run = new Runnable() { + @Override + public void run() { + try { + String path = "/jsp/async/async1.jsp"; + Thread.currentThread().setName("Async1-Thread"); + log.info("Putting AsyncThread to sleep"); + Thread.sleep(2*1000); + log.info("Dispatching to "+path); + actx.dispatch(path); + }catch (InterruptedException x) { + log.error("Async1",x); + }catch (IllegalStateException x) { + log.error("Async1",x); + } + } + }; + Thread t = new Thread(run); + t.start(); + } + + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2$1.class new file mode 100644 index 0000000..10cfa14 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2.class new file mode 100644 index 0000000..d79bb88 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2.java new file mode 100644 index 0000000..736da93 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async2.java @@ -0,0 +1,64 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package async; + +import java.io.IOException; + +import javax.servlet.AsyncContext; +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import org.apache.juli.logging.Log; +import org.apache.juli.logging.LogFactory; + +public class Async2 extends HttpServlet { + + private static final long serialVersionUID = 1L; + + private static final Log log = LogFactory.getLog(Async2.class); + + @Override + protected void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { + final AsyncContext actx = req.startAsync(); + actx.setTimeout(30*1000); + Runnable run = new Runnable() { + @Override + public void run() { + try { + Thread.currentThread().setName("Async2-Thread"); + log.info("Putting AsyncThread to sleep"); + Thread.sleep(2*1000); + log.info("Writing data."); + actx.getResponse().getWriter().write("Output from background thread. Time:"+System.currentTimeMillis()+"\n"); + actx.complete(); + }catch (InterruptedException x) { + log.error("Async2",x); + }catch (IllegalStateException x) { + log.error("Async2",x); + }catch (IOException x) { + log.error("Async2",x); + } + } + }; + Thread t = new Thread(run); + t.start(); + } + + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async3.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async3.class new file mode 100644 index 0000000..bd90d90 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async3.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async3.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async3.java new file mode 100644 index 0000000..e1ff5e0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Async3.java @@ -0,0 +1,39 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package async; + +import java.io.IOException; + +import javax.servlet.AsyncContext; +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +public class Async3 extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + protected void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { + final AsyncContext actx = req.startAsync(); + actx.setTimeout(30*1000); + actx.dispatch("/jsp/async/async3.jsp"); + } + + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockContextListener.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockContextListener.class new file mode 100644 index 0000000..ceda024 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockContextListener.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockContextListener.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockContextListener.java new file mode 100644 index 0000000..685ac23 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockContextListener.java @@ -0,0 +1,44 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package async; + +import javax.servlet.ServletContext; +import javax.servlet.ServletContextEvent; +import javax.servlet.ServletContextListener; + +/* + * Ensures the Stockticker is shut down cleanly when the context stops. This + * also covers the case when the server shuts down. + */ +public class AsyncStockContextListener implements ServletContextListener { + + public static final String STOCK_TICKER_KEY = "StockTicker"; + + @Override + public void contextInitialized(ServletContextEvent sce) { + Stockticker stockticker = new Stockticker(); + ServletContext sc = sce.getServletContext(); + sc.setAttribute(STOCK_TICKER_KEY, stockticker); + } + + @Override + public void contextDestroyed(ServletContextEvent sce) { + ServletContext sc = sce.getServletContext(); + Stockticker stockticker = (Stockticker) sc.getAttribute(STOCK_TICKER_KEY); + stockticker.shutdown(); + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockServlet.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockServlet.class new file mode 100644 index 0000000..891d6b8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockServlet.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockServlet.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockServlet.java new file mode 100644 index 0000000..644f53c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/AsyncStockServlet.java @@ -0,0 +1,145 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package async; + +import java.io.IOException; +import java.io.PrintWriter; +import java.util.ArrayList; +import java.util.concurrent.ConcurrentLinkedQueue; +import java.util.concurrent.atomic.AtomicInteger; + +import javax.servlet.AsyncContext; +import javax.servlet.AsyncEvent; +import javax.servlet.AsyncListener; +import javax.servlet.ServletContext; +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import async.Stockticker.Stock; +import async.Stockticker.TickListener; + +public class AsyncStockServlet extends HttpServlet implements TickListener, AsyncListener{ + + private static final long serialVersionUID = 1L; + + public static final String POLL = "POLL"; + public static final String LONG_POLL = "LONG-POLL"; + public static final String STREAM = "STREAM"; + + static ArrayList ticks = new ArrayList(); + static ConcurrentLinkedQueue clients = new ConcurrentLinkedQueue(); + static AtomicInteger clientcount = new AtomicInteger(0); + + public AsyncStockServlet() { + System.out.println("AsyncStockServlet created"); + } + + + @Override + protected void service(HttpServletRequest req, HttpServletResponse resp) + throws ServletException, IOException { + if (req.isAsyncStarted()) { + req.getAsyncContext().complete(); + } else if (req.isAsyncSupported()) { + AsyncContext actx = req.startAsync(); + actx.addListener(this); + resp.setContentType("text/plain"); + clients.add(actx); + if (clientcount.incrementAndGet()==1) { + Stockticker ticker = (Stockticker) req.getServletContext().getAttribute( + AsyncStockContextListener.STOCK_TICKER_KEY); + ticker.addTickListener(this); + } + } else { + new Exception("Async Not Supported").printStackTrace(); + resp.sendError(400,"Async is not supported."); + } + } + + + @Override + public void tick(Stock stock) { + ticks.add((Stock)stock.clone()); + for (AsyncContext actx : clients) { + try { + writeStock(actx, stock); + } catch (Exception e) { + // Ignore. The async error handling will deal with this. + } + } + } + + + public void writeStock(AsyncContext actx, Stock stock) throws IOException { + HttpServletResponse response = (HttpServletResponse)actx.getResponse(); + PrintWriter writer = response.getWriter(); + writer.write("STOCK#");//make client parsing easier + writer.write(stock.getSymbol()); + writer.write("#"); + writer.write(stock.getValueAsString()); + writer.write("#"); + writer.write(stock.getLastChangeAsString()); + writer.write("#"); + writer.write(String.valueOf(stock.getCnt())); + writer.write("\n"); + writer.flush(); + response.flushBuffer(); + } + + + @Override + public void shutdown() { + // The web application is shutting down. Complete any AsyncContexts + // associated with an active client. + for (AsyncContext actx : clients) { + try { + actx.complete(); + } catch (Exception e) { + // Ignore. The async error handling will deal with this. + } + } + } + + + @Override + public void onComplete(AsyncEvent event) throws IOException { + if (clients.remove(event.getAsyncContext()) && clientcount.decrementAndGet()==0) { + ServletContext sc = event.getAsyncContext().getRequest().getServletContext(); + Stockticker ticker = (Stockticker) sc.getAttribute( + AsyncStockContextListener.STOCK_TICKER_KEY); + ticker.removeTickListener(this); + } + } + + @Override + public void onError(AsyncEvent event) throws IOException { + event.getAsyncContext().complete(); + } + + @Override + public void onTimeout(AsyncEvent event) throws IOException { + event.getAsyncContext().complete(); + } + + + @Override + public void onStartAsync(AsyncEvent event) throws IOException { + // NOOP + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker$Stock.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker$Stock.class new file mode 100644 index 0000000..aa842f3 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker$Stock.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker$TickListener.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker$TickListener.class new file mode 100644 index 0000000..e18ea76 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker$TickListener.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker.class new file mode 100644 index 0000000..3abe791 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker.java new file mode 100644 index 0000000..580e094 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/async/Stockticker.java @@ -0,0 +1,207 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package async; + +import java.text.DecimalFormat; +import java.util.List; +import java.util.Random; +import java.util.concurrent.CopyOnWriteArrayList; +import java.util.concurrent.atomic.AtomicInteger; + +public class Stockticker implements Runnable { + public volatile boolean run = true; + protected final AtomicInteger counter = new AtomicInteger(0); + final List listeners = new CopyOnWriteArrayList(); + protected volatile Thread ticker = null; + protected volatile int ticknr = 0; + + public synchronized void start() { + run = true; + ticker = new Thread(this); + ticker.setName("Ticker Thread"); + ticker.start(); + } + + public synchronized void stop() { + // On context stop this can be called multiple times. + // NO-OP is the ticker thread is not set + // (i.e. stop() has already completed) + if (ticker == null) { + return; + } + run = false; + try { + ticker.join(); + }catch (InterruptedException x) { + Thread.interrupted(); + } + + ticker = null; + } + + public void shutdown() { + // Notify each listener of the shutdown. This enables them to + // trigger any necessary clean-up. + for (TickListener l : listeners) { + l.shutdown(); + } + // Wait for the thread to stop. This prevents warnings in the logs + // that the thread is still active when the context stops. + stop(); + } + + public void addTickListener(TickListener listener) { + if (listeners.add(listener)) { + if (counter.incrementAndGet()==1) start(); + } + + } + + public void removeTickListener(TickListener listener) { + if (listeners.remove(listener)) { + if (counter.decrementAndGet()==0) stop(); + } + } + + @Override + public void run() { + try { + + Stock[] stocks = new Stock[] { new Stock("GOOG", 435.43), + new Stock("YHOO", 27.88), new Stock("ASF", 1015.55), }; + Random r = new Random(System.currentTimeMillis()); + while (run) { + for (int j = 0; j < 1; j++) { + int i = r.nextInt() % 3; + if (i < 0) + i = i * (-1); + Stock stock = stocks[i]; + double change = r.nextDouble(); + boolean plus = r.nextBoolean(); + if (plus) { + stock.setValue(stock.getValue() + change); + } else { + stock.setValue(stock.getValue() - change); + } + stock.setCnt(++ticknr); + for (TickListener l : listeners) { + l.tick(stock); + } + + } + Thread.sleep(850); + } + } catch (InterruptedException ix) { + // Ignore + } catch (Exception x) { + x.printStackTrace(); + } + } + + + public static interface TickListener { + public void tick(Stock stock); + public void shutdown(); + } + + public static final class Stock implements Cloneable { + protected static DecimalFormat df = new DecimalFormat("0.00"); + protected String symbol = ""; + protected double value = 0.0d; + protected double lastchange = 0.0d; + protected int cnt = 0; + + public Stock(String symbol, double initvalue) { + this.symbol = symbol; + this.value = initvalue; + } + + public void setCnt(int c) { + this.cnt = c; + } + + public int getCnt() { + return cnt; + } + + public String getSymbol() { + return symbol; + } + + public double getValue() { + return value; + } + + public void setValue(double value) { + double old = this.value; + this.value = value; + this.lastchange = value - old; + } + + public String getValueAsString() { + return df.format(value); + } + + public double getLastChange() { + return this.lastchange; + } + + public void setLastChange(double lastchange) { + this.lastchange = lastchange; + } + + public String getLastChangeAsString() { + return df.format(lastchange); + } + + @Override + public int hashCode() { + return symbol.hashCode(); + } + + @Override + public boolean equals(Object other) { + if (other instanceof Stock) { + return this.symbol.equals(((Stock) other).symbol); + } + + return false; + } + + @Override + public String toString() { + StringBuilder buf = new StringBuilder("STOCK#"); + buf.append(getSymbol()); + buf.append("#"); + buf.append(getValueAsString()); + buf.append("#"); + buf.append(getLastChangeAsString()); + buf.append("#"); + buf.append(String.valueOf(getCnt())); + return buf.toString(); + + } + + @Override + public Object clone() { + Stock s = new Stock(this.getSymbol(), this.getValue()); + s.setLastChange(this.getLastChange()); + s.setCnt(this.cnt); + return s; + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entries.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entries.class new file mode 100644 index 0000000..30bed2f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entries.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entries.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entries.java new file mode 100644 index 0000000..e95f3a0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entries.java @@ -0,0 +1,60 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package cal; + +import java.util.Hashtable; + +import javax.servlet.http.HttpServletRequest; + +public class Entries { + + private Hashtable entries; + private static final String[] time = { "8am", "9am", "10am", "11am", + "12pm", "1pm", "2pm", "3pm", "4pm", "5pm", "6pm", "7pm", "8pm" }; + public static final int rows = 12; + + public Entries() { + entries = new Hashtable(rows); + for (int i = 0; i < rows; i++) { + entries.put(time[i], new Entry(time[i])); + } + } + + public int getRows() { + return rows; + } + + public Entry getEntry(int index) { + return this.entries.get(time[index]); + } + + public int getIndex(String tm) { + for (int i = 0; i < rows; i++) + if (tm.equals(time[i])) + return i; + return -1; + } + + public void processRequest(HttpServletRequest request, String tm) { + int index = getIndex(tm); + if (index >= 0) { + String descr = request.getParameter("description"); + entries.get(time[index]).setDescription(descr); + } + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entry.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entry.class new file mode 100644 index 0000000..44c493d Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entry.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entry.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entry.java new file mode 100644 index 0000000..85f81cf --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/Entry.java @@ -0,0 +1,53 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package cal; + +public class Entry { + + String hour; + String description; + + public Entry(String hour) { + this.hour = hour; + this.description = ""; + + } + + public String getHour() { + return this.hour; + } + + public String getColor() { + if (description.equals("")) { + return "lightblue"; + } + return "red"; + } + + public String getDescription() { + if (description.equals("")) { + return "None"; + } + return this.description; + } + + public void setDescription(String descr) { + description = descr; + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/JspCalendar.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/JspCalendar.class new file mode 100644 index 0000000..e1c6efa Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/JspCalendar.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/JspCalendar.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/JspCalendar.java new file mode 100644 index 0000000..96da046 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/JspCalendar.java @@ -0,0 +1,151 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +package cal; + +import java.util.Calendar; +import java.util.Date; + +public class JspCalendar { + Calendar calendar = null; + + public JspCalendar() { + calendar = Calendar.getInstance(); + Date trialTime = new Date(); + calendar.setTime(trialTime); + } + + + public int getYear() { + return calendar.get(Calendar.YEAR); + } + + public String getMonth() { + int m = getMonthInt(); + String[] months = new String [] { "January", "February", "March", + "April", "May", "June", + "July", "August", "September", + "October", "November", "December" }; + if (m > 12) + return "Unknown to Man"; + + return months[m - 1]; + + } + + public String getDay() { + int x = getDayOfWeek(); + String[] days = new String[] {"Sunday", "Monday", "Tuesday", "Wednesday", + "Thursday", "Friday", "Saturday"}; + + if (x > 7) + return "Unknown to Man"; + + return days[x - 1]; + + } + + public int getMonthInt() { + return 1 + calendar.get(Calendar.MONTH); + } + + public String getDate() { + return getMonthInt() + "/" + getDayOfMonth() + "/" + getYear(); + } + + public String getCurrentDate() { + Date dt = new Date (); + calendar.setTime (dt); + return getMonthInt() + "/" + getDayOfMonth() + "/" + getYear(); + + } + + public String getNextDate() { + calendar.set (Calendar.DAY_OF_MONTH, getDayOfMonth() + 1); + return getDate (); + } + + public String getPrevDate() { + calendar.set (Calendar.DAY_OF_MONTH, getDayOfMonth() - 1); + return getDate (); + } + + public String getTime() { + return getHour() + ":" + getMinute() + ":" + getSecond(); + } + + public int getDayOfMonth() { + return calendar.get(Calendar.DAY_OF_MONTH); + } + + public int getDayOfYear() { + return calendar.get(Calendar.DAY_OF_YEAR); + } + + public int getWeekOfYear() { + return calendar.get(Calendar.WEEK_OF_YEAR); + } + + public int getWeekOfMonth() { + return calendar.get(Calendar.WEEK_OF_MONTH); + } + + public int getDayOfWeek() { + return calendar.get(Calendar.DAY_OF_WEEK); + } + + public int getHour() { + return calendar.get(Calendar.HOUR_OF_DAY); + } + + public int getMinute() { + return calendar.get(Calendar.MINUTE); + } + + + public int getSecond() { + return calendar.get(Calendar.SECOND); + } + + + public int getEra() { + return calendar.get(Calendar.ERA); + } + + public String getUSTimeZone() { + String[] zones = new String[] {"Hawaii", "Alaskan", "Pacific", + "Mountain", "Central", "Eastern"}; + + return zones[10 + getZoneOffset()]; + } + + public int getZoneOffset() { + return calendar.get(Calendar.ZONE_OFFSET)/(60*60*1000); + } + + + public int getDSTOffset() { + return calendar.get(Calendar.DST_OFFSET)/(60*60*1000); + } + + + public int getAMPM() { + return calendar.get(Calendar.AM_PM); + } +} + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/TableBean.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/TableBean.class new file mode 100644 index 0000000..fdd37a8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/TableBean.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/TableBean.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/TableBean.java new file mode 100644 index 0000000..6db4672 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/cal/TableBean.java @@ -0,0 +1,101 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package cal; + +import java.util.Hashtable; + +import javax.servlet.http.HttpServletRequest; + +public class TableBean { + + Hashtable table; + JspCalendar JspCal; + Entries entries; + String date; + String name = null; + String email = null; + boolean processError = false; + + public TableBean() { + this.table = new Hashtable(10); + this.JspCal = new JspCalendar(); + this.date = JspCal.getCurrentDate(); + } + + public void setName(String nm) { + this.name = nm; + } + + public String getName() { + return this.name; + } + + public void setEmail(String mail) { + this.email = mail; + } + + public String getEmail() { + return this.email; + } + + public String getDate() { + return this.date; + } + + public Entries getEntries() { + return this.entries; + } + + public void processRequest(HttpServletRequest request) { + + // Get the name and e-mail. + this.processError = false; + if (name == null || name.equals("")) + setName(request.getParameter("name")); + if (email == null || email.equals("")) + setEmail(request.getParameter("email")); + if (name == null || email == null || name.equals("") + || email.equals("")) { + this.processError = true; + return; + } + + // Get the date. + String dateR = request.getParameter("date"); + if (dateR == null) + date = JspCal.getCurrentDate(); + else if (dateR.equalsIgnoreCase("next")) + date = JspCal.getNextDate(); + else if (dateR.equalsIgnoreCase("prev")) + date = JspCal.getPrevDate(); + + entries = table.get(date); + if (entries == null) { + entries = new Entries(); + table.put(date, entries); + } + + // If time is provided add the event. + String time = request.getParameter("time"); + if (time != null) + entries.processRequest(request, time); + } + + public boolean getProcessError() { + return this.processError; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet$MessageSender.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet$MessageSender.class new file mode 100644 index 0000000..c4be561 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet$MessageSender.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet.class new file mode 100644 index 0000000..ea047bd Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet.java new file mode 100644 index 0000000..7aa1ec9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/chat/ChatServlet.java @@ -0,0 +1,292 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +package chat; + + +import java.io.IOException; +import java.io.InputStream; +import java.io.PrintWriter; +import java.util.ArrayList; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import org.apache.catalina.comet.CometEvent; +import org.apache.catalina.comet.CometProcessor; + + +/** + * Helper class to implement Comet functionality. + */ +public class ChatServlet + extends HttpServlet implements CometProcessor { + + private static final long serialVersionUID = 1L; + + private static final String CHARSET = "UTF-8"; + + protected ArrayList connections = + new ArrayList(); + protected transient MessageSender messageSender = null; + + @Override + public void init() throws ServletException { + messageSender = new MessageSender(); + Thread messageSenderThread = + new Thread(messageSender, "MessageSender[" + getServletContext().getContextPath() + "]"); + messageSenderThread.setDaemon(true); + messageSenderThread.start(); + } + + @Override + public void destroy() { + connections.clear(); + messageSender.stop(); + messageSender = null; + } + + /** + * Process the given Comet event. + * + * @param event The Comet event that will be processed + * @throws IOException + * @throws ServletException + */ + @Override + public void event(CometEvent event) + throws IOException, ServletException { + + // Note: There should really be two servlets in this example, to avoid + // mixing Comet stuff with regular connection processing + HttpServletRequest request = event.getHttpServletRequest(); + HttpServletResponse response = event.getHttpServletResponse(); + + if (event.getEventType() == CometEvent.EventType.BEGIN) { + String action = request.getParameter("action"); + if (action != null) { + if ("login".equals(action)) { + String nickname = request.getParameter("nickname"); + request.getSession(true).setAttribute("nickname", nickname); + response.sendRedirect("index.jsp"); + event.close(); + return; + } + String nickname = (String) request.getSession(true).getAttribute("nickname"); + String message = request.getParameter("message"); + messageSender.send(nickname, message); + response.sendRedirect("post.jsp"); + event.close(); + return; + } + if (request.getSession(true).getAttribute("nickname") == null) { + // Redirect to "login" + log("Redirect to login for session: " + request.getSession(true).getId()); + response.sendRedirect("login.jsp"); + event.close(); + return; + } + begin(event, request, response); + } else if (event.getEventType() == CometEvent.EventType.ERROR) { + error(event, request, response); + } else if (event.getEventType() == CometEvent.EventType.END) { + end(event, request, response); + } else if (event.getEventType() == CometEvent.EventType.READ) { + read(event, request, response); + } + } + + protected void begin(@SuppressWarnings("unused") CometEvent event, + HttpServletRequest request, HttpServletResponse response) + throws IOException { + log("Begin for session: " + request.getSession(true).getId()); + + response.setContentType("text/html; charset=" + CHARSET); + + PrintWriter writer = response.getWriter(); + writer.println(""); + writer.println("JSP Chat"); + writer.println("

"); + writer.flush(); + + synchronized(connections) { + connections.add(response); + } + + messageSender.send("Tomcat", request.getSession(true).getAttribute("nickname") + " joined the chat."); + } + + protected void end(CometEvent event, HttpServletRequest request, HttpServletResponse response) + throws IOException { + log("End for session: " + request.getSession(true).getId()); + synchronized(connections) { + connections.remove(response); + } + + PrintWriter writer = response.getWriter(); + writer.println(""); + + event.close(); + } + + protected void error(CometEvent event, HttpServletRequest request, HttpServletResponse response) + throws IOException { + log("Error for session: " + request.getSession(true).getId()); + synchronized(connections) { + connections.remove(response); + } + event.close(); + } + + protected void read(CometEvent event, HttpServletRequest request, HttpServletResponse response) + throws IOException { + InputStream is = request.getInputStream(); + byte[] buf = new byte[512]; + while (is.available() > 0) { + log("Available: " + is.available()); + int n = is.read(buf); + if (n > 0) { + log("Read " + n + " bytes: " + new String(buf, 0, n) + + " for session: " + request.getSession(true).getId()); + } else if (n < 0) { + log("End of file: " + n); + end(event, request, response); + return; + } + } + } + + @Override + protected void service(HttpServletRequest request, HttpServletResponse response) + throws IOException, ServletException { + // Compatibility method: equivalent method using the regular connection model + response.setContentType("text/html; charset=" + CHARSET); + PrintWriter writer = response.getWriter(); + writer.println(""); + writer.println("JSP Chat"); + writer.println("Chat example only supports Comet processing. "); + writer.println("Configure a connector that supports Comet and try again."); + writer.println(""); + } + + + /** + * Poller class. + */ + public class MessageSender implements Runnable { + + protected boolean running = true; + protected ArrayList messages = new ArrayList(); + + public MessageSender() { + // Default contructor + } + + public void stop() { + running = false; + synchronized (messages) { + messages.notify(); + } + } + + public void send(String user, String message) { + synchronized (messages) { + messages.add("[" + user + "]: " + message); + messages.notify(); + } + } + + /** + * The background thread that listens for incoming TCP/IP connections and + * hands them off to an appropriate processor. + */ + @Override + public void run() { + + // Loop until we receive a shutdown command + while (running) { + String[] pendingMessages; + synchronized (messages) { + try { + if (running && messages.size() == 0) { + messages.wait(); + } + } catch (InterruptedException e) { + // Ignore + } + pendingMessages = messages.toArray(new String[0]); + messages.clear(); + } + + synchronized (connections) { + for (int i = 0; i < connections.size(); i++) { + try { + PrintWriter writer = connections.get(i).getWriter(); + for (int j = 0; j < pendingMessages.length; j++) { + writer.println("
"+filter(pendingMessages[j]) + "
"); + } + writer.flush(); + } catch (IOException e) { + log("IOException sending message", e); + } + } + } + + } + + } + + } + + /** + * Filter the specified message string for characters that are sensitive + * in HTML. + * + * @param message The message string to be filtered + * @author Copied from org.apache.catalina.util.RequestUtil#filter(String) + */ + protected static String filter(String message) { + if (message == null) + return (null); + + char content[] = new char[message.length()]; + message.getChars(0, message.length(), content, 0); + StringBuilder result = new StringBuilder(content.length + 50); + for (int i = 0; i < content.length; i++) { + switch (content[i]) { + case '<': + result.append("<"); + break; + case '>': + result.append(">"); + break; + case '&': + result.append("&"); + break; + case '"': + result.append("""); + break; + default: + result.append(content[i]); + } + } + return (result.toString()); + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/checkbox/CheckTest.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/checkbox/CheckTest.class new file mode 100644 index 0000000..e5fc31c Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/checkbox/CheckTest.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/checkbox/CheckTest.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/checkbox/CheckTest.java new file mode 100644 index 0000000..e38269c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/checkbox/CheckTest.java @@ -0,0 +1,31 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +package checkbox; + +public class CheckTest { + + String b[] = new String[] { "1", "2", "3", "4" }; + + public String[] getFruit() { + return b; + } + + public void setFruit(String [] b) { + this.b = b; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/colors/ColorGameBean.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/colors/ColorGameBean.class new file mode 100644 index 0000000..bed4bf3 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/colors/ColorGameBean.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/colors/ColorGameBean.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/colors/ColorGameBean.java new file mode 100644 index 0000000..7c64d94 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/colors/ColorGameBean.java @@ -0,0 +1,113 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package colors; + +public class ColorGameBean { + + private String background = "yellow"; + private String foreground = "red"; + private String color1 = foreground; + private String color2 = background; + private String hint = "no"; + private int attempts = 0; + private int intval = 0; + private boolean tookHints = false; + + public void processRequest() { + + // background = "yellow"; + // foreground = "red"; + + if (! color1.equals(foreground)) { + if (color1.equalsIgnoreCase("black") || + color1.equalsIgnoreCase("cyan")) { + background = color1; + } + } + + if (! color2.equals(background)) { + if (color2.equalsIgnoreCase("black") || + color2.equalsIgnoreCase("cyan")) { + foreground = color2; + } + } + + attempts++; + } + + public void setColor2(String x) { + color2 = x; + } + + public void setColor1(String x) { + color1 = x; + } + + public void setAction(String x) { + if (!tookHints) + tookHints = x.equalsIgnoreCase("Hint"); + hint = x; + } + + public String getColor2() { + return background; + } + + public String getColor1() { + return foreground; + } + + public int getAttempts() { + return attempts; + } + + public boolean getHint() { + return hint.equalsIgnoreCase("Hint"); + } + + public boolean getSuccess() { + if (background.equalsIgnoreCase("black") || + background.equalsIgnoreCase("cyan")) { + + if (foreground.equalsIgnoreCase("black") || + foreground.equalsIgnoreCase("cyan")) { + return true; + } + return false; + } + + return false; + } + + public boolean getHintTaken() { + return tookHints; + } + + public void reset() { + foreground = "red"; + background = "yellow"; + } + + public void setIntval(int value) { + intval = value; + } + + public int getIntval() { + return intval; + } +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilter.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilter.class new file mode 100644 index 0000000..51ec72b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilter.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilter.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilter.java new file mode 100644 index 0000000..1dc0559 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilter.java @@ -0,0 +1,268 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package compressionFilters; + +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Enumeration; +import java.util.List; +import java.util.StringTokenizer; + +import javax.servlet.Filter; +import javax.servlet.FilterChain; +import javax.servlet.FilterConfig; +import javax.servlet.ServletException; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +/** + * Implementation of javax.servlet.Filter used to compress + * the ServletResponse if it is bigger than a threshold. + * + * @author Amy Roh + * @author Dmitri Valdin + */ +public class CompressionFilter implements Filter { + + /** + * Minimal reasonable threshold. + */ + private static final int MIN_THRESHOLD = 128; + + /** + * Minimal reasonable buffer. + */ + // 8KB is what tomcat would use by default anyway + private static final int MIN_BUFFER = 8192; + + /** + * The filter configuration object we are associated with. If this value + * is null, this filter instance is not currently configured. + */ + private FilterConfig config = null; + + /** + * The threshold number to compress. + */ + protected int compressionThreshold = 0; + + /** + * The compression buffer size to avoid chunking. + */ + protected int compressionBuffer = 0; + + /** + * The mime types to compress. + */ + protected String[] compressionMimeTypes = {"text/html", "text/xml", "text/plain"}; + + /** + * Debug level for this filter. + */ + private int debug = 0; + + /** + * Place this filter into service. + * + * @param filterConfig The filter configuration object + */ + @Override + public void init(FilterConfig filterConfig) { + + config = filterConfig; + if (filterConfig != null) { + String value = filterConfig.getInitParameter("debug"); + if (value!=null) { + debug = Integer.parseInt(value); + } + + String str = filterConfig.getInitParameter("compressionThreshold"); + if (str!=null) { + compressionThreshold = Integer.parseInt(str); + if (compressionThreshold != 0 && compressionThreshold < MIN_THRESHOLD) { + if (debug > 0) { + System.out.println("compressionThreshold should be either 0 - no compression or >= " + MIN_THRESHOLD); + System.out.println("compressionThreshold set to " + MIN_THRESHOLD); + } + compressionThreshold = MIN_THRESHOLD; + } + } + + str = filterConfig.getInitParameter("compressionBuffer"); + if (str!=null) { + compressionBuffer = Integer.parseInt(str); + if (compressionBuffer < MIN_BUFFER) { + if (debug > 0) { + System.out.println("compressionBuffer should be >= " + MIN_BUFFER); + System.out.println("compressionBuffer set to " + MIN_BUFFER); + } + compressionBuffer = MIN_BUFFER; + } + } + + str = filterConfig.getInitParameter("compressionMimeTypes"); + if (str!=null) { + List values = new ArrayList(); + StringTokenizer st = new StringTokenizer(str, ","); + + while (st.hasMoreTokens()) { + String token = st.nextToken().trim(); + if (token.length() > 0) { + values.add(token); + } + } + + if (values.size() > 0) { + compressionMimeTypes = values.toArray(new String[0]); + } else { + compressionMimeTypes = null; + } + + if (debug > 0) { + System.out.println("compressionMimeTypes set to " + + Arrays.toString(compressionMimeTypes)); + } + } + } + + } + + /** + * Take this filter out of service. + */ + @Override + public void destroy() { + + this.config = null; + + } + + /** + * The doFilter method of the Filter is called by the container + * each time a request/response pair is passed through the chain due + * to a client request for a resource at the end of the chain. + * The FilterChain passed into this method allows the Filter to pass on the + * request and response to the next entity in the chain.

+ * This method first examines the request to check whether the client support + * compression.
+ * It simply just pass the request and response if there is no support for + * compression.
+ * If the compression support is available, it creates a + * CompressionServletResponseWrapper object which compresses the content and + * modifies the header if the content length is big enough. + * It then invokes the next entity in the chain using the FilterChain object + * (chain.doFilter()),
+ **/ + @Override + public void doFilter ( ServletRequest request, ServletResponse response, + FilterChain chain ) throws IOException, ServletException { + + if (debug > 0) { + System.out.println("@doFilter"); + } + + if (compressionThreshold == 0) { + if (debug > 0) { + System.out.println("doFilter got called, but compressionThreshold is set to 0 - no compression"); + } + chain.doFilter(request, response); + return; + } + + boolean supportCompression = false; + if (request instanceof HttpServletRequest) { + if (debug > 1) { + System.out.println("requestURI = " + ((HttpServletRequest)request).getRequestURI()); + } + + // Are we allowed to compress ? + String s = ((HttpServletRequest)request).getParameter("gzip"); + if ("false".equals(s)) { + if (debug > 0) { + System.out.println("got parameter gzip=false --> don't compress, just chain filter"); + } + chain.doFilter(request, response); + return; + } + + Enumeration e = + ((HttpServletRequest)request).getHeaders("Accept-Encoding"); + while (e.hasMoreElements()) { + String name = e.nextElement(); + if (name.indexOf("gzip") != -1) { + if (debug > 0) { + System.out.println("supports compression"); + } + supportCompression = true; + } else { + if (debug > 0) { + System.out.println("no support for compression"); + } + } + } + } + + if (supportCompression) { + if (response instanceof HttpServletResponse) { + CompressionServletResponseWrapper wrappedResponse = + new CompressionServletResponseWrapper((HttpServletResponse)response); + wrappedResponse.setDebugLevel(debug); + wrappedResponse.setCompressionThreshold(compressionThreshold); + wrappedResponse.setCompressionBuffer(compressionBuffer); + wrappedResponse.setCompressionMimeTypes(compressionMimeTypes); + if (debug > 0) { + System.out.println("doFilter gets called with compression"); + } + try { + chain.doFilter(request, wrappedResponse); + } finally { + wrappedResponse.finishResponse(); + } + return; + } + } else { + if (debug > 0) { + System.out.println("doFilter gets called w/o compression"); + } + chain.doFilter(request, response); + return; + } + } + + /** + * Set filter config + * This function is equivalent to init. Required by Weblogic 6.1 + * + * @param filterConfig The filter configuration object + */ + public void setFilterConfig(FilterConfig filterConfig) { + init(filterConfig); + } + + /** + * Required by Weblogic 6.1 + * + * @return the FilterConfig that was used to initialise this filter. + */ + public FilterConfig getFilterConfig() { + return config; + } +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilterTestServlet.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilterTestServlet.class new file mode 100644 index 0000000..c00c4fc Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilterTestServlet.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilterTestServlet.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilterTestServlet.java new file mode 100644 index 0000000..a973937 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionFilterTestServlet.java @@ -0,0 +1,65 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package compressionFilters; + +import java.io.IOException; +import java.util.Enumeration; + +import javax.servlet.ServletException; +import javax.servlet.ServletOutputStream; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +/** + * Very Simple test servlet to test compression filter + * @author Amy Roh + */ +public class CompressionFilterTestServlet extends HttpServlet { + + private static final long serialVersionUID = 1L; + + @Override + public void doGet(HttpServletRequest request, HttpServletResponse response) + throws ServletException, IOException { + + ServletOutputStream out = response.getOutputStream(); + response.setContentType("text/plain"); + + Enumeration e = request.getHeaders("Accept-Encoding"); + while (e.hasMoreElements()) { + String name = e.nextElement(); + out.println(name); + if (name.indexOf("gzip") != -1) { + out.println("gzip supported -- able to compress"); + } else { + out.println("gzip not supported"); + } + } + + + out.println("Compression Filter Test Servlet"); + out.println("Minimum content length for compression is 128 bytes"); + out.println("********** 32 bytes **********"); + out.println("********** 32 bytes **********"); + out.println("********** 32 bytes **********"); + out.println("********** 32 bytes **********"); + out.close(); + } + +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionResponseStream.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionResponseStream.class new file mode 100644 index 0000000..5d54802 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionResponseStream.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionResponseStream.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionResponseStream.java new file mode 100644 index 0000000..070bdda --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionResponseStream.java @@ -0,0 +1,414 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package compressionFilters; + +import java.io.IOException; +import java.io.OutputStream; +import java.util.Arrays; +import java.util.zip.GZIPOutputStream; + +import javax.servlet.ServletOutputStream; + +/** + * Implementation of ServletOutputStream that works with + * the CompressionServletResponseWrapper implementation. + * + * @author Amy Roh + * @author Dmitri Valdin + */ +public class CompressionResponseStream extends ServletOutputStream { + + // ----------------------------------------------------------- Constructors + + /** + * Construct a servlet output stream associated with the specified Response. + * + * @param responseWrapper The associated response wrapper + * @param originalOutput the output stream + */ + public CompressionResponseStream( + CompressionServletResponseWrapper responseWrapper, + ServletOutputStream originalOutput) { + + super(); + closed = false; + this.response = responseWrapper; + this.output = originalOutput; + } + + + // ----------------------------------------------------- Instance Variables + + + /** + * The threshold number which decides to compress or not. + * Users can configure in web.xml to set it to fit their needs. + */ + protected int compressionThreshold = 0; + + /** + * The compression buffer size to avoid chunking + */ + protected int compressionBuffer = 0; + + /** + * The mime types to compress + */ + protected String[] compressionMimeTypes = {"text/html", "text/xml", "text/plain"}; + + /** + * Debug level + */ + private int debug = 0; + + /** + * The buffer through which all of our output bytes are passed. + */ + protected byte[] buffer = null; + + /** + * The number of data bytes currently in the buffer. + */ + protected int bufferCount = 0; + + /** + * The underlying gzip output stream to which we should write data. + */ + protected OutputStream gzipstream = null; + + /** + * Has this stream been closed? + */ + protected boolean closed = false; + + /** + * The content length past which we will not write, or -1 if there is + * no defined content length. + */ + protected int length = -1; + + /** + * The response with which this servlet output stream is associated. + */ + protected CompressionServletResponseWrapper response = null; + + /** + * The underlying servlet output stream to which we should write data. + */ + protected ServletOutputStream output = null; + + + // --------------------------------------------------------- Public Methods + + /** + * Set debug level + */ + public void setDebugLevel(int debug) { + this.debug = debug; + } + + + /** + * Set the compressionThreshold number and create buffer for this size + */ + protected void setCompressionThreshold(int compressionThreshold) { + this.compressionThreshold = compressionThreshold; + buffer = new byte[this.compressionThreshold]; + if (debug > 1) { + System.out.println("compressionThreshold is set to "+ this.compressionThreshold); + } + } + + /** + * The compression buffer size to avoid chunking + */ + protected void setCompressionBuffer(int compressionBuffer) { + this.compressionBuffer = compressionBuffer; + if (debug > 1) { + System.out.println("compressionBuffer is set to "+ this.compressionBuffer); + } + } + + /** + * Set supported mime types + */ + public void setCompressionMimeTypes(String[] compressionMimeTypes) { + this.compressionMimeTypes = compressionMimeTypes; + if (debug > 1) { + System.out.println("compressionMimeTypes is set to " + + Arrays.toString(this.compressionMimeTypes)); + } + } + + /** + * Close this output stream, causing any buffered data to be flushed and + * any further output data to throw an IOException. + */ + @Override + public void close() throws IOException { + + if (debug > 1) { + System.out.println("close() @ CompressionResponseStream"); + } + if (closed) + throw new IOException("This output stream has already been closed"); + + if (gzipstream != null) { + flushToGZip(); + gzipstream.close(); + gzipstream = null; + } else { + if (bufferCount > 0) { + if (debug > 2) { + System.out.print("output.write("); + System.out.write(buffer, 0, bufferCount); + System.out.println(")"); + } + output.write(buffer, 0, bufferCount); + bufferCount = 0; + } + } + + output.close(); + closed = true; + + } + + + /** + * Flush any buffered data for this output stream, which also causes the + * response to be committed. + */ + @Override + public void flush() throws IOException { + + if (debug > 1) { + System.out.println("flush() @ CompressionResponseStream"); + } + if (closed) { + throw new IOException("Cannot flush a closed output stream"); + } + + if (gzipstream != null) { + gzipstream.flush(); + } + + } + + public void flushToGZip() throws IOException { + + if (debug > 1) { + System.out.println("flushToGZip() @ CompressionResponseStream"); + } + if (bufferCount > 0) { + if (debug > 1) { + System.out.println("flushing out to GZipStream, bufferCount = " + bufferCount); + } + writeToGZip(buffer, 0, bufferCount); + bufferCount = 0; + } + + } + + /** + * Write the specified byte to our output stream. + * + * @param b The byte to be written + * + * @exception IOException if an input/output error occurs + */ + @Override + public void write(int b) throws IOException { + + if (debug > 1) { + System.out.println("write "+b+" in CompressionResponseStream "); + } + if (closed) + throw new IOException("Cannot write to a closed output stream"); + + if (bufferCount >= buffer.length) { + flushToGZip(); + } + + buffer[bufferCount++] = (byte) b; + + } + + + /** + * Write b.length bytes from the specified byte array + * to our output stream. + * + * @param b The byte array to be written + * + * @exception IOException if an input/output error occurs + */ + @Override + public void write(byte b[]) throws IOException { + + write(b, 0, b.length); + + } + + + /** + * Write len bytes from the specified byte array, starting + * at the specified offset, to our output stream. + * + * @param b The byte array containing the bytes to be written + * @param off Zero-relative starting offset of the bytes to be written + * @param len The number of bytes to be written + * + * @exception IOException if an input/output error occurs + */ + @Override + public void write(byte b[], int off, int len) throws IOException { + + if (debug > 1) { + System.out.println("write, bufferCount = " + bufferCount + " len = " + len + " off = " + off); + } + if (debug > 2) { + System.out.print("write("); + System.out.write(b, off, len); + System.out.println(")"); + } + + if (closed) + throw new IOException("Cannot write to a closed output stream"); + + if (len == 0) + return; + + // Can we write into buffer ? + if (len <= (buffer.length - bufferCount)) { + System.arraycopy(b, off, buffer, bufferCount, len); + bufferCount += len; + return; + } + + // There is not enough space in buffer. Flush it ... + flushToGZip(); + + // ... and try again. Note, that bufferCount = 0 here ! + if (len <= (buffer.length - bufferCount)) { + System.arraycopy(b, off, buffer, bufferCount, len); + bufferCount += len; + return; + } + + // write direct to gzip + writeToGZip(b, off, len); + } + + public void writeToGZip(byte b[], int off, int len) throws IOException { + + if (debug > 1) { + System.out.println("writeToGZip, len = " + len); + } + if (debug > 2) { + System.out.print("writeToGZip("); + System.out.write(b, off, len); + System.out.println(")"); + } + if (gzipstream == null) { + if (debug > 1) { + System.out.println("new GZIPOutputStream"); + } + + boolean alreadyCompressed = false; + String contentEncoding = response.getHeader("Content-Encoding"); + if (contentEncoding != null) { + if (contentEncoding.contains("gzip")) { + alreadyCompressed = true; + if (debug > 0) { + System.out.println("content is already compressed"); + } + } else { + if (debug > 0) { + System.out.println("content is not compressed yet"); + } + } + } + + boolean compressibleMimeType = false; + // Check for compatible MIME-TYPE + if (compressionMimeTypes != null) { + if (startsWithStringArray(compressionMimeTypes, response.getContentType())) { + compressibleMimeType = true; + if (debug > 0) { + System.out.println("mime type " + response.getContentType() + " is compressible"); + } + } else { + if (debug > 0) { + System.out.println("mime type " + response.getContentType() + " is not compressible"); + } + } + } + + if (response.isCommitted()) { + if (debug > 1) + System.out.print("Response already committed. Using original output stream"); + gzipstream = output; + } else if (alreadyCompressed) { + if (debug > 1) + System.out.print("Response already compressed. Using original output stream"); + gzipstream = output; + } else if (!compressibleMimeType) { + if (debug > 1) + System.out.print("Response mime type is not compressible. Using original output stream"); + gzipstream = output; + } else { + response.addHeader("Content-Encoding", "gzip"); + response.setContentLength(-1); // don't use any preset content-length as it will be wrong after gzipping + response.setBufferSize(compressionBuffer); + gzipstream = new GZIPOutputStream(output); + } + } + gzipstream.write(b, off, len); + + } + + + // -------------------------------------------------------- Package Methods + + + /** + * Has this response stream been closed? + */ + public boolean closed() { + + return (this.closed); + + } + + /** + * Checks if any entry in the string array starts with the specified value + * + * @param sArray the StringArray + * @param value string + */ + private boolean startsWithStringArray(String sArray[], String value) { + if (value == null) + return false; + for (String s : sArray) { + if (value.startsWith(s)) { + return true; + } + } + return false; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionServletResponseWrapper.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionServletResponseWrapper.class new file mode 100644 index 0000000..c49e041 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionServletResponseWrapper.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionServletResponseWrapper.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionServletResponseWrapper.java new file mode 100644 index 0000000..b187f33 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/compressionFilters/CompressionServletResponseWrapper.java @@ -0,0 +1,287 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package compressionFilters; + +import java.io.IOException; +import java.io.OutputStreamWriter; +import java.io.PrintWriter; +import java.util.Arrays; +import java.util.HashMap; +import java.util.Map; + +import javax.servlet.ServletOutputStream; +import javax.servlet.http.HttpServletResponse; +import javax.servlet.http.HttpServletResponseWrapper; + +/** + * Implementation of HttpServletResponseWrapper that works with + * the CompressionServletResponseStream implementation.. + * + * @author Amy Roh + * @author Dmitri Valdin + */ +public class CompressionServletResponseWrapper + extends HttpServletResponseWrapper { + + // ----------------------------------------------------- Constructor + + /** + * Calls the parent constructor which creates a ServletResponse adaptor + * wrapping the given response object. + */ + public CompressionServletResponseWrapper(HttpServletResponse response) { + super(response); + origResponse = response; + if (debug > 1) { + System.out.println("CompressionServletResponseWrapper constructor gets called"); + } + } + + + // ----------------------------------------------------- Instance Variables + + /** + * Original response + */ + + protected HttpServletResponse origResponse = null; + + /** + * Descriptive information about this Response implementation. + */ + + protected static final String info = "CompressionServletResponseWrapper"; + + /** + * The ServletOutputStream that has been returned by + * getOutputStream(), if any. + */ + + protected ServletOutputStream stream = null; + + + /** + * The PrintWriter that has been returned by + * getWriter(), if any. + */ + + protected PrintWriter writer = null; + + /** + * The threshold number to compress + */ + protected int compressionThreshold = 0; + + /** + * The compression buffer size + */ + protected int compressionBuffer = 8192; // 8KB default + + /** + * The mime types to compress + */ + protected String[] compressionMimeTypes = {"text/html", "text/xml", "text/plain"}; + + /** + * Debug level + */ + protected int debug = 0; + + /** + * keeps a copy of all headers set + */ + private Map headerCopies = new HashMap(); + + + // --------------------------------------------------------- Public Methods + + + /** + * Set threshold number + */ + public void setCompressionThreshold(int threshold) { + if (debug > 1) { + System.out.println("setCompressionThreshold to " + threshold); + } + this.compressionThreshold = threshold; + } + + /** + * Set compression buffer + */ + public void setCompressionBuffer(int buffer) { + if (debug > 1) { + System.out.println("setCompressionBuffer to " + buffer); + } + this.compressionBuffer = buffer; + } + + /** + * Set compressible mime types + */ + public void setCompressionMimeTypes(String[] mimeTypes) { + if (debug > 1) { + System.out.println("setCompressionMimeTypes to " + + Arrays.toString(mimeTypes)); + } + this.compressionMimeTypes = mimeTypes; + } + + /** + * Set debug level + */ + public void setDebugLevel(int debug) { + this.debug = debug; + } + + + /** + * Create and return a ServletOutputStream to write the content + * associated with this Response. + * + * @exception IOException if an input/output error occurs + */ + public ServletOutputStream createOutputStream() throws IOException { + if (debug > 1) { + System.out.println("createOutputStream gets called"); + } + + CompressionResponseStream stream = new CompressionResponseStream( + this, origResponse.getOutputStream()); + stream.setDebugLevel(debug); + stream.setCompressionThreshold(compressionThreshold); + stream.setCompressionBuffer(compressionBuffer); + stream.setCompressionMimeTypes(compressionMimeTypes); + + return stream; + } + + + /** + * Finish a response. + */ + public void finishResponse() { + try { + if (writer != null) { + writer.close(); + } else { + if (stream != null) + stream.close(); + } + } catch (IOException e) { + // Ignore + } + } + + + // ------------------------------------------------ ServletResponse Methods + + + /** + * Flush the buffer and commit this response. + * + * @exception IOException if an input/output error occurs + */ + @Override + public void flushBuffer() throws IOException { + if (debug > 1) { + System.out.println("flush buffer @ GZipServletResponseWrapper"); + } + ((CompressionResponseStream)stream).flush(); + + } + + /** + * Return the servlet output stream associated with this Response. + * + * @exception IllegalStateException if getWriter has + * already been called for this response + * @exception IOException if an input/output error occurs + */ + @Override + public ServletOutputStream getOutputStream() throws IOException { + + if (writer != null) + throw new IllegalStateException("getWriter() has already been called for this response"); + + if (stream == null) + stream = createOutputStream(); + if (debug > 1) { + System.out.println("stream is set to "+stream+" in getOutputStream"); + } + + return (stream); + + } + + /** + * Return the writer associated with this Response. + * + * @exception IllegalStateException if getOutputStream has + * already been called for this response + * @exception IOException if an input/output error occurs + */ + @Override + public PrintWriter getWriter() throws IOException { + + if (writer != null) + return (writer); + + if (stream != null) + throw new IllegalStateException("getOutputStream() has already been called for this response"); + + stream = createOutputStream(); + if (debug > 1) { + System.out.println("stream is set to "+stream+" in getWriter"); + } + String charEnc = origResponse.getCharacterEncoding(); + if (debug > 1) { + System.out.println("character encoding is " + charEnc); + } + // HttpServletResponse.getCharacterEncoding() shouldn't return null + // according the spec, so feel free to remove that "if" + if (charEnc != null) { + writer = new PrintWriter(new OutputStreamWriter(stream, charEnc)); + } else { + writer = new PrintWriter(stream); + } + + return (writer); + } + + @Override + public String getHeader(String name) { + return headerCopies.get(name); + } + + @Override + public void addHeader(String name, String value) { + if (headerCopies.containsKey(name)) { + String existingValue = headerCopies.get(name); + if ((existingValue != null) && (existingValue.length() > 0)) headerCopies.put(name, existingValue + "," + value); + else headerCopies.put(name, value); + } else headerCopies.put(name, value); + super.addHeader(name, value); + } + + + @Override + public void setHeader(String name, String value) { + headerCopies.put(name, value); + super.setHeader(name, value); + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/dates/JspCalendar.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/dates/JspCalendar.class new file mode 100644 index 0000000..56cd2b5 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/dates/JspCalendar.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/dates/JspCalendar.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/dates/JspCalendar.java new file mode 100644 index 0000000..2e5e7b9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/dates/JspCalendar.java @@ -0,0 +1,153 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package dates; + +import java.util.Calendar; +import java.util.Date; + +public class JspCalendar { + Calendar calendar = null; + + public JspCalendar() { + calendar = Calendar.getInstance(); + Date trialTime = new Date(); + calendar.setTime(trialTime); + } + + public int getYear() { + return calendar.get(Calendar.YEAR); + } + + public String getMonth() { + int m = getMonthInt(); + String[] months = new String [] { "January", "February", "March", + "April", "May", "June", + "July", "August", "September", + "October", "November", "December" }; + if (m > 12) + return "Unknown to Man"; + + return months[m - 1]; + + } + + public String getDay() { + int x = getDayOfWeek(); + String[] days = new String[] {"Sunday", "Monday", "Tuesday", "Wednesday", + "Thursday", "Friday", "Saturday"}; + + if (x > 7) + return "Unknown to Man"; + + return days[x - 1]; + + } + + public int getMonthInt() { + return 1 + calendar.get(Calendar.MONTH); + } + + public String getDate() { + return getMonthInt() + "/" + getDayOfMonth() + "/" + getYear(); + + } + + public String getTime() { + return getHour() + ":" + getMinute() + ":" + getSecond(); + } + + public int getDayOfMonth() { + return calendar.get(Calendar.DAY_OF_MONTH); + } + + public int getDayOfYear() { + return calendar.get(Calendar.DAY_OF_YEAR); + } + + public int getWeekOfYear() { + return calendar.get(Calendar.WEEK_OF_YEAR); + } + + public int getWeekOfMonth() { + return calendar.get(Calendar.WEEK_OF_MONTH); + } + + public int getDayOfWeek() { + return calendar.get(Calendar.DAY_OF_WEEK); + } + + public int getHour() { + return calendar.get(Calendar.HOUR_OF_DAY); + } + + public int getMinute() { + return calendar.get(Calendar.MINUTE); + } + + + public int getSecond() { + return calendar.get(Calendar.SECOND); + } + + public static void main(String args[]) { + JspCalendar db = new JspCalendar(); + p("date: " + db.getDayOfMonth()); + p("year: " + db.getYear()); + p("month: " + db.getMonth()); + p("time: " + db.getTime()); + p("date: " + db.getDate()); + p("Day: " + db.getDay()); + p("DayOfYear: " + db.getDayOfYear()); + p("WeekOfYear: " + db.getWeekOfYear()); + p("era: " + db.getEra()); + p("ampm: " + db.getAMPM()); + p("DST: " + db.getDSTOffset()); + p("ZONE Offset: " + db.getZoneOffset()); + p("TIMEZONE: " + db.getUSTimeZone()); + } + + private static void p(String x) { + System.out.println(x); + } + + + public int getEra() { + return calendar.get(Calendar.ERA); + } + + public String getUSTimeZone() { + String[] zones = new String[] {"Hawaii", "Alaskan", "Pacific", + "Mountain", "Central", "Eastern"}; + + return zones[10 + getZoneOffset()]; + } + + public int getZoneOffset() { + return calendar.get(Calendar.ZONE_OFFSET)/(60*60*1000); + } + + + public int getDSTOffset() { + return calendar.get(Calendar.DST_OFFSET)/(60*60*1000); + } + + + public int getAMPM() { + return calendar.get(Calendar.AM_PM); + } +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/error/Smart.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/error/Smart.class new file mode 100644 index 0000000..fd96ee2 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/error/Smart.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/error/Smart.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/error/Smart.java new file mode 100644 index 0000000..82c22f6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/error/Smart.java @@ -0,0 +1,30 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package error; + +public class Smart { + + String name = "JSP"; + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ExampleTagBase.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ExampleTagBase.class new file mode 100644 index 0000000..4ac9330 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ExampleTagBase.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ExampleTagBase.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ExampleTagBase.java new file mode 100644 index 0000000..127eddf --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ExampleTagBase.java @@ -0,0 +1,74 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package examples; + +import javax.servlet.jsp.JspException; +import javax.servlet.jsp.tagext.BodyContent; +import javax.servlet.jsp.tagext.BodyTagSupport; +import javax.servlet.jsp.tagext.Tag; + +public abstract class ExampleTagBase extends BodyTagSupport { + + private static final long serialVersionUID = 1L; + + @Override + public void setParent(Tag parent) { + this.parent = parent; + } + + @Override + public void setBodyContent(BodyContent bodyOut) { + this.bodyOut = bodyOut; + } + + @Override + public Tag getParent() { + return this.parent; + } + + @Override + public int doStartTag() throws JspException { + return SKIP_BODY; + } + + @Override + public int doEndTag() throws JspException { + return EVAL_PAGE; + } + + + @Override + public void doInitBody() throws JspException { + // Default implementations for BodyTag methods as well + // just in case a tag decides to implement BodyTag. + } + + @Override + public int doAfterBody() throws JspException { + return SKIP_BODY; + } + + @Override + public void release() { + bodyOut = null; + pageContext = null; + parent = null; + } + + protected BodyContent bodyOut; + protected Tag parent; +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTag.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTag.class new file mode 100644 index 0000000..3d6d760 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTag.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTag.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTag.java new file mode 100644 index 0000000..6255b65 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTag.java @@ -0,0 +1,87 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package examples; + +import java.io.IOException; + +import javax.servlet.jsp.JspException; +import javax.servlet.jsp.JspTagException; + +/** + * Example1: the simplest tag + * Collect attributes and call into some actions + * + * + */ + +public class FooTag extends ExampleTagBase { + + private static final long serialVersionUID = 1L; + + private String atts[] = new String[3]; + int i = 0; + + private final void setAtt(int index, String value) { + atts[index] = value; + } + + public void setAtt1(String value) { + setAtt(0, value); + } + + public void setAtt2(String value) { + setAtt(1, value); + } + + public void setAtt3(String value) { + setAtt(2, value); + } + + /** + * Process start tag + * + * @return EVAL_BODY_INCLUDE + */ + @Override + public int doStartTag() throws JspException { + i = 0; + return EVAL_BODY_BUFFERED; + } + + @Override + public void doInitBody() throws JspException { + pageContext.setAttribute("member", atts[i]); + i++; + } + + @Override + public int doAfterBody() throws JspException { + try { + if (i == 3) { + bodyOut.writeOut(bodyOut.getEnclosingWriter()); + return SKIP_BODY; + } + + pageContext.setAttribute("member", atts[i]); + i++; + return EVAL_BODY_BUFFERED; + } catch (IOException ex) { + throw new JspTagException(ex.toString()); + } + } +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTagExtraInfo.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTagExtraInfo.class new file mode 100644 index 0000000..ead843e Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTagExtraInfo.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTagExtraInfo.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTagExtraInfo.java new file mode 100644 index 0000000..e3fe371 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/FooTagExtraInfo.java @@ -0,0 +1,36 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package examples; + +import javax.servlet.jsp.tagext.TagData; +import javax.servlet.jsp.tagext.TagExtraInfo; +import javax.servlet.jsp.tagext.VariableInfo; + +public class FooTagExtraInfo extends TagExtraInfo { + @Override + public VariableInfo[] getVariableInfo(TagData data) { + return new VariableInfo[] + { + new VariableInfo("member", + "String", + true, + VariableInfo.NESTED) + }; + } +} + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/LogTag.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/LogTag.class new file mode 100644 index 0000000..7b62ca8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/LogTag.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/LogTag.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/LogTag.java new file mode 100644 index 0000000..0f38280 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/LogTag.java @@ -0,0 +1,61 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package examples; + +import java.io.IOException; + +import javax.servlet.jsp.JspException; +import javax.servlet.jsp.JspTagException; + +/** + * Log the contents of the body. Could be used to handle errors etc. + */ +public class LogTag extends ExampleTagBase { + + private static final long serialVersionUID = 1L; + + boolean toBrowser = false; + + public void setToBrowser(String value) { + if (value == null) + toBrowser = false; + else if (value.equalsIgnoreCase("true")) + toBrowser = true; + else + toBrowser = false; + } + + @Override + public int doStartTag() throws JspException { + return EVAL_BODY_BUFFERED; + } + + @Override + public int doAfterBody() throws JspException { + try { + String s = bodyOut.getString(); + System.err.println(s); + if (toBrowser) + bodyOut.writeOut(bodyOut.getEnclosingWriter()); + return SKIP_BODY; + } catch (IOException ex) { + throw new JspTagException(ex.toString()); + } + } +} + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ValuesTag.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ValuesTag.class new file mode 100644 index 0000000..cc4d3ff Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ValuesTag.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ValuesTag.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ValuesTag.java new file mode 100644 index 0000000..b335860 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/examples/ValuesTag.java @@ -0,0 +1,79 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package examples; + +import java.io.IOException; + +import javax.servlet.jsp.JspException; +import javax.servlet.jsp.JspTagException; +import javax.servlet.jsp.JspWriter; +import javax.servlet.jsp.tagext.TagSupport; + +/** + * Accept and display a value. + */ +public class ValuesTag extends TagSupport { + + private static final long serialVersionUID = 1L; + + // Using "-1" as the default value, + // in the assumption that it won't be used as the value. + // Cannot use null here, because null is an important case + // that should be present in the tests. + private Object objectValue = "-1"; + private String stringValue = "-1"; + private long longValue = -1; + private double doubleValue = -1; + + public void setObject(Object objectValue) { + this.objectValue = objectValue; + } + + public void setString(String stringValue) { + this.stringValue = stringValue; + } + + public void setLong(long longValue) { + this.longValue = longValue; + } + + public void setDouble(double doubleValue) { + this.doubleValue = doubleValue; + } + + @Override + public int doEndTag() throws JspException { + JspWriter out = pageContext.getOut(); + + try { + if (!"-1".equals(objectValue)) { + out.print(objectValue); + } else if (!"-1".equals(stringValue)) { + out.print(stringValue); + } else if (longValue != -1) { + out.print(longValue); + } else if (doubleValue != -1) { + out.print(doubleValue); + } else { + out.print("-1"); + } + } catch (IOException ex) { + throw new JspTagException("IOException: " + ex.toString(), ex); + } + return super.doEndTag(); + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/filters/ExampleFilter.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/filters/ExampleFilter.class new file mode 100644 index 0000000..12e41d8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/filters/ExampleFilter.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/filters/ExampleFilter.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/filters/ExampleFilter.java new file mode 100644 index 0000000..84bd52a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/filters/ExampleFilter.java @@ -0,0 +1,142 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +package filters; + + +import java.io.IOException; + +import javax.servlet.Filter; +import javax.servlet.FilterChain; +import javax.servlet.FilterConfig; +import javax.servlet.ServletException; +import javax.servlet.ServletRequest; +import javax.servlet.ServletResponse; + + +/** + * Example filter that can be attached to either an individual servlet + * or to a URL pattern. This filter performs the following functions: + *

    + *
  • Attaches itself as a request attribute, under the attribute name + * defined by the value of the attribute initialization + * parameter.
  • + *
  • Calculates the number of milliseconds required to perform the + * servlet processing required by this request, including any + * subsequently defined filters, and logs the result to the servlet + * context log for this application. + *
+ * + * @author Craig McClanahan + */ +public final class ExampleFilter implements Filter { + + + // ----------------------------------------------------- Instance Variables + + + /** + * The request attribute name under which we store a reference to ourself. + */ + private String attribute = null; + + + /** + * The filter configuration object we are associated with. If this value + * is null, this filter instance is not currently configured. + */ + private FilterConfig filterConfig = null; + + + // --------------------------------------------------------- Public Methods + + + /** + * Take this filter out of service. + */ + @Override + public void destroy() { + + this.attribute = null; + this.filterConfig = null; + + } + + + /** + * Time the processing that is performed by all subsequent filters in the + * current filter stack, including the ultimately invoked servlet. + * + * @param request The servlet request we are processing + * @param response The servlet response we are creating + * @param chain The filter chain we are processing + * + * @exception IOException if an input/output error occurs + * @exception ServletException if a servlet error occurs + */ + @Override + public void doFilter(ServletRequest request, ServletResponse response, + FilterChain chain) + throws IOException, ServletException { + + // Store ourselves as a request attribute (if requested) + if (attribute != null) + request.setAttribute(attribute, this); + + // Time and log the subsequent processing + long startTime = System.currentTimeMillis(); + chain.doFilter(request, response); + long stopTime = System.currentTimeMillis(); + filterConfig.getServletContext().log + (this.toString() + ": " + (stopTime - startTime) + + " milliseconds"); + + } + + + /** + * Place this filter into service. + * + * @param fConfig The filter configuration object + */ + @Override + public void init(FilterConfig fConfig) throws ServletException { + + this.filterConfig = fConfig; + this.attribute = fConfig.getInitParameter("attribute"); + + } + + + /** + * Return a String representation of this object. + */ + @Override + public String toString() { + + if (filterConfig == null) + return ("TimingFilter()"); + StringBuilder sb = new StringBuilder("TimingFilter("); + sb.append(filterConfig); + sb.append(")"); + return (sb.toString()); + + } + + +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/BookBean.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/BookBean.class new file mode 100644 index 0000000..e817362 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/BookBean.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/BookBean.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/BookBean.java new file mode 100644 index 0000000..01f9280 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/BookBean.java @@ -0,0 +1,44 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + + +package jsp2.examples; + +public class BookBean { + private String title; + private String author; + private String isbn; + + public BookBean( String title, String author, String isbn ) { + this.title = title; + this.author = author; + this.isbn = isbn; + } + + public String getTitle() { + return this.title; + } + + public String getAuthor() { + return this.author; + } + + public String getIsbn() { + return this.isbn; + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/FooBean.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/FooBean.class new file mode 100644 index 0000000..f624400 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/FooBean.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/FooBean.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/FooBean.java new file mode 100644 index 0000000..4dc0a78 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/FooBean.java @@ -0,0 +1,36 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + + +package jsp2.examples; + +public class FooBean { + private String bar; + + public FooBean() { + bar = "Initial value"; + } + + public String getBar() { + return this.bar; + } + + public void setBar(String bar) { + this.bar = bar; + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/ValuesBean.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/ValuesBean.class new file mode 100644 index 0000000..1ae6315 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/ValuesBean.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/ValuesBean.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/ValuesBean.java new file mode 100644 index 0000000..686039c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/ValuesBean.java @@ -0,0 +1,52 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + + +package jsp2.examples; + +/** + * Accept and display a value. + */ +public class ValuesBean { + private String string; + private double doubleValue; + private long longValue; + + public String getStringValue() { + return this.string; + } + + public void setStringValue(String string) { + this.string = string; + } + + public double getDoubleValue() { + return doubleValue; + } + + public void setDoubleValue(double doubleValue) { + this.doubleValue = doubleValue; + } + + public long getLongValue() { + return longValue; + } + + public void setLongValue(long longValue) { + this.longValue = longValue; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/el/Functions.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/el/Functions.class new file mode 100644 index 0000000..54f11ef Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/el/Functions.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/el/Functions.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/el/Functions.java new file mode 100644 index 0000000..77fdb9c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/el/Functions.java @@ -0,0 +1,45 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package jsp2.examples.el; + +import java.util.Locale; + +/** + * Defines the functions for the jsp2 example tag library. + * + *

Each function is defined as a static method.

+ */ +public class Functions { + public static String reverse( String text ) { + return new StringBuilder( text ).reverse().toString(); + } + + public static int numVowels( String text ) { + String vowels = "aeiouAEIOU"; + int result = 0; + for( int i = 0; i < text.length(); i++ ) { + if( vowels.indexOf( text.charAt( i ) ) != -1 ) { + result++; + } + } + return result; + } + + public static String caps( String text ) { + return text.toUpperCase(Locale.ENGLISH); + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/EchoAttributesTag.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/EchoAttributesTag.class new file mode 100644 index 0000000..f1ca8cd Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/EchoAttributesTag.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/EchoAttributesTag.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/EchoAttributesTag.java new file mode 100644 index 0000000..8f62e67 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/EchoAttributesTag.java @@ -0,0 +1,57 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + + +package jsp2.examples.simpletag; + +import java.io.IOException; +import java.util.ArrayList; + +import javax.servlet.jsp.JspException; +import javax.servlet.jsp.JspWriter; +import javax.servlet.jsp.tagext.DynamicAttributes; +import javax.servlet.jsp.tagext.SimpleTagSupport; + +/** + * SimpleTag handler that echoes all its attributes + */ +public class EchoAttributesTag + extends SimpleTagSupport + implements DynamicAttributes +{ + private ArrayList keys = new ArrayList(); + private ArrayList values = new ArrayList(); + + @Override + public void doTag() throws JspException, IOException { + JspWriter out = getJspContext().getOut(); + for( int i = 0; i < keys.size(); i++ ) { + String key = keys.get( i ); + Object value = values.get( i ); + out.println( "
  • " + key + " = " + value + "
  • " ); + } + } + + @Override + public void setDynamicAttribute( String uri, String localName, + Object value ) + throws JspException + { + keys.add( localName ); + values.add( value ); + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/FindBookSimpleTag.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/FindBookSimpleTag.class new file mode 100644 index 0000000..01eb62a Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/FindBookSimpleTag.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/FindBookSimpleTag.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/FindBookSimpleTag.java new file mode 100644 index 0000000..6a55d19 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/FindBookSimpleTag.java @@ -0,0 +1,46 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + + +package jsp2.examples.simpletag; + +import javax.servlet.jsp.JspException; +import javax.servlet.jsp.tagext.SimpleTagSupport; + +import jsp2.examples.BookBean; + +/** + * SimpleTag handler that pretends to search for a book, and stores + * the result in a scoped variable. + */ +public class FindBookSimpleTag extends SimpleTagSupport { + private String var; + + private static final String BOOK_TITLE = "The Lord of the Rings"; + private static final String BOOK_AUTHOR = "J. R. R. Tolkien"; + private static final String BOOK_ISBN = "0618002251"; + + @Override + public void doTag() throws JspException { + BookBean book = new BookBean( BOOK_TITLE, BOOK_AUTHOR, BOOK_ISBN ); + getJspContext().setAttribute( this.var, book ); + } + + public void setVar( String var ) { + this.var = var; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/HelloWorldSimpleTag.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/HelloWorldSimpleTag.class new file mode 100644 index 0000000..21450f5 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/HelloWorldSimpleTag.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/HelloWorldSimpleTag.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/HelloWorldSimpleTag.java new file mode 100644 index 0000000..f87736f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/HelloWorldSimpleTag.java @@ -0,0 +1,34 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + + +package jsp2.examples.simpletag; + +import java.io.IOException; + +import javax.servlet.jsp.JspException; +import javax.servlet.jsp.tagext.SimpleTagSupport; + +/** + * SimpleTag handler that prints "Hello, world!" + */ +public class HelloWorldSimpleTag extends SimpleTagSupport { + @Override + public void doTag() throws JspException, IOException { + getJspContext().getOut().write( "Hello, world!" ); + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/RepeatSimpleTag.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/RepeatSimpleTag.class new file mode 100644 index 0000000..6307468 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/RepeatSimpleTag.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/RepeatSimpleTag.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/RepeatSimpleTag.java new file mode 100644 index 0000000..41a9f3c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/jsp2/examples/simpletag/RepeatSimpleTag.java @@ -0,0 +1,44 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + + +package jsp2.examples.simpletag; + +import java.io.IOException; + +import javax.servlet.jsp.JspException; +import javax.servlet.jsp.tagext.SimpleTagSupport; + +/** + * SimpleTag handler that accepts a num attribute and + * invokes its body 'num' times. + */ +public class RepeatSimpleTag extends SimpleTagSupport { + private int num; + + @Override + public void doTag() throws JspException, IOException { + for (int i=0; i
    " + this.label + + "
    " ); + } + + public void setColor( String color ) { + this.color = color; + } + + public void setLabel( String label ) { + this.label = label; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/ContextListener.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/ContextListener.class new file mode 100644 index 0000000..26619b0 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/ContextListener.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/ContextListener.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/ContextListener.java new file mode 100644 index 0000000..31f5545 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/ContextListener.java @@ -0,0 +1,138 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package listeners; + + +import javax.servlet.ServletContext; +import javax.servlet.ServletContextAttributeEvent; +import javax.servlet.ServletContextAttributeListener; +import javax.servlet.ServletContextEvent; +import javax.servlet.ServletContextListener; + + +/** + * Example listener for context-related application events, which were + * introduced in the 2.3 version of the Servlet API. This listener + * merely documents the occurrence of such events in the application log + * associated with our servlet context. + * + * @author Craig R. McClanahan + */ +public final class ContextListener + implements ServletContextAttributeListener, ServletContextListener { + + + // ----------------------------------------------------- Instance Variables + + + /** + * The servlet context with which we are associated. + */ + private ServletContext context = null; + + + // --------------------------------------------------------- Public Methods + + + /** + * Record the fact that a servlet context attribute was added. + * + * @param event The servlet context attribute event + */ + @Override + public void attributeAdded(ServletContextAttributeEvent event) { + + log("attributeAdded('" + event.getName() + "', '" + + event.getValue() + "')"); + + } + + + /** + * Record the fact that a servlet context attribute was removed. + * + * @param event The servlet context attribute event + */ + @Override + public void attributeRemoved(ServletContextAttributeEvent event) { + + log("attributeRemoved('" + event.getName() + "', '" + + event.getValue() + "')"); + + } + + + /** + * Record the fact that a servlet context attribute was replaced. + * + * @param event The servlet context attribute event + */ + @Override + public void attributeReplaced(ServletContextAttributeEvent event) { + + log("attributeReplaced('" + event.getName() + "', '" + + event.getValue() + "')"); + + } + + + /** + * Record the fact that this web application has been destroyed. + * + * @param event The servlet context event + */ + @Override + public void contextDestroyed(ServletContextEvent event) { + + log("contextDestroyed()"); + this.context = null; + + } + + + /** + * Record the fact that this web application has been initialized. + * + * @param event The servlet context event + */ + @Override + public void contextInitialized(ServletContextEvent event) { + + this.context = event.getServletContext(); + log("contextInitialized()"); + + } + + + // -------------------------------------------------------- Private Methods + + + /** + * Log a message to the servlet context application log. + * + * @param message Message to be logged + */ + private void log(String message) { + + if (context != null) + context.log("ContextListener: " + message); + else + System.out.println("ContextListener: " + message); + + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/SessionListener.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/SessionListener.class new file mode 100644 index 0000000..22c53ea Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/SessionListener.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/SessionListener.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/SessionListener.java new file mode 100644 index 0000000..f03e48f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/listeners/SessionListener.java @@ -0,0 +1,160 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package listeners; + +import javax.servlet.ServletContext; +import javax.servlet.ServletContextEvent; +import javax.servlet.ServletContextListener; +import javax.servlet.http.HttpSessionAttributeListener; +import javax.servlet.http.HttpSessionBindingEvent; +import javax.servlet.http.HttpSessionEvent; +import javax.servlet.http.HttpSessionListener; + +/** + * Example listener for context-related application events, which were + * introduced in the 2.3 version of the Servlet API. This listener merely + * documents the occurrence of such events in the application log associated + * with our servlet context. + * + * @author Craig R. McClanahan + */ +public final class SessionListener implements ServletContextListener, + HttpSessionAttributeListener, HttpSessionListener { + + // ----------------------------------------------------- Instance Variables + + /** + * The servlet context with which we are associated. + */ + private ServletContext context = null; + + // --------------------------------------------------------- Public Methods + + /** + * Record the fact that a servlet context attribute was added. + * + * @param event + * The session attribute event + */ + @Override + public void attributeAdded(HttpSessionBindingEvent event) { + + log("attributeAdded('" + event.getSession().getId() + "', '" + + event.getName() + "', '" + event.getValue() + "')"); + + } + + /** + * Record the fact that a servlet context attribute was removed. + * + * @param event + * The session attribute event + */ + @Override + public void attributeRemoved(HttpSessionBindingEvent event) { + + log("attributeRemoved('" + event.getSession().getId() + "', '" + + event.getName() + "', '" + event.getValue() + "')"); + + } + + /** + * Record the fact that a servlet context attribute was replaced. + * + * @param event + * The session attribute event + */ + @Override + public void attributeReplaced(HttpSessionBindingEvent event) { + + log("attributeReplaced('" + event.getSession().getId() + "', '" + + event.getName() + "', '" + event.getValue() + "')"); + + } + + /** + * Record the fact that this web application has been destroyed. + * + * @param event + * The servlet context event + */ + @Override + public void contextDestroyed(ServletContextEvent event) { + + log("contextDestroyed()"); + this.context = null; + + } + + /** + * Record the fact that this web application has been initialized. + * + * @param event + * The servlet context event + */ + @Override + public void contextInitialized(ServletContextEvent event) { + + this.context = event.getServletContext(); + log("contextInitialized()"); + + } + + /** + * Record the fact that a session has been created. + * + * @param event + * The session event + */ + @Override + public void sessionCreated(HttpSessionEvent event) { + + log("sessionCreated('" + event.getSession().getId() + "')"); + + } + + /** + * Record the fact that a session has been destroyed. + * + * @param event + * The session event + */ + @Override + public void sessionDestroyed(HttpSessionEvent event) { + + log("sessionDestroyed('" + event.getSession().getId() + "')"); + + } + + // -------------------------------------------------------- Private Methods + + /** + * Log a message to the servlet context application log. + * + * @param message + * Message to be logged + */ + private void log(String message) { + + if (context != null) + context.log("SessionListener: " + message); + else + System.out.println("SessionListener: " + message); + + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/num/NumberGuessBean.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/num/NumberGuessBean.class new file mode 100644 index 0000000..e2051e9 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/num/NumberGuessBean.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/num/NumberGuessBean.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/num/NumberGuessBean.java new file mode 100644 index 0000000..1d3b1af --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/num/NumberGuessBean.java @@ -0,0 +1,99 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* + * Originally written by Jason Hunter, http://www.servlets.com. + */ + +package num; + +import java.io.Serializable; +import java.util.Random; + +public class NumberGuessBean implements Serializable { + + private static final long serialVersionUID = 1L; + + private int answer; + private String hint; + private int numGuesses; + private boolean success; + private Random random = new Random(); + + public NumberGuessBean() { + reset(); + } + + public int getAnswer() { + return answer; + } + + public void setAnswer(int answer) { + this.answer = answer; + } + + public String getHint() { + return "" + hint; + } + + public void setHint(String hint) { + this.hint = hint; + } + + public void setNumGuesses(int numGuesses) { + this.numGuesses = numGuesses; + } + + public int getNumGuesses() { + return numGuesses; + } + + public boolean getSuccess() { + return success; + } + + public void setSuccess(boolean success) { + this.success = success; + } + + public void setGuess(String guess) { + numGuesses++; + + int g; + try { + g = Integer.parseInt(guess); + } catch (NumberFormatException e) { + g = -1; + } + + if (g == answer) { + success = true; + } else if (g == -1) { + hint = "a number next time"; + } else if (g < answer) { + hint = "higher"; + } else if (g > answer) { + hint = "lower"; + } + } + + public void reset() { + answer = Math.abs(random.nextInt() % 100) + 1; + success = false; + numGuesses = 0; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/sessions/DummyCart.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/sessions/DummyCart.class new file mode 100644 index 0000000..2ad60c0 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/sessions/DummyCart.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/sessions/DummyCart.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/sessions/DummyCart.java new file mode 100644 index 0000000..2beda8e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/sessions/DummyCart.java @@ -0,0 +1,65 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package sessions; + +import java.util.Vector; + +public class DummyCart { + Vector v = new Vector(); + String submit = null; + String item = null; + + private void addItem(String name) { + v.addElement(name); + } + + private void removeItem(String name) { + v.removeElement(name); + } + + public void setItem(String name) { + item = name; + } + + public void setSubmit(String s) { + submit = s; + } + + public String[] getItems() { + String[] s = new String[v.size()]; + v.copyInto(s); + return s; + } + + public void processRequest() { + // null value for submit - user hit enter instead of clicking on + // "add" or "remove" + if (submit == null || submit.equals("add")) + addItem(item); + else if (submit.equals("remove")) + removeItem(item); + + // reset at the end of the request + reset(); + } + + // reset + private void reset() { + submit = null; + item = null; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/CookieFilter.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/CookieFilter.class new file mode 100644 index 0000000..44f4d69 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/CookieFilter.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/CookieFilter.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/CookieFilter.java new file mode 100644 index 0000000..19243ee --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/CookieFilter.java @@ -0,0 +1,85 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package util; + +import java.util.Locale; +import java.util.StringTokenizer; + +/** + * Processes a cookie header and attempts to obfuscate any cookie values that + * represent session IDs from other web applications. Since session cookie names + * are configurable, as are session ID lengths, this filter is not expected to + * be 100% effective. + * + * It is required that the examples web application is removed in security + * conscious environments as documented in the Security How-To. This filter is + * intended to reduce the impact of failing to follow that advice. A failure by + * this filter to obfuscate a session ID or similar value is not a security + * vulnerability. In such instances the vulnerability is the failure to remove + * the examples web application. + */ +public class CookieFilter { + + private static final String OBFUSCATED = "[obfuscated]"; + + private CookieFilter() { + // Hide default constructor + } + + public static String filter(String cookieHeader, String sessionId) { + + StringBuilder sb = new StringBuilder(cookieHeader.length()); + + // Cookie name value pairs are ';' separated. + // Session IDs don't use ; in the value so don't worry about quoted + // values that contain ; + StringTokenizer st = new StringTokenizer(cookieHeader, ";"); + + boolean first = true; + while (st.hasMoreTokens()) { + if (first) { + first = false; + } else { + sb.append(';'); + } + sb.append(filterNameValuePair(st.nextToken(), sessionId)); + } + + + return sb.toString(); + } + + private static String filterNameValuePair(String input, String sessionId) { + int i = input.indexOf('='); + if (i == -1) { + return input; + } + String name = input.substring(0, i); + String value = input.substring(i + 1, input.length()); + + return name + "=" + filter(name, value, sessionId); + } + + public static String filter(String cookieName, String cookieValue, String sessionId) { + if (cookieName.toLowerCase(Locale.ENGLISH).contains("jsessionid") && + (sessionId == null || !cookieValue.contains(sessionId))) { + cookieValue = OBFUSCATED; + } + + return cookieValue; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/HTMLFilter.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/HTMLFilter.class new file mode 100644 index 0000000..69ecbe1 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/HTMLFilter.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/HTMLFilter.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/HTMLFilter.java new file mode 100644 index 0000000..938bb5a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/util/HTMLFilter.java @@ -0,0 +1,68 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ +package util; + +/** + * HTML filter utility. + * + * @author Craig R. McClanahan + * @author Tim Tye + */ +public final class HTMLFilter { + + + /** + * Filter the specified message string for characters that are sensitive + * in HTML. This avoids potential attacks caused by including JavaScript + * codes in the request URL that is often reported in error messages. + * + * @param message The message string to be filtered + * + * @return the filtered version of the message + */ + public static String filter(String message) { + + if (message == null) + return null; + + char content[] = new char[message.length()]; + message.getChars(0, message.length(), content, 0); + StringBuilder result = new StringBuilder(content.length + 50); + for (char c : content) { + switch (c) { + case '<': + result.append("<"); + break; + case '>': + result.append(">"); + break; + case '&': + result.append("&"); + break; + case '"': + result.append("""); + break; + default: + result.append(c); + } + } + return result.toString(); + } + + +} + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/validators/DebugValidator.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/validators/DebugValidator.class new file mode 100644 index 0000000..4a9fb4c Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/validators/DebugValidator.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/validators/DebugValidator.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/validators/DebugValidator.java new file mode 100644 index 0000000..d0ac758 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/validators/DebugValidator.java @@ -0,0 +1,84 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + + +package validators; + + +import java.io.IOException; +import java.io.InputStream; + +import javax.servlet.jsp.tagext.PageData; +import javax.servlet.jsp.tagext.TagLibraryValidator; +import javax.servlet.jsp.tagext.ValidationMessage; + + +/** + * Example tag library validator that simply dumps the XML version of each + * page to standard output (which will typically be sent to the file + * $CATALINA_HOME/logs/catalina.out). To utilize it, simply + * include a taglib directive for this tag library at the top + * of your JSP page. + * + * @author Craig McClanahan + */ +public class DebugValidator extends TagLibraryValidator { + + + // ----------------------------------------------------- Instance Variables + + + // --------------------------------------------------------- Public Methods + + + /** + * Validate a JSP page. This will get invoked once per directive in the + * JSP page. This method will return null if the page is + * valid; otherwise the method should return an array of + * ValidationMessage objects. An array of length zero is + * also interpreted as no errors. + * + * @param prefix The value of the prefix argument in this directive + * @param uri The value of the URI argument in this directive + * @param page The page data for this page + */ + @Override + public ValidationMessage[] validate(String prefix, String uri, + PageData page) { + + System.out.println("---------- Prefix=" + prefix + " URI=" + uri + + "----------"); + + InputStream is = page.getInputStream(); + while (true) { + try { + int ch = is.read(); + if (ch < 0) + break; + System.out.print((char) ch); + } catch (IOException e) { + break; + } + } + System.out.println(); + System.out.println("-----------------------------------------------"); + return (null); + + } + + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/ExamplesConfig.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/ExamplesConfig.class new file mode 100644 index 0000000..188802e Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/ExamplesConfig.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/ExamplesConfig.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/ExamplesConfig.java new file mode 100644 index 0000000..8b37b12 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/ExamplesConfig.java @@ -0,0 +1,66 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket; + +import java.util.HashSet; +import java.util.Set; + +import javax.websocket.Endpoint; +import javax.websocket.server.ServerApplicationConfig; +import javax.websocket.server.ServerEndpointConfig; + +import websocket.drawboard.DrawboardEndpoint; +import websocket.echo.EchoEndpoint; + +public class ExamplesConfig implements ServerApplicationConfig { + + @Override + public Set getEndpointConfigs( + Set> scanned) { + + Set result = new HashSet(); + + if (scanned.contains(EchoEndpoint.class)) { + result.add(ServerEndpointConfig.Builder.create( + EchoEndpoint.class, + "/websocket/echoProgrammatic").build()); + } + + if (scanned.contains(DrawboardEndpoint.class)) { + result.add(ServerEndpointConfig.Builder.create( + DrawboardEndpoint.class, + "/websocket/drawboard").build()); + } + + return result; + } + + + @Override + public Set> getAnnotatedEndpointClasses(Set> scanned) { + // Deploy all WebSocket endpoints defined by annotations in the examples + // web application. Filter out all others to avoid issues when running + // tests on Gump + Set> results = new HashSet>(); + for (Class clazz : scanned) { + if (clazz.getPackage().getName().startsWith("websocket.")) { + results.add(clazz); + } + } + return results; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/chat/ChatAnnotation.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/chat/ChatAnnotation.class new file mode 100644 index 0000000..154bd54 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/chat/ChatAnnotation.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/chat/ChatAnnotation.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/chat/ChatAnnotation.java new file mode 100644 index 0000000..e84d25b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/chat/ChatAnnotation.java @@ -0,0 +1,109 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.chat; + +import java.io.IOException; +import java.util.Set; +import java.util.concurrent.CopyOnWriteArraySet; +import java.util.concurrent.atomic.AtomicInteger; + +import javax.websocket.OnClose; +import javax.websocket.OnError; +import javax.websocket.OnMessage; +import javax.websocket.OnOpen; +import javax.websocket.Session; +import javax.websocket.server.ServerEndpoint; + +import org.apache.juli.logging.Log; +import org.apache.juli.logging.LogFactory; + +import util.HTMLFilter; + +@ServerEndpoint(value = "/websocket/chat") +public class ChatAnnotation { + + private static final Log log = LogFactory.getLog(ChatAnnotation.class); + + private static final String GUEST_PREFIX = "Guest"; + private static final AtomicInteger connectionIds = new AtomicInteger(0); + private static final Set connections = + new CopyOnWriteArraySet(); + + private final String nickname; + private Session session; + + public ChatAnnotation() { + nickname = GUEST_PREFIX + connectionIds.getAndIncrement(); + } + + + @OnOpen + public void start(Session session) { + this.session = session; + connections.add(this); + String message = String.format("* %s %s", nickname, "has joined."); + broadcast(message); + } + + + @OnClose + public void end() { + connections.remove(this); + String message = String.format("* %s %s", + nickname, "has disconnected."); + broadcast(message); + } + + + @OnMessage + public void incoming(String message) { + // Never trust the client + String filteredMessage = String.format("%s: %s", + nickname, HTMLFilter.filter(message.toString())); + broadcast(filteredMessage); + } + + + + + @OnError + public void onError(Throwable t) throws Throwable { + log.error("Chat Error: " + t.toString(), t); + } + + + private static void broadcast(String msg) { + for (ChatAnnotation client : connections) { + try { + synchronized (client) { + client.session.getBasicRemote().sendText(msg); + } + } catch (IOException e) { + log.debug("Chat Error: Failed to send message to client", e); + connections.remove(client); + try { + client.session.close(); + } catch (IOException e1) { + // Ignore + } + String message = String.format("* %s %s", + client.nickname, "has been disconnected."); + broadcast(message); + } + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client$1.class new file mode 100644 index 0000000..c152c6b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client.class new file mode 100644 index 0000000..53bb52a Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client.java new file mode 100644 index 0000000..bedf847 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Client.java @@ -0,0 +1,233 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard; + +import java.io.IOException; +import java.util.LinkedList; + +import javax.websocket.CloseReason; +import javax.websocket.CloseReason.CloseCodes; +import javax.websocket.RemoteEndpoint.Async; +import javax.websocket.SendHandler; +import javax.websocket.SendResult; +import javax.websocket.Session; + +import websocket.drawboard.wsmessages.AbstractWebsocketMessage; +import websocket.drawboard.wsmessages.BinaryWebsocketMessage; +import websocket.drawboard.wsmessages.CloseWebsocketMessage; +import websocket.drawboard.wsmessages.StringWebsocketMessage; + +/** + * Represents a client with methods to send messages asynchronously. + */ +public class Client { + + private final Session session; + private final Async async; + + /** + * Contains the messages which are buffered until the previous + * send operation has finished. + */ + private final LinkedList messagesToSend = + new LinkedList(); + /** + * If this client is currently sending a messages asynchronously. + */ + private volatile boolean isSendingMessage = false; + /** + * If this client is closing. If true, new messages to + * send will be ignored. + */ + private volatile boolean isClosing = false; + /** + * The length of all current buffered messages, to avoid iterating + * over a linked list. + */ + private volatile long messagesToSendLength = 0; + + public Client(Session session) { + this.session = session; + this.async = session.getAsyncRemote(); + } + + /** + * Asynchronously closes the Websocket session. This will wait until all + * remaining messages have been sent to the Client and then close + * the Websocket session. + */ + public void close() { + sendMessage(new CloseWebsocketMessage()); + } + + /** + * Sends the given message asynchronously to the client. + * If there is already a async sending in progress, then the message + * will be buffered and sent when possible.

    + * + * This method can be called from multiple threads. + * @param msg + */ + public void sendMessage(AbstractWebsocketMessage msg) { + synchronized (messagesToSend) { + if (!isClosing) { + // Check if we have a Close message + if (msg instanceof CloseWebsocketMessage) { + isClosing = true; + } + + if (isSendingMessage) { + // Check if the buffered messages exceed + // a specific amount - in that case, disconnect the client + // to prevent DoS. + // In this case we check if there are >= 1000 messages + // or length(of all messages) >= 1000000 bytes. + if (messagesToSend.size() >= 1000 + || messagesToSendLength >= 1000000) { + isClosing = true; + + // Discard the new message and close the session immediately. + CloseReason cr = new CloseReason( + CloseCodes.VIOLATED_POLICY, + "Send Buffer exceeded"); + try { + // TODO: close() may block if the remote endpoint doesn't read the data + // (eventually there will be a TimeoutException). However, this method + // (sendMessage) is intended to run asynchronous code and shouldn't + // block. Otherwise it would temporarily stop processing of messages + // from other clients. + // Maybe call this method on another thread. + // Note that when this method is called, the RemoteEndpoint.Async + // is still in the process of sending data, so there probably should + // be another way to cancel the Websocket connection. + // Ideally, there should be some method that cancels the connection + // immediately... + session.close(cr); + } catch (IOException e) { + // Ignore + } + + } else { + + // Check if the last message and the new message are + // String messages - in that case we concatenate them + // to reduce TCP overhead (using ";" as separator). + if (msg instanceof StringWebsocketMessage + && !messagesToSend.isEmpty() + && messagesToSend.getLast() + instanceof StringWebsocketMessage) { + + StringWebsocketMessage ms = + (StringWebsocketMessage) messagesToSend.removeLast(); + messagesToSendLength -= calculateMessageLength(ms); + + String concatenated = ms.getString() + ";" + + ((StringWebsocketMessage) msg).getString(); + msg = new StringWebsocketMessage(concatenated); + } + + messagesToSend.add(msg); + messagesToSendLength += calculateMessageLength(msg); + } + } else { + isSendingMessage = true; + internalSendMessageAsync(msg); + } + } + + } + } + + private long calculateMessageLength(AbstractWebsocketMessage msg) { + if (msg instanceof BinaryWebsocketMessage) { + return ((BinaryWebsocketMessage) msg).getBytes().capacity(); + } else if (msg instanceof StringWebsocketMessage) { + return ((StringWebsocketMessage) msg).getString().length() * 2; + } + + return 0; + } + + /** + * Internally sends the messages asynchronously. + * @param msg + */ + private void internalSendMessageAsync(AbstractWebsocketMessage msg) { + try { + if (msg instanceof StringWebsocketMessage) { + StringWebsocketMessage sMsg = (StringWebsocketMessage) msg; + async.sendText(sMsg.getString(), sendHandler); + + } else if (msg instanceof BinaryWebsocketMessage) { + BinaryWebsocketMessage bMsg = (BinaryWebsocketMessage) msg; + async.sendBinary(bMsg.getBytes(), sendHandler); + + } else if (msg instanceof CloseWebsocketMessage) { + // Close the session. + session.close(); + } + } catch (IllegalStateException ex) { + // Trying to write to the client when the session has + // already been closed. + // Ignore + } catch (IOException ex) { + // Trying to write to the client when the session has + // already been closed. + // Ignore + } + } + + + + /** + * SendHandler that will continue to send buffered messages. + */ + private final SendHandler sendHandler = new SendHandler() { + @Override + public void onResult(SendResult result) { + if (!result.isOK()) { + // Message could not be sent. In this case, we don't + // set isSendingMessage to false because we must assume the connection + // broke (and onClose will be called), so we don't try to send + // other messages. + // As a precaution, we close the session (e.g. if a send timeout occurred). + // TODO: session.close() blocks, while this handler shouldn't block. + // Ideally, there should be some method that cancels the connection + // immediately... + try { + session.close(); + } catch (IOException ex) { + // Ignore + } + } + synchronized (messagesToSend) { + + if (!messagesToSend.isEmpty()) { + AbstractWebsocketMessage msg = messagesToSend.remove(); + messagesToSendLength -= calculateMessageLength(msg); + + internalSendMessageAsync(msg); + + } else { + isSendingMessage = false; + } + + } + } + }; + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage$ParseException.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage$ParseException.class new file mode 100644 index 0000000..51943a6 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage$ParseException.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage.class new file mode 100644 index 0000000..f37e237 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage.java new file mode 100644 index 0000000..52d7971 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawMessage.java @@ -0,0 +1,270 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard; + +import java.awt.BasicStroke; +import java.awt.Color; +import java.awt.Graphics2D; +import java.awt.geom.Arc2D; +import java.awt.geom.Line2D; +import java.awt.geom.Rectangle2D; + +/** + * A message that represents a drawing action. + * Note that we use primitive types instead of Point, Color etc. + * to reduce object allocation.

    + * + * TODO: But a Color objects needs to be created anyway for drawing this + * onto a Graphics2D object, so this probably does not save much. + */ +public final class DrawMessage { + + private int type; + private byte colorR, colorG, colorB, colorA; + private double thickness; + private double x1, y1, x2, y2; + private boolean lastInChain; + + /** + * The type.
    + * 1: Brush
    + * 2: Line
    + * 3: Rectangle
    + * 4: Ellipse + */ + public int getType() { + return type; + } + public void setType(int type) { + this.type = type; + } + + public double getThickness() { + return thickness; + } + public void setThickness(double thickness) { + this.thickness = thickness; + } + + public byte getColorR() { + return colorR; + } + public void setColorR(byte colorR) { + this.colorR = colorR; + } + public byte getColorG() { + return colorG; + } + public void setColorG(byte colorG) { + this.colorG = colorG; + } + public byte getColorB() { + return colorB; + } + public void setColorB(byte colorB) { + this.colorB = colorB; + } + public byte getColorA() { + return colorA; + } + public void setColorA(byte colorA) { + this.colorA = colorA; + } + + public double getX1() { + return x1; + } + public void setX1(double x1) { + this.x1 = x1; + } + public double getX2() { + return x2; + } + public void setX2(double x2) { + this.x2 = x2; + } + public double getY1() { + return y1; + } + public void setY1(double y1) { + this.y1 = y1; + } + public double getY2() { + return y2; + } + public void setY2(double y2) { + this.y2 = y2; + } + + /** + * Specifies if this DrawMessage is the last one in a chain + * (e.g. a chain of brush paths).
    + * Currently it is unused. + */ + public boolean isLastInChain() { + return lastInChain; + } + public void setLastInChain(boolean lastInChain) { + this.lastInChain = lastInChain; + } + + + + public DrawMessage(int type, byte colorR, byte colorG, byte colorB, + byte colorA, double thickness, double x1, double x2, double y1, + double y2, boolean lastInChain) { + + this.type = type; + this.colorR = colorR; + this.colorG = colorG; + this.colorB = colorB; + this.colorA = colorA; + this.thickness = thickness; + this.x1 = x1; + this.x2 = x2; + this.y1 = y1; + this.y2 = y2; + this.lastInChain = lastInChain; + } + + + /** + * Draws this DrawMessage onto the given Graphics2D. + * @param g + */ + public void draw(Graphics2D g) { + + g.setStroke(new BasicStroke((float) thickness, + BasicStroke.CAP_ROUND, BasicStroke.JOIN_MITER)); + g.setColor(new Color(colorR & 0xFF, colorG & 0xFF, colorB & 0xFF, + colorA & 0xFF)); + + if (x1 == x2 && y1 == y2) { + // Always draw as arc to meet the behavior in the HTML5 Canvas. + Arc2D arc = new Arc2D.Double(x1, y1, 0, 0, + 0d, 360d, Arc2D.OPEN); + g.draw(arc); + + } else if (type == 1 || type == 2) { + // Draw a line. + Line2D line = new Line2D.Double(x1, y1, x2, y2); + g.draw(line); + + } else if (type == 3 || type == 4) { + double x1 = this.x1, x2 = this.x2, + y1 = this.y1, y2 = this.y2; + if (x1 > x2) { + x1 = this.x2; + x2 = this.x1; + } + if (y1 > y2) { + y1 = this.y2; + y2 = this.y1; + } + + // TODO: If (x1 == x2 || y1 == y2) draw as line. + + if (type == 3) { + // Draw a rectangle. + Rectangle2D rect = new Rectangle2D.Double(x1, y1, + x2 - x1, y2 - y1); + g.draw(rect); + + } else if (type == 4) { + // Draw an ellipse. + Arc2D arc = new Arc2D.Double(x1, y1, x2 - x1, y2 - y1, + 0d, 360d, Arc2D.OPEN); + g.draw(arc); + + } + } + } + + /** + * Converts this message into a String representation that + * can be sent over WebSocket.
    + * Since a DrawMessage consists only of numbers, + * we concatenate those numbers with a ",". + */ + @Override + public String toString() { + + return type + "," + (colorR & 0xFF) + "," + (colorG & 0xFF) + "," + + (colorB & 0xFF) + "," + (colorA & 0xFF) + "," + thickness + + "," + x1 + "," + y1 + "," + x2 + "," + y2 + "," + + (lastInChain ? "1" : "0"); + } + + public static DrawMessage parseFromString(String str) + throws ParseException { + + int type; + byte[] colors = new byte[4]; + double thickness; + double[] coords = new double[4]; + boolean last; + + try { + String[] elements = str.split(","); + + type = Integer.parseInt(elements[0]); + if (!(type >= 1 && type <= 4)) + throw new ParseException("Invalid type: " + type); + + for (int i = 0; i < colors.length; i++) { + colors[i] = (byte) Integer.parseInt(elements[1 + i]); + } + + thickness = Double.parseDouble(elements[5]); + if (Double.isNaN(thickness) || thickness < 0 || thickness > 100) + throw new ParseException("Invalid thickness: " + thickness); + + for (int i = 0; i < coords.length; i++) { + coords[i] = Double.parseDouble(elements[6 + i]); + if (Double.isNaN(coords[i])) + throw new ParseException("Invalid coordinate: " + + coords[i]); + } + + last = !"0".equals(elements[10]); + + } catch (RuntimeException ex) { + throw new ParseException(ex); + } + + DrawMessage m = new DrawMessage(type, colors[0], colors[1], + colors[2], colors[3], thickness, coords[0], coords[2], + coords[1], coords[3], last); + + return m; + } + + public static class ParseException extends Exception { + private static final long serialVersionUID = -6651972769789842960L; + + public ParseException(Throwable root) { + super(root); + } + + public ParseException(String message) { + super(message); + } + } + + + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.class new file mode 100644 index 0000000..f6724e6 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java new file mode 100644 index 0000000..dd022ba --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java @@ -0,0 +1,37 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard; + +import javax.servlet.ServletContextEvent; +import javax.servlet.ServletContextListener; + +public final class DrawboardContextListener implements ServletContextListener { + + @Override + public void contextInitialized(ServletContextEvent sce) { + // NO-OP + } + + @Override + public void contextDestroyed(ServletContextEvent sce) { + // Shutdown our room. + Room room = DrawboardEndpoint.getRoom(false); + if (room != null) { + room.shutdown(); + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$1.class new file mode 100644 index 0000000..3add6a1 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$2.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$2.class new file mode 100644 index 0000000..ee2f923 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$2.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$3$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$3$1.class new file mode 100644 index 0000000..86ff72e Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$3$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$3.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$3.class new file mode 100644 index 0000000..9a9499e Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint$3.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.class new file mode 100644 index 0000000..5f35890 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java new file mode 100644 index 0000000..5851bac --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java @@ -0,0 +1,236 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard; + +import java.io.EOFException; +import java.io.IOException; + +import javax.websocket.CloseReason; +import javax.websocket.Endpoint; +import javax.websocket.EndpointConfig; +import javax.websocket.MessageHandler; +import javax.websocket.Session; + +import org.apache.juli.logging.Log; +import org.apache.juli.logging.LogFactory; + +import websocket.drawboard.DrawMessage.ParseException; +import websocket.drawboard.wsmessages.StringWebsocketMessage; + + +public final class DrawboardEndpoint extends Endpoint { + + private static final Log log = + LogFactory.getLog(DrawboardEndpoint.class); + + + /** + * Our room where players can join. + */ + private static volatile Room room = null; + private static final Object roomLock = new Object(); + + public static Room getRoom(boolean create) { + if (create) { + if (room == null) { + synchronized (roomLock) { + if (room == null) { + room = new Room(); + } + } + } + return room; + } else { + return room; + } + } + + /** + * The player that is associated with this Endpoint and the current room. + * Note that this variable is only accessed from the Room Thread.

    + * + * TODO: Currently, Tomcat uses an Endpoint instance once - however + * the java doc of endpoint says: + * "Each instance of a websocket endpoint is guaranteed not to be called by + * more than one thread at a time per active connection." + * This could mean that after calling onClose(), the instance + * could be reused for another connection so onOpen() will get called + * (possibly from another thread).
    + * If this is the case, we would need a variable holder for the variables + * that are accessed by the Room thread, and read the reference to the holder + * at the beginning of onOpen, onMessage, onClose methods to ensure the room + * thread always gets the correct instance of the variable holder. + */ + private Room.Player player; + + + @Override + public void onOpen(Session session, EndpointConfig config) { + // Set maximum messages size to 10.000 bytes. + session.setMaxTextMessageBufferSize(10000); + session.addMessageHandler(stringHandler); + final Client client = new Client(session); + + final Room room = getRoom(true); + room.invokeAndWait(new Runnable() { + @Override + public void run() { + try { + + // Create a new Player and add it to the room. + try { + player = room.createAndAddPlayer(client); + } catch (IllegalStateException ex) { + // Probably the max. number of players has been + // reached. + client.sendMessage(new StringWebsocketMessage( + "0" + ex.getLocalizedMessage())); + // Close the connection. + client.close(); + } + + } catch (RuntimeException ex) { + log.error("Unexpected exception: " + ex.toString(), ex); + } + } + }); + + } + + + @Override + public void onClose(Session session, CloseReason closeReason) { + Room room = getRoom(false); + if (room != null) { + room.invokeAndWait(new Runnable() { + @Override + public void run() { + try { + // Player can be null if it couldn't enter the room + if (player != null) { + // Remove this player from the room. + player.removeFromRoom(); + + // Set player to null to prevent NPEs when onMessage events + // are processed (from other threads) after onClose has been + // called from different thread which closed the Websocket session. + player = null; + } + } catch (RuntimeException ex) { + log.error("Unexpected exception: " + ex.toString(), ex); + } + } + }); + } + } + + + + @Override + public void onError(Session session, Throwable t) { + // Most likely cause is a user closing their browser. Check to see if + // the root cause is EOF and if it is ignore it. + // Protect against infinite loops. + int count = 0; + Throwable root = t; + while (root.getCause() != null && count < 20) { + root = root.getCause(); + count ++; + } + if (root instanceof EOFException) { + // Assume this is triggered by the user closing their browser and + // ignore it. + } else if (!session.isOpen() && root instanceof IOException) { + // IOException after close. Assume this is a variation of the user + // closing their browser (or refreshing very quickly) and ignore it. + } else { + log.error("onError: " + t.toString(), t); + } + } + + + + private final MessageHandler.Whole stringHandler = + new MessageHandler.Whole() { + + @Override + public void onMessage(final String message) { + // Invoke handling of the message in the room. + room.invokeAndWait(new Runnable() { + @Override + public void run() { + try { + + // Currently, the only types of messages the client will send + // are draw messages prefixed by a Message ID + // (starting with char '1'), and pong messages (starting + // with char '0'). + // Draw messages should look like this: + // ID|type,colR,colB,colG,colA,thickness,x1,y1,x2,y2,lastInChain + + boolean dontSwallowException = false; + try { + char messageType = message.charAt(0); + String messageContent = message.substring(1); + switch (messageType) { + case '0': + // Pong message. + // Do nothing. + break; + + case '1': + // Draw message + int indexOfChar = messageContent.indexOf('|'); + long msgId = Long.parseLong( + messageContent.substring(0, indexOfChar)); + + DrawMessage msg = DrawMessage.parseFromString( + messageContent.substring(indexOfChar + 1)); + + // Don't ignore RuntimeExceptions thrown by + // this method + // TODO: Find a better solution than this variable + dontSwallowException = true; + if (player != null) { + player.handleDrawMessage(msg, msgId); + } + dontSwallowException = false; + + break; + } + + } catch (RuntimeException ex) { + // Client sent invalid data. + // Ignore, TODO: maybe close connection + if (dontSwallowException) { + throw ex; + } + } catch (ParseException ex) { + // Client sent invalid data. + // Ignore, TODO: maybe close connection + } + } catch (RuntimeException ex) { + log.error("Unexpected exception: " + ex.toString(), ex); + } + } + }); + + } + }; + + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$1$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$1$1.class new file mode 100644 index 0000000..604acea Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$1$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$1.class new file mode 100644 index 0000000..ba034ac Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$2.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$2.class new file mode 100644 index 0000000..6ef92d7 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$2.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$MessageType.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$MessageType.class new file mode 100644 index 0000000..1e5b6bc Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$MessageType.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$Player.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$Player.class new file mode 100644 index 0000000..bf50834 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room$Player.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room.class new file mode 100644 index 0000000..56c4b9f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room.java new file mode 100644 index 0000000..3ffe39b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/Room.java @@ -0,0 +1,490 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard; + +import java.awt.Color; +import java.awt.Graphics2D; +import java.awt.RenderingHints; +import java.awt.image.BufferedImage; +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.nio.ByteBuffer; +import java.util.ArrayList; +import java.util.List; +import java.util.Timer; +import java.util.TimerTask; +import java.util.concurrent.locks.ReentrantLock; + +import javax.imageio.ImageIO; + +import websocket.drawboard.wsmessages.BinaryWebsocketMessage; +import websocket.drawboard.wsmessages.StringWebsocketMessage; + +/** + * A Room represents a drawboard where a number of + * users participate.

    + * + * Note: Instance methods should only be invoked by calling + * {@link #invokeAndWait(Runnable)} to ensure access is correctly synchronized. + */ +public final class Room { + + /** + * Specifies the type of a room message that is sent to a client.
    + * Note: Currently we are sending simple string messages - for production + * apps, a JSON lib should be used for object-level messages.

    + * + * The number (single char) will be prefixed to the string when sending + * the message. + */ + public static enum MessageType { + /** + * '0': Error: contains error message. + */ + ERROR('0'), + /** + * '1': DrawMessage: contains serialized DrawMessage(s) prefixed + * with the current Player's {@link Player#lastReceivedMessageId} + * and ",".
    + * Multiple draw messages are concatenated with "|" as separator. + */ + DRAW_MESSAGE('1'), + /** + * '2': ImageMessage: Contains number of current players in this room. + * After this message a Binary Websocket message will follow, + * containing the current Room image as PNG.
    + * This is the first message that a Room sends to a new Player. + */ + IMAGE_MESSAGE('2'), + /** + * '3': PlayerChanged: contains "+" or "-" which indicate a player + * was added or removed to this Room. + */ + PLAYER_CHANGED('3'); + + private final char flag; + + private MessageType(char flag) { + this.flag = flag; + } + + } + + + /** + * The lock used to synchronize access to this Room. + */ + private final ReentrantLock roomLock = new ReentrantLock(); + + /** + * Indicates if this room has already been shutdown. + */ + private volatile boolean closed = false; + + /** + * If true, outgoing DrawMessages will be buffered until the + * drawmessageBroadcastTimer ticks. Otherwise they will be sent + * immediately. + */ + private static final boolean BUFFER_DRAW_MESSAGES = true; + + /** + * A timer which sends buffered drawmessages to the client at once + * at a regular interval, to avoid sending a lot of very small + * messages which would cause TCP overhead and high CPU usage. + */ + private final Timer drawmessageBroadcastTimer = new Timer(); + + private static final int TIMER_DELAY = 30; + + /** + * The current active broadcast timer task. If null, then no Broadcast task is scheduled. + * The Task will be scheduled if the first player enters the Room, and + * cancelled if the last player exits the Room, to avoid unnecessary timer executions. + */ + private TimerTask activeBroadcastTimerTask; + + + /** + * The current image of the room drawboard. DrawMessages that are + * received from Players will be drawn onto this image. + */ + private final BufferedImage roomImage = + new BufferedImage(900, 600, BufferedImage.TYPE_INT_RGB); + private final Graphics2D roomGraphics = roomImage.createGraphics(); + + + /** + * The maximum number of players that can join this room. + */ + private static final int MAX_PLAYER_COUNT = 100; + + /** + * List of all currently joined players. + */ + private final List players = new ArrayList(); + + + + public Room() { + roomGraphics.setRenderingHint(RenderingHints.KEY_ANTIALIASING, + RenderingHints.VALUE_ANTIALIAS_ON); + + // Clear the image with white background. + roomGraphics.setBackground(Color.WHITE); + roomGraphics.clearRect(0, 0, roomImage.getWidth(), + roomImage.getHeight()); + } + + private TimerTask createBroadcastTimerTask() { + return new TimerTask() { + @Override + public void run() { + invokeAndWait(new Runnable() { + @Override + public void run() { + broadcastTimerTick(); + } + }); + } + }; + } + + /** + * Creates a Player from the given Client and adds it to this room. + * @param client the client + */ + public Player createAndAddPlayer(Client client) { + if (players.size() >= MAX_PLAYER_COUNT) { + throw new IllegalStateException("Maximum player count (" + + MAX_PLAYER_COUNT + ") has been reached."); + } + + Player p = new Player(this, client); + + // Broadcast to the other players that one player joined. + broadcastRoomMessage(MessageType.PLAYER_CHANGED, "+"); + + // Add the new player to the list. + players.add(p); + + // If currently no Broadcast Timer Task is scheduled, then we need to create one. + if (activeBroadcastTimerTask == null) { + activeBroadcastTimerTask = createBroadcastTimerTask(); + drawmessageBroadcastTimer.schedule(activeBroadcastTimerTask, + TIMER_DELAY, TIMER_DELAY); + } + + // Send him the current number of players and the current room image. + String content = String.valueOf(players.size()); + p.sendRoomMessage(MessageType.IMAGE_MESSAGE, content); + + // Store image as PNG + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + try { + ImageIO.write(roomImage, "PNG", bout); + } catch (IOException e) { /* Should never happen */ } + + + // Send the image as binary message. + BinaryWebsocketMessage msg = new BinaryWebsocketMessage( + ByteBuffer.wrap(bout.toByteArray())); + p.getClient().sendMessage(msg); + + return p; + + } + + /** + * @see Player#removeFromRoom() + * @param p + */ + private void internalRemovePlayer(Player p) { + boolean removed = players.remove(p); + assert removed; + + // If the last player left the Room, we need to cancel the Broadcast Timer Task. + if (players.size() == 0) { + // Cancel the task. + // Note that it can happen that the TimerTask is just about to execute (from + // the Timer thread) but waits until all players are gone (or even until a new + // player is added to the list), and then executes. This is OK. To prevent it, + // a TimerTask subclass would need to have some boolean "cancel" instance variable and + // query it in the invocation of Room#invokeAndWait. + activeBroadcastTimerTask.cancel(); + activeBroadcastTimerTask = null; + } + + // Broadcast that one player is removed. + broadcastRoomMessage(MessageType.PLAYER_CHANGED, "-"); + } + + /** + * @see Player#handleDrawMessage(DrawMessage, long) + * @param p + * @param msg + * @param msgId + */ + private void internalHandleDrawMessage(Player p, DrawMessage msg, + long msgId) { + p.setLastReceivedMessageId(msgId); + + // Draw the RoomMessage onto our Room Image. + msg.draw(roomGraphics); + + // Broadcast the Draw Message. + broadcastDrawMessage(msg); + } + + + /** + * Broadcasts the given drawboard message to all connected players.
    + * Note: For DrawMessages, please use + * {@link #broadcastDrawMessage(DrawMessage)} + * as this method will buffer them and prefix them with the correct + * last received Message ID. + * @param type + * @param content + */ + private void broadcastRoomMessage(MessageType type, String content) { + for (Player p : players) { + p.sendRoomMessage(type, content); + } + } + + + /** + * Broadcast the given DrawMessage. This will buffer the message + * and the {@link #drawmessageBroadcastTimer} will broadcast them + * at a regular interval, prefixing them with the player's current + * {@link Player#lastReceivedMessageId}. + * @param msg + */ + private void broadcastDrawMessage(DrawMessage msg) { + if (!BUFFER_DRAW_MESSAGES) { + String msgStr = msg.toString(); + + for (Player p : players) { + String s = String.valueOf(p.getLastReceivedMessageId()) + + "," + msgStr; + p.sendRoomMessage(MessageType.DRAW_MESSAGE, s); + } + } else { + for (Player p : players) { + p.getBufferedDrawMessages().add(msg); + } + } + } + + + /** + * Tick handler for the broadcastTimer. + */ + private void broadcastTimerTick() { + // For each Player, send all per Player buffered + // DrawMessages, prefixing each DrawMessage with the player's + // lastReceivedMessageId. + // Multiple messages are concatenated with "|". + + for (Player p : players) { + + StringBuilder sb = new StringBuilder(); + List drawMessages = p.getBufferedDrawMessages(); + + if (drawMessages.size() > 0) { + for (int i = 0; i < drawMessages.size(); i++) { + DrawMessage msg = drawMessages.get(i); + + String s = String.valueOf(p.getLastReceivedMessageId()) + + "," + msg.toString(); + if (i > 0) + sb.append("|"); + + sb.append(s); + } + drawMessages.clear(); + + p.sendRoomMessage(MessageType.DRAW_MESSAGE, sb.toString()); + } + } + } + + /** + * A list of cached {@link Runnable}s to prevent recursive invocation of Runnables + * by one thread. This variable is only used by one thread at a time and then + * set to null. + */ + private List cachedRunnables = null; + + /** + * Submits the given Runnable to the Room Executor and waits until it + * has been executed. Currently, this simply means that the Runnable + * will be run directly inside of a synchronized() block.
    + * Note that if a runnable recursively calls invokeAndWait() with another + * runnable on this Room, it will not be executed recursively, but instead + * cached until the original runnable is finished, to keep the behavior of + * using a Executor. + * @param task + */ + public void invokeAndWait(Runnable task) { + + // Check if the current thread already holds a lock on this room. + // If yes, then we must not directly execute the Runnable but instead + // cache it until the original invokeAndWait() has finished. + if (roomLock.isHeldByCurrentThread()) { + + if (cachedRunnables == null) { + cachedRunnables = new ArrayList(); + } + cachedRunnables.add(task); + + } else { + + roomLock.lock(); + try { + // Explicitly overwrite value to ensure data consistency in + // current thread + cachedRunnables = null; + + if (!closed) { + task.run(); + } + + // Run the cached runnables. + if (cachedRunnables != null) { + for (Runnable cachedRunnable : cachedRunnables) { + if (!closed) { + cachedRunnable.run(); + } + } + cachedRunnables = null; + } + + } finally { + roomLock.unlock(); + } + + } + + } + + /** + * Shuts down the roomExecutor and the drawmessageBroadcastTimer. + */ + public void shutdown() { + invokeAndWait(new Runnable() { + @Override + public void run() { + closed = true; + drawmessageBroadcastTimer.cancel(); + roomGraphics.dispose(); + } + }); + } + + + /** + * A Player participates in a Room. It is the interface between the + * {@link Room} and the {@link Client}.

    + * + * Note: This means a player object is actually a join between Room and + * Client. + */ + public final class Player { + + /** + * The room to which this player belongs. + */ + private Room room; + + /** + * The room buffers the last draw message ID that was received from + * this player. + */ + private long lastReceivedMessageId = 0; + + private final Client client; + + /** + * Buffered DrawMessages that will be sent by a Timer. + */ + private final List bufferedDrawMessages = + new ArrayList(); + + private List getBufferedDrawMessages() { + return bufferedDrawMessages; + } + + private Player(Room room, Client client) { + this.room = room; + this.client = client; + } + + public Room getRoom() { + return room; + } + + public Client getClient() { + return client; + } + + /** + * Removes this player from its room, e.g. when + * the client disconnects. + */ + public void removeFromRoom() { + if (room != null) { + room.internalRemovePlayer(this); + room = null; + } + } + + + private long getLastReceivedMessageId() { + return lastReceivedMessageId; + } + private void setLastReceivedMessageId(long value) { + lastReceivedMessageId = value; + } + + + /** + * Handles the given DrawMessage by drawing it onto this Room's + * image and by broadcasting it to the connected players. + * @param msg + * @param msgId + */ + public void handleDrawMessage(DrawMessage msg, long msgId) { + room.internalHandleDrawMessage(this, msg, msgId); + } + + + /** + * Sends the given room message. + * @param type + * @param content + */ + private void sendRoomMessage(MessageType type, String content) { + if (content == null || type == null) + throw new NullPointerException(); + + String completeMsg = String.valueOf(type.flag) + content; + + client.sendMessage(new StringWebsocketMessage(completeMsg)); + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/AbstractWebsocketMessage.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/AbstractWebsocketMessage.class new file mode 100644 index 0000000..3f4846b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/AbstractWebsocketMessage.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/AbstractWebsocketMessage.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/AbstractWebsocketMessage.java new file mode 100644 index 0000000..d425393 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/AbstractWebsocketMessage.java @@ -0,0 +1,25 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard.wsmessages; + +/** + * Abstract base class for Websocket Messages (binary or string) + * that can be buffered. + */ +public abstract class AbstractWebsocketMessage { + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/BinaryWebsocketMessage.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/BinaryWebsocketMessage.class new file mode 100644 index 0000000..fe5a3f4 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/BinaryWebsocketMessage.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/BinaryWebsocketMessage.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/BinaryWebsocketMessage.java new file mode 100644 index 0000000..b16e1ae --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/BinaryWebsocketMessage.java @@ -0,0 +1,34 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard.wsmessages; + +import java.nio.ByteBuffer; + +/** + * Represents a binary websocket message. + */ +public final class BinaryWebsocketMessage extends AbstractWebsocketMessage { + private final ByteBuffer bytes; + + public BinaryWebsocketMessage(ByteBuffer bytes) { + this.bytes = bytes; + } + + public ByteBuffer getBytes() { + return bytes; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/CloseWebsocketMessage.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/CloseWebsocketMessage.class new file mode 100644 index 0000000..bad57e0 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/CloseWebsocketMessage.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/CloseWebsocketMessage.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/CloseWebsocketMessage.java new file mode 100644 index 0000000..44f48ad --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/CloseWebsocketMessage.java @@ -0,0 +1,24 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard.wsmessages; + +/** + * Represents a "close" message that closes the session. + */ +public class CloseWebsocketMessage extends AbstractWebsocketMessage { + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/StringWebsocketMessage.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/StringWebsocketMessage.class new file mode 100644 index 0000000..acf3928 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/StringWebsocketMessage.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/StringWebsocketMessage.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/StringWebsocketMessage.java new file mode 100644 index 0000000..49be369 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/drawboard/wsmessages/StringWebsocketMessage.java @@ -0,0 +1,34 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.drawboard.wsmessages; + +/** + * Represents a string websocket message. + * + */ +public final class StringWebsocketMessage extends AbstractWebsocketMessage { + private final String string; + + public StringWebsocketMessage(String string) { + this.string = string; + } + + public String getString() { + return string; + } + +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoAnnotation.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoAnnotation.class new file mode 100644 index 0000000..8c03f33 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoAnnotation.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoAnnotation.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoAnnotation.java new file mode 100644 index 0000000..6a04b46 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoAnnotation.java @@ -0,0 +1,70 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.echo; + +import java.io.IOException; +import java.nio.ByteBuffer; + +import javax.websocket.OnMessage; +import javax.websocket.PongMessage; +import javax.websocket.Session; +import javax.websocket.server.ServerEndpoint; + +@ServerEndpoint("/websocket/echoAnnotation") +public class EchoAnnotation { + + @OnMessage + public void echoTextMessage(Session session, String msg, boolean last) { + try { + if (session.isOpen()) { + session.getBasicRemote().sendText(msg, last); + } + } catch (IOException e) { + try { + session.close(); + } catch (IOException e1) { + // Ignore + } + } + } + + @OnMessage + public void echoBinaryMessage(Session session, ByteBuffer bb, + boolean last) { + try { + if (session.isOpen()) { + session.getBasicRemote().sendBinary(bb, last); + } + } catch (IOException e) { + try { + session.close(); + } catch (IOException e1) { + // Ignore + } + } + } + + /** + * Process a received pong. This is a NO-OP. + * + * @param pm Ignored. + */ + @OnMessage + public void echoPongMessage(PongMessage pm) { + // NO-OP + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$1.class new file mode 100644 index 0000000..18684e5 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$EchoMessageHandlerBinary.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$EchoMessageHandlerBinary.class new file mode 100644 index 0000000..62bf22d Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$EchoMessageHandlerBinary.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$EchoMessageHandlerText.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$EchoMessageHandlerText.class new file mode 100644 index 0000000..c7ca81c Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint$EchoMessageHandlerText.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint.class new file mode 100644 index 0000000..4a304db Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint.java new file mode 100644 index 0000000..3620238 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/echo/EchoEndpoint.java @@ -0,0 +1,80 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.echo; + +import java.io.IOException; +import java.nio.ByteBuffer; + +import javax.websocket.Endpoint; +import javax.websocket.EndpointConfig; +import javax.websocket.MessageHandler; +import javax.websocket.RemoteEndpoint; +import javax.websocket.Session; + +public class EchoEndpoint extends Endpoint { + + @Override + public void onOpen(Session session, EndpointConfig endpointConfig) { + RemoteEndpoint.Basic remoteEndpointBasic = session.getBasicRemote(); + session.addMessageHandler(new EchoMessageHandlerText(remoteEndpointBasic)); + session.addMessageHandler(new EchoMessageHandlerBinary(remoteEndpointBasic)); + } + + private static class EchoMessageHandlerText + implements MessageHandler.Partial { + + private final RemoteEndpoint.Basic remoteEndpointBasic; + + private EchoMessageHandlerText(RemoteEndpoint.Basic remoteEndpointBasic) { + this.remoteEndpointBasic = remoteEndpointBasic; + } + + @Override + public void onMessage(String message, boolean last) { + try { + if (remoteEndpointBasic != null) { + remoteEndpointBasic.sendText(message, last); + } + } catch (IOException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + } + } + + private static class EchoMessageHandlerBinary + implements MessageHandler.Partial { + + private final RemoteEndpoint.Basic remoteEndpointBasic; + + private EchoMessageHandlerBinary(RemoteEndpoint.Basic remoteEndpointBasic) { + this.remoteEndpointBasic = remoteEndpointBasic; + } + + @Override + public void onMessage(ByteBuffer message, boolean last) { + try { + if (remoteEndpointBasic != null) { + remoteEndpointBasic.sendBinary(message, last); + } + } catch (IOException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Direction.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Direction.class new file mode 100644 index 0000000..b6f4494 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Direction.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Direction.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Direction.java new file mode 100644 index 0000000..4440c9d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Direction.java @@ -0,0 +1,21 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.snake; + +public enum Direction { + NONE, NORTH, SOUTH, EAST, WEST +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location$1.class new file mode 100644 index 0000000..2b42186 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location.class new file mode 100644 index 0000000..e9db638 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location.java new file mode 100644 index 0000000..acbfeb7 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Location.java @@ -0,0 +1,65 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.snake; + +public class Location { + + public int x; + public int y; + + public Location(int x, int y) { + this.x = x; + this.y = y; + } + + public Location getAdjacentLocation(Direction direction) { + switch (direction) { + case NORTH: + return new Location(x, y - SnakeAnnotation.GRID_SIZE); + case SOUTH: + return new Location(x, y + SnakeAnnotation.GRID_SIZE); + case EAST: + return new Location(x + SnakeAnnotation.GRID_SIZE, y); + case WEST: + return new Location(x - SnakeAnnotation.GRID_SIZE, y); + case NONE: + // fall through + default: + return this; + } + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + + Location location = (Location) o; + + if (x != location.x) return false; + if (y != location.y) return false; + + return true; + } + + @Override + public int hashCode() { + int result = x; + result = 31 * result + y; + return result; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Snake.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Snake.class new file mode 100644 index 0000000..1449f3c Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Snake.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Snake.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Snake.java new file mode 100644 index 0000000..acfac59 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/Snake.java @@ -0,0 +1,150 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.snake; + +import java.io.IOException; +import java.util.ArrayDeque; +import java.util.Collection; +import java.util.Deque; + +import javax.websocket.CloseReason; +import javax.websocket.CloseReason.CloseCodes; +import javax.websocket.Session; + +public class Snake { + + private static final int DEFAULT_LENGTH = 5; + + private final int id; + private final Session session; + + private Direction direction; + private int length = DEFAULT_LENGTH; + private Location head; + private final Deque tail = new ArrayDeque(); + private final String hexColor; + + public Snake(int id, Session session) { + this.id = id; + this.session = session; + this.hexColor = SnakeAnnotation.getRandomHexColor(); + resetState(); + } + + private void resetState() { + this.direction = Direction.NONE; + this.head = SnakeAnnotation.getRandomLocation(); + this.tail.clear(); + this.length = DEFAULT_LENGTH; + } + + private synchronized void kill() { + resetState(); + sendMessage("{'type': 'dead'}"); + } + + private synchronized void reward() { + length++; + sendMessage("{'type': 'kill'}"); + } + + + protected void sendMessage(String msg) { + try { + session.getBasicRemote().sendText(msg); + } catch (IOException ioe) { + CloseReason cr = + new CloseReason(CloseCodes.CLOSED_ABNORMALLY, ioe.getMessage()); + try { + session.close(cr); + } catch (IOException ioe2) { + // Ignore + } + } + } + + public synchronized void update(Collection snakes) { + Location nextLocation = head.getAdjacentLocation(direction); + if (nextLocation.x >= SnakeAnnotation.PLAYFIELD_WIDTH) { + nextLocation.x = 0; + } + if (nextLocation.y >= SnakeAnnotation.PLAYFIELD_HEIGHT) { + nextLocation.y = 0; + } + if (nextLocation.x < 0) { + nextLocation.x = SnakeAnnotation.PLAYFIELD_WIDTH; + } + if (nextLocation.y < 0) { + nextLocation.y = SnakeAnnotation.PLAYFIELD_HEIGHT; + } + if (direction != Direction.NONE) { + tail.addFirst(head); + if (tail.size() > length) { + tail.removeLast(); + } + head = nextLocation; + } + + handleCollisions(snakes); + } + + private void handleCollisions(Collection snakes) { + for (Snake snake : snakes) { + boolean headCollision = id != snake.id && snake.getHead().equals(head); + boolean tailCollision = snake.getTail().contains(head); + if (headCollision || tailCollision) { + kill(); + if (id != snake.id) { + snake.reward(); + } + } + } + } + + public synchronized Location getHead() { + return head; + } + + public synchronized Collection getTail() { + return tail; + } + + public synchronized void setDirection(Direction direction) { + this.direction = direction; + } + + public synchronized String getLocationsJson() { + StringBuilder sb = new StringBuilder(); + sb.append(String.format("{x: %d, y: %d}", + Integer.valueOf(head.x), Integer.valueOf(head.y))); + for (Location location : tail) { + sb.append(','); + sb.append(String.format("{x: %d, y: %d}", + Integer.valueOf(location.x), Integer.valueOf(location.y))); + } + return String.format("{'id':%d,'body':[%s]}", + Integer.valueOf(id), sb.toString()); + } + + public int getId() { + return id; + } + + public String getHexColor() { + return hexColor; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeAnnotation.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeAnnotation.class new file mode 100644 index 0000000..57b9447 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeAnnotation.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeAnnotation.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeAnnotation.java new file mode 100644 index 0000000..0edeeb3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeAnnotation.java @@ -0,0 +1,135 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.snake; + +import java.awt.Color; +import java.io.EOFException; +import java.util.Iterator; +import java.util.Random; +import java.util.concurrent.atomic.AtomicInteger; + +import javax.websocket.OnClose; +import javax.websocket.OnError; +import javax.websocket.OnMessage; +import javax.websocket.OnOpen; +import javax.websocket.Session; +import javax.websocket.server.ServerEndpoint; + +@ServerEndpoint(value = "/websocket/snake") +public class SnakeAnnotation { + + public static final int PLAYFIELD_WIDTH = 640; + public static final int PLAYFIELD_HEIGHT = 480; + public static final int GRID_SIZE = 10; + + private static final AtomicInteger snakeIds = new AtomicInteger(0); + private static final Random random = new Random(); + + + private final int id; + private Snake snake; + + public static String getRandomHexColor() { + float hue = random.nextFloat(); + // sat between 0.1 and 0.3 + float saturation = (random.nextInt(2000) + 1000) / 10000f; + float luminance = 0.9f; + Color color = Color.getHSBColor(hue, saturation, luminance); + return '#' + Integer.toHexString( + (color.getRGB() & 0xffffff) | 0x1000000).substring(1); + } + + + public static Location getRandomLocation() { + int x = roundByGridSize(random.nextInt(PLAYFIELD_WIDTH)); + int y = roundByGridSize(random.nextInt(PLAYFIELD_HEIGHT)); + return new Location(x, y); + } + + + private static int roundByGridSize(int value) { + value = value + (GRID_SIZE / 2); + value = value / GRID_SIZE; + value = value * GRID_SIZE; + return value; + } + + public SnakeAnnotation() { + this.id = snakeIds.getAndIncrement(); + } + + + @OnOpen + public void onOpen(Session session) { + this.snake = new Snake(id, session); + SnakeTimer.addSnake(snake); + StringBuilder sb = new StringBuilder(); + for (Iterator iterator = SnakeTimer.getSnakes().iterator(); + iterator.hasNext();) { + Snake snake = iterator.next(); + sb.append(String.format("{id: %d, color: '%s'}", + Integer.valueOf(snake.getId()), snake.getHexColor())); + if (iterator.hasNext()) { + sb.append(','); + } + } + SnakeTimer.broadcast(String.format("{'type': 'join','data':[%s]}", + sb.toString())); + } + + + @OnMessage + public void onTextMessage(String message) { + if ("west".equals(message)) { + snake.setDirection(Direction.WEST); + } else if ("north".equals(message)) { + snake.setDirection(Direction.NORTH); + } else if ("east".equals(message)) { + snake.setDirection(Direction.EAST); + } else if ("south".equals(message)) { + snake.setDirection(Direction.SOUTH); + } + } + + + @OnClose + public void onClose() { + SnakeTimer.removeSnake(snake); + SnakeTimer.broadcast(String.format("{'type': 'leave', 'id': %d}", + Integer.valueOf(id))); + } + + + @OnError + public void onError(Throwable t) throws Throwable { + // Most likely cause is a user closing their browser. Check to see if + // the root cause is EOF and if it is ignore it. + // Protect against infinite loops. + int count = 0; + Throwable root = t; + while (root.getCause() != null && count < 20) { + root = root.getCause(); + count ++; + } + if (root instanceof EOFException) { + // Assume this is triggered by the user closing their browser and + // ignore it. + } else { + throw t; + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer$1.class new file mode 100644 index 0000000..1fb6005 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer.class new file mode 100644 index 0000000..14693fc Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer.java new file mode 100644 index 0000000..1692b8e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/snake/SnakeTimer.java @@ -0,0 +1,115 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.snake; + +import java.util.Collection; +import java.util.Collections; +import java.util.Iterator; +import java.util.Timer; +import java.util.TimerTask; +import java.util.concurrent.ConcurrentHashMap; + +import org.apache.juli.logging.Log; +import org.apache.juli.logging.LogFactory; + +/** + * Sets up the timer for the multi-player snake game WebSocket example. + */ +public class SnakeTimer { + + private static final Log log = + LogFactory.getLog(SnakeTimer.class); + + private static Timer gameTimer = null; + + private static final long TICK_DELAY = 100; + + private static final ConcurrentHashMap snakes = + new ConcurrentHashMap(); + + protected static synchronized void addSnake(Snake snake) { + if (snakes.size() == 0) { + startTimer(); + } + snakes.put(Integer.valueOf(snake.getId()), snake); + } + + + protected static Collection getSnakes() { + return Collections.unmodifiableCollection(snakes.values()); + } + + + protected static synchronized void removeSnake(Snake snake) { + snakes.remove(Integer.valueOf(snake.getId())); + if (snakes.size() == 0) { + stopTimer(); + } + } + + + protected static void tick() { + StringBuilder sb = new StringBuilder(); + for (Iterator iterator = SnakeTimer.getSnakes().iterator(); + iterator.hasNext();) { + Snake snake = iterator.next(); + snake.update(SnakeTimer.getSnakes()); + sb.append(snake.getLocationsJson()); + if (iterator.hasNext()) { + sb.append(','); + } + } + broadcast(String.format("{'type': 'update', 'data' : [%s]}", + sb.toString())); + } + + protected static void broadcast(String message) { + for (Snake snake : SnakeTimer.getSnakes()) { + try { + snake.sendMessage(message); + } catch (IllegalStateException ise) { + // An ISE can occur if an attempt is made to write to a + // WebSocket connection after it has been closed. The + // alternative to catching this exception is to synchronise + // the writes to the clients along with the addSnake() and + // removeSnake() methods that are already synchronised. + } + } + } + + + public static void startTimer() { + gameTimer = new Timer(SnakeTimer.class.getSimpleName() + " Timer"); + gameTimer.scheduleAtFixedRate(new TimerTask() { + @Override + public void run() { + try { + tick(); + } catch (RuntimeException e) { + log.error("Caught to prevent timer from shutting down", e); + } + } + }, TICK_DELAY, TICK_DELAY); + } + + + public static void stopTimer() { + if (gameTimer != null) { + gameTimer.cancel(); + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet$1.class new file mode 100644 index 0000000..9bbb179 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet$ChatMessageInbound.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet$ChatMessageInbound.class new file mode 100644 index 0000000..3eecb9e Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet$ChatMessageInbound.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet.class new file mode 100644 index 0000000..edf666f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet.java new file mode 100644 index 0000000..2afd694 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/chat/ChatWebSocketServlet.java @@ -0,0 +1,105 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.tc7.chat; + +import java.io.IOException; +import java.nio.ByteBuffer; +import java.nio.CharBuffer; +import java.util.Set; +import java.util.concurrent.CopyOnWriteArraySet; +import java.util.concurrent.atomic.AtomicInteger; + +import javax.servlet.http.HttpServletRequest; + +import org.apache.catalina.websocket.MessageInbound; +import org.apache.catalina.websocket.StreamInbound; +import org.apache.catalina.websocket.WebSocketServlet; +import org.apache.catalina.websocket.WsOutbound; + +import util.HTMLFilter; + +/** + * Example web socket servlet for chat. + * @deprecated See {@link websocket.chat.ChatAnnotation} + */ +@Deprecated +public class ChatWebSocketServlet extends WebSocketServlet { + + private static final long serialVersionUID = 1L; + + private static final String GUEST_PREFIX = "Guest"; + + private final AtomicInteger connectionIds = new AtomicInteger(0); + private final Set connections = + new CopyOnWriteArraySet(); + + @Override + protected StreamInbound createWebSocketInbound(String subProtocol, + HttpServletRequest request) { + return new ChatMessageInbound(connectionIds.incrementAndGet()); + } + + private final class ChatMessageInbound extends MessageInbound { + + private final String nickname; + + private ChatMessageInbound(int id) { + this.nickname = GUEST_PREFIX + id; + } + + @Override + protected void onOpen(WsOutbound outbound) { + connections.add(this); + String message = String.format("* %s %s", + nickname, "has joined."); + broadcast(message); + } + + @Override + protected void onClose(int status) { + connections.remove(this); + String message = String.format("* %s %s", + nickname, "has disconnected."); + broadcast(message); + } + + @Override + protected void onBinaryMessage(ByteBuffer message) throws IOException { + throw new UnsupportedOperationException( + "Binary message not supported."); + } + + @Override + protected void onTextMessage(CharBuffer message) throws IOException { + // Never trust the client + String filteredMessage = String.format("%s: %s", + nickname, HTMLFilter.filter(message.toString())); + broadcast(filteredMessage); + } + + private void broadcast(String message) { + for (ChatMessageInbound connection : connections) { + try { + CharBuffer buffer = CharBuffer.wrap(message); + connection.getWsOutbound().writeTextMessage(buffer); + } catch (IOException ignore) { + // Ignore + } + } + } + } +} \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage$EchoMessageInbound.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage$EchoMessageInbound.class new file mode 100644 index 0000000..ddb9dc4 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage$EchoMessageInbound.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage.class new file mode 100644 index 0000000..d600882 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage.java new file mode 100644 index 0000000..e7d42e8 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoMessage.java @@ -0,0 +1,88 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.tc7.echo; + +import java.io.IOException; +import java.nio.ByteBuffer; +import java.nio.CharBuffer; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServletRequest; + +import org.apache.catalina.websocket.MessageInbound; +import org.apache.catalina.websocket.StreamInbound; +import org.apache.catalina.websocket.WebSocketServlet; +/** + * @deprecated See {@link websocket.echo.EchoAnnotation} + */ +@Deprecated +public class EchoMessage extends WebSocketServlet { + + private static final long serialVersionUID = 1L; + private volatile int byteBufSize; + private volatile int charBufSize; + + @Override + public void init() throws ServletException { + super.init(); + byteBufSize = getInitParameterIntValue("byteBufferMaxSize", 2097152); + charBufSize = getInitParameterIntValue("charBufferMaxSize", 2097152); + } + + public int getInitParameterIntValue(String name, int defaultValue) { + String val = this.getInitParameter(name); + int result; + if(null != val) { + try { + result = Integer.parseInt(val); + }catch (Exception x) { + result = defaultValue; + } + } else { + result = defaultValue; + } + + return result; + } + + + + @Override + protected StreamInbound createWebSocketInbound(String subProtocol, + HttpServletRequest request) { + return new EchoMessageInbound(byteBufSize,charBufSize); + } + + private static final class EchoMessageInbound extends MessageInbound { + + public EchoMessageInbound(int byteBufferMaxSize, int charBufferMaxSize) { + super(); + setByteBufferMaxSize(byteBufferMaxSize); + setCharBufferMaxSize(charBufferMaxSize); + } + + @Override + protected void onBinaryMessage(ByteBuffer message) throws IOException { + getWsOutbound().writeBinaryMessage(message); + } + + @Override + protected void onTextMessage(CharBuffer message) throws IOException { + getWsOutbound().writeTextMessage(message); + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream$1.class new file mode 100644 index 0000000..b770d79 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream$EchoStreamInbound.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream$EchoStreamInbound.class new file mode 100644 index 0000000..478607d Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream$EchoStreamInbound.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream.class new file mode 100644 index 0000000..f3d819d Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream.java new file mode 100644 index 0000000..f14ebac --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/echo/EchoStream.java @@ -0,0 +1,73 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.tc7.echo; + +import java.io.IOException; +import java.io.InputStream; +import java.io.Reader; + +import javax.servlet.http.HttpServletRequest; + +import org.apache.catalina.websocket.StreamInbound; +import org.apache.catalina.websocket.WebSocketServlet; +import org.apache.catalina.websocket.WsOutbound; + +/** + * @deprecated See {@link websocket.echo.EchoAnnotation} + */ +@Deprecated +public class EchoStream extends WebSocketServlet { + + private static final long serialVersionUID = 1L; + + @Override + protected StreamInbound createWebSocketInbound(String subProtocol, + HttpServletRequest request) { + return new EchoStreamInbound(); + } + + private static final class EchoStreamInbound extends StreamInbound { + + @Override + protected void onBinaryData(InputStream is) throws IOException { + // Simply echo the data to back to the client. + WsOutbound outbound = getWsOutbound(); + + int i = is.read(); + while (i != -1) { + outbound.writeBinaryData(i); + i = is.read(); + } + + outbound.flush(); + } + + @Override + protected void onTextData(Reader r) throws IOException { + // Simply echo the data to back to the client. + WsOutbound outbound = getWsOutbound(); + + int c = r.read(); + while (c != -1) { + outbound.writeTextData((char) c); + c = r.read(); + } + + outbound.flush(); + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Direction.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Direction.class new file mode 100644 index 0000000..7db9c55 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Direction.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Direction.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Direction.java new file mode 100644 index 0000000..3bd54d6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Direction.java @@ -0,0 +1,25 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.tc7.snake; + +/** + * @deprecated See {@link websocket.snake.Direction} + */ +@Deprecated +public enum Direction { + NONE, NORTH, SOUTH, EAST, WEST +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location$1.class new file mode 100644 index 0000000..7e71c10 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location.class new file mode 100644 index 0000000..b052a15 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location.java new file mode 100644 index 0000000..96c91ac --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Location.java @@ -0,0 +1,69 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.tc7.snake; + +/** + * @deprecated See {@link websocket.snake.Location} + */ +@Deprecated +public class Location { + + public int x; + public int y; + + public Location(int x, int y) { + this.x = x; + this.y = y; + } + + public Location getAdjacentLocation(Direction direction) { + switch (direction) { + case NORTH: + return new Location(x, y - SnakeWebSocketServlet.GRID_SIZE); + case SOUTH: + return new Location(x, y + SnakeWebSocketServlet.GRID_SIZE); + case EAST: + return new Location(x + SnakeWebSocketServlet.GRID_SIZE, y); + case WEST: + return new Location(x - SnakeWebSocketServlet.GRID_SIZE, y); + case NONE: + // fall through + default: + return this; + } + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + + Location location = (Location) o; + + if (x != location.x) return false; + if (y != location.y) return false; + + return true; + } + + @Override + public int hashCode() { + int result = x; + result = 31 * result + y; + return result; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Snake.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Snake.class new file mode 100644 index 0000000..336a9c3 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Snake.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Snake.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Snake.java new file mode 100644 index 0000000..949dcf1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/Snake.java @@ -0,0 +1,148 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.tc7.snake; + +import java.io.IOException; +import java.nio.CharBuffer; +import java.util.ArrayDeque; +import java.util.Collection; +import java.util.Deque; + +import org.apache.catalina.websocket.WsOutbound; + +/** + * @deprecated See {@link websocket.snake.Snake} + */ +@Deprecated +public class Snake { + + private static final int DEFAULT_LENGTH = 5; + + private final int id; + private final WsOutbound outbound; + + private Direction direction; + private int length = DEFAULT_LENGTH; + private Location head; + private Deque tail = new ArrayDeque(); + private String hexColor; + + public Snake(int id, WsOutbound outbound) { + this.id = id; + this.outbound = outbound; + this.hexColor = SnakeWebSocketServlet.getRandomHexColor(); + resetState(); + } + + private void resetState() { + this.direction = Direction.NONE; + this.head = SnakeWebSocketServlet.getRandomLocation(); + this.tail.clear(); + this.length = DEFAULT_LENGTH; + } + + private synchronized void kill() { + resetState(); + try { + CharBuffer response = CharBuffer.wrap("{'type': 'dead'}"); + outbound.writeTextMessage(response); + } catch (IOException ioe) { + // Ignore + } + } + + private synchronized void reward() { + length++; + try { + CharBuffer response = CharBuffer.wrap("{'type': 'kill'}"); + outbound.writeTextMessage(response); + } catch (IOException ioe) { + // Ignore + } + } + + public synchronized void update(Collection snakes) { + Location nextLocation = head.getAdjacentLocation(direction); + if (nextLocation.x >= SnakeWebSocketServlet.PLAYFIELD_WIDTH) { + nextLocation.x = 0; + } + if (nextLocation.y >= SnakeWebSocketServlet.PLAYFIELD_HEIGHT) { + nextLocation.y = 0; + } + if (nextLocation.x < 0) { + nextLocation.x = SnakeWebSocketServlet.PLAYFIELD_WIDTH; + } + if (nextLocation.y < 0) { + nextLocation.y = SnakeWebSocketServlet.PLAYFIELD_HEIGHT; + } + if (direction != Direction.NONE) { + tail.addFirst(head); + if (tail.size() > length) { + tail.removeLast(); + } + head = nextLocation; + } + + handleCollisions(snakes); + } + + private void handleCollisions(Collection snakes) { + for (Snake snake : snakes) { + boolean headCollision = id != snake.id && snake.getHead().equals(head); + boolean tailCollision = snake.getTail().contains(head); + if (headCollision || tailCollision) { + kill(); + if (id != snake.id) { + snake.reward(); + } + } + } + } + + public synchronized Location getHead() { + return head; + } + + public synchronized Collection getTail() { + return tail; + } + + public synchronized void setDirection(Direction direction) { + this.direction = direction; + } + + public synchronized String getLocationsJson() { + StringBuilder sb = new StringBuilder(); + sb.append(String.format("{x: %d, y: %d}", + Integer.valueOf(head.x), Integer.valueOf(head.y))); + for (Location location : tail) { + sb.append(','); + sb.append(String.format("{x: %d, y: %d}", + Integer.valueOf(location.x), Integer.valueOf(location.y))); + } + return String.format("{'id':%d,'body':[%s]}", + Integer.valueOf(id), sb.toString()); + } + + public int getId() { + return id; + } + + public String getHexColor() { + return hexColor; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet$1.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet$1.class new file mode 100644 index 0000000..2707bb7 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet$1.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet$SnakeMessageInbound.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet$SnakeMessageInbound.class new file mode 100644 index 0000000..2649169 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet$SnakeMessageInbound.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet.class new file mode 100644 index 0000000..f174143 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet.java new file mode 100644 index 0000000..53f3289 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/classes/websocket/tc7/snake/SnakeWebSocketServlet.java @@ -0,0 +1,215 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package websocket.tc7.snake; + +import java.awt.Color; +import java.io.IOException; +import java.nio.ByteBuffer; +import java.nio.CharBuffer; +import java.util.Collection; +import java.util.Collections; +import java.util.Iterator; +import java.util.Random; +import java.util.Timer; +import java.util.TimerTask; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.atomic.AtomicInteger; + +import javax.servlet.ServletException; +import javax.servlet.http.HttpServletRequest; + +import org.apache.catalina.websocket.MessageInbound; +import org.apache.catalina.websocket.StreamInbound; +import org.apache.catalina.websocket.WebSocketServlet; +import org.apache.catalina.websocket.WsOutbound; +import org.apache.juli.logging.Log; +import org.apache.juli.logging.LogFactory; + +/** + * Example web socket servlet for simple multi-player snake. + * @deprecated See {@link websocket.snake.SnakeAnnotation} + */ +@Deprecated +public class SnakeWebSocketServlet extends WebSocketServlet { + + private static final long serialVersionUID = 1L; + + private static final Log log = + LogFactory.getLog(SnakeWebSocketServlet.class); + + public static final int PLAYFIELD_WIDTH = 640; + public static final int PLAYFIELD_HEIGHT = 480; + public static final int GRID_SIZE = 10; + + private static final long TICK_DELAY = 100; + + private static final Random random = new Random(); + + private final Timer gameTimer = + new Timer(SnakeWebSocketServlet.class.getSimpleName() + " Timer"); + + private final AtomicInteger connectionIds = new AtomicInteger(0); + private final ConcurrentHashMap snakes = + new ConcurrentHashMap(); + private final ConcurrentHashMap connections = + new ConcurrentHashMap(); + + @Override + public void init() throws ServletException { + super.init(); + gameTimer.scheduleAtFixedRate(new TimerTask() { + @Override + public void run() { + try { + tick(); + } catch (RuntimeException e) { + log.error("Caught to prevent timer from shutting down", e); + } + } + }, TICK_DELAY, TICK_DELAY); + } + + private void tick() { + StringBuilder sb = new StringBuilder(); + for (Iterator iterator = getSnakes().iterator(); + iterator.hasNext();) { + Snake snake = iterator.next(); + snake.update(getSnakes()); + sb.append(snake.getLocationsJson()); + if (iterator.hasNext()) { + sb.append(','); + } + } + broadcast(String.format("{'type': 'update', 'data' : [%s]}", + sb.toString())); + } + + private void broadcast(String message) { + for (SnakeMessageInbound connection : getConnections()) { + try { + CharBuffer buffer = CharBuffer.wrap(message); + connection.getWsOutbound().writeTextMessage(buffer); + } catch (IOException ignore) { + // Ignore + } + } + } + + private Collection getConnections() { + return Collections.unmodifiableCollection(connections.values()); + } + + private Collection getSnakes() { + return Collections.unmodifiableCollection(snakes.values()); + } + + public static String getRandomHexColor() { + float hue = random.nextFloat(); + // sat between 0.1 and 0.3 + float saturation = (random.nextInt(2000) + 1000) / 10000f; + float luminance = 0.9f; + Color color = Color.getHSBColor(hue, saturation, luminance); + return '#' + Integer.toHexString( + (color.getRGB() & 0xffffff) | 0x1000000).substring(1); + } + + public static Location getRandomLocation() { + int x = roundByGridSize( + random.nextInt(SnakeWebSocketServlet.PLAYFIELD_WIDTH)); + int y = roundByGridSize( + random.nextInt(SnakeWebSocketServlet.PLAYFIELD_HEIGHT)); + return new Location(x, y); + } + + private static int roundByGridSize(int value) { + value = value + (SnakeWebSocketServlet.GRID_SIZE / 2); + value = value / SnakeWebSocketServlet.GRID_SIZE; + value = value * SnakeWebSocketServlet.GRID_SIZE; + return value; + } + + @Override + public void destroy() { + super.destroy(); + if (gameTimer != null) { + gameTimer.cancel(); + } + } + + @Override + protected StreamInbound createWebSocketInbound(String subProtocol, + HttpServletRequest request) { + return new SnakeMessageInbound(connectionIds.incrementAndGet()); + } + + private final class SnakeMessageInbound extends MessageInbound { + + private final int id; + private Snake snake; + + private SnakeMessageInbound(int id) { + this.id = id; + } + + @Override + protected void onOpen(WsOutbound outbound) { + this.snake = new Snake(id, outbound); + snakes.put(Integer.valueOf(id), snake); + connections.put(Integer.valueOf(id), this); + StringBuilder sb = new StringBuilder(); + for (Iterator iterator = getSnakes().iterator(); + iterator.hasNext();) { + Snake snake = iterator.next(); + sb.append(String.format("{id: %d, color: '%s'}", + Integer.valueOf(snake.getId()), snake.getHexColor())); + if (iterator.hasNext()) { + sb.append(','); + } + } + broadcast(String.format("{'type': 'join','data':[%s]}", + sb.toString())); + } + + @Override + protected void onClose(int status) { + connections.remove(Integer.valueOf(id)); + snakes.remove(Integer.valueOf(id)); + broadcast(String.format("{'type': 'leave', 'id': %d}", + Integer.valueOf(id))); + } + + @Override + protected void onBinaryMessage(ByteBuffer message) throws IOException { + throw new UnsupportedOperationException( + "Binary message not supported."); + } + + @Override + protected void onTextMessage(CharBuffer charBuffer) throws IOException { + String message = charBuffer.toString(); + if ("west".equals(message)) { + snake.setDirection(Direction.WEST); + } else if ("north".equals(message)) { + snake.setDirection(Direction.NORTH); + } else if ("east".equals(message)) { + snake.setDirection(Direction.EAST); + } else if ("south".equals(message)) { + snake.setDirection(Direction.SOUTH); + } + } + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/applet/Clock2.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/applet/Clock2.java new file mode 100644 index 0000000..aa79a04 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/applet/Clock2.java @@ -0,0 +1,229 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import java.applet.Applet; +import java.awt.Color; +import java.awt.Font; +import java.awt.Graphics; +import java.text.SimpleDateFormat; +import java.util.Date; +import java.util.Locale; + +/** + * Time! + * + * @author Rachel Gollub + */ + +public class Clock2 extends Applet implements Runnable { + private static final long serialVersionUID = 1L; + Thread timer; // The thread that displays clock + int lastxs, lastys, lastxm, + lastym, lastxh, lastyh; // Dimensions used to draw hands + SimpleDateFormat formatter; // Formats the date displayed + String lastdate; // String to hold date displayed + Font clockFaceFont; // Font for number display on clock + Date currentDate; // Used to get date to display + Color handColor; // Color of main hands and dial + Color numberColor; // Color of second hand and numbers + + @Override + public void init() { + lastxs = lastys = lastxm = lastym = lastxh = lastyh = 0; + formatter = new SimpleDateFormat ("EEE MMM dd hh:mm:ss yyyy", Locale.getDefault()); + currentDate = new Date(); + lastdate = formatter.format(currentDate); + clockFaceFont = new Font("Serif", Font.PLAIN, 14); + handColor = Color.blue; + numberColor = Color.darkGray; + + try { + setBackground(new Color(Integer.parseInt(getParameter("bgcolor"),16))); + } catch (Exception e) { + // Ignore + } + try { + handColor = new Color(Integer.parseInt(getParameter("fgcolor1"),16)); + } catch (Exception e) { + // Ignore + } + try { + numberColor = new Color(Integer.parseInt(getParameter("fgcolor2"),16)); + } catch (Exception e) { + // Ignore + } + resize(300,300); // Set clock window size + } + + // Plotpoints allows calculation to only cover 45 degrees of the circle, + // and then mirror + public void plotpoints(int x0, int y0, int x, int y, Graphics g) { + g.drawLine(x0+x,y0+y,x0+x,y0+y); + g.drawLine(x0+y,y0+x,x0+y,y0+x); + g.drawLine(x0+y,y0-x,x0+y,y0-x); + g.drawLine(x0+x,y0-y,x0+x,y0-y); + g.drawLine(x0-x,y0-y,x0-x,y0-y); + g.drawLine(x0-y,y0-x,x0-y,y0-x); + g.drawLine(x0-y,y0+x,x0-y,y0+x); + g.drawLine(x0-x,y0+y,x0-x,y0+y); + } + + // Circle is just Bresenham's algorithm for a scan converted circle + public void circle(int x0, int y0, int r, Graphics g) { + int x,y; + float d; + x=0; + y=r; + d=5/4-r; + plotpoints(x0,y0,x,y,g); + + while (y>x){ + if (d<0) { + d=d+2*x+3; + x++; + } else { + d=d+2*(x-y)+5; + x++; + y--; + } + plotpoints(x0,y0,x,y,g); + } + } + + // Paint is the main part of the program + @Override + public void paint(Graphics g) { + int xh, yh, xm, ym, xs, ys, s = 0, m = 10, h = 10, xcenter, ycenter; + String today; + + currentDate = new Date(); + SimpleDateFormat formatter = new SimpleDateFormat("s",Locale.getDefault()); + try { + s = Integer.parseInt(formatter.format(currentDate)); + } catch (NumberFormatException n) { + s = 0; + } + formatter.applyPattern("m"); + try { + m = Integer.parseInt(formatter.format(currentDate)); + } catch (NumberFormatException n) { + m = 10; + } + formatter.applyPattern("h"); + try { + h = Integer.parseInt(formatter.format(currentDate)); + } catch (NumberFormatException n) { + h = 10; + } + formatter.applyPattern("EEE MMM dd HH:mm:ss yyyy"); + today = formatter.format(currentDate); + xcenter=80; + ycenter=55; + + // a= s* pi/2 - pi/2 (to switch 0,0 from 3:00 to 12:00) + // x = r(cos a) + xcenter, y = r(sin a) + ycenter + + xs = (int)(Math.cos(s * 3.14f/30 - 3.14f/2) * 45 + xcenter); + ys = (int)(Math.sin(s * 3.14f/30 - 3.14f/2) * 45 + ycenter); + xm = (int)(Math.cos(m * 3.14f/30 - 3.14f/2) * 40 + xcenter); + ym = (int)(Math.sin(m * 3.14f/30 - 3.14f/2) * 40 + ycenter); + xh = (int)(Math.cos((h*30 + m/2) * 3.14f/180 - 3.14f/2) * 30 + xcenter); + yh = (int)(Math.sin((h*30 + m/2) * 3.14f/180 - 3.14f/2) * 30 + ycenter); + + // Draw the circle and numbers + + g.setFont(clockFaceFont); + g.setColor(handColor); + circle(xcenter,ycenter,50,g); + g.setColor(numberColor); + g.drawString("9",xcenter-45,ycenter+3); + g.drawString("3",xcenter+40,ycenter+3); + g.drawString("12",xcenter-5,ycenter-37); + g.drawString("6",xcenter-3,ycenter+45); + + // Erase if necessary, and redraw + + g.setColor(getBackground()); + if (xs != lastxs || ys != lastys) { + g.drawLine(xcenter, ycenter, lastxs, lastys); + g.drawString(lastdate, 5, 125); + } + if (xm != lastxm || ym != lastym) { + g.drawLine(xcenter, ycenter-1, lastxm, lastym); + g.drawLine(xcenter-1, ycenter, lastxm, lastym); } + if (xh != lastxh || yh != lastyh) { + g.drawLine(xcenter, ycenter-1, lastxh, lastyh); + g.drawLine(xcenter-1, ycenter, lastxh, lastyh); } + g.setColor(numberColor); + g.drawString("", 5, 125); + g.drawString(today, 5, 125); + g.drawLine(xcenter, ycenter, xs, ys); + g.setColor(handColor); + g.drawLine(xcenter, ycenter-1, xm, ym); + g.drawLine(xcenter-1, ycenter, xm, ym); + g.drawLine(xcenter, ycenter-1, xh, yh); + g.drawLine(xcenter-1, ycenter, xh, yh); + lastxs=xs; lastys=ys; + lastxm=xm; lastym=ym; + lastxh=xh; lastyh=yh; + lastdate = today; + currentDate=null; + } + + @Override + public void start() { + timer = new Thread(this); + timer.start(); + } + + @Override + public void stop() { + timer = null; + } + + @Override + public void run() { + Thread me = Thread.currentThread(); + while (timer == me) { + try { + Thread.sleep(100); + } catch (InterruptedException e) { + } + repaint(); + } + } + + @Override + public void update(Graphics g) { + paint(g); + } + + @Override + public String getAppletInfo() { + return "Title: A Clock \nAuthor: Rachel Gollub, 1995 \nAn analog clock."; + } + + @Override + public String[][] getParameterInfo() { + String[][] info = { + {"bgcolor", "hexadecimal RGB number", "The background color. Default is the color of your browser."}, + {"fgcolor1", "hexadecimal RGB number", "The color of the hands and dial. Default is blue."}, + {"fgcolor2", "hexadecimal RGB number", "The color of the seconds hand and numbers. Default is dark gray."} + }; + return info; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/debug-taglib.tld b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/debug-taglib.tld new file mode 100644 index 0000000..424a3df --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/debug-taglib.tld @@ -0,0 +1,54 @@ + + + + + + + + 1.0 + 1.2 + debug + http://tomcat.apache.org/debug-taglib + + This tag library defines no tags. Instead, its purpose is encapsulated + in the TagLibraryValidator implementation that simply outputs the XML + version of a JSP page to standard output, whenever this tag library is + referenced in a "taglib" directive in a JSP page. + + + validators.DebugValidator + + + + + log + examples.LogTag + TAGDEPENDENT + + Perform a server side action; Log the message. + + + toBrowser + false + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/example-taglib.tld b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/example-taglib.tld new file mode 100644 index 0000000..f60e353 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp/example-taglib.tld @@ -0,0 +1,107 @@ + + + + + + + 1.0 + 1.2 + simple + http://tomcat.apache.org/example-taglib + + A simple tab library for the examples + + + + + + foo + examples.FooTag + examples.FooTagExtraInfo + JSP + + Perform a server side action; uses 3 mandatory attributes + + + + att1 + true + + + att2 + true + + + att3 + true + + + + + + + log + examples.LogTag + TAGDEPENDENT + + Perform a server side action; Log the message. + + + toBrowser + false + + + + + + + values + examples.ValuesTag + empty + + Accept and return values of different types. This tag is used + to illustrate type coercions. + + + object + false + true + java.lang.Object + + + string + false + true + java.lang.String + + + long + false + true + long + + + double + false + true + double + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp2/jsp2-example-taglib.tld b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp2/jsp2-example-taglib.tld new file mode 100644 index 0000000..73173bd --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/jsp2/jsp2-example-taglib.tld @@ -0,0 +1,124 @@ + + + + + A tag library exercising SimpleTag handlers. + 1.0 + SimpleTagLibrary + http://tomcat.apache.org/jsp2-example-taglib + + Outputs Hello, World + helloWorld + jsp2.examples.simpletag.HelloWorldSimpleTag + empty + + + Repeats the body of the tag 'num' times + repeat + jsp2.examples.simpletag.RepeatSimpleTag + scriptless + + Current invocation count (1 to num) + count + + + num + true + true + + + + Populates the page context with a BookBean + findBook + jsp2.examples.simpletag.FindBookSimpleTag + empty + + var + true + true + + + + + Takes 3 fragments and invokes them in a random order + + shuffle + jsp2.examples.simpletag.ShuffleSimpleTag + empty + + fragment1 + true + true + + + fragment2 + true + true + + + fragment3 + true + true + + + + Outputs a colored tile + tile + jsp2.examples.simpletag.TileSimpleTag + empty + + color + true + + + label + true + + + + + Tag that echoes all its attributes and body content + + echoAttributes + jsp2.examples.simpletag.EchoAttributesTag + empty + true + + + Reverses the characters in the given String + reverse + jsp2.examples.el.Functions + java.lang.String reverse( java.lang.String ) + + + Counts the number of vowels (a,e,i,o,u) in the given String + countVowels + jsp2.examples.el.Functions + java.lang.String numVowels( java.lang.String ) + + + Converts the string to all caps + caps + jsp2.examples.el.Functions + java.lang.String caps( java.lang.String ) + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/lib/taglibs-standard-impl-1.2.5.jar b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/lib/taglibs-standard-impl-1.2.5.jar new file mode 100644 index 0000000..9176777 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/lib/taglibs-standard-impl-1.2.5.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/lib/taglibs-standard-spec-1.2.5.jar b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/lib/taglibs-standard-spec-1.2.5.jar new file mode 100644 index 0000000..d547867 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/lib/taglibs-standard-spec-1.2.5.jar differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/displayProducts.tag b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/displayProducts.tag new file mode 100644 index 0000000..41e8c35 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/displayProducts.tag @@ -0,0 +1,55 @@ + +<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> +<%@ attribute name="normalPrice" fragment="true" %> +<%@ attribute name="onSale" fragment="true" %> +<%@ variable name-given="name" %> +<%@ variable name-given="price" %> +<%@ variable name-given="origPrice" %> +<%@ variable name-given="salePrice" %> + + + + + + + + + +
    + + + + + + + + + + + + + + + + + + + + + +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/helloWorld.tag b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/helloWorld.tag new file mode 100644 index 0000000..192bf53 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/helloWorld.tag @@ -0,0 +1,17 @@ + +Hello, world! diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/panel.tag b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/panel.tag new file mode 100644 index 0000000..f4f30d0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/panel.tag @@ -0,0 +1,29 @@ + +<%@ attribute name="color" %> +<%@ attribute name="bgcolor" %> +<%@ attribute name="title" %> + + + + + + + +
    ${title}
    + +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/xhtmlbasic.tag b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/xhtmlbasic.tag new file mode 100644 index 0000000..170a9bc --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/tags/xhtmlbasic.tag @@ -0,0 +1,21 @@ + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/web.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/web.xml new file mode 100644 index 0000000..669e85d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/WEB-INF/web.xml @@ -0,0 +1,438 @@ + + + + + + Servlet and JSP Examples. + + Servlet and JSP Examples + + + + Timing filter + filters.ExampleFilter + + attribute + filters.ExampleFilter + + + + + Request Dumper Filter + org.apache.catalina.filters.RequestDumperFilter + + + + + Set Character Encoding + org.apache.catalina.filters.SetCharacterEncodingFilter + + encoding + EUC_JP + + + ignore + true + + + + + Compression Filter + compressionFilters.CompressionFilter + + compressionThreshold + 128 + + + compressionBuffer + 8192 + + + compressionMimeTypes + text/html,text/plain,text/xml + + + debug + 0 + + + + + + + + HTTP header security filter + org.apache.catalina.filters.HttpHeaderSecurityFilter + true + + hstsEnabled + false + + + + + + + + + + + + + + + + HTTP header security filter + /* + + + + + listeners.ContextListener + + + listeners.SessionListener + + + + + async.AsyncStockContextListener + + + + + + ServletToJsp + ServletToJsp + + + ChatServlet + chat.ChatServlet + + + CompressionFilterTestServlet + compressionFilters.CompressionFilterTestServlet + + + HelloWorldExample + HelloWorldExample + + + RequestInfoExample + RequestInfoExample + + + RequestHeaderExample + RequestHeaderExample + + + RequestParamExample + RequestParamExample + + + CookieExample + CookieExample + + + SessionExample + SessionExample + + + + ChatServlet + /servlets/chat/chat + + + CompressionFilterTestServlet + /CompressionTest + + + HelloWorldExample + /servlets/servlet/HelloWorldExample + + + RequestInfoExample + /servlets/servlet/RequestInfoExample/* + + + RequestHeaderExample + /servlets/servlet/RequestHeaderExample + + + RequestParamExample + /servlets/servlet/RequestParamExample + + + CookieExample + /servlets/servlet/CookieExample + + + SessionExample + /servlets/servlet/SessionExample + + + ServletToJsp + /servletToJsp + + + + + + http://tomcat.apache.org/debug-taglib + + + /WEB-INF/jsp/debug-taglib.tld + + + + + + http://tomcat.apache.org/example-taglib + + + /WEB-INF/jsp/example-taglib.tld + + + + + + http://tomcat.apache.org/jsp2-example-taglib + + + /WEB-INF/jsp2/jsp2-example-taglib.tld + + + + + + Special property group for JSP Configuration JSP example. + + JSPConfiguration + /jsp/jsp2/misc/config.jsp + true + ISO-8859-1 + true + /jsp/jsp2/misc/prelude.jspf + /jsp/jsp2/misc/coda.jspf + + + + + Example Security Constraint + + Protected Area + + /jsp/security/protected/* + + DELETE + GET + POST + PUT + + + + tomcat + role1 + + + + + + FORM + Example Form-Based Authentication Area + + /jsp/security/protected/login.jsp + /jsp/security/protected/error.jsp + + + + + + role1 + + + tomcat + + + + + + minExemptions + java.lang.Integer + 1 + + + foo/name1 + java.lang.String + value1 + + + foo/bar/name2 + java.lang.Boolean + true + + + name3 + java.lang.Integer + 1 + + + foo/name4 + java.lang.Integer + 10 + + + + + async0 + async.Async0 + true + + + async0 + /async/async0 + + + async1 + async.Async1 + true + + + async1 + /async/async1 + + + async2 + async.Async2 + true + + + async2 + /async/async2 + + + async3 + async.Async3 + true + + + async3 + /async/async3 + + + stock + async.AsyncStockServlet + true + + + stock + /async/stockticker + + + + + wsEchoStream + websocket.tc7.echo.EchoStream + + + wsEchoStream + /websocket/tc7/echoStream + + + wsEchoMessage + websocket.tc7.echo.EchoMessage + + + + + wsEchoMessage + /websocket/tc7/echoMessage + + + wsChat + websocket.tc7.chat.ChatWebSocketServlet + + + wsChat + /websocket/tc7/chat + + + wsSnake + websocket.tc7.snake.SnakeWebSocketServlet + + + wsSnake + /websocket/tc7/snake + + + + websocket.drawboard.DrawboardContextListener + + + + index.html + index.xhtml + index.htm + index.jsp + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/index.html new file mode 100644 index 0000000..f58bfef --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/index.html @@ -0,0 +1,32 @@ + + + +Apache Tomcat Examples + + +

    +

    Apache Tomcat Examples

    +

    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async1.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async1.jsp new file mode 100644 index 0000000..b7e3da6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async1.jsp @@ -0,0 +1,26 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@page session="false"%> +Output from async1.jsp +Type is <%=request.getDispatcherType()%> +<% +System.out.println("Inside Async 1"); + if (request.isAsyncStarted()) { + request.getAsyncContext().complete(); + } +%> +Completed async request at <%=new java.sql.Date(System.currentTimeMillis())%> \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async1.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async1.jsp.html new file mode 100644 index 0000000..9a52e71 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async1.jsp.html @@ -0,0 +1,28 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@page session="false"%>
    +Output from async1.jsp
    +Type is <%=request.getDispatcherType()%>
    +<%
    +System.out.println("Inside Async 1");
    +  if (request.isAsyncStarted()) {
    +    request.getAsyncContext().complete();
    +  }
    +%>
    +Completed async request at <%=new java.sql.Date(System.currentTimeMillis())%>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async3.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async3.jsp new file mode 100644 index 0000000..fd54054 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async3.jsp @@ -0,0 +1,20 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@page session="false"%> +Output from async3.jsp +Type is <%=request.getDispatcherType()%> +Completed async 3 request at <%=new java.sql.Date(System.currentTimeMillis())%> \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async3.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async3.jsp.html new file mode 100644 index 0000000..671a409 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/async3.jsp.html @@ -0,0 +1,22 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@page session="false"%>
    +Output from async3.jsp
    +Type is <%=request.getDispatcherType()%>
    +Completed async 3 request at <%=new java.sql.Date(System.currentTimeMillis())%>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/index.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/index.jsp new file mode 100644 index 0000000..be2d713 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/index.jsp @@ -0,0 +1,69 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@page session="false"%> + +
    +Use cases:
    +
    +1. Simple dispatch
    + - servlet does startAsync()
    + - background thread calls ctx.dispatch()
    +   "> Async 0 
    +
    +2. Simple dispatch
    + - servlet does startAsync()
    + - background thread calls dispatch(/path/to/jsp)
    +   "> Async 1 
    +
    +3. Simple dispatch
    + - servlet does startAsync()
    + - background thread calls writes and calls complete()
    +   "> Async 2 
    +
    +4. Simple dispatch
    + - servlet does a startAsync()
    + - servlet calls dispatch(/path/to/jsp)
    + - servlet calls complete()
    +   "> Async 3 
    +
    +3. Timeout s1
    + - servlet does a startAsync()
    + - servlet does a setAsyncTimeout
    + - returns - waits for timeout to happen should return error page
    +
    +4. Timeout s2
    + - servlet does a startAsync()
    + - servlet does a setAsyncTimeout
    + - servlet does a addAsyncListener
    + - returns - waits for timeout to happen and listener invoked
    +
    +5. Dispatch to asyncSupported=false servlet
    + - servlet1 does a startAsync()
    + - servlet1 dispatches to dispatch(/servlet2)
    + - the container calls complete() after servlet2 is complete
    + - TODO
    +
    +6. Chained dispatch
    + - servlet1 does a startAsync
    + - servlet1 does a dispatch to servlet2 (asyncsupported=true)
    + - servlet2 does a dispatch to servlet3 (asyncsupported=true)
    + - servlet3 does a dispatch to servlet4 (asyncsupported=false)
    +
    +
    +7. Stock ticker
    +   "> StockTicker 
    +
    \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/index.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/index.jsp.html new file mode 100644 index 0000000..8099de8 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/async/index.jsp.html @@ -0,0 +1,71 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@page session="false"%>
    +
    +<pre>
    +Use cases:
    +
    +1. Simple dispatch
    + - servlet does startAsync()
    + - background thread calls ctx.dispatch()
    +   <a href="<%=response.encodeURL("/examples/async/async0")%>"> Async 0 </a>
    +
    +2. Simple dispatch
    + - servlet does startAsync()
    + - background thread calls dispatch(/path/to/jsp)
    +   <a href="<%=response.encodeURL("/examples/async/async1")%>"> Async 1 </a>
    +
    +3. Simple dispatch
    + - servlet does startAsync()
    + - background thread calls writes and calls complete()
    +   <a href="<%=response.encodeURL("/examples/async/async2")%>"> Async 2 </a>
    +
    +4. Simple dispatch
    + - servlet does a startAsync()
    + - servlet calls dispatch(/path/to/jsp)
    + - servlet calls complete()
    +   <a href="<%=response.encodeURL("/examples/async/async3")%>"> Async 3 </a>
    +
    +3. Timeout s1
    + - servlet does a startAsync()
    + - servlet does a setAsyncTimeout
    + - returns - waits for timeout to happen should return error page
    +
    +4. Timeout s2
    + - servlet does a startAsync()
    + - servlet does a setAsyncTimeout
    + - servlet does a addAsyncListener
    + - returns - waits for timeout to happen and listener invoked
    +
    +5. Dispatch to asyncSupported=false servlet
    + - servlet1 does a startAsync()
    + - servlet1 dispatches to dispatch(/servlet2)
    + - the container calls complete() after servlet2 is complete
    + - TODO
    +
    +6. Chained dispatch
    + - servlet1 does a startAsync
    + - servlet1 does a dispatch to servlet2 (asyncsupported=true)
    + - servlet2 does a dispatch to servlet3 (asyncsupported=true)
    + - servlet3 does a dispatch to servlet4 (asyncsupported=false)
    +
    +
    +7. Stock ticker
    +   <a href="<%=response.encodeURL("/examples/async/stockticker")%>"> StockTicker </a>
    +</pre>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/Entries.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/Entries.java.html new file mode 100644 index 0000000..5bbdc91 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/Entries.java.html @@ -0,0 +1,62 @@ +
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one or more
    + * contributor license agreements.  See the NOTICE file distributed with
    + * this work for additional information regarding copyright ownership.
    + * The ASF licenses this file to You under the Apache License, Version 2.0
    + * (the "License"); you may not use this file except in compliance with
    + * the License.  You may obtain a copy of the License at
    + *
    + *     http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing, software
    + * distributed under the License is distributed on an "AS IS" BASIS,
    + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    + * See the License for the specific language governing permissions and
    + * limitations under the License.
    + */
    +package cal;
    +
    +import java.util.Hashtable;
    +
    +import javax.servlet.http.HttpServletRequest;
    +
    +public class Entries {
    +
    +    private Hashtable<String, Entry> entries;
    +    private static final String[] time = { "8am", "9am", "10am", "11am",
    +            "12pm", "1pm", "2pm", "3pm", "4pm", "5pm", "6pm", "7pm", "8pm" };
    +    public static final int rows = 12;
    +
    +    public Entries() {
    +        entries = new Hashtable<String, Entry>(rows);
    +        for (int i = 0; i < rows; i++) {
    +            entries.put(time[i], new Entry(time[i]));
    +        }
    +    }
    +
    +    public int getRows() {
    +        return rows;
    +    }
    +
    +    public Entry getEntry(int index) {
    +        return this.entries.get(time[index]);
    +    }
    +
    +    public int getIndex(String tm) {
    +        for (int i = 0; i < rows; i++)
    +            if (tm.equals(time[i]))
    +                return i;
    +        return -1;
    +    }
    +
    +    public void processRequest(HttpServletRequest request, String tm) {
    +        int index = getIndex(tm);
    +        if (index >= 0) {
    +            String descr = request.getParameter("description");
    +            entries.get(time[index]).setDescription(descr);
    +        }
    +    }
    +
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/Entry.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/Entry.java.html new file mode 100644 index 0000000..65e768d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/Entry.java.html @@ -0,0 +1,55 @@ +
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one or more
    + * contributor license agreements.  See the NOTICE file distributed with
    + * this work for additional information regarding copyright ownership.
    + * The ASF licenses this file to You under the Apache License, Version 2.0
    + * (the "License"); you may not use this file except in compliance with
    + * the License.  You may obtain a copy of the License at
    + *
    + *     http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing, software
    + * distributed under the License is distributed on an "AS IS" BASIS,
    + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    + * See the License for the specific language governing permissions and
    + * limitations under the License.
    + */
    +
    +package cal;
    +
    +public class Entry {
    +
    +    String hour;
    +    String description;
    +
    +    public Entry(String hour) {
    +        this.hour = hour;
    +        this.description = "";
    +
    +    }
    +
    +    public String getHour() {
    +        return this.hour;
    +    }
    +
    +    public String getColor() {
    +        if (description.equals("")) {
    +            return "lightblue";
    +        }
    +        return "red";
    +    }
    +
    +    public String getDescription() {
    +        if (description.equals("")) {
    +            return "None";
    +        }
    +        return this.description;
    +    }
    +
    +    public void setDescription(String descr) {
    +        description = descr;
    +    }
    +
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/JspCalendar.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/JspCalendar.java.html new file mode 100644 index 0000000..6ca9efa --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/JspCalendar.java.html @@ -0,0 +1,153 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +package cal;
    +
    +import java.util.Calendar;
    +import java.util.Date;
    +
    +public class JspCalendar {
    +    Calendar  calendar = null;
    +
    +    public JspCalendar() {
    +        calendar = Calendar.getInstance();
    +        Date trialTime = new Date();
    +        calendar.setTime(trialTime);
    +    }
    +
    +
    +    public int getYear() {
    +        return calendar.get(Calendar.YEAR);
    +    }
    +
    +    public String getMonth() {
    +        int m = getMonthInt();
    +        String[] months = new String [] { "January", "February", "March",
    +                                        "April", "May", "June",
    +                                        "July", "August", "September",
    +                                        "October", "November", "December" };
    +        if (m > 12)
    +            return "Unknown to Man";
    +
    +        return months[m - 1];
    +
    +    }
    +
    +    public String getDay() {
    +        int x = getDayOfWeek();
    +        String[] days = new String[] {"Sunday", "Monday", "Tuesday", "Wednesday",
    +                                      "Thursday", "Friday", "Saturday"};
    +
    +        if (x > 7)
    +            return "Unknown to Man";
    +
    +        return days[x - 1];
    +
    +    }
    +
    +    public int getMonthInt() {
    +        return 1 + calendar.get(Calendar.MONTH);
    +    }
    +
    +    public String getDate() {
    +        return getMonthInt() + "/" + getDayOfMonth() + "/" +  getYear();
    +    }
    +
    +    public String getCurrentDate() {
    +        Date dt = new Date ();
    +        calendar.setTime (dt);
    +        return getMonthInt() + "/" + getDayOfMonth() + "/" +  getYear();
    +
    +    }
    +
    +    public String getNextDate() {
    +        calendar.set (Calendar.DAY_OF_MONTH, getDayOfMonth() + 1);
    +        return getDate ();
    +    }
    +
    +    public String getPrevDate() {
    +        calendar.set (Calendar.DAY_OF_MONTH, getDayOfMonth() - 1);
    +        return getDate ();
    +    }
    +
    +    public String getTime() {
    +        return getHour() + ":" + getMinute() + ":" + getSecond();
    +    }
    +
    +    public int getDayOfMonth() {
    +        return calendar.get(Calendar.DAY_OF_MONTH);
    +    }
    +
    +    public int getDayOfYear() {
    +        return calendar.get(Calendar.DAY_OF_YEAR);
    +    }
    +
    +    public int getWeekOfYear() {
    +        return calendar.get(Calendar.WEEK_OF_YEAR);
    +    }
    +
    +    public int getWeekOfMonth() {
    +        return calendar.get(Calendar.WEEK_OF_MONTH);
    +    }
    +
    +    public int getDayOfWeek() {
    +        return calendar.get(Calendar.DAY_OF_WEEK);
    +    }
    +
    +    public int getHour() {
    +        return calendar.get(Calendar.HOUR_OF_DAY);
    +    }
    +
    +    public int getMinute() {
    +        return calendar.get(Calendar.MINUTE);
    +    }
    +
    +
    +    public int getSecond() {
    +        return calendar.get(Calendar.SECOND);
    +    }
    +
    +
    +    public int getEra() {
    +        return calendar.get(Calendar.ERA);
    +    }
    +
    +    public String getUSTimeZone() {
    +        String[] zones = new String[] {"Hawaii", "Alaskan", "Pacific",
    +                                       "Mountain", "Central", "Eastern"};
    +
    +        return zones[10 + getZoneOffset()];
    +    }
    +
    +    public int getZoneOffset() {
    +        return calendar.get(Calendar.ZONE_OFFSET)/(60*60*1000);
    +    }
    +
    +
    +    public int getDSTOffset() {
    +        return calendar.get(Calendar.DST_OFFSET)/(60*60*1000);
    +    }
    +
    +
    +    public int getAMPM() {
    +        return calendar.get(Calendar.AM_PM);
    +    }
    +}
    +
    +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/TableBean.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/TableBean.java.html new file mode 100644 index 0000000..54a160f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/TableBean.java.html @@ -0,0 +1,103 @@ +
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one or more
    + * contributor license agreements.  See the NOTICE file distributed with
    + * this work for additional information regarding copyright ownership.
    + * The ASF licenses this file to You under the Apache License, Version 2.0
    + * (the "License"); you may not use this file except in compliance with
    + * the License.  You may obtain a copy of the License at
    + *
    + *     http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing, software
    + * distributed under the License is distributed on an "AS IS" BASIS,
    + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    + * See the License for the specific language governing permissions and
    + * limitations under the License.
    + */
    +package cal;
    +
    +import java.util.Hashtable;
    +
    +import javax.servlet.http.HttpServletRequest;
    +
    +public class TableBean {
    +
    +    Hashtable<String, Entries> table;
    +    JspCalendar JspCal;
    +    Entries entries;
    +    String date;
    +    String name = null;
    +    String email = null;
    +    boolean processError = false;
    +
    +    public TableBean() {
    +        this.table = new Hashtable<String, Entries>(10);
    +        this.JspCal = new JspCalendar();
    +        this.date = JspCal.getCurrentDate();
    +    }
    +
    +    public void setName(String nm) {
    +        this.name = nm;
    +    }
    +
    +    public String getName() {
    +        return this.name;
    +    }
    +
    +    public void setEmail(String mail) {
    +        this.email = mail;
    +    }
    +
    +    public String getEmail() {
    +        return this.email;
    +    }
    +
    +    public String getDate() {
    +        return this.date;
    +    }
    +
    +    public Entries getEntries() {
    +        return this.entries;
    +    }
    +
    +    public void processRequest(HttpServletRequest request) {
    +
    +        // Get the name and e-mail.
    +        this.processError = false;
    +        if (name == null || name.equals(""))
    +            setName(request.getParameter("name"));
    +        if (email == null || email.equals(""))
    +            setEmail(request.getParameter("email"));
    +        if (name == null || email == null || name.equals("")
    +                || email.equals("")) {
    +            this.processError = true;
    +            return;
    +        }
    +
    +        // Get the date.
    +        String dateR = request.getParameter("date");
    +        if (dateR == null)
    +            date = JspCal.getCurrentDate();
    +        else if (dateR.equalsIgnoreCase("next"))
    +            date = JspCal.getNextDate();
    +        else if (dateR.equalsIgnoreCase("prev"))
    +            date = JspCal.getPrevDate();
    +
    +        entries = table.get(date);
    +        if (entries == null) {
    +            entries = new Entries();
    +            table.put(date, entries);
    +        }
    +
    +        // If time is provided add the event.
    +        String time = request.getParameter("time");
    +        if (time != null)
    +            entries.processRequest(request, time);
    +    }
    +
    +    public boolean getProcessError() {
    +        return this.processError;
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal1.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal1.jsp new file mode 100644 index 0000000..6454311 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal1.jsp @@ -0,0 +1,93 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + Calendar: A JSP APPLICATION + + + + + +<%@ page language="java" import="cal.*" %> + + +<% + table.processRequest(request); + if (table.getProcessError() == false) { +%> + + +
    + + + + +
    prev + Calendar:<%= table.getDate() %> next +
    + + + + + + + + +<% + for(int i=0; i + + + + +<% + } +%> + +
    Time Appointment
    + > + <%= entr.getHour() %> + > + <% out.print(util.HTMLFilter.filter(entr.getDescription())); %> +
    +
    + + + + + + +
    <% out.print(util.HTMLFilter.filter(table.getName())); %> : + <% out.print(util.HTMLFilter.filter(table.getEmail())); %>
    +
    + +<% + } else { +%> + + You must enter your name and email address correctly. + +<% + } +%> + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal1.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal1.jsp.html new file mode 100644 index 0000000..b8a5202 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal1.jsp.html @@ -0,0 +1,95 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<HTML>
    +<HEAD><TITLE>
    +    Calendar: A JSP APPLICATION
    +</TITLE></HEAD>
    +
    +
    +<BODY BGCOLOR="white">
    +
    +<%@ page language="java" import="cal.*" %>
    +<jsp:useBean id="table" scope="session" class="cal.TableBean" />
    +
    +<%
    +    table.processRequest(request);
    +    if (table.getProcessError() == false) {
    +%>
    +
    +<!-- HTML table goes here -->
    +<CENTER>
    +<TABLE WIDTH=60% BGCOLOR=yellow CELLPADDING=15>
    +<TR>
    +<TD ALIGN=CENTER> <A HREF=cal1.jsp?date=prev> prev </A>
    +<TD ALIGN=CENTER> Calendar:<%= table.getDate() %></TD>
    +<TD ALIGN=CENTER> <A HREF=cal1.jsp?date=next> next </A>
    +</TR>
    +</TABLE>
    +
    +<!-- the main table -->
    +<TABLE WIDTH=60% BGCOLOR=lightblue BORDER=1 CELLPADDING=10>
    +<TR>
    +<TH> Time </TH>
    +<TH> Appointment </TH>
    +</TR>
    +<FORM METHOD=POST ACTION=cal1.jsp>
    +<%
    +    for(int i=0; i<table.getEntries().getRows(); i++) {
    +       cal.Entry entr = table.getEntries().getEntry(i);
    +%>
    +    <TR>
    +    <TD>
    +    <A HREF=cal2.jsp?time=<%= entr.getHour() %>>
    +        <%= entr.getHour() %> </A>
    +    </TD>
    +    <TD BGCOLOR=<%= entr.getColor() %>>
    +    <% out.print(util.HTMLFilter.filter(entr.getDescription())); %>
    +    </TD>
    +    </TR>
    +<%
    +    }
    +%>
    +</FORM>
    +</TABLE>
    +<BR>
    +
    +<!-- footer -->
    +<TABLE WIDTH=60% BGCOLOR=yellow CELLPADDING=15>
    +<TR>
    +<TD ALIGN=CENTER>  <% out.print(util.HTMLFilter.filter(table.getName())); %> :
    +             <% out.print(util.HTMLFilter.filter(table.getEmail())); %> </TD>
    +</TR>
    +</TABLE>
    +</CENTER>
    +
    +<%
    +    } else {
    +%>
    +<font size=5>
    +    You must enter your name and email address correctly.
    +</font>
    +<%
    +    }
    +%>
    +
    +
    +</BODY>
    +</HTML>
    +
    +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal2.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal2.jsp new file mode 100644 index 0000000..46a36bb --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal2.jsp @@ -0,0 +1,44 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + Calendar: A JSP APPLICATION + + + + + + +<% + String time = request.getParameter ("time"); +%> + + Please add the following event: +

    Date <%= table.getDate() %> +
    Time <%= util.HTMLFilter.filter(time) %>

    +
    +
    +
    +
    +
    +

    Description of the event

    +
    +
    + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal2.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal2.jsp.html new file mode 100644 index 0000000..a4329da --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/cal2.jsp.html @@ -0,0 +1,46 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<HTML>
    +<HEAD><TITLE>
    +    Calendar: A JSP APPLICATION
    +</TITLE></HEAD>
    +
    +
    +<BODY BGCOLOR="white">
    +<jsp:useBean id="table" scope="session" class="cal.TableBean" />
    +
    +<%
    +    String time = request.getParameter ("time");
    +%>
    +
    +<FONT SIZE=5> Please add the following event:
    +<BR> <h3> Date <%= table.getDate() %>
    +<BR> Time <%= util.HTMLFilter.filter(time) %> </h3>
    +</FONT>
    +<FORM METHOD=POST ACTION=cal1.jsp>
    +<BR>
    +<BR> <INPUT NAME="date" TYPE=HIDDEN VALUE="current">
    +<BR> <INPUT NAME="time" TYPE=HIDDEN VALUE="<%= util.HTMLFilter.filter(time) %>">
    +<BR> <h2> Description of the event <INPUT NAME="description" TYPE=TEXT SIZE=20> </h2>
    +<BR> <INPUT TYPE=SUBMIT VALUE="submit">
    +</FORM>
    +
    +</BODY>
    +</HTML>
    +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/calendar.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/calendar.html new file mode 100644 index 0000000..a0a3ea1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/calendar.html @@ -0,0 +1,43 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for Calendar Example.
    +

    cal1.jsp +

    +

    cal2.jsp +

    + +
    +

    Beans. +

    TableBean +

    +

    Entries +

    +

    Entry +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/login.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/login.html new file mode 100644 index 0000000..8a62eca --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/cal/login.html @@ -0,0 +1,47 @@ + + + + + Login page for the calendar. + + + +
    + + Please Enter the following information: + +
    +
    + + Name + +
    + Email + +
    + + +
    +
    + Note: This application does not implement the complete +functionality of a typical calendar application. It demonstrates a way JSP can +be used with HTML tables and forms. + +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/CheckTest.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/CheckTest.html new file mode 100644 index 0000000..284d9ec --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/CheckTest.html @@ -0,0 +1,56 @@ + + + + + +checkbox.CheckTest Bean Properties + + +

    +checkbox.CheckTest Bean Properties +

    +
    +
    +
    public class CheckTest
    extends Object
    + +

    +


    + +

    + + + + + + + + + +
    +Properties Summary
    + +String +CheckTest:fruit +
    +
    + +Multi +
    +


    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/check.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/check.html new file mode 100644 index 0000000..b6d6b3b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/check.html @@ -0,0 +1,38 @@ + + + + + + +
    +
    + +Check all Favorite fruits:
    + + Apples
    + Grapes
    + Oranges
    + Melons
    + + +
    + +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/checkresult.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/checkresult.jsp new file mode 100644 index 0000000..4e64739 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/checkresult.jsp @@ -0,0 +1,65 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + +<%! String[] fruits; %> + + + +
    +The checked fruits (got using request) are:
    +<% + fruits = request.getParameterValues("fruit"); +%> +
      +<% + if (fruits != null) { + for (String fruit : fruits) { +%> +
    • +<% + out.println (util.HTMLFilter.filter(fruit)); + } + } else out.println ("none selected"); +%> +
    +
    +
    + +The checked fruits (got using beans) are
    + +<% + fruits = foo.getFruit(); +%> +
      +<% + if (!fruits[0].equals("1")) { + for (String fruit : fruits) { +%> +
    • +<% + out.println (util.HTMLFilter.filter(fruit)); + } + } else { + out.println ("none selected"); + } +%> +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/checkresult.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/checkresult.jsp.html new file mode 100644 index 0000000..4fbb10e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/checkresult.jsp.html @@ -0,0 +1,67 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<body bgcolor="white">
    +<font size=5 color="red">
    +<%! String[] fruits; %>
    +<jsp:useBean id="foo" scope="page" class="checkbox.CheckTest" />
    +
    +<jsp:setProperty name="foo" property="fruit" param="fruit" />
    +<hr>
    +The checked fruits (got using request) are: <br>
    +<%
    +    fruits = request.getParameterValues("fruit");
    +%>
    +<ul>
    +<%
    +    if (fruits != null) {
    +        for (String fruit : fruits) {
    +%>
    +<li>
    +<%
    +            out.println (util.HTMLFilter.filter(fruit));
    +        }
    +    } else out.println ("none selected");
    +%>
    +</ul>
    +<br>
    +<hr>
    +
    +The checked fruits (got using beans) are <br>
    +
    +<%
    +        fruits = foo.getFruit();
    +%>
    +<ul>
    +<%
    +    if (!fruits[0].equals("1")) {
    +        for (String fruit : fruits) {
    +%>
    +<li>
    +<%
    +            out.println (util.HTMLFilter.filter(fruit));
    +        }
    +    } else {
    +        out.println ("none selected");
    +    }
    +%>
    +</ul>
    +</font>
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/cresult.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/cresult.html new file mode 100644 index 0000000..b6a28d6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/checkbox/cresult.html @@ -0,0 +1,34 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for Checkbox Example +

    + +

    Property Sheet for CheckTest +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/ColorGameBean.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/ColorGameBean.html new file mode 100644 index 0000000..172bc66 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/ColorGameBean.html @@ -0,0 +1,116 @@ + + + + + +colors.ColorGameBean Bean Properties + + +

    +colors.ColorGameBean Bean Properties +

    +
    +
    +
    public class ColorGameBean
    extends Object
    + +

    +


    + +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +Properties Summary
    + +String +ColorGameBean:color2 +
    +
    + +Single +
    + +String +ColorGameBean:color1 +
    +
    + +Single +
    + +int +ColorGameBean:attempts +
    +
    + +Single +
    + +boolean +ColorGameBean:hint +
    +
    + +Single +
    + +boolean +ColorGameBean:success +
    +
    + +Single +
    + +boolean +ColorGameBean:hintTaken +
    +
    + +Single +
    +


    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/clr.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/clr.html new file mode 100644 index 0000000..e411f59 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/clr.html @@ -0,0 +1,34 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for Color Example +

    + +

    Property Sheet for ColorGameBean +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colors.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colors.html new file mode 100644 index 0000000..900651e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colors.html @@ -0,0 +1,47 @@ + + + + + + +
    +This web page is an example using JSP and BEANs. +

    +Guess my favorite two colors + +

    If you fail to guess both of them - you get yellow on red. + +

    If you guess one of them right, either your foreground or + your background will change to the color that was guessed right. + +

    Guess them both right and your browser foreground/background + will change to my two favorite colors to display this page. + +


    +
    +Color #1: +
    +Color #2: +

    + + +

    + +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colrs.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colrs.jsp new file mode 100644 index 0000000..ec3af88 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colrs.jsp @@ -0,0 +1,70 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + + + +<% + cb.processRequest(); +%> + +> +> +

    + +<% if (cb.getHint()==true) { %> + +

    Hint #1: Vampires prey at night! +

    Hint #2: Nancy without the n. + +<% } %> + +<% if (cb.getSuccess()==true) { %> + +

    CONGRATULATIONS!! + <% if (cb.getHintTaken()==true) { %> + +

    ( although I know you cheated and peeked into the hints) + + <% } %> + +<% } %> + +

    Total attempts so far: <%= cb.getAttempts() %> +

    + +

    + +

    + +Color #1: + +
    + +Color #2: + +

    + + + + +

    + +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colrs.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colrs.jsp.html new file mode 100644 index 0000000..a5119f1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/colors/colrs.jsp.html @@ -0,0 +1,72 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +
    +<jsp:useBean id="cb" scope="session" class="colors.ColorGameBean" />
    +<jsp:setProperty name="cb" property="*" />
    +
    +<%
    +    cb.processRequest();
    +%>
    +
    +<body bgcolor=<%= cb.getColor1() %>>
    +<font size=6 color=<%= cb.getColor2() %>>
    +<p>
    +
    +<% if (cb.getHint()==true) { %>
    +
    +    <p> Hint #1: Vampires prey at night!
    +    <p>  <p> Hint #2: Nancy without the n.
    +
    +<% } %>
    +
    +<% if  (cb.getSuccess()==true) { %>
    +
    +    <p> CONGRATULATIONS!!
    +    <% if  (cb.getHintTaken()==true) { %>
    +
    +        <p> ( although I know you cheated and peeked into the hints)
    +
    +    <% } %>
    +
    +<% } %>
    +
    +<p> Total attempts so far: <%= cb.getAttempts() %>
    +<p>
    +
    +<p>
    +
    +<form method=POST action=colrs.jsp>
    +
    +Color #1: <input type=text name= color1 size=16>
    +
    +<br>
    +
    +Color #2: <input type=text name= color2 size=16>
    +
    +<p>
    +
    +<input type=submit name=action value="Submit">
    +<input type=submit name=action value="Hint">
    +
    +</form>
    +
    +</font>
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.html new file mode 100644 index 0000000..683ab4d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.html @@ -0,0 +1,31 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for Date Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.jsp new file mode 100644 index 0000000..d6c6b86 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.jsp @@ -0,0 +1,41 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + +<%@ page session="false"%> + + + + + +
      +
    • Day of month: is +
    • Year: is +
    • Month: is +
    • Time: is +
    • Date: is +
    • Day: is +
    • Day Of Year: is +
    • Week Of Year: is +
    • era: is +
    • DST Offset: is +
    • Zone Offset: is +
    +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.jsp.html new file mode 100644 index 0000000..d251504 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/dates/date.jsp.html @@ -0,0 +1,43 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +
    +<%@ page session="false"%>
    +
    +<body bgcolor="white">
    +<jsp:useBean id='clock' scope='page' class='dates.JspCalendar' type="dates.JspCalendar" />
    +
    +<font size=4>
    +<ul>
    +<li>    Day of month: is  <jsp:getProperty name="clock" property="dayOfMonth"/>
    +<li>    Year: is  <jsp:getProperty name="clock" property="year"/>
    +<li>    Month: is  <jsp:getProperty name="clock" property="month"/>
    +<li>    Time: is  <jsp:getProperty name="clock" property="time"/>
    +<li>    Date: is  <jsp:getProperty name="clock" property="date"/>
    +<li>    Day: is  <jsp:getProperty name="clock" property="day"/>
    +<li>    Day Of Year: is  <jsp:getProperty name="clock" property="dayOfYear"/>
    +<li>    Week Of Year: is  <jsp:getProperty name="clock" property="weekOfYear"/>
    +<li>    era: is  <jsp:getProperty name="clock" property="era"/>
    +<li>    DST Offset: is  <jsp:getProperty name="clock" property="DSTOffset"/>
    +<li>    Zone Offset: is  <jsp:getProperty name="clock" property="zoneOffset"/>
    +</ul>
    +</font>
    +
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/er.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/er.html new file mode 100644 index 0000000..af78159 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/er.html @@ -0,0 +1,31 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for Error Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/err.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/err.jsp new file mode 100644 index 0000000..d188456 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/err.jsp @@ -0,0 +1,44 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + + <%@ page errorPage="errorpge.jsp" %> + + <% + String name = null; + + if (request.getParameter("name") == null) { + %> + <%@ include file="error.html" %> + <% + } else { + foo.setName(request.getParameter("name")); + if (foo.getName().equalsIgnoreCase("integra")) + name = "acura"; + if (name.equalsIgnoreCase("acura")) { + %> + +

    Yes!!! Acura is my favorite car. + + <% + } + } + %> + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/err.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/err.jsp.html new file mode 100644 index 0000000..a9c0ca1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/err.jsp.html @@ -0,0 +1,46 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<body bgcolor="lightblue">
    +
    +    <%@ page errorPage="errorpge.jsp" %>
    +    <jsp:useBean id="foo" scope="request" class="error.Smart" />
    +    <%
    +        String name = null;
    +
    +        if (request.getParameter("name") == null) {
    +    %>
    +    <%@ include file="error.html" %>
    +    <%
    +        } else {
    +          foo.setName(request.getParameter("name"));
    +          if (foo.getName().equalsIgnoreCase("integra"))
    +              name = "acura";
    +          if (name.equalsIgnoreCase("acura")) {
    +    %>
    +
    +    <H1> Yes!!! <a href="http://www.acura.com">Acura</a> is my favorite car.
    +
    +    <%
    +          }
    +        }
    +    %>
    +</body>
    +</html>
    +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/error.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/error.html new file mode 100644 index 0000000..b1b029c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/error.html @@ -0,0 +1,37 @@ + + + + + +

    This example uses errorpage directive

    +
    +

    Select my favourite car.

    +
    + + +
    +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/errorpge.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/errorpge.jsp new file mode 100644 index 0000000..5c6eb0a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/errorpge.jsp @@ -0,0 +1,25 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + + + <%@ page isErrorPage="true" %> +

    The exception <%= exception.getMessage() %> tells me you + made a wrong choice. + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/errorpge.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/errorpge.jsp.html new file mode 100644 index 0000000..4fb58a8 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/error/errorpge.jsp.html @@ -0,0 +1,27 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +
    +<body bgcolor="red">
    +
    +    <%@ page isErrorPage="true" %>
    +    <h1> The exception <%= exception.getMessage() %> tells me you
    +         made a wrong choice.
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/forward.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/forward.jsp new file mode 100644 index 0000000..092d9b4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/forward.jsp @@ -0,0 +1,33 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + +<% + double freeMem = Runtime.getRuntime().freeMemory(); + double totlMem = Runtime.getRuntime().totalMemory(); + double percent = freeMem/totlMem; + if (percent < 0.5) { +%> + + + +<% } else { %> + + + +<% } %> + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/forward.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/forward.jsp.html new file mode 100644 index 0000000..1e05077 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/forward.jsp.html @@ -0,0 +1,35 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<%
    +   double freeMem = Runtime.getRuntime().freeMemory();
    +   double totlMem = Runtime.getRuntime().totalMemory();
    +   double percent = freeMem/totlMem;
    +   if (percent < 0.5) {
    +%>
    +
    +<jsp:forward page="one.jsp"/>
    +
    +<% } else { %>
    +
    +<jsp:forward page="two.html"/>
    +
    +<% } %>
    +
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/fwd.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/fwd.html new file mode 100644 index 0000000..b3b0219 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/fwd.html @@ -0,0 +1,30 @@ + + + +Untitled Document + + + + +

    + +

    Source Code for Forward Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/one.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/one.jsp new file mode 100644 index 0000000..c7f0004 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/one.jsp @@ -0,0 +1,23 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + + + +VM Memory usage < 50%. + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/one.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/one.jsp.html new file mode 100644 index 0000000..321f89a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/one.jsp.html @@ -0,0 +1,25 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +
    +<body bgcolor="white">
    +<font color="red">
    +
    +VM Memory usage &lt; 50%.
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/two.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/two.html new file mode 100644 index 0000000..24f4c08 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/forward/two.html @@ -0,0 +1,23 @@ + + + + + + +VM Memory usage > 50%. + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/code.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/code.gif new file mode 100644 index 0000000..93af2cd Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/code.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/execute.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/execute.gif new file mode 100644 index 0000000..f64d70f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/execute.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/read.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/read.gif new file mode 100644 index 0000000..66cb4e9 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/read.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/return.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/return.gif new file mode 100644 index 0000000..af4f68f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/images/return.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.html new file mode 100644 index 0000000..168c8c8 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.html @@ -0,0 +1,17 @@ + +To get the current time in ms diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.jsp new file mode 100644 index 0000000..bb476c7 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.jsp @@ -0,0 +1,17 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--%><%= System.currentTimeMillis() %> diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.jsp.html new file mode 100644 index 0000000..90b2da0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/foo.jsp.html @@ -0,0 +1,19 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +
    +--%><%= System.currentTimeMillis() %>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/inc.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/inc.html new file mode 100644 index 0000000..fedaed0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/inc.html @@ -0,0 +1,30 @@ + + + +Untitled Document + + + + +

    + +

    Source Code for Include Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/include.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/include.jsp new file mode 100644 index 0000000..62a8c22 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/include.jsp @@ -0,0 +1,30 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + + + + +<%@ page buffer="5kb" autoFlush="false" %> + +

    In place evaluation of another JSP which gives you the current time: <%@ include file="foo.jsp" %> + +

    by including the output of another JSP: +:-) + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/include.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/include.jsp.html new file mode 100644 index 0000000..27492ef --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/include/include.jsp.html @@ -0,0 +1,32 @@ +

    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +
    +<body bgcolor="white">
    +
    +<font color="red">
    +
    +<%@ page buffer="5kb" autoFlush="false" %>
    +
    +<p>In place evaluation of another JSP which gives you the current time: <%@ include file="foo.jsp" %>
    +
    +<p> <jsp:include page="foo.html" flush="true"/> by including the output of another JSP: <jsp:include page="foo.jsp" flush="true"/>
    +:-)
    +
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/index.html new file mode 100644 index 0000000..dcb4047 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/index.html @@ -0,0 +1,397 @@ + + + + + + + + JSP Examples + + +JSP +Samples +

    This is a collection of samples demonstrating the usage of different +parts of the Java Server Pages (JSP) specification. Both JSP 2.0 and +JSP 1.2 examples are presented below. +

    These examples will only work when these pages are being served by a +servlet engine; of course, we recommend +Tomcat. +They will not work if you are viewing these pages via a +"file://..." URL. +

    To navigate your way through the examples, the following icons will +help: +
      + + + + + + + + + + + + + + + + + + + + + +
    Execute the example
    Look at the source code for the example
    Return to this screen
    + +

    Tip: For session scoped beans to work, the cookies must be enabled. +This can be done using browser options. +
      +
    +JSP 2.0 Examples
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Expression Language
    Basic ArithmeticExecuteSource
    Basic ComparisonsExecuteSource
    Implicit ObjectsExecuteSource
    FunctionsExecuteSource
    Composite ExpressionsExecuteSource

    SimpleTag Handlers and JSP Fragments
    Hello World TagExecuteSource
    Repeat TagExecuteSource
    Book ExampleExecuteSource

    Tag Files
    Hello World Tag FileExecuteSource
    Panel Tag FileExecuteSource
    Display Products ExampleExecuteSource

    New JSP XML Syntax (.jspx)
    XHTML Basic ExampleExecuteSource
    SVG (Scalable Vector Graphics)ExecuteSource

    Other JSP 2.0 Features
    <jsp:attribute> and <jsp:body>ExecuteSource
    Shuffle ExampleExecuteSource
    Attributes With Dynamic NamesExecuteSource
    JSP ConfigurationExecuteSource
    + +
    +JSP 1.2 Examples
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Numberguess ExecuteSource
    Date ExecuteSource
    SnoopExecuteSource
    ErrorPage ExecuteSource
    Carts ExecuteSource
    Checkbox ExecuteSource
    Color ExecuteSource
    Calendar ExecuteSource
    Include ExecuteSource
    Forward ExecuteSource
    Plugin ExecuteSource
    JSP-Servlet-JSP ExecuteSource
    Custom tag exampleExecuteSource
    XML syntax exampleExecuteSource
    + +
    +Tag Plugins
    + + + + + + + + + + + + + + + + + + + + +
    If  + + Execute + + + Source +
    ForEach  + + Execute + + + Source +
    Choose  + + Execute + + + Source +
    + +
    +Other Examples
    + + + + + + + + + + + +
    FORM Authentication  + Execute +
    Example that demonstrates protecting a resource and + using Form-Based authentication. To access the page the user must + have role of either "tomcat" or "role1". By default no user + is configured to have these roles.
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/Functions.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/Functions.java.html new file mode 100644 index 0000000..12c567b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/Functions.java.html @@ -0,0 +1,47 @@ +

    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +package jsp2.examples.el;
    +
    +import java.util.Locale;
    +
    +/**
    + * Defines the functions for the jsp2 example tag library.
    + *
    + * <p>Each function is defined as a static method.</p>
    + */
    +public class Functions {
    +    public static String reverse( String text ) {
    +        return new StringBuilder( text ).reverse().toString();
    +    }
    +
    +    public static int numVowels( String text ) {
    +        String vowels = "aeiouAEIOU";
    +        int result = 0;
    +        for( int i = 0; i < text.length(); i++ ) {
    +            if( vowels.indexOf( text.charAt( i ) ) != -1 ) {
    +                result++;
    +            }
    +        }
    +        return result;
    +    }
    +
    +    public static String caps( String text ) {
    +        return text.toUpperCase(Locale.ENGLISH);
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/ValuesBean.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/ValuesBean.java.html new file mode 100644 index 0000000..354a32a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/ValuesBean.java.html @@ -0,0 +1,54 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples;
    +
    +/**
    + * Accept and display a value.
    + */
    +public class ValuesBean {
    +    private String string;
    +    private double doubleValue;
    +    private long longValue;
    +
    +    public String getStringValue() {
    +        return this.string;
    +    }
    +
    +    public void setStringValue(String string) {
    +        this.string = string;
    +    }
    +
    +    public double getDoubleValue() {
    +        return doubleValue;
    +    }
    +
    +    public void setDoubleValue(double doubleValue) {
    +        this.doubleValue = doubleValue;
    +    }
    +
    +    public long getLongValue() {
    +        return longValue;
    +    }
    +
    +    public void setLongValue(long longValue) {
    +        this.longValue = longValue;
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/ValuesTag.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/ValuesTag.java.html new file mode 100644 index 0000000..9f5860d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/ValuesTag.java.html @@ -0,0 +1,81 @@ +
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one or more
    + * contributor license agreements.  See the NOTICE file distributed with
    + * this work for additional information regarding copyright ownership.
    + * The ASF licenses this file to You under the Apache License, Version 2.0
    + * (the "License"); you may not use this file except in compliance with
    + * the License.  You may obtain a copy of the License at
    + *
    + *     http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing, software
    + * distributed under the License is distributed on an "AS IS" BASIS,
    + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    + * See the License for the specific language governing permissions and
    + * limitations under the License.
    + */
    +package examples;
    +
    +import java.io.IOException;
    +
    +import javax.servlet.jsp.JspException;
    +import javax.servlet.jsp.JspTagException;
    +import javax.servlet.jsp.JspWriter;
    +import javax.servlet.jsp.tagext.TagSupport;
    +
    +/**
    + * Accept and display a value.
    + */
    +public class ValuesTag extends TagSupport {
    +
    +    private static final long serialVersionUID = 1L;
    +
    +    // Using "-1" as the default value,
    +    // in the assumption that it won't be used as the value.
    +    // Cannot use null here, because null is an important case
    +    // that should be present in the tests.
    +    private Object objectValue = "-1";
    +    private String stringValue = "-1";
    +    private long longValue = -1;
    +    private double doubleValue = -1;
    +
    +    public void setObject(Object objectValue) {
    +        this.objectValue = objectValue;
    +    }
    +
    +    public void setString(String stringValue) {
    +        this.stringValue = stringValue;
    +    }
    +
    +    public void setLong(long longValue) {
    +        this.longValue = longValue;
    +    }
    +
    +    public void setDouble(double doubleValue) {
    +        this.doubleValue = doubleValue;
    +    }
    +
    +    @Override
    +    public int doEndTag() throws JspException {
    +        JspWriter out = pageContext.getOut();
    +
    +        try {
    +            if (!"-1".equals(objectValue)) {
    +                out.print(objectValue);
    +            } else if (!"-1".equals(stringValue)) {
    +                out.print(stringValue);
    +            } else if (longValue != -1) {
    +                out.print(longValue);
    +            } else if (doubleValue != -1) {
    +                out.print(doubleValue);
    +            } else {
    +                out.print("-1");
    +            }
    +        } catch (IOException ex) {
    +            throw new JspTagException("IOException: " + ex.toString(), ex);
    +        }
    +        return super.doEndTag();
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.html new file mode 100644 index 0000000..8a2f0a6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.html @@ -0,0 +1,30 @@ + + + +View Source Code + + + + +

    + +

    Source Code for Basic Arithmetic Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.jsp new file mode 100644 index 0000000..757e809 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.jsp @@ -0,0 +1,88 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + JSP 2.0 Expression Language - Basic Arithmetic + + +

    JSP 2.0 Expression Language - Basic Arithmetic

    +
    + This example illustrates basic Expression Language arithmetic. + Addition (+), subtraction (-), multiplication (*), division (/ or div), + and modulus (% or mod) are all supported. Error conditions, like + division by zero, are handled gracefully. +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EL ExpressionResult
    \${1}${1}
    \${1 + 2}${1 + 2}
    \${1.2 + 2.3}${1.2 + 2.3}
    \${1.2E4 + 1.4}${1.2E4 + 1.4}
    \${-4 - 2}${-4 - 2}
    \${21 * 2}${21 * 2}
    \${3/4}${3/4}
    \${3 div 4}${3 div 4}
    \${3/0}${3/0}
    \${10%4}${10%4}
    \${10 mod 4}${10 mod 4}
    \${(1==2) ? 3 : 4}${(1==2) ? 3 : 4}
    +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.jsp.html new file mode 100644 index 0000000..004d764 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-arithmetic.jsp.html @@ -0,0 +1,90 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Expression Language - Basic Arithmetic</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Expression Language - Basic Arithmetic</h1>
    +    <hr>
    +    This example illustrates basic Expression Language arithmetic.
    +    Addition (+), subtraction (-), multiplication (*), division (/ or div),
    +    and modulus (% or mod) are all supported.  Error conditions, like
    +    division by zero, are handled gracefully.
    +    <br>
    +    <blockquote>
    +      <code>
    +        <table border="1">
    +          <thead>
    +        <td><b>EL Expression</b></td>
    +        <td><b>Result</b></td>
    +      </thead>
    +      <tr>
    +        <td>\${1}</td>
    +        <td>${1}</td>
    +      </tr>
    +      <tr>
    +        <td>\${1 + 2}</td>
    +        <td>${1 + 2}</td>
    +      </tr>
    +      <tr>
    +        <td>\${1.2 + 2.3}</td>
    +        <td>${1.2 + 2.3}</td>
    +      </tr>
    +      <tr>
    +        <td>\${1.2E4 + 1.4}</td>
    +        <td>${1.2E4 + 1.4}</td>
    +      </tr>
    +      <tr>
    +        <td>\${-4 - 2}</td>
    +        <td>${-4 - 2}</td>
    +      </tr>
    +      <tr>
    +        <td>\${21 * 2}</td>
    +        <td>${21 * 2}</td>
    +      </tr>
    +      <tr>
    +        <td>\${3/4}</td>
    +        <td>${3/4}</td>
    +      </tr>
    +      <tr>
    +        <td>\${3 div 4}</td>
    +        <td>${3 div 4}</td>
    +      </tr>
    +      <tr>
    +        <td>\${3/0}</td>
    +        <td>${3/0}</td>
    +      </tr>
    +      <tr>
    +        <td>\${10%4}</td>
    +        <td>${10%4}</td>
    +      </tr>
    +      <tr>
    +        <td>\${10 mod 4}</td>
    +        <td>${10 mod 4}</td>
    +      </tr>
    +    <tr>
    +      <td>\${(1==2) ? 3 : 4}</td>
    +      <td>${(1==2) ? 3 : 4}</td>
    +    </tr>
    +    </table>
    +      </code>
    +    </blockquote>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.html new file mode 100644 index 0000000..60fb40a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.html @@ -0,0 +1,30 @@ + + + +View Source Code + + + + +

    + +

    Source Code for Basic Comparisons Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.jsp new file mode 100644 index 0000000..d72f724 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.jsp @@ -0,0 +1,116 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + JSP 2.0 Expression Language - Basic Comparisons + + +

    JSP 2.0 Expression Language - Basic Comparisons

    +
    + This example illustrates basic Expression Language comparisons. + The following comparison operators are supported: +
      +
    • Less-than (< or lt)
    • +
    • Greater-than (> or gt)
    • +
    • Less-than-or-equal (<= or le)
    • +
    • Greater-than-or-equal (>= or ge)
    • +
    • Equal (== or eq)
    • +
    • Not Equal (!= or ne)
    • +
    +
    + Numeric + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EL ExpressionResult
    \${1 < 2}${1 < 2}
    \${1 lt 2}${1 lt 2}
    \${1 > (4/2)}${1 > (4/2)}
    \${1 gt (4/2)}${1 gt (4/2)}
    \${4.0 >= 3}${4.0 >= 3}
    \${4.0 ge 3}${4.0 ge 3}
    \${4 <= 3}${4 <= 3}
    \${4 le 3}${4 le 3}
    \${100.0 == 100}${100.0 == 100}
    \${100.0 eq 100}${100.0 eq 100}
    \${(10*10) != 100}${(10*10) != 100}
    \${(10*10) ne 100}${(10*10) ne 100}
    +
    +
    + Alphabetic + + + + + + + + + + + + + + + + + + +
    EL ExpressionResult
    \${'a' < 'b'}${'a' < 'b'}
    \${'hip' > 'hit'}${'hip' > 'hit'}
    \${'4' > 3}${'4' > 3}
    +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.jsp.html new file mode 100644 index 0000000..b8edd5e --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/basic-comparisons.jsp.html @@ -0,0 +1,118 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Expression Language - Basic Comparisons</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Expression Language - Basic Comparisons</h1>
    +    <hr>
    +    This example illustrates basic Expression Language comparisons.
    +    The following comparison operators are supported:
    +    <ul>
    +      <li>Less-than (&lt; or lt)</li>
    +      <li>Greater-than (&gt; or gt)</li>
    +      <li>Less-than-or-equal (&lt;= or le)</li>
    +      <li>Greater-than-or-equal (&gt;= or ge)</li>
    +      <li>Equal (== or eq)</li>
    +      <li>Not Equal (!= or ne)</li>
    +    </ul>
    +    <blockquote>
    +      <u><b>Numeric</b></u>
    +      <code>
    +        <table border="1">
    +          <thead>
    +        <td><b>EL Expression</b></td>
    +        <td><b>Result</b></td>
    +      </thead>
    +      <tr>
    +        <td>\${1 &lt; 2}</td>
    +        <td>${1 < 2}</td>
    +      </tr>
    +      <tr>
    +        <td>\${1 lt 2}</td>
    +        <td>${1 lt 2}</td>
    +      </tr>
    +      <tr>
    +        <td>\${1 &gt; (4/2)}</td>
    +        <td>${1 > (4/2)}</td>
    +      </tr>
    +      <tr>
    +        <td>\${1 gt (4/2)}</td>
    +        <td>${1 gt (4/2)}</td>
    +      </tr>
    +      <tr>
    +        <td>\${4.0 &gt;= 3}</td>
    +        <td>${4.0 >= 3}</td>
    +      </tr>
    +      <tr>
    +        <td>\${4.0 ge 3}</td>
    +        <td>${4.0 ge 3}</td>
    +      </tr>
    +      <tr>
    +        <td>\${4 &lt;= 3}</td>
    +        <td>${4 <= 3}</td>
    +      </tr>
    +      <tr>
    +        <td>\${4 le 3}</td>
    +        <td>${4 le 3}</td>
    +      </tr>
    +      <tr>
    +        <td>\${100.0 == 100}</td>
    +        <td>${100.0 == 100}</td>
    +      </tr>
    +      <tr>
    +        <td>\${100.0 eq 100}</td>
    +        <td>${100.0 eq 100}</td>
    +      </tr>
    +      <tr>
    +        <td>\${(10*10) != 100}</td>
    +        <td>${(10*10) != 100}</td>
    +      </tr>
    +      <tr>
    +        <td>\${(10*10) ne 100}</td>
    +        <td>${(10*10) ne 100}</td>
    +      </tr>
    +    </table>
    +      </code>
    +      <br>
    +      <u><b>Alphabetic</b></u>
    +      <code>
    +        <table border="1">
    +          <thead>
    +            <td><b>EL Expression</b></td>
    +            <td><b>Result</b></td>
    +          </thead>
    +          <tr>
    +            <td>\${'a' &lt; 'b'}</td>
    +            <td>${'a' < 'b'}</td>
    +          </tr>
    +          <tr>
    +            <td>\${'hip' &gt; 'hit'}</td>
    +            <td>${'hip' > 'hit'}</td>
    +          </tr>
    +          <tr>
    +            <td>\${'4' &gt; 3}</td>
    +            <td>${'4' > 3}</td>
    +          </tr>
    +        </table>
    +      </code>
    +    </blockquote>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.html new file mode 100644 index 0000000..5900008 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.html @@ -0,0 +1,31 @@ + + + +View Source Code + + + + +

    + +

    Source Code for composite.jsp

    +

    Source Code for ValuesTag.java

    +

    Source Code for ValuesBean.java

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.jsp new file mode 100644 index 0000000..ae671d4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.jsp @@ -0,0 +1,110 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="my" uri="http://tomcat.apache.org/example-taglib" %> + + + + JSP 2.0 Expression Language - Composite Expressions + + +

    JSP 2.0 Expression Language - Composite Expressions

    +
    + This example illustrates EL composite expressions. Composite expressions + are formed by grouping together multiple EL expressions. Each of them is + evaluated from left to right, coerced to String, all those strings are + concatenated, and the result is coerced to the expected type. + + + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EL ExpressionTypeResult
    \${'hello'} wo\${'rld'}String${values.stringValue}
    \${'hello'} wo\${'rld'}String
    \${1+2}.\${220}Double${values.doubleValue}
    \${1+2}.\${220}Double
    000\${1}\${7}Long${values.longValue}
    000\${1}\${7}Long
    \${undefinedFoo}hello world\${undefinedBar}String${values.stringValue}
    \${undefinedFoo}hello world\${undefinedBar}String
    \${undefinedFoo}\${undefinedBar}Double${values.doubleValue}
    \${undefinedFoo}\${undefinedBar}Double
    \${undefinedFoo}\${undefinedBar}Long${values.longValue}
    \${undefinedFoo}\${undefinedBar}Long
    +
    +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.jsp.html new file mode 100644 index 0000000..b498538 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/composite.jsp.html @@ -0,0 +1,112 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="my" uri="http://tomcat.apache.org/example-taglib" %>
    +
    +<html>
    +  <head>
    +    <title>JSP 2.0 Expression Language - Composite Expressions</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Expression Language - Composite Expressions</h1>
    +    <hr>
    +    This example illustrates EL composite expressions. Composite expressions
    +    are formed by grouping together multiple EL expressions. Each of them is
    +    evaluated from left to right, coerced to String, all those strings are
    +    concatenated, and the result is coerced to the expected type.
    +
    +    <jsp:useBean id="values" class="jsp2.examples.ValuesBean" />
    +
    +    <blockquote>
    +      <code>
    +        <table border="1">
    +          <thead>
    +        <td><b>EL Expression</b></td>
    +        <td><b>Type</b></td>
    +        <td><b>Result</b></td>
    +      </thead>
    +      <tr>
    +        <td>\${'hello'} wo\${'rld'}</td>
    +        <td>String</td>
    +        <td><jsp:setProperty name="values" property="stringValue" value="${'hello'} wo${'rld'}"/>${values.stringValue}</td>
    +      </tr>
    +      <tr>
    +        <td>\${'hello'} wo\${'rld'}</td>
    +        <td>String</td>
    +        <td><my:values string="${'hello'} wo${'rld'}"/></td>
    +      </tr>
    +      <tr>
    +        <td>\${1+2}.\${220}</td>
    +        <td>Double</td>
    +        <td><jsp:setProperty name="values" property="doubleValue" value="${1+2}.${220}"/>${values.doubleValue}</td>
    +      </tr>
    +      <tr>
    +        <td>\${1+2}.\${220}</td>
    +        <td>Double</td>
    +        <td><my:values double="${1+2}.${220}"/></td>
    +      </tr>
    +      <tr>
    +        <td>000\${1}\${7}</td>
    +        <td>Long</td>
    +        <td><jsp:setProperty name="values" property="longValue" value="000${1}${7}"/>${values.longValue}</td>
    +      </tr>
    +      <tr>
    +        <td>000\${1}\${7}</td>
    +        <td>Long</td>
    +        <td><my:values long="000${1}${7}"/></td>
    +      </tr>
    +      <!--
    +         Undefined values are to be coerced to String, to be "",
    +         https://bz.apache.org/bugzilla/show_bug.cgi?id=47413
    +       -->
    +      <tr>
    +        <td>\${undefinedFoo}hello world\${undefinedBar}</td>
    +        <td>String</td>
    +        <td><jsp:setProperty name="values" property="stringValue" value="${undefinedFoo}hello world${undefinedBar}"/>${values.stringValue}</td>
    +      </tr>
    +      <tr>
    +        <td>\${undefinedFoo}hello world\${undefinedBar}</td>
    +        <td>String</td>
    +        <td><my:values string="${undefinedFoo}hello world${undefinedBar}"/></td>
    +      </tr>
    +      <tr>
    +        <td>\${undefinedFoo}\${undefinedBar}</td>
    +        <td>Double</td>
    +        <td><jsp:setProperty name="values" property="doubleValue" value="${undefinedFoo}${undefinedBar}"/>${values.doubleValue}</td>
    +      </tr>
    +      <tr>
    +        <td>\${undefinedFoo}\${undefinedBar}</td>
    +        <td>Double</td>
    +        <td><my:values double="${undefinedFoo}${undefinedBar}"/></td>
    +      </tr>
    +      <tr>
    +        <td>\${undefinedFoo}\${undefinedBar}</td>
    +        <td>Long</td>
    +        <td><jsp:setProperty name="values" property="longValue" value="${undefinedFoo}${undefinedBar}"/>${values.longValue}</td>
    +      </tr>
    +      <tr>
    +        <td>\${undefinedFoo}\${undefinedBar}</td>
    +        <td>Long</td>
    +        <td><my:values long="${undefinedFoo}${undefinedBar}"/></td>
    +      </tr>
    +    </table>
    +      </code>
    +    </blockquote>
    +  </body>
    +</html>
    +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.html new file mode 100644 index 0000000..726dda3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.html @@ -0,0 +1,32 @@ + + + +View Source Code + + + + +

    + +

    Source Code for functions.jsp +

    +

    Source Code for Functions.java +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.jsp new file mode 100644 index 0000000..6a24165 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.jsp @@ -0,0 +1,66 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%> + + + + JSP 2.0 Expression Language - Functions + + +

    JSP 2.0 Expression Language - Functions

    +
    + An upgrade from the JSTL expression language, the JSP 2.0 EL also + allows for simple function invocation. Functions are defined + by tag libraries and are implemented by a Java programmer as + static methods. + +
    + Change Parameter +
    + foo = + +
    +
    + + + + + + + + + + + + + + + + + + + + + + +
    EL ExpressionResult
    \${param["foo"]}${fn:escapeXml(param["foo"])} 
    \${my:reverse(param["foo"])}${my:reverse(fn:escapeXml(param["foo"]))} 
    \${my:reverse(my:reverse(param["foo"]))}${my:reverse(my:reverse(fn:escapeXml(param["foo"])))} 
    \${my:countVowels(param["foo"])}${my:countVowels(fn:escapeXml(param["foo"]))} 
    +
    +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.jsp.html new file mode 100644 index 0000000..2f8a2f2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/functions.jsp.html @@ -0,0 +1,68 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
    +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%>
    +
    +<html>
    +  <head>
    +    <title>JSP 2.0 Expression Language - Functions</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Expression Language - Functions</h1>
    +    <hr>
    +    An upgrade from the JSTL expression language, the JSP 2.0 EL also
    +    allows for simple function invocation.  Functions are defined
    +    by tag libraries and are implemented by a Java programmer as
    +    static methods.
    +
    +    <blockquote>
    +      <u><b>Change Parameter</b></u>
    +      <form action="functions.jsp" method="GET">
    +          foo = <input type="text" name="foo" value="${fn:escapeXml(param["foo"])}">
    +          <input type="submit">
    +      </form>
    +      <br>
    +      <code>
    +        <table border="1">
    +          <thead>
    +            <td><b>EL Expression</b></td>
    +            <td><b>Result</b></td>
    +          </thead>
    +          <tr>
    +            <td>\${param["foo"]}</td>
    +            <td>${fn:escapeXml(param["foo"])}&nbsp;</td>
    +          </tr>
    +          <tr>
    +            <td>\${my:reverse(param["foo"])}</td>
    +            <td>${my:reverse(fn:escapeXml(param["foo"]))}&nbsp;</td>
    +          </tr>
    +          <tr>
    +            <td>\${my:reverse(my:reverse(param["foo"]))}</td>
    +            <td>${my:reverse(my:reverse(fn:escapeXml(param["foo"])))}&nbsp;</td>
    +          </tr>
    +          <tr>
    +            <td>\${my:countVowels(param["foo"])}</td>
    +            <td>${my:countVowels(fn:escapeXml(param["foo"]))}&nbsp;</td>
    +          </tr>
    +        </table>
    +      </code>
    +    </blockquote>
    +  </body>
    +</html>
    +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.html new file mode 100644 index 0000000..15268db --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.html @@ -0,0 +1,31 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for Implicit Objects Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.jsp new file mode 100644 index 0000000..9888c7d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.jsp @@ -0,0 +1,89 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> + + + + JSP 2.0 Expression Language - Implicit Objects + + +

    JSP 2.0 Expression Language - Implicit Objects

    +
    + This example illustrates some of the implicit objects available + in the Expression Language. The following implicit objects are + available (not all illustrated here): +
      +
    • pageContext - the PageContext object
    • +
    • pageScope - a Map that maps page-scoped attribute names to + their values
    • +
    • requestScope - a Map that maps request-scoped attribute names + to their values
    • +
    • sessionScope - a Map that maps session-scoped attribute names + to their values
    • +
    • applicationScope - a Map that maps application-scoped attribute + names to their values
    • +
    • param - a Map that maps parameter names to a single String + parameter value
    • +
    • paramValues - a Map that maps parameter names to a String[] of + all values for that parameter
    • +
    • header - a Map that maps header names to a single String + header value
    • +
    • headerValues - a Map that maps header names to a String[] of + all values for that header
    • +
    • initParam - a Map that maps context initialization parameter + names to their String parameter value
    • +
    • cookie - a Map that maps cookie names to a single Cookie object.
    • +
    + +
    + Change Parameter +
    + foo = + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + +
    EL ExpressionResult
    \${param.foo}${fn:escapeXml(param["foo"])} 
    \${param["foo"]}${fn:escapeXml(param["foo"])} 
    \${header["host"]}${fn:escapeXml(header["host"])} 
    \${header["accept"]}${fn:escapeXml(header["accept"])} 
    \${header["user-agent"]}${fn:escapeXml(header["user-agent"])} 
    +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.jsp.html new file mode 100644 index 0000000..984b502 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/el/implicit-objects.jsp.html @@ -0,0 +1,91 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
    +
    +<html>
    +  <head>
    +    <title>JSP 2.0 Expression Language - Implicit Objects</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Expression Language - Implicit Objects</h1>
    +    <hr>
    +    This example illustrates some of the implicit objects available
    +    in the Expression Language.  The following implicit objects are
    +    available (not all illustrated here):
    +    <ul>
    +      <li>pageContext - the PageContext object</li>
    +      <li>pageScope - a Map that maps page-scoped attribute names to
    +          their values</li>
    +      <li>requestScope - a Map that maps request-scoped attribute names
    +          to their values</li>
    +      <li>sessionScope - a Map that maps session-scoped attribute names
    +          to their values</li>
    +      <li>applicationScope - a Map that maps application-scoped attribute
    +          names to their values</li>
    +      <li>param - a Map that maps parameter names to a single String
    +          parameter value</li>
    +      <li>paramValues - a Map that maps parameter names to a String[] of
    +          all values for that parameter</li>
    +      <li>header - a Map that maps header names to a single String
    +          header value</li>
    +      <li>headerValues - a Map that maps header names to a String[] of
    +          all values for that header</li>
    +      <li>initParam - a Map that maps context initialization parameter
    +          names to their String parameter value</li>
    +      <li>cookie - a Map that maps cookie names to a single Cookie object.</li>
    +    </ul>
    +
    +    <blockquote>
    +      <u><b>Change Parameter</b></u>
    +      <form action="implicit-objects.jsp" method="GET">
    +          foo = <input type="text" name="foo" value="${fn:escapeXml(param["foo"])}">
    +          <input type="submit">
    +      </form>
    +      <br>
    +      <code>
    +        <table border="1">
    +          <thead>
    +            <td><b>EL Expression</b></td>
    +            <td><b>Result</b></td>
    +          </thead>
    +          <tr>
    +            <td>\${param.foo}</td>
    +            <td>${fn:escapeXml(param["foo"])}&nbsp;</td>
    +          </tr>
    +          <tr>
    +            <td>\${param["foo"]}</td>
    +            <td>${fn:escapeXml(param["foo"])}&nbsp;</td>
    +          </tr>
    +          <tr>
    +            <td>\${header["host"]}</td>
    +            <td>${fn:escapeXml(header["host"])}&nbsp;</td>
    +          </tr>
    +          <tr>
    +            <td>\${header["accept"]}</td>
    +            <td>${fn:escapeXml(header["accept"])}&nbsp;</td>
    +          </tr>
    +          <tr>
    +            <td>\${header["user-agent"]}</td>
    +            <td>${fn:escapeXml(header["user-agent"])}&nbsp;</td>
    +          </tr>
    +        </table>
    +      </code>
    +    </blockquote>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/FooBean.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/FooBean.java.html new file mode 100644 index 0000000..74f808d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/FooBean.java.html @@ -0,0 +1,38 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples;
    +
    +public class FooBean {
    +    private String bar;
    +
    +    public FooBean() {
    +        bar = "Initial value";
    +    }
    +
    +    public String getBar() {
    +        return this.bar;
    +    }
    +
    +    public void setBar(String bar) {
    +        this.bar = bar;
    +    }
    +
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/HelloWorldSimpleTag.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/HelloWorldSimpleTag.java.html new file mode 100644 index 0000000..2d55267 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/HelloWorldSimpleTag.java.html @@ -0,0 +1,36 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples.simpletag;
    +
    +import java.io.IOException;
    +
    +import javax.servlet.jsp.JspException;
    +import javax.servlet.jsp.tagext.SimpleTagSupport;
    +
    +/**
    + * SimpleTag handler that prints "Hello, world!"
    + */
    +public class HelloWorldSimpleTag extends SimpleTagSupport {
    +    @Override
    +    public void doTag() throws JspException, IOException {
    +        getJspContext().getOut().write( "Hello, world!" );
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/ShuffleSimpleTag.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/ShuffleSimpleTag.java.html new file mode 100644 index 0000000..06a8e5b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/ShuffleSimpleTag.java.html @@ -0,0 +1,89 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples.simpletag;
    +
    +import java.io.IOException;
    +import java.util.Random;
    +
    +import javax.servlet.jsp.JspException;
    +import javax.servlet.jsp.tagext.JspFragment;
    +import javax.servlet.jsp.tagext.SimpleTagSupport;
    +
    +/**
    + * SimpleTag handler that accepts takes three attributes of type
    + * JspFragment and invokes then in a random order.
    + */
    +public class ShuffleSimpleTag extends SimpleTagSupport {
    +    // No need for this to use SecureRandom
    +    private static Random random = new Random();
    +
    +    private JspFragment fragment1;
    +    private JspFragment fragment2;
    +    private JspFragment fragment3;
    +
    +    @Override
    +    public void doTag() throws JspException, IOException {
    +        switch(random.nextInt(6)) {
    +            case 0:
    +                fragment1.invoke( null );
    +                fragment2.invoke( null );
    +                fragment3.invoke( null );
    +                break;
    +            case 1:
    +                fragment1.invoke( null );
    +                fragment3.invoke( null );
    +                fragment2.invoke( null );
    +                break;
    +            case 2:
    +                fragment2.invoke( null );
    +                fragment1.invoke( null );
    +                fragment3.invoke( null );
    +                break;
    +            case 3:
    +                fragment2.invoke( null );
    +                fragment3.invoke( null );
    +                fragment1.invoke( null );
    +                break;
    +            case 4:
    +                fragment3.invoke( null );
    +                fragment1.invoke( null );
    +                fragment2.invoke( null );
    +                break;
    +            case 5:
    +                fragment3.invoke( null );
    +                fragment2.invoke( null );
    +                fragment1.invoke( null );
    +                break;
    +        }
    +    }
    +
    +    public void setFragment1( JspFragment fragment1 ) {
    +        this.fragment1 = fragment1;
    +    }
    +
    +    public void setFragment2( JspFragment fragment2 ) {
    +        this.fragment2 = fragment2;
    +    }
    +
    +    public void setFragment3( JspFragment fragment3 ) {
    +        this.fragment3 = fragment3;
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/TileSimpleTag.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/TileSimpleTag.java.html new file mode 100644 index 0000000..1c8cbf4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/TileSimpleTag.java.html @@ -0,0 +1,50 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples.simpletag;
    +
    +import java.io.IOException;
    +
    +import javax.servlet.jsp.JspException;
    +import javax.servlet.jsp.tagext.SimpleTagSupport;
    +
    +/**
    + * Displays a tile as a single cell in a table.
    + */
    +public class TileSimpleTag extends SimpleTagSupport {
    +    private String color;
    +    private String label;
    +
    +    @Override
    +    public void doTag() throws JspException, IOException {
    +        getJspContext().getOut().write(
    +                "<td width=\"32\" height=\"32\" bgcolor=\"" + this.color +
    +                "\"><font color=\"#ffffff\"><center>" + this.label +
    +                "</center></font></td>" );
    +    }
    +
    +    public void setColor( String color ) {
    +        this.color = color;
    +    }
    +
    +    public void setLabel( String label ) {
    +        this.label = label;
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.html new file mode 100644 index 0000000..df1b6e6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.html @@ -0,0 +1,37 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for jspattribute.jsp +

    + +

    Source Code for HelloWorldSimpleTag.java +

    + +

    Source Code for FooBean.java +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.jsp new file mode 100644 index 0000000..8050b34 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.jsp @@ -0,0 +1,46 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%> + + + + JSP 2.0 Examples - jsp:attribute and jsp:body + + +

    JSP 2.0 Examples - jsp:attribute and jsp:body

    +
    +

    The new <jsp:attribute> and <jsp:body> + standard actions can be used to specify the value of any standard + action or custom action attribute.

    +

    This example uses the <jsp:attribute> + standard action to use the output of a custom action invocation + (one that simply outputs "Hello, World!") to set the value of a + bean property. This would normally require an intermediary + step, such as using JSTL's <c:set> action.

    +
    + + Bean created! Setting foo.bar...
    + + + + + +
    +
    + Result: ${foo.bar} + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.jsp.html new file mode 100644 index 0000000..78062cc --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/jspattribute.jsp.html @@ -0,0 +1,48 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%>
    +
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - jsp:attribute and jsp:body</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - jsp:attribute and jsp:body</h1>
    +    <hr>
    +    <p>The new &lt;jsp:attribute&gt; and &lt;jsp:body&gt;
    +    standard actions can be used to specify the value of any standard
    +    action or custom action attribute.</p>
    +    <p>This example uses the &lt;jsp:attribute&gt;
    +    standard action to use the output of a custom action invocation
    +    (one that simply outputs "Hello, World!") to set the value of a
    +    bean property.  This would normally require an intermediary
    +    step, such as using JSTL's &lt;c:set&gt; action.</p>
    +    <br>
    +    <jsp:useBean id="foo" class="jsp2.examples.FooBean">
    +      Bean created!  Setting foo.bar...<br>
    +      <jsp:setProperty name="foo" property="bar">
    +        <jsp:attribute name="value">
    +          <my:helloWorld/>
    +        </jsp:attribute>
    +      </jsp:setProperty>
    +    </jsp:useBean>
    +    <br>
    +    Result: ${foo.bar}
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.html new file mode 100644 index 0000000..5711860 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.html @@ -0,0 +1,37 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for shuffle.jsp +

    + +

    Source Code for ShuffleSimpleTag.java +

    + +

    Source Code for TileSimpleTag.java +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.jsp new file mode 100644 index 0000000..737ff65 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.jsp @@ -0,0 +1,90 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%> + + + + JSP 2.0 Examples - Shuffle Example + + +

    JSP 2.0 Examples - Shuffle Example

    +
    +

    Try reloading the page a few times. Both the rows and the columns + are shuffled and appear different each time.

    +

    Here's how the code works. The SimpleTag handler called + <my:shuffle> accepts three attributes. Each attribute is a + JSP Fragment, meaning it is a fragment of JSP code that can be + dynamically executed by the shuffle tag handler on demand. The + shuffle tag handler executes the three fragments in a random order. + To shuffle both the rows and the columns, the shuffle tag is used + with itself as a parameter.

    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.jsp.html new file mode 100644 index 0000000..ad2bc98 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspattribute/shuffle.jsp.html @@ -0,0 +1,92 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%>
    +
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - Shuffle Example</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - Shuffle Example</h1>
    +    <hr>
    +    <p>Try reloading the page a few times.  Both the rows and the columns
    +    are shuffled and appear different each time.</p>
    +    <p>Here's how the code works.  The SimpleTag handler called
    +    &lt;my:shuffle&gt; accepts three attributes.  Each attribute is a
    +    JSP Fragment, meaning it is a fragment of JSP code that can be
    +    dynamically executed by the shuffle tag handler on demand.  The
    +    shuffle tag handler executes the three fragments in a random order.
    +    To shuffle both the rows and the columns, the shuffle tag is used
    +    with itself as a parameter.</p>
    +    <hr>
    +    <blockquote>
    +     <font color="#ffffff">
    +      <table>
    +        <my:shuffle>
    +          <jsp:attribute name="fragment1">
    +            <tr>
    +              <my:shuffle>
    +                <jsp:attribute name="fragment1">
    +                  <my:tile color="#ff0000" label="A"/>
    +                </jsp:attribute>
    +                <jsp:attribute name="fragment2">
    +                  <my:tile color="#00ff00" label="B"/>
    +                </jsp:attribute>
    +                <jsp:attribute name="fragment3">
    +                  <my:tile color="#0000ff" label="C"/>
    +                </jsp:attribute>
    +              </my:shuffle>
    +            </tr>
    +          </jsp:attribute>
    +          <jsp:attribute name="fragment2">
    +            <tr>
    +              <my:shuffle>
    +                <jsp:attribute name="fragment1">
    +                  <my:tile color="#ff0000" label="1"/>
    +                </jsp:attribute>
    +                <jsp:attribute name="fragment2">
    +                  <my:tile color="#00ff00" label="2"/>
    +                </jsp:attribute>
    +                <jsp:attribute name="fragment3">
    +                  <my:tile color="#0000ff" label="3"/>
    +                </jsp:attribute>
    +              </my:shuffle>
    +            </tr>
    +          </jsp:attribute>
    +          <jsp:attribute name="fragment3">
    +            <tr>
    +              <my:shuffle>
    +                <jsp:attribute name="fragment1">
    +                  <my:tile color="#ff0000" label="!"/>
    +                </jsp:attribute>
    +                <jsp:attribute name="fragment2">
    +                  <my:tile color="#00ff00" label="@"/>
    +                </jsp:attribute>
    +                <jsp:attribute name="fragment3">
    +                  <my:tile color="#0000ff" label="#"/>
    +                </jsp:attribute>
    +              </my:shuffle>
    +            </tr>
    +          </jsp:attribute>
    +        </my:shuffle>
    +      </table>
    +     </font>
    +    </blockquote>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.html new file mode 100644 index 0000000..51552d3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.html @@ -0,0 +1,31 @@ + + + +View Source Code + + + + +

    + +

    Source Code for XHTML Basic Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.jspx b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.jspx new file mode 100644 index 0000000..c41a157 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.jspx @@ -0,0 +1,46 @@ + + + + + JSPX - XHTML Basic Example + + +

    JSPX - XHTML Basic Example

    +
    + This example illustrates how to use JSPX to produce an XHTML basic + document suitable for use with mobile phones, televisions, + PDAs, vending machines, pagers, car navigation systems, + mobile game machines, digital book readers, smart watches, etc. +

    + JSPX lets you create dynamic documents in a pure XML syntax compatible + with existing XML tools. The XML syntax in JSP 1.2 was awkward and + required &lt;jsp:root&gt; to be the root element of the document. + This is no longer the case in JSP 2.0. +

    + This particular example uses a tag file to produce the DOCTYPE and + namespace declarations to make the output of this page a valid XHTML + Basic document. +

    + Just to prove this is live, here's some dynamic content: + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.jspx.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.jspx.html new file mode 100644 index 0000000..33e3039 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/basic.jspx.html @@ -0,0 +1,48 @@ +

    +<!--
    +  Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +<tags:xhtmlbasic xmlns:tags="urn:jsptagdir:/WEB-INF/tags"
    +                 xmlns:jsp="http://java.sun.com/JSP/Page"
    +                 xmlns:fmt="http://java.sun.com/jsp/jstl/fmt"
    +                 xmlns="http://www.w3.org/1999/xhtml">
    +  <jsp:directive.page contentType="text/html" />
    +  <head>
    +    <title>JSPX - XHTML Basic Example</title>
    +  </head>
    +  <body>
    +    <h1>JSPX - XHTML Basic Example</h1>
    +    <hr/>
    +    This example illustrates how to use JSPX to produce an XHTML basic
    +    document suitable for use with mobile phones, televisions,
    +    PDAs, vending machines, pagers, car navigation systems,
    +    mobile game machines, digital book readers, smart watches, etc.
    +    <p/>
    +    JSPX lets you create dynamic documents in a pure XML syntax compatible
    +    with existing XML tools.  The XML syntax in JSP 1.2 was awkward and
    +    required &amp;lt;jsp:root&amp;gt; to be the root element of the document.
    +    This is no longer the case in JSP 2.0.
    +    <p/>
    +    This particular example uses a tag file to produce the DOCTYPE and
    +    namespace declarations to make the output of this page a valid XHTML
    +    Basic document.
    +    <p/>
    +    Just to prove this is live, here's some dynamic content:
    +    <jsp:useBean id="now" class="java.util.Date" />
    +    <fmt:formatDate value="${now}" pattern="MMMM d, yyyy, H:mm:ss"/>
    +  </body>
    +</tags:xhtmlbasic>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/svgexample.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/svgexample.html new file mode 100644 index 0000000..2879a25 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/svgexample.html @@ -0,0 +1,52 @@ + + + + JSP 2.0 SVG Example + + +

    JSP 2.0 SVG Example

    +
    + This example uses JSP 2.0's new, simplified JSPX syntax to render a + Scalable Vector Graphics (SVG) document. When you view the source, + notice the lack of a <jsp:root> element! The text to be rendered + can be modified by changing the value of the name parameter. +

    + SVG has many potential uses, such as searchable images, or images + customized with the name of your site's visitor (e.g. a "Susan's Store" + tab image). JSPX is a natural fit for generating dynamic XML content + such as SVG. +

    + To execute this example, follow these steps: +

      +
    1. Download Apache Batik, + or any other SVG viewer.
    2. +
    3. Copy the following URL: + + http://localhost:8080/examples/jsp/jsp2/jspx/textRotate.jspx?name=JSPX +
    4. +
    5. Paste the URL into Batik's Location field and press Enter
    6. +
    7. Customize by changing the name=JSPX parameter
    8. +
    +
    + The following is a screenshot of the resulting image, for those that + don't have an SVG viewer: +
    + +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.html new file mode 100644 index 0000000..97f9cdd --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.html @@ -0,0 +1,32 @@ + + + +View Source Code + + + + +

    + +

    Source Code for SVG (Scalable Vector Graphics) +Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jpg b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jpg new file mode 100644 index 0000000..9e98736 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jpg differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jspx b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jspx new file mode 100644 index 0000000..1ee71e9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jspx @@ -0,0 +1,52 @@ + + + + + JSP 2.0 JSPX + + + + + JSP 2.0 XML Syntax (.jspx) Demo + + Try changing the name parameter! + + + + <g opacity="0.95" transform="scale(1.05) rotate(15)"> + + ${name} + + + </g> + + ${name} + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jspx.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jspx.html new file mode 100644 index 0000000..2dfe377 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/jspx/textRotate.jspx.html @@ -0,0 +1,54 @@ +
    +<!--
    +  Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +<!--
    +  - This example is based off the textRotate.svg example that comes
    +  - with Apache Batik.  The original example was written by Bill Haneman.
    +  - This version by Mark Roth.
    +  -->
    +<svg xmlns="http://www.w3.org/2000/svg"
    +     width="450" height="500" viewBox="0 0 450 500"
    +     xmlns:c="http://java.sun.com/jsp/jstl/core"
    +     xmlns:fn="http://java.sun.com/jsp/jstl/functions"
    +     xmlns:jsp="http://java.sun.com/JSP/Page">
    +  <jsp:directive.page contentType="image/svg+xml" />
    +  <title>JSP 2.0 JSPX</title>
    +  <!-- select name parameter, or default to JSPX -->
    +  <c:set var="name" value='${empty fn:escapeXml(param["name"]) ? "JSPX" : fn:escapeXml(param["name"])}'/>
    +  <g id="testContent">
    +    <text class="title" x="50%" y="10%" font-size="15" text-anchor="middle" >
    +            JSP 2.0 XML Syntax (.jspx) Demo</text>
    +    <text class="title" x="50%" y="15%" font-size="15" text-anchor="middle" >
    +            Try changing the name parameter!</text>
    +    <g opacity="1.0" transform="translate(225, 250)" id="rotatedText">
    +      <c:forEach var="i" begin="1" end="24">
    +        <jsp:text>
    +          <![CDATA[<g opacity="0.95" transform="scale(1.05) rotate(15)">]]>
    +        </jsp:text>
    +        <text x="0" y="0" transform="scale(1.6, 1.6)" fill="DarkSlateBlue"
    +              text-anchor="middle" font-size="40" font-family="Serif"
    +              id="words">${name}</text>
    +      </c:forEach>
    +      <c:forEach var="i" begin="1" end="24">
    +        <jsp:text><![CDATA[</g>]]></jsp:text>
    +      </c:forEach>
    +      <text style="font-size:75;font-family:Serif;fill:white"
    +            text-anchor="middle">${name}</text>
    +    </g>
    +  </g>
    +</svg>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/EchoAttributesTag.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/EchoAttributesTag.java.html new file mode 100644 index 0000000..c0163f9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/EchoAttributesTag.java.html @@ -0,0 +1,59 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples.simpletag;
    +
    +import java.io.IOException;
    +import java.util.ArrayList;
    +
    +import javax.servlet.jsp.JspException;
    +import javax.servlet.jsp.JspWriter;
    +import javax.servlet.jsp.tagext.DynamicAttributes;
    +import javax.servlet.jsp.tagext.SimpleTagSupport;
    +
    +/**
    + * SimpleTag handler that echoes all its attributes
    + */
    +public class EchoAttributesTag
    +    extends SimpleTagSupport
    +    implements DynamicAttributes
    +{
    +    private ArrayList<String> keys = new ArrayList<String>();
    +    private ArrayList<Object> values = new ArrayList<Object>();
    +
    +    @Override
    +    public void doTag() throws JspException, IOException {
    +        JspWriter out = getJspContext().getOut();
    +        for( int i = 0; i < keys.size(); i++ ) {
    +            String key = keys.get( i );
    +            Object value = values.get( i );
    +            out.println( "<li>" + key + " = " + value + "</li>" );
    +        }
    +    }
    +
    +    @Override
    +    public void setDynamicAttribute( String uri, String localName,
    +        Object value )
    +        throws JspException
    +    {
    +        keys.add( localName );
    +        values.add( value );
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/coda.jspf b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/coda.jspf new file mode 100644 index 0000000..d767de5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/coda.jspf @@ -0,0 +1,21 @@ + +
    +
    +This banner included with <include-coda> +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/coda.jspf.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/coda.jspf.html new file mode 100644 index 0000000..4428a55 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/coda.jspf.html @@ -0,0 +1,23 @@ +
    +<!--
    +  Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +<hr>
    +<center>
    +This banner included with &lt;include-coda&gt;
    +</center>
    +<hr>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.html new file mode 100644 index 0000000..707d68f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.html @@ -0,0 +1,35 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for config.jsp +

    +

    Source Code for prelude.jspf +

    +

    Source Code for coda.jspf +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.jsp new file mode 100644 index 0000000..0372889 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.jsp @@ -0,0 +1,32 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%> +

    JSP 2.0 Examples - JSP Configuration

    +
    +

    Using a <jsp-property-group> element in the web.xml + deployment descriptor, this JSP page has been configured in the + following ways:

    +
      +
    • Uses <include-prelude> to include the top banner.
    • +
    • Uses <include-coda> to include the bottom banner.
    • +
    • Uses <scripting-invalid> true to disable + <% scripting %> elements
    • +
    • Uses <el-ignored> true to disable ${EL} elements
    • +
    • Uses <page-encoding> ISO-8859-1 to set the page encoding (though this is the default anyway)
    • +
    + There are various other configuration options that can be used. + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.jsp.html new file mode 100644 index 0000000..d7e7c35 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/config.jsp.html @@ -0,0 +1,34 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%>
    +    <h1>JSP 2.0 Examples - JSP Configuration</h1>
    +    <hr>
    +    <p>Using a &lt;jsp-property-group&gt; element in the web.xml
    +    deployment descriptor, this JSP page has been configured in the
    +    following ways:</p>
    +    <ul>
    +      <li>Uses &lt;include-prelude&gt; to include the top banner.</li>
    +      <li>Uses &lt;include-coda&gt; to include the bottom banner.</li>
    +      <li>Uses &lt;scripting-invalid&gt; true to disable
    +          &lt;% scripting %&gt; elements</li>
    +      <li>Uses &lt;el-ignored&gt; true to disable ${EL} elements</li>
    +      <li>Uses &lt;page-encoding&gt; ISO-8859-1 to set the page encoding (though this is the default anyway)</li>
    +    </ul>
    +    There are various other configuration options that can be used.
    +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.html new file mode 100644 index 0000000..4fa1bf1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.html @@ -0,0 +1,33 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for dynamicattrs.jsp +

    +

    Source Code for EchoAttributesTag.java +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.jsp new file mode 100644 index 0000000..251c49d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.jsp @@ -0,0 +1,44 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%> + + + JSP 2.0 Examples - Dynamic Attributes + + +

    JSP 2.0 Examples - Dynamic Attributes

    +
    +

    This JSP page invokes a custom tag that accepts a dynamic set + of attributes. The tag echoes the name and value of all attributes + passed to it.

    +
    +

    Invocation 1 (six attributes)

    +
      + +
    +

    Invocation 2 (zero attributes)

    +
      + +
    +

    Invocation 3 (three attributes)

    +
      + +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.jsp.html new file mode 100644 index 0000000..13af357 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/dynamicattrs.jsp.html @@ -0,0 +1,46 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="my" uri="http://tomcat.apache.org/jsp2-example-taglib"%>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - Dynamic Attributes</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - Dynamic Attributes</h1>
    +    <hr>
    +    <p>This JSP page invokes a custom tag that accepts a dynamic set
    +    of attributes.  The tag echoes the name and value of all attributes
    +    passed to it.</p>
    +    <hr>
    +    <h2>Invocation 1 (six attributes)</h2>
    +    <ul>
    +      <my:echoAttributes x="1" y="2" z="3" r="red" g="green" b="blue"/>
    +    </ul>
    +    <h2>Invocation 2 (zero attributes)</h2>
    +    <ul>
    +      <my:echoAttributes/>
    +    </ul>
    +    <h2>Invocation 3 (three attributes)</h2>
    +    <ul>
    +      <my:echoAttributes dogName="Scruffy"
    +                         catName="Fluffy"
    +                         blowfishName="Puffy"/>
    +    </ul>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/prelude.jspf b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/prelude.jspf new file mode 100644 index 0000000..05f7c84 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/prelude.jspf @@ -0,0 +1,21 @@ + +
    +
    +This banner included with <include-prelude> +
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/prelude.jspf.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/prelude.jspf.html new file mode 100644 index 0000000..760cac1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/misc/prelude.jspf.html @@ -0,0 +1,23 @@ +
    +<!--
    +  Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +<hr>
    +<center>
    +This banner included with &lt;include-prelude&gt;
    +</center>
    +<hr>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/BookBean.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/BookBean.java.html new file mode 100644 index 0000000..a8284c2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/BookBean.java.html @@ -0,0 +1,46 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples;
    +
    +public class BookBean {
    +    private String title;
    +    private String author;
    +    private String isbn;
    +
    +    public BookBean( String title, String author, String isbn ) {
    +        this.title = title;
    +        this.author = author;
    +        this.isbn = isbn;
    +    }
    +
    +    public String getTitle() {
    +        return this.title;
    +    }
    +
    +    public String getAuthor() {
    +        return this.author;
    +    }
    +
    +    public String getIsbn() {
    +        return this.isbn;
    +    }
    +
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/FindBookSimpleTag.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/FindBookSimpleTag.java.html new file mode 100644 index 0000000..6657151 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/FindBookSimpleTag.java.html @@ -0,0 +1,48 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples.simpletag;
    +
    +import javax.servlet.jsp.JspException;
    +import javax.servlet.jsp.tagext.SimpleTagSupport;
    +
    +import jsp2.examples.BookBean;
    +
    +/**
    + * SimpleTag handler that pretends to search for a book, and stores
    + * the result in a scoped variable.
    + */
    +public class FindBookSimpleTag extends SimpleTagSupport {
    +    private String var;
    +
    +    private static final String BOOK_TITLE = "The Lord of the Rings";
    +    private static final String BOOK_AUTHOR = "J. R. R. Tolkien";
    +    private static final String BOOK_ISBN = "0618002251";
    +
    +    @Override
    +    public void doTag() throws JspException {
    +        BookBean book = new BookBean( BOOK_TITLE, BOOK_AUTHOR, BOOK_ISBN );
    +        getJspContext().setAttribute( this.var, book );
    +    }
    +
    +    public void setVar( String var ) {
    +        this.var = var;
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/Functions.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/Functions.java.html new file mode 100644 index 0000000..12c567b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/Functions.java.html @@ -0,0 +1,47 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +package jsp2.examples.el;
    +
    +import java.util.Locale;
    +
    +/**
    + * Defines the functions for the jsp2 example tag library.
    + *
    + * <p>Each function is defined as a static method.</p>
    + */
    +public class Functions {
    +    public static String reverse( String text ) {
    +        return new StringBuilder( text ).reverse().toString();
    +    }
    +
    +    public static int numVowels( String text ) {
    +        String vowels = "aeiouAEIOU";
    +        int result = 0;
    +        for( int i = 0; i < text.length(); i++ ) {
    +            if( vowels.indexOf( text.charAt( i ) ) != -1 ) {
    +                result++;
    +            }
    +        }
    +        return result;
    +    }
    +
    +    public static String caps( String text ) {
    +        return text.toUpperCase(Locale.ENGLISH);
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/HelloWorldSimpleTag.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/HelloWorldSimpleTag.java.html new file mode 100644 index 0000000..2d55267 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/HelloWorldSimpleTag.java.html @@ -0,0 +1,36 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples.simpletag;
    +
    +import java.io.IOException;
    +
    +import javax.servlet.jsp.JspException;
    +import javax.servlet.jsp.tagext.SimpleTagSupport;
    +
    +/**
    + * SimpleTag handler that prints "Hello, world!"
    + */
    +public class HelloWorldSimpleTag extends SimpleTagSupport {
    +    @Override
    +    public void doTag() throws JspException, IOException {
    +        getJspContext().getOut().write( "Hello, world!" );
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/RepeatSimpleTag.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/RepeatSimpleTag.java.html new file mode 100644 index 0000000..de23b29 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/RepeatSimpleTag.java.html @@ -0,0 +1,46 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +
    +package jsp2.examples.simpletag;
    +
    +import java.io.IOException;
    +
    +import javax.servlet.jsp.JspException;
    +import javax.servlet.jsp.tagext.SimpleTagSupport;
    +
    +/**
    + * SimpleTag handler that accepts a num attribute and
    + * invokes its body 'num' times.
    + */
    +public class RepeatSimpleTag extends SimpleTagSupport {
    +    private int num;
    +
    +    @Override
    +    public void doTag() throws JspException, IOException {
    +        for (int i=0; i<num; i++) {
    +            getJspContext().setAttribute("count", String.valueOf( i + 1 ) );
    +            getJspBody().invoke(null);
    +        }
    +    }
    +
    +    public void setNum(int num) {
    +        this.num = num;
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.html new file mode 100644 index 0000000..2841acf --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.html @@ -0,0 +1,37 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for the Book Example JSP +

    +

    Source Code for the FindBook SimpleTag Handler +

    +

    Source Code for BookBean +

    +

    Source Code for the EL Functions +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.jsp new file mode 100644 index 0000000..ba07cfb --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.jsp @@ -0,0 +1,55 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="my" uri="/WEB-INF/jsp2/jsp2-example-taglib.tld" %> + + + JSP 2.0 Examples - Book SimpleTag Handler + + +

    JSP 2.0 Examples - Book SimpleTag Handler

    +
    +

    Illustrates a semi-realistic use of SimpleTag and the Expression + Language. First, a <my:findBook> tag is invoked to populate + the page context with a BookBean. Then, the books fields are printed + in all caps.

    +
    + Result:
    + + + + + + + + + + + + + + + + + + + + + + +
    FieldValueCapitalized
    Title${book.title}${my:caps(book.title)}
    Author${book.author}${my:caps(book.author)}
    ISBN${book.isbn}${my:caps(book.isbn)}
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.jsp.html new file mode 100644 index 0000000..2ca8b4b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/book.jsp.html @@ -0,0 +1,57 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="my" uri="/WEB-INF/jsp2/jsp2-example-taglib.tld" %>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - Book SimpleTag Handler</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - Book SimpleTag Handler</h1>
    +    <hr>
    +    <p>Illustrates a semi-realistic use of SimpleTag and the Expression
    +    Language.  First, a &lt;my:findBook&gt; tag is invoked to populate
    +    the page context with a BookBean.  Then, the books fields are printed
    +    in all caps.</p>
    +    <br>
    +    <b><u>Result:</u></b><br>
    +    <my:findBook var="book"/>
    +    <table border="1">
    +        <thead>
    +        <td><b>Field</b></td>
    +        <td><b>Value</b></td>
    +        <td><b>Capitalized</b></td>
    +    </thead>
    +    <tr>
    +        <td>Title</td>
    +        <td>${book.title}</td>
    +        <td>${my:caps(book.title)}</td>
    +    </tr>
    +    <tr>
    +        <td>Author</td>
    +        <td>${book.author}</td>
    +        <td>${my:caps(book.author)}</td>
    +    </tr>
    +    <tr>
    +        <td>ISBN</td>
    +        <td>${book.isbn}</td>
    +        <td>${my:caps(book.isbn)}</td>
    +    </tr>
    +    </table>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.html new file mode 100644 index 0000000..20cadf8 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.html @@ -0,0 +1,33 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for the Hello World Tag Example JSP +

    +

    Source Code for the Hello World SimpleTag Handler +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.jsp new file mode 100644 index 0000000..d9f22a2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.jsp @@ -0,0 +1,31 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="mytag" uri="/WEB-INF/jsp2/jsp2-example-taglib.tld" %> + + + JSP 2.0 Examples - Hello World SimpleTag Handler + + +

    JSP 2.0 Examples - Hello World SimpleTag Handler

    +
    +

    This tag handler simply echos "Hello, World!" It's an example of + a very basic SimpleTag handler with no body.

    +
    + Result: + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.jsp.html new file mode 100644 index 0000000..2df40ba --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/hello.jsp.html @@ -0,0 +1,33 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="mytag" uri="/WEB-INF/jsp2/jsp2-example-taglib.tld" %>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - Hello World SimpleTag Handler</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - Hello World SimpleTag Handler</h1>
    +    <hr>
    +    <p>This tag handler simply echos "Hello, World!"  It's an example of
    +    a very basic SimpleTag handler with no body.</p>
    +    <br>
    +    <b><u>Result:</u></b>
    +    <mytag:helloWorld/>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.html new file mode 100644 index 0000000..a56bfcd --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.html @@ -0,0 +1,33 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for the Repeat Tag Example JSP +

    +

    Source Code for the Repeat SimpleTag Handler +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.jsp new file mode 100644 index 0000000..b12d0a9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.jsp @@ -0,0 +1,39 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="mytag" uri="/WEB-INF/jsp2/jsp2-example-taglib.tld" %> + + + JSP 2.0 Examples - Repeat SimpleTag Handler + + +

    JSP 2.0 Examples - Repeat SimpleTag Handler

    +
    +

    This tag handler accepts a "num" parameter and repeats the body of the + tag "num" times. It's a simple example, but the implementation of + such a tag in JSP 2.0 is substantially simpler than the equivalent + JSP 1.2-style classic tag handler.

    +

    The body of the tag is encapsulated in a "JSP Fragment" and passed + to the tag handler, which then executes it five times, inside a + for loop. The tag handler passes in the current invocation in a + scoped variable called count, which can be accessed using the EL.

    +
    + Result:
    + + Invocation ${count} of 5
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.jsp.html new file mode 100644 index 0000000..a659c81 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/simpletag/repeat.jsp.html @@ -0,0 +1,41 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="mytag" uri="/WEB-INF/jsp2/jsp2-example-taglib.tld" %>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - Repeat SimpleTag Handler</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - Repeat SimpleTag Handler</h1>
    +    <hr>
    +    <p>This tag handler accepts a "num" parameter and repeats the body of the
    +    tag "num" times.  It's a simple example, but the implementation of
    +    such a tag in JSP 2.0 is substantially simpler than the equivalent
    +    JSP 1.2-style classic tag handler.</p>
    +    <p>The body of the tag is encapsulated in a "JSP Fragment" and passed
    +    to the tag handler, which then executes it five times, inside a
    +    for loop.  The tag handler passes in the current invocation in a
    +    scoped variable called count, which can be accessed using the EL.</p>
    +    <br>
    +    <b><u>Result:</u></b><br>
    +    <mytag:repeat num="5">
    +      Invocation ${count} of 5<br>
    +    </mytag:repeat>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/displayProducts.tag.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/displayProducts.tag.html new file mode 100644 index 0000000..c1788db --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/displayProducts.tag.html @@ -0,0 +1,57 @@ +
    +<!--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    +<%@ attribute name="normalPrice" fragment="true" %>
    +<%@ attribute name="onSale" fragment="true" %>
    +<%@ variable name-given="name" %>
    +<%@ variable name-given="price" %>
    +<%@ variable name-given="origPrice" %>
    +<%@ variable name-given="salePrice" %>
    +
    +<table border="1">
    +  <tr>
    +    <td>
    +      <c:set var="name" value="Hand-held Color PDA"/>
    +      <c:set var="price" value="$298.86"/>
    +      <jsp:invoke fragment="normalPrice"/>
    +    </td>
    +    <td>
    +      <c:set var="name" value="4-Pack 150 Watt Light Bulbs"/>
    +      <c:set var="origPrice" value="$2.98"/>
    +      <c:set var="salePrice" value="$2.32"/>
    +      <jsp:invoke fragment="onSale"/>
    +    </td>
    +    <td>
    +      <c:set var="name" value="Digital Cellular Phone"/>
    +      <c:set var="price" value="$68.74"/>
    +      <jsp:invoke fragment="normalPrice"/>
    +    </td>
    +    <td>
    +      <c:set var="name" value="Baby Grand Piano"/>
    +      <c:set var="price" value="$10,800.00"/>
    +      <jsp:invoke fragment="normalPrice"/>
    +    </td>
    +    <td>
    +      <c:set var="name" value="Luxury Car w/ Leather Seats"/>
    +      <c:set var="origPrice" value="$23,980.00"/>
    +      <c:set var="salePrice" value="$21,070.00"/>
    +      <jsp:invoke fragment="onSale"/>
    +    </td>
    +  </tr>
    +</table>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.html new file mode 100644 index 0000000..f29a379 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.html @@ -0,0 +1,33 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for hello.jsp +

    +

    Source Code for helloWorld.tag +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.jsp new file mode 100644 index 0000000..9b260f5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.jsp @@ -0,0 +1,35 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="tags" tagdir="/WEB-INF/tags" %> + + + JSP 2.0 Examples - Hello World Using a Tag File + + +

    JSP 2.0 Examples - Hello World Using a Tag File

    +
    +

    This JSP page invokes a custom tag that simply echos "Hello, World!" + The custom tag is generated from a tag file in the /WEB-INF/tags + directory.

    +

    Notice that we did not need to write a TLD for this tag. We just + created /WEB-INF/tags/helloWorld.tag, imported it using the taglib + directive, and used it!

    +
    + Result: + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.jsp.html new file mode 100644 index 0000000..f9732d4 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/hello.jsp.html @@ -0,0 +1,37 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="tags" tagdir="/WEB-INF/tags" %>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - Hello World Using a Tag File</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - Hello World Using a Tag File</h1>
    +    <hr>
    +    <p>This JSP page invokes a custom tag that simply echos "Hello, World!"
    +    The custom tag is generated from a tag file in the /WEB-INF/tags
    +    directory.</p>
    +    <p>Notice that we did not need to write a TLD for this tag.  We just
    +    created /WEB-INF/tags/helloWorld.tag, imported it using the taglib
    +    directive, and used it!</p>
    +    <br>
    +    <b><u>Result:</u></b>
    +    <tags:helloWorld/>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/helloWorld.tag.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/helloWorld.tag.html new file mode 100644 index 0000000..3ae87e1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/helloWorld.tag.html @@ -0,0 +1,19 @@ +
    +<!--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +Hello, world!
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.html new file mode 100644 index 0000000..1f03b9c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.html @@ -0,0 +1,33 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for panel.jsp +

    +

    Source Code for panel.tag +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.jsp new file mode 100644 index 0000000..d963877 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.jsp @@ -0,0 +1,58 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="tags" tagdir="/WEB-INF/tags" %> + + + JSP 2.0 Examples - Panels using Tag Files + + +

    JSP 2.0 Examples - Panels using Tag Files

    +
    +

    This JSP page invokes a custom tag that draws a + panel around the contents of the tag body. Normally, such a tag + implementation would require a Java class with many println() statements, + outputting HTML. Instead, we can use a .tag file as a template, + and we don't need to write a single line of Java or even a TLD!

    +
    + + + + + + +
    + + First panel.
    +
    +
    + + Second panel.
    + Second panel.
    + Second panel.
    + Second panel.
    +
    +
    + + Third panel.
    + + A panel in a panel. + + Third panel.
    +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.jsp.html new file mode 100644 index 0000000..c3bba68 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.jsp.html @@ -0,0 +1,60 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="tags" tagdir="/WEB-INF/tags" %>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - Panels using Tag Files</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - Panels using Tag Files</h1>
    +    <hr>
    +    <p>This JSP page invokes a custom tag that draws a
    +    panel around the contents of the tag body.  Normally, such a tag
    +    implementation would require a Java class with many println() statements,
    +    outputting HTML.  Instead, we can use a .tag file as a template,
    +    and we don't need to write a single line of Java or even a TLD!</p>
    +    <hr>
    +    <table border="0">
    +      <tr valign="top">
    +        <td>
    +          <tags:panel color="#ff8080" bgcolor="#ffc0c0" title="Panel 1">
    +            First panel.<br/>
    +          </tags:panel>
    +        </td>
    +        <td>
    +          <tags:panel color="#80ff80" bgcolor="#c0ffc0" title="Panel 2">
    +            Second panel.<br/>
    +            Second panel.<br/>
    +            Second panel.<br/>
    +            Second panel.<br/>
    +          </tags:panel>
    +        </td>
    +        <td>
    +          <tags:panel color="#8080ff" bgcolor="#c0c0ff" title="Panel 3">
    +            Third panel.<br/>
    +            <tags:panel color="#ff80ff" bgcolor="#ffc0ff" title="Inner">
    +              A panel in a panel.
    +            </tags:panel>
    +            Third panel.<br/>
    +          </tags:panel>
    +        </td>
    +      </tr>
    +    </table>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.tag.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.tag.html new file mode 100644 index 0000000..d2a3c84 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/panel.tag.html @@ -0,0 +1,31 @@ +
    +<!--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +<%@ attribute name="color" %>
    +<%@ attribute name="bgcolor" %>
    +<%@ attribute name="title" %>
    +<table border="1" bgcolor="${color}">
    +  <tr>
    +    <td><b>${title}</b></td>
    +  </tr>
    +  <tr>
    +    <td bgcolor="${bgcolor}">
    +      <jsp:doBody/>
    +    </td>
    +  </tr>
    +</table>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.html new file mode 100644 index 0000000..72ae49f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.html @@ -0,0 +1,33 @@ + + + +View Source Code + + + + +

    +

    + +

    Source Code for products.jsp +

    +

    Source Code for displayProducts.tag +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.jsp new file mode 100644 index 0000000..7f32ffb --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.jsp @@ -0,0 +1,54 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ taglib prefix="tags" tagdir="/WEB-INF/tags" %> + + + JSP 2.0 Examples - Display Products Tag File + + +

    JSP 2.0 Examples - Display Products Tag File

    +
    +

    This JSP page invokes a tag file that displays a listing of + products. The custom tag accepts two fragments that enable + customization of appearance. One for when the product is on sale + and one for normal price.

    +

    The tag is invoked twice, using different styles

    +
    +

    Products

    + + + Item: ${name}
    + Price: ${price} +
    + + Item: ${name}
    + Was: ${origPrice}
    + Now: ${salePrice} +
    +
    +
    +

    Products (Same tag, alternate style)

    + + + ${name} @ ${price} ea. + + + ${name} @ ${salePrice} ea. (was: ${origPrice}) + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.jsp.html new file mode 100644 index 0000000..5477a77 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/products.jsp.html @@ -0,0 +1,56 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ taglib prefix="tags" tagdir="/WEB-INF/tags" %>
    +<html>
    +  <head>
    +    <title>JSP 2.0 Examples - Display Products Tag File</title>
    +  </head>
    +  <body>
    +    <h1>JSP 2.0 Examples - Display Products Tag File</h1>
    +    <hr>
    +    <p>This JSP page invokes a tag file that displays a listing of
    +    products.  The custom tag accepts two fragments that enable
    +    customization of appearance.  One for when the product is on sale
    +    and one for normal price.</p>
    +    <p>The tag is invoked twice, using different styles</p>
    +    <hr>
    +    <h2>Products</h2>
    +    <tags:displayProducts>
    +      <jsp:attribute name="normalPrice">
    +        Item: ${name}<br/>
    +        Price: ${price}
    +      </jsp:attribute>
    +      <jsp:attribute name="onSale">
    +        Item: ${name}<br/>
    +        <font color="red"><strike>Was: ${origPrice}</strike></font><br/>
    +        <b>Now: ${salePrice}</b>
    +      </jsp:attribute>
    +    </tags:displayProducts>
    +    <hr>
    +    <h2>Products (Same tag, alternate style)</h2>
    +    <tags:displayProducts>
    +      <jsp:attribute name="normalPrice">
    +        <b>${name}</b> @ ${price} ea.
    +      </jsp:attribute>
    +      <jsp:attribute name="onSale">
    +        <b>${name}</b> @ ${salePrice} ea. (was: ${origPrice})
    +      </jsp:attribute>
    +    </tags:displayProducts>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/xhtmlbasic.tag.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/xhtmlbasic.tag.html new file mode 100644 index 0000000..5826b01 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsp2/tagfiles/xhtmlbasic.tag.html @@ -0,0 +1,23 @@ +
    +<!--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.0//EN"
    +"http://www.w3.org/TR/xhtml-basic/xhtml-basic10.dtd">
    +<html xmlns="http://www.w3.org/1999/xhtml">
    +<jsp:doBody/>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/ServletToJsp.java.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/ServletToJsp.java.html new file mode 100644 index 0000000..8aca657 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/ServletToJsp.java.html @@ -0,0 +1,41 @@ +
    +/*
    +* Licensed to the Apache Software Foundation (ASF) under one or more
    +* contributor license agreements.  See the NOTICE file distributed with
    +* this work for additional information regarding copyright ownership.
    +* The ASF licenses this file to You under the Apache License, Version 2.0
    +* (the "License"); you may not use this file except in compliance with
    +* the License.  You may obtain a copy of the License at
    +*
    +*     http://www.apache.org/licenses/LICENSE-2.0
    +*
    +* Unless required by applicable law or agreed to in writing, software
    +* distributed under the License is distributed on an "AS IS" BASIS,
    +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +* See the License for the specific language governing permissions and
    +* limitations under the License.
    +*/
    +
    +import javax.servlet.http.HttpServlet;
    +import javax.servlet.http.HttpServletRequest;
    +import javax.servlet.http.HttpServletResponse;
    +
    +public class ServletToJsp extends HttpServlet {
    +
    +    private static final long serialVersionUID = 1L;
    +
    +    @Override
    +    public void doGet (HttpServletRequest request,
    +            HttpServletResponse response) {
    +
    +       try {
    +           // Set the attribute and Forward to hello.jsp
    +           request.setAttribute ("servletName", "servletToJsp");
    +           getServletConfig().getServletContext().getRequestDispatcher(
    +                   "/jsp/jsptoserv/hello.jsp").forward(request, response);
    +       } catch (Exception ex) {
    +           ex.printStackTrace ();
    +       }
    +    }
    +}
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/hello.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/hello.jsp new file mode 100644 index 0000000..8b2a43f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/hello.jsp @@ -0,0 +1,26 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + +

    +I have been invoked by +<% out.print (request.getAttribute("servletName").toString()); %> +Servlet. +

    + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/hello.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/hello.jsp.html new file mode 100644 index 0000000..c1f7e86 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/hello.jsp.html @@ -0,0 +1,28 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<body bgcolor="white">
    +
    +<h1>
    +I have been invoked by
    +<% out.print (request.getAttribute("servletName").toString()); %>
    +Servlet.
    +</h1>
    +
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jsptoservlet.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jsptoservlet.jsp new file mode 100644 index 0000000..db68a6f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jsptoservlet.jsp @@ -0,0 +1,23 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + + + + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jsptoservlet.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jsptoservlet.jsp.html new file mode 100644 index 0000000..9a6a715 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jsptoservlet.jsp.html @@ -0,0 +1,25 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<body bgcolor="white">
    +
    +<!-- Forward to a servlet -->
    +<jsp:forward page="/servletToJsp" />
    +
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jts.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jts.html new file mode 100644 index 0000000..55927e7 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/jsptoserv/jts.html @@ -0,0 +1,34 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for JSP calling servlet +

    + +

    Source Code for Servlet calling JSP +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.html new file mode 100644 index 0000000..1c5a484 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.html @@ -0,0 +1,34 @@ + + + +Untitled Document + + + + +

    + +

    Source Code for Numguess Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.jsp new file mode 100644 index 0000000..d9c61b9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.jsp @@ -0,0 +1,69 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Number Guess Game + Written by Jason Hunter, CTO, K&A Software + http://www.servlets.com +--%> + +<%@ page import = "num.NumberGuessBean" %> + + + + + +Number Guess + + + +<% if (numguess.getSuccess()) { %> + + Congratulations! You got it. + And after just <%= numguess.getNumGuesses() %> tries.

    + + <% numguess.reset(); %> + + Care to try again? + +<% } else if (numguess.getNumGuesses() == 0) { %> + + Welcome to the Number Guess game.

    + + I'm thinking of a number between 1 and 100.

    + +

    + What's your guess? + +
    + +<% } else { %> + + Good guess, but nope. Try <%= numguess.getHint() %>. + + You have made <%= numguess.getNumGuesses() %> guesses.

    + + I'm thinking of a number between 1 and 100.

    + +

    + What's your guess? + +
    + +<% } %> + +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.jsp.html new file mode 100644 index 0000000..750db65 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/num/numguess.jsp.html @@ -0,0 +1,71 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +
    +  Number Guess Game
    +  Written by Jason Hunter, CTO, K&A Software
    +  http://www.servlets.com
    +--%>
    +
    +<%@ page import = "num.NumberGuessBean" %>
    +
    +<jsp:useBean id="numguess" class="num.NumberGuessBean" scope="session"/>
    +<jsp:setProperty name="numguess" property="*"/>
    +
    +<html>
    +<head><title>Number Guess</title></head>
    +<body bgcolor="white">
    +<font size=4>
    +
    +<% if (numguess.getSuccess()) { %>
    +
    +  Congratulations!  You got it.
    +  And after just <%= numguess.getNumGuesses() %> tries.<p>
    +
    +  <% numguess.reset(); %>
    +
    +  Care to <a href="numguess.jsp">try again</a>?
    +
    +<% } else if (numguess.getNumGuesses() == 0) { %>
    +
    +  Welcome to the Number Guess game.<p>
    +
    +  I'm thinking of a number between 1 and 100.<p>
    +
    +  <form method=get>
    +  What's your guess? <input type=text name=guess>
    +  <input type=submit value="Submit">
    +  </form>
    +
    +<% } else { %>
    +
    +  Good guess, but nope.  Try <b><%= numguess.getHint() %></b>.
    +
    +  You have made <%= numguess.getNumGuesses() %> guesses.<p>
    +
    +  I'm thinking of a number between 1 and 100.<p>
    +
    +  <form method=get>
    +  What's your guess? <input type=text name=guess>
    +  <input type=submit value="Submit">
    +  </form>
    +
    +<% } %>
    +
    +</font>
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/applet/Clock2.class b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/applet/Clock2.class new file mode 100644 index 0000000..0636834 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/applet/Clock2.class differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/applet/Clock2.java b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/applet/Clock2.java new file mode 100644 index 0000000..957c4e0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/applet/Clock2.java @@ -0,0 +1,223 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one or more +* contributor license agreements. See the NOTICE file distributed with +* this work for additional information regarding copyright ownership. +* The ASF licenses this file to You under the Apache License, Version 2.0 +* (the "License"); you may not use this file except in compliance with +* the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, software +* distributed under the License is distributed on an "AS IS" BASIS, +* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +* See the License for the specific language governing permissions and +* limitations under the License. +*/ + +import java.applet.Applet; +import java.awt.Color; +import java.awt.Font; +import java.awt.Graphics; +import java.text.SimpleDateFormat; +import java.util.Date; +import java.util.Locale; + +/** + * Time! + * + * @author Rachel Gollub + */ + +public class Clock2 extends Applet implements Runnable { + private static final long serialVersionUID = 1L; + Thread timer; // The thread that displays clock + int lastxs, lastys, lastxm, + lastym, lastxh, lastyh; // Dimensions used to draw hands + SimpleDateFormat formatter; // Formats the date displayed + String lastdate; // String to hold date displayed + Font clockFaceFont; // Font for number display on clock + Date currentDate; // Used to get date to display + Color handColor; // Color of main hands and dial + Color numberColor; // Color of second hand and numbers + + @Override + public void init() { + lastxs = lastys = lastxm = lastym = lastxh = lastyh = 0; + formatter = new SimpleDateFormat ("EEE MMM dd hh:mm:ss yyyy", Locale.getDefault()); + currentDate = new Date(); + lastdate = formatter.format(currentDate); + clockFaceFont = new Font("Serif", Font.PLAIN, 14); + handColor = Color.blue; + numberColor = Color.darkGray; + + try { + setBackground(new Color(Integer.parseInt(getParameter("bgcolor"),16))); + } catch (Exception E) { } + try { + handColor = new Color(Integer.parseInt(getParameter("fgcolor1"),16)); + } catch (Exception E) { } + try { + numberColor = new Color(Integer.parseInt(getParameter("fgcolor2"),16)); + } catch (Exception E) { } + resize(300,300); // Set clock window size + } + + // Plotpoints allows calculation to only cover 45 degrees of the circle, + // and then mirror + public void plotpoints(int x0, int y0, int x, int y, Graphics g) { + g.drawLine(x0+x,y0+y,x0+x,y0+y); + g.drawLine(x0+y,y0+x,x0+y,y0+x); + g.drawLine(x0+y,y0-x,x0+y,y0-x); + g.drawLine(x0+x,y0-y,x0+x,y0-y); + g.drawLine(x0-x,y0-y,x0-x,y0-y); + g.drawLine(x0-y,y0-x,x0-y,y0-x); + g.drawLine(x0-y,y0+x,x0-y,y0+x); + g.drawLine(x0-x,y0+y,x0-x,y0+y); + } + + // Circle is just Bresenham's algorithm for a scan converted circle + public void circle(int x0, int y0, int r, Graphics g) { + int x,y; + float d; + x=0; + y=r; + d=5/4-r; + plotpoints(x0,y0,x,y,g); + + while (y>x){ + if (d<0) { + d=d+2*x+3; + x++; + } else { + d=d+2*(x-y)+5; + x++; + y--; + } + plotpoints(x0,y0,x,y,g); + } + } + + // Paint is the main part of the program + @Override + public void paint(Graphics g) { + int xh, yh, xm, ym, xs, ys, s = 0, m = 10, h = 10, xcenter, ycenter; + String today; + + currentDate = new Date(); + SimpleDateFormat formatter = new SimpleDateFormat("s",Locale.getDefault()); + try { + s = Integer.parseInt(formatter.format(currentDate)); + } catch (NumberFormatException n) { + s = 0; + } + formatter.applyPattern("m"); + try { + m = Integer.parseInt(formatter.format(currentDate)); + } catch (NumberFormatException n) { + m = 10; + } + formatter.applyPattern("h"); + try { + h = Integer.parseInt(formatter.format(currentDate)); + } catch (NumberFormatException n) { + h = 10; + } + formatter.applyPattern("EEE MMM dd HH:mm:ss yyyy"); + today = formatter.format(currentDate); + xcenter=80; + ycenter=55; + + // a= s* pi/2 - pi/2 (to switch 0,0 from 3:00 to 12:00) + // x = r(cos a) + xcenter, y = r(sin a) + ycenter + + xs = (int)(Math.cos(s * 3.14f/30 - 3.14f/2) * 45 + xcenter); + ys = (int)(Math.sin(s * 3.14f/30 - 3.14f/2) * 45 + ycenter); + xm = (int)(Math.cos(m * 3.14f/30 - 3.14f/2) * 40 + xcenter); + ym = (int)(Math.sin(m * 3.14f/30 - 3.14f/2) * 40 + ycenter); + xh = (int)(Math.cos((h*30 + m/2) * 3.14f/180 - 3.14f/2) * 30 + xcenter); + yh = (int)(Math.sin((h*30 + m/2) * 3.14f/180 - 3.14f/2) * 30 + ycenter); + + // Draw the circle and numbers + + g.setFont(clockFaceFont); + g.setColor(handColor); + circle(xcenter,ycenter,50,g); + g.setColor(numberColor); + g.drawString("9",xcenter-45,ycenter+3); + g.drawString("3",xcenter+40,ycenter+3); + g.drawString("12",xcenter-5,ycenter-37); + g.drawString("6",xcenter-3,ycenter+45); + + // Erase if necessary, and redraw + + g.setColor(getBackground()); + if (xs != lastxs || ys != lastys) { + g.drawLine(xcenter, ycenter, lastxs, lastys); + g.drawString(lastdate, 5, 125); + } + if (xm != lastxm || ym != lastym) { + g.drawLine(xcenter, ycenter-1, lastxm, lastym); + g.drawLine(xcenter-1, ycenter, lastxm, lastym); } + if (xh != lastxh || yh != lastyh) { + g.drawLine(xcenter, ycenter-1, lastxh, lastyh); + g.drawLine(xcenter-1, ycenter, lastxh, lastyh); } + g.setColor(numberColor); + g.drawString("", 5, 125); + g.drawString(today, 5, 125); + g.drawLine(xcenter, ycenter, xs, ys); + g.setColor(handColor); + g.drawLine(xcenter, ycenter-1, xm, ym); + g.drawLine(xcenter-1, ycenter, xm, ym); + g.drawLine(xcenter, ycenter-1, xh, yh); + g.drawLine(xcenter-1, ycenter, xh, yh); + lastxs=xs; lastys=ys; + lastxm=xm; lastym=ym; + lastxh=xh; lastyh=yh; + lastdate = today; + currentDate=null; + } + + @Override + public void start() { + timer = new Thread(this); + timer.start(); + } + + @Override + public void stop() { + timer = null; + } + + @Override + public void run() { + Thread me = Thread.currentThread(); + while (timer == me) { + try { + Thread.sleep(100); + } catch (InterruptedException e) { + } + repaint(); + } + } + + @Override + public void update(Graphics g) { + paint(g); + } + + @Override + public String getAppletInfo() { + return "Title: A Clock \nAuthor: Rachel Gollub, 1995 \nAn analog clock."; + } + + @Override + public String[][] getParameterInfo() { + String[][] info = { + {"bgcolor", "hexadecimal RGB number", "The background color. Default is the color of your browser."}, + {"fgcolor1", "hexadecimal RGB number", "The color of the hands and dial. Default is blue."}, + {"fgcolor2", "hexadecimal RGB number", "The color of the seconds hand and numbers. Default is dark gray."} + }; + return info; + } +} diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.html new file mode 100644 index 0000000..27bc51b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.html @@ -0,0 +1,30 @@ + + + +Untitled Document + + + + +

    + +

    Source Code for Plugin Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.jsp new file mode 100644 index 0000000..a07dda3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.jsp @@ -0,0 +1,34 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + Plugin example + +

    Current time is :

    + + + Plugin tag OBJECT or EMBED not supported by browser. + + +

    +

    + +The above applet is loaded using the Java Plugin from a jsp page using the +plugin tag. + +

    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.jsp.html new file mode 100644 index 0000000..fc5e83a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/plugin/plugin.jsp.html @@ -0,0 +1,36 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<title> Plugin example </title>
    +<body bgcolor="white">
    +<h3> Current time is : </h3>
    +<jsp:plugin type="applet" code="Clock2.class" codebase="applet" jreversion="1.2" width="160" height="150" >
    +    <jsp:fallback>
    +        Plugin tag OBJECT or EMBED not supported by browser.
    +    </jsp:fallback>
    +</jsp:plugin>
    +<p>
    +<h4>
    +<font color=red>
    +The above applet is loaded using the Java Plugin from a jsp page using the
    +plugin tag.
    +</font>
    +</h4>
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/error.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/error.jsp new file mode 100644 index 0000000..3ef5743 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/error.jsp @@ -0,0 +1,25 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + +Error Page For Examples + + +Invalid username and/or password, please try +again. + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/error.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/error.jsp.html new file mode 100644 index 0000000..78fa3fb --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/error.jsp.html @@ -0,0 +1,27 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<head>
    +<title>Error Page For Examples</title>
    +</head>
    +<body bgcolor="white">
    +Invalid username and/or password, please try
    +<a href='<%= response.encodeURL("index.jsp") %>'>again</a>.
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/index.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/index.jsp new file mode 100644 index 0000000..31122eb --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/index.jsp @@ -0,0 +1,112 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page import="java.util.Enumeration" %> +<% + if (request.getParameter("logoff") != null) { + session.invalidate(); + response.sendRedirect("index.jsp"); + return; + } +%> + + +Protected Page for Examples + + + +You are logged in as remote user +<%= util.HTMLFilter.filter(request.getRemoteUser()) %> +in session <%= session.getId() %>

    + +<% + if (request.getUserPrincipal() != null) { +%> + Your user principal name is + <%= util.HTMLFilter.filter(request.getUserPrincipal().getName()) %> +

    +<% + } else { +%> + No user principal could be identified.

    +<% + } +%> + +<% + String role = request.getParameter("role"); + if (role == null) + role = ""; + if (role.length() > 0) { + if (request.isUserInRole(role)) { +%> + You have been granted role + <%= util.HTMLFilter.filter(role) %>

    +<% + } else { +%> + You have not been granted role + <%= util.HTMLFilter.filter(role) %>

    +<% + } + } +%> + +To check whether your user name has been granted a particular role, +enter it here: +
    + + +
    +

    + +To add some data to the authenticated session, enter it here: +
    + + + +
    +

    + +<% + String dataName = request.getParameter("dataName"); + if (dataName != null) { + session.setAttribute(dataName, request.getParameter("dataValue")); + } +%> +

    The authenticated session contains the following attributes:

    + + +<% + Enumeration names = session.getAttributeNames(); + while (names.hasMoreElements()) { + String name = names.nextElement(); +%> + +<% + } +%> +
    NameValue
    <%= name %><%= session.getAttribute(name) %>
    +

    + +If you have configured this application for form-based authentication, you can +log off by clicking +here. +This should cause you to be returned to the login page after the redirect +that is performed. + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/index.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/index.jsp.html new file mode 100644 index 0000000..9199db0 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/index.jsp.html @@ -0,0 +1,114 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@ page import="java.util.Enumeration" %>
    +<%
    +  if (request.getParameter("logoff") != null) {
    +    session.invalidate();
    +    response.sendRedirect("index.jsp");
    +    return;
    +  }
    +%>
    +<html>
    +<head>
    +<title>Protected Page for Examples</title>
    +</head>
    +<body bgcolor="white">
    +
    +You are logged in as remote user
    +<b><%= util.HTMLFilter.filter(request.getRemoteUser()) %></b>
    +in session <b><%= session.getId() %></b><br><br>
    +
    +<%
    +  if (request.getUserPrincipal() != null) {
    +%>
    +    Your user principal name is
    +    <b><%= util.HTMLFilter.filter(request.getUserPrincipal().getName()) %></b>
    +    <br><br>
    +<%
    +  } else {
    +%>
    +    No user principal could be identified.<br><br>
    +<%
    +  }
    +%>
    +
    +<%
    +  String role = request.getParameter("role");
    +  if (role == null)
    +    role = "";
    +  if (role.length() > 0) {
    +    if (request.isUserInRole(role)) {
    +%>
    +      You have been granted role
    +      <b><%= util.HTMLFilter.filter(role) %></b><br><br>
    +<%
    +    } else {
    +%>
    +      You have <i>not</i> been granted role
    +      <b><%= util.HTMLFilter.filter(role) %></b><br><br>
    +<%
    +    }
    +  }
    +%>
    +
    +To check whether your user name has been granted a particular role,
    +enter it here:
    +<form method="GET" action='<%= response.encodeURL("index.jsp") %>'>
    +<input type="text" name="role" value="<%= util.HTMLFilter.filter(role) %>">
    +<input type="submit" >
    +</form>
    +<br><br>
    +
    +To add some data to the authenticated session, enter it here:
    +<form method="GET" action='<%= response.encodeURL("index.jsp") %>'>
    +<input type="text" name="dataName">
    +<input type="text" name="dataValue">
    +<input type="submit" >
    +</form>
    +<br><br>
    +
    +<%
    +  String dataName = request.getParameter("dataName");
    +  if (dataName != null) {
    +    session.setAttribute(dataName, request.getParameter("dataValue"));
    +  }
    +%>
    +<p>The authenticated session contains the following attributes:</p>
    +<table>
    +<tr><th>Name</th><th>Value</th></tr>
    +<%
    +  Enumeration<String> names = session.getAttributeNames();
    +  while (names.hasMoreElements()) {
    +    String name = names.nextElement();
    +%>
    +<tr><td><%= name %></td><td><%= session.getAttribute(name) %></td>
    +<%
    +  }
    +%>
    +</table>
    +<br><br>
    +
    +If you have configured this application for form-based authentication, you can
    +log off by clicking
    +<a href='<%= response.encodeURL("index.jsp?logoff=true") %>'>here</a>.
    +This should cause you to be returned to the login page after the redirect
    +that is performed.
    +
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/login.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/login.jsp new file mode 100644 index 0000000..e11a898 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/login.jsp @@ -0,0 +1,38 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + +Login Page for Examples + +
    + + + + + + + + + + + + + +
    Username:
    Password:
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/login.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/login.jsp.html new file mode 100644 index 0000000..55e3883 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/security/protected/login.jsp.html @@ -0,0 +1,40 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<head>
    +<title>Login Page for Examples</title>
    +<body bgcolor="white">
    +<form method="POST" action='<%= response.encodeURL("j_security_check") %>' >
    +  <table border="0" cellspacing="5">
    +    <tr>
    +      <th align="right">Username:</th>
    +      <td align="left"><input type="text" name="j_username"></td>
    +    </tr>
    +    <tr>
    +      <th align="right">Password:</th>
    +      <td align="left"><input type="password" name="j_password"></td>
    +    </tr>
    +    <tr>
    +      <td align="right"><input type="submit" value="Log In"></td>
    +      <td align="left"><input type="reset"></td>
    +    </tr>
    +  </table>
    +</form>
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/DummyCart.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/DummyCart.html new file mode 100644 index 0000000..d953fa9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/DummyCart.html @@ -0,0 +1,56 @@ + + + + + +sessions.DummyCart Bean Properties + + +

    +sessions.DummyCart Bean Properties +

    +
    +
    +
    public class DummyCart
    extends Object
    + +

    +


    + +

    + + + + + + + + + +
    +Properties Summary
    + +String +DummyCart:items +
    +
    + +Multi +
    +


    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.html new file mode 100644 index 0000000..834ee0a --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.html @@ -0,0 +1,53 @@ + + + + + carts + + + + + +
    +
    +Please enter item to add or remove: +
    +Add Item: + + + + +

    + + + +
    + +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.jsp new file mode 100644 index 0000000..dc51495 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.jsp @@ -0,0 +1,43 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + + +<% + cart.processRequest(); +%> + + + +
    You have the following items in your cart: +
      +<% + String[] items = cart.getItems(); + for (String item : items) { +%> +
    1. <% out.print(util.HTMLFilter.filter(item)); %> +<% + } +%> +
    + +
    + +
    +<%@ include file ="carts.html" %> + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.jsp.html new file mode 100644 index 0000000..5f985d3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/carts.jsp.html @@ -0,0 +1,45 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<jsp:useBean id="cart" scope="session" class="sessions.DummyCart" />
    +
    +<jsp:setProperty name="cart" property="*" />
    +<%
    +    cart.processRequest();
    +%>
    +
    +
    +<FONT size = 5 COLOR="#CC0000">
    +<br> You have the following items in your cart:
    +<ol>
    +<%
    +    String[] items = cart.getItems();
    +    for (String item : items) {
    +%>
    +<li> <% out.print(util.HTMLFilter.filter(item)); %>
    +<%
    +    }
    +%>
    +</ol>
    +
    +</FONT>
    +
    +<hr>
    +<%@ include file ="carts.html" %>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/crt.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/crt.html new file mode 100644 index 0000000..11e6eda --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/sessions/crt.html @@ -0,0 +1,34 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for Cart Example +

    + +

    Property Sheet for DummyCart +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.html new file mode 100644 index 0000000..e20f840 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.html @@ -0,0 +1,30 @@ + + + +Untitled Document + + + + +

    + +

    Source Code for the Simple Tag Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.jsp new file mode 100644 index 0000000..2489146 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.jsp @@ -0,0 +1,38 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + +<%@ taglib uri="http://tomcat.apache.org/example-taglib" prefix="eg"%> + +Radio stations that rock: + +
      + +
    • <%= member %>
    • +
      +
    + + +Did you see me on the stderr window? + + + +Did you see me on the browser window as well? + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.jsp.html new file mode 100644 index 0000000..99d7172 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/simpletag/foo.jsp.html @@ -0,0 +1,40 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<body>
    +<%@ taglib uri="http://tomcat.apache.org/example-taglib" prefix="eg"%>
    +
    +Radio stations that rock:
    +
    +<ul>
    +<eg:foo att1="98.5" att2="92.3" att3="107.7">
    +<li><%= member %></li>
    +</eg:foo>
    +</ul>
    +
    +<eg:log>
    +Did you see me on the stderr window?
    +</eg:log>
    +
    +<eg:log toBrowser="true">
    +Did you see me on the browser window as well?
    +</eg:log>
    +
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.html new file mode 100644 index 0000000..e48355b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.html @@ -0,0 +1,31 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for Request Parameters Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.jsp new file mode 100644 index 0000000..9bb57a8 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.jsp @@ -0,0 +1,56 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + +

    Request Information

    + +JSP Request Method: <%= util.HTMLFilter.filter(request.getMethod()) %> +
    +Request URI: <%= util.HTMLFilter.filter(request.getRequestURI()) %> +
    +Request Protocol: <%= util.HTMLFilter.filter(request.getProtocol()) %> +
    +Servlet path: <%= util.HTMLFilter.filter(request.getServletPath()) %> +
    +Path info: <%= util.HTMLFilter.filter(request.getPathInfo()) %> +
    +Query string: <%= util.HTMLFilter.filter(request.getQueryString()) %> +
    +Content length: <%= request.getContentLength() %> +
    +Content type: <%= util.HTMLFilter.filter(request.getContentType()) %> +
    +Server name: <%= util.HTMLFilter.filter(request.getServerName()) %> +
    +Server port: <%= request.getServerPort() %> +
    +Remote user: <%= util.HTMLFilter.filter(request.getRemoteUser()) %> +
    +Remote address: <%= util.HTMLFilter.filter(request.getRemoteAddr()) %> +
    +Remote host: <%= util.HTMLFilter.filter(request.getRemoteHost()) %> +
    +Authorization scheme: <%= util.HTMLFilter.filter(request.getAuthType()) %> +
    +Locale: <%= request.getLocale() %> +
    +The browser you are using is +<%= util.HTMLFilter.filter(request.getHeader("User-Agent")) %> +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.jsp.html new file mode 100644 index 0000000..eb5c64f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/snp/snoop.jsp.html @@ -0,0 +1,58 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +<body bgcolor="white">
    +<h1> Request Information </h1>
    +<font size="4">
    +JSP Request Method: <%= util.HTMLFilter.filter(request.getMethod()) %>
    +<br>
    +Request URI: <%= util.HTMLFilter.filter(request.getRequestURI()) %>
    +<br>
    +Request Protocol: <%= util.HTMLFilter.filter(request.getProtocol()) %>
    +<br>
    +Servlet path: <%= util.HTMLFilter.filter(request.getServletPath()) %>
    +<br>
    +Path info: <%= util.HTMLFilter.filter(request.getPathInfo()) %>
    +<br>
    +Query string: <%= util.HTMLFilter.filter(request.getQueryString()) %>
    +<br>
    +Content length: <%= request.getContentLength() %>
    +<br>
    +Content type: <%= util.HTMLFilter.filter(request.getContentType()) %>
    +<br>
    +Server name: <%= util.HTMLFilter.filter(request.getServerName()) %>
    +<br>
    +Server port: <%= request.getServerPort() %>
    +<br>
    +Remote user: <%= util.HTMLFilter.filter(request.getRemoteUser()) %>
    +<br>
    +Remote address: <%= util.HTMLFilter.filter(request.getRemoteAddr()) %>
    +<br>
    +Remote host: <%= util.HTMLFilter.filter(request.getRemoteHost()) %>
    +<br>
    +Authorization scheme: <%= util.HTMLFilter.filter(request.getAuthType()) %>
    +<br>
    +Locale: <%= request.getLocale() %>
    +<hr>
    +The browser you are using is
    +<%= util.HTMLFilter.filter(request.getHeader("User-Agent")) %>
    +<hr>
    +</font>
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.html new file mode 100644 index 0000000..afe90b2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.html @@ -0,0 +1,36 @@ + + + +View Source Code + + + +

    + + + + + +

    + +

    + Source Code for choose.jsp +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.jsp new file mode 100644 index 0000000..745e5f5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.jsp @@ -0,0 +1,54 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + Tag Examples - choose + + +

    Tag Plugin Examples - <c:choose>

    + +
    +
    + Plugin Introductory Notes +
    + Brief Instructions for Writing Plugins +

    +
    + +
    + + <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> + + + # ${index}: + + + One!
    +
    + + Four!
    +
    + + Three!
    +
    + + Huh?
    +
    +
    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.jsp.html new file mode 100644 index 0000000..ee26203 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/choose.jsp.html @@ -0,0 +1,56 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +  <head>
    +    <title>Tag Examples - choose</title>
    +  </head>
    +  <body>
    +    <h1>Tag Plugin Examples - &lt;c:choose></h1>
    +
    +    <hr/>
    +    <br/>
    +    <a href="notes.html">Plugin Introductory Notes</a>
    +    <br/>
    +    <a href="howto.html">Brief Instructions for Writing Plugins</a>
    +    <br/> <br/>
    +    <hr/>
    +
    +    <br/>
    +
    +    <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
    +
    +    <c:forEach var="index" begin="0" end="4">
    +      # ${index}:
    +      <c:choose>
    +        <c:when test="${index == 1}">
    +          One!<br/>
    +        </c:when>
    +        <c:when test="${index == 4}">
    +          Four!<br/>
    +        </c:when>
    +        <c:when test="${index == 3}">
    +          Three!<br/>
    +        </c:when>
    +        <c:otherwise>
    +          Huh?<br/>
    +        </c:otherwise>
    +      </c:choose>
    +    </c:forEach>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.html new file mode 100644 index 0000000..3d2e608 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.html @@ -0,0 +1,36 @@ + + + +View Source Code + + + +

    + + + + + +

    + +

    + Source Code for foreach.jsp +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.jsp new file mode 100644 index 0000000..2def434 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.jsp @@ -0,0 +1,54 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + Tag Plugin Examples: forEach + + +

    Tag Plugin Examples - <c:forEach>

    + +
    +
    + Plugin Introductory Notes +
    + Brief Instructions for Writing Plugins +

    +
    + +
    + + <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> + <%@ page import="java.util.Vector" %> + +

    Iterating over a range

    + + ${item} + + + <% Vector v = new Vector(); + v.add("One"); v.add("Two"); v.add("Three"); v.add("Four"); + + pageContext.setAttribute("vector", v); + %> + +

    Iterating over a Vector

    + + + ${item} + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.jsp.html new file mode 100644 index 0000000..02af512 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/foreach.jsp.html @@ -0,0 +1,56 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +  <head>
    +    <title>Tag Plugin Examples: forEach</title>
    +  </head>
    +  <body>
    +    <h1>Tag Plugin Examples - &lt;c:forEach></h1>
    +
    +    <hr/>
    +    <br/>
    +    <a href="notes.html">Plugin Introductory Notes</a>
    +    <br/>
    +    <a href="howto.html">Brief Instructions for Writing Plugins</a>
    +    <br/> <br/>
    +    <hr/>
    +
    +    <br/>
    +
    +    <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
    +    <%@ page import="java.util.Vector" %>
    +
    +    <h3>Iterating over a range</h3>
    +    <c:forEach var="item" begin="1" end="10">
    +        ${item}
    +    </c:forEach>
    +
    +    <% Vector<String> v = new Vector<String>();
    +        v.add("One"); v.add("Two"); v.add("Three"); v.add("Four");
    +
    +        pageContext.setAttribute("vector", v);
    +    %>
    +
    +    <h3>Iterating over a Vector</h3>
    +
    +    <c:forEach items="${vector}" var="item" >
    +        ${item}
    +    </c:forEach>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/howto.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/howto.html new file mode 100644 index 0000000..5f1d223 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/howto.html @@ -0,0 +1,45 @@ + + + + Tag Plugin Implementation + + +

    How to write tag plugins

    +

    + To write a plugin, you'll need to download the source for Tomcat. + There are two steps: +

      +
    1. + Implement the plugin class.

      + This class, which implements + org.apache.jasper.compiler.tagplugin.TagPlugin + instructs Jasper what Java codes to generate in place of the tag + handler calls. + See Javadoc for org.apache.jasper.compiler.tagplugin.TagPlugin + for details. +

    2. + +
    3. + Create the plugin descriptor file WEB-INF/tagPlugins.xml

      + This file + specifies the plugin classes and their corresponding tag handler + classes. +

    4. +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.html new file mode 100644 index 0000000..b04ac59 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.html @@ -0,0 +1,36 @@ + + + +View Source Code + + + +

    + + + + + +

    + +

    + Source Code for if.jsp +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.jsp new file mode 100644 index 0000000..af627bf --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.jsp @@ -0,0 +1,47 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + + + Tag Plugin Examples: if + + +

    Tag Plugin Examples - <c:if>

    + +
    +
    + Plugin Introductory Notes +
    + Brief Instructions for Writing Plugins +

    +
    + +
    + <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> + +

    Set the test result to a variable

    + + The result of testing for (1==1) is: ${theTruth} + +

    Conditionally execute the body

    + +

    It's true that (2>0)! Working.

    +
    + +

    It's not true that (0>2)! Failed.

    +
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.jsp.html new file mode 100644 index 0000000..83aa912 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/if.jsp.html @@ -0,0 +1,49 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<html>
    +  <head>
    +    <title>Tag Plugin Examples: if</title>
    +  </head>
    +  <body>
    +    <h1>Tag Plugin Examples - &lt;c:if></h1>
    +
    +    <hr/>
    +    <br/>
    +    <a href="notes.html">Plugin Introductory Notes</a>
    +    <br/>
    +    <a href="howto.html">Brief Instructions for Writing Plugins</a>
    +    <br/> <br/>
    +    <hr/>
    +
    +    <br/>
    +    <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
    +
    +    <h3>Set the test result to a variable</h3>
    +    <c:if test="${1==1}" var="theTruth" scope="page"/>
    +    The result of testing for (1==1) is: ${theTruth}
    +
    +    <h3>Conditionally execute the body</h3>
    +    <c:if test="${2>0}">
    +        <p>It's true that (2>0)! Working.</p>
    +    </c:if>
    +    <c:if test="${0>2}">
    +        <p>It's not true that (0>2)! Failed.</p>
    +    </c:if>
    +  </body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/notes.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/notes.html new file mode 100644 index 0000000..cd326fc --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/tagplugin/notes.html @@ -0,0 +1,41 @@ + + + + Tag Plugin Introduction + + +

    Tag Plugins: Introductory Notes

    +

    + Tomcat provides a framework for implementing tag plugins. The + plugins instruct Jasper, at translation time, to replace tag handler + calls with Java scriptlets. + The framework allows tag library authors to implement plugins for + their tags. +

    +

    + Tomcat is released with plugins for several JSTL tags. Note + that these plugins work with JSTL 1.1 as well as JSTL 1.0, though + the examples uses JSTL 1.1 and JSP 2.0. + These plugins are not complete (for instance, some item types are not + handled in <c:if>). + They do serve as examples to show plugins in action (just + examine the generated Java files), and how they can be implemented. +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.html new file mode 100644 index 0000000..0012142 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.html @@ -0,0 +1,31 @@ + + + + +Untitled Document + + + + +

    + +

    Source Code for XML syntax Example +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.jsp new file mode 100644 index 0000000..fdd5f47 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.jsp @@ -0,0 +1,70 @@ + + + + + + + + + String getDateTimeStr(Locale l) { + DateFormat df = SimpleDateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.MEDIUM, l); + return df.format(new Date()); + } + + + + + Example JSP in XML format + + + +This is the output of a simple JSP using XML format. +
    + +
    Use a jsp:scriptlet to loop from 1 to 10:
    + +// Note we need to declare CDATA because we don't escape the less than symbol + + + + +
    +]]> + +
    + Use a jsp:expression to write the date and time in the browser's locale: + getDateTimeStr(request.getLocale()) +
    + + + + <p>This sentence is enclosed in a jsp:text element.</p> + + + + +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.jsp.html new file mode 100644 index 0000000..45b6991 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/jsp/xml/xml.jsp.html @@ -0,0 +1,72 @@ +
    +<?xml version="1.0"?>
    +<!--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +-->
    +<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"
    +  version="1.2">
    +<jsp:directive.page contentType="text/html"/>
    +<jsp:directive.page import="java.util.Date, java.util.Locale"/>
    +<jsp:directive.page import="java.text.*"/>
    +
    +<jsp:declaration>
    +  String getDateTimeStr(Locale l) {
    +    DateFormat df = SimpleDateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.MEDIUM, l);
    +    return df.format(new Date());
    +  }
    +</jsp:declaration>
    +
    +<html>
    +<head>
    +  <title>Example JSP in XML format</title>
    +</head>
    +
    +<body>
    +This is the output of a simple JSP using XML format.
    +<br />
    +
    +<div>Use a jsp:scriptlet to loop from 1 to 10: </div>
    +<jsp:scriptlet>
    +// Note we need to declare CDATA because we don't escape the less than symbol
    +<![CDATA[
    +  for (int i = 1; i<=10; i++) {
    +    out.println(i);
    +    if (i < 10) {
    +      out.println(", ");
    +    }
    +  }
    +]]>
    +</jsp:scriptlet>
    +
    +<!-- Because I omit br's end tag, declare it as CDATA -->
    +<![CDATA[
    +  <br><br>
    +]]>
    +
    +<div align="left">
    +  Use a jsp:expression to write the date and time in the browser's locale:
    +  <jsp:expression>getDateTimeStr(request.getLocale())</jsp:expression>
    +</div>
    +
    +
    +<jsp:text>
    +  &lt;p&gt;This sentence is enclosed in a jsp:text element.&lt;/p&gt;
    +</jsp:text>
    +
    +</body>
    +</html>
    +</jsp:root>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/index.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/index.jsp new file mode 100644 index 0000000..a867e37 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/index.jsp @@ -0,0 +1,32 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@page contentType="text/html; charset=UTF-8" %> +<% if (session.getAttribute("nickname") == null) { + response.sendRedirect("login.jsp"); + return; +} +%> + + + + JSP Chat + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/index.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/index.jsp.html new file mode 100644 index 0000000..ea11653 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/index.jsp.html @@ -0,0 +1,34 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<%@page contentType="text/html; charset=UTF-8" %>
    +<% if (session.getAttribute("nickname") == null) {
    +    response.sendRedirect("login.jsp");
    +    return;
    +}
    +%>
    +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
    +<html>
    +<head>
    +   <title>JSP Chat</title>
    +</head>
    +<frameset rows="1*,4*">
    +  <frame name="post" src="post.jsp" scrolling="no" title="Post message">
    +  <frame name="chat" src="chat" scrolling="yes" title="Chat">
    +</frameset>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/login.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/login.jsp new file mode 100644 index 0000000..beb3b38 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/login.jsp @@ -0,0 +1,33 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + +<%@page contentType="text/html; charset=UTF-8" %> + + + JSP Chat + + + + +
    + +Nickname: + +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/login.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/login.jsp.html new file mode 100644 index 0000000..32be849 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/login.jsp.html @@ -0,0 +1,35 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    +<%@page contentType="text/html; charset=UTF-8" %>
    +<html>
    +<head>
    +   <title>JSP Chat</title>
    +</head>
    +
    +<body bgcolor="#FFFFFF">
    +
    +<form method="POST" action='chat' target="_top" name="loginForm">
    +<input type="hidden" name="action" value="login">
    +Nickname: <input type="text" name="nickname">
    +<input type="submit">
    +</form>
    +
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/post.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/post.jsp new file mode 100644 index 0000000..f6b38e5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/post.jsp @@ -0,0 +1,55 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> + +<%@page contentType="text/html; charset=UTF-8" %> + + + JSP Chat + + + + +
    + +Message: + +
    + +
    +<% + String serverName = request.getServerName(); + if ("localhost".equals(serverName)) { + serverName = "127.0.0.1"; + } else if ("127.0.0.1".equals(serverName)) { + serverName = "localhost"; + } + + String chatUrl = request.getScheme() + "://" + serverName + ":" + + request.getServerPort() + request.getContextPath() + + request.getServletPath(); + + // strip "post.jsp" from the address + chatUrl = chatUrl.substring(0, chatUrl.lastIndexOf("/") + 1); +%> +Click to open a new chat window +Note: To avoid hitting the limit on the count of simultaneous +connections to the same host, imposed by the +HTTP specification, +the second chat window should be opened using a different URL, e.g. with +an IP address instead of the host name. + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/post.jsp.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/post.jsp.html new file mode 100644 index 0000000..684a2e6 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/chat/post.jsp.html @@ -0,0 +1,57 @@ +
    +<%--
    + Licensed to the Apache Software Foundation (ASF) under one or more
    +  contributor license agreements.  See the NOTICE file distributed with
    +  this work for additional information regarding copyright ownership.
    +  The ASF licenses this file to You under the Apache License, Version 2.0
    +  (the "License"); you may not use this file except in compliance with
    +  the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +--%>
    +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    +<%@page contentType="text/html; charset=UTF-8" %>
    +<html>
    +<head>
    +   <title>JSP Chat</title>
    +</head>
    +
    +<body bgcolor="#FFFFFF">
    +
    +<form method="POST" action='chat' name="postForm">
    +<input type="hidden" name="action" value="post">
    +Message: <input type="text" name="message">
    +<input type="submit">
    +</form>
    +
    +<br>
    +<%
    +  String serverName = request.getServerName();
    +  if ("localhost".equals(serverName)) {
    +      serverName = "127.0.0.1";
    +  } else if ("127.0.0.1".equals(serverName)) {
    +      serverName = "localhost";
    +  }
    +
    +  String chatUrl = request.getScheme() + "://" + serverName + ":"
    +    + request.getServerPort() + request.getContextPath()
    +    + request.getServletPath();
    +
    +  // strip "post.jsp" from the address
    +  chatUrl = chatUrl.substring(0, chatUrl.lastIndexOf("/") + 1);
    +%>
    +<a target="_blank" href="<%=chatUrl %>">Click to open a new chat window</a>
    +<em>Note</em>: To avoid hitting the limit on the count of simultaneous
    +connections to the same host, imposed by the
    +<a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec8.html#sec8.1.4">HTTP specification</a>,
    +the second chat window should be opened using a different URL, e.g. with
    +an IP address instead of the host name.
    +</body>
    +</html>
    +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/cookies.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/cookies.html new file mode 100644 index 0000000..bacee44 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/cookies.html @@ -0,0 +1,61 @@ + + + +Untitled Document + + + + +

    +

    Source Code for Cookie Example
    +

    + +
    import java.io.*;
    +import javax.servlet.*;
    +import javax.servlet.http.*;
    +
    +public class CookieExample extends HttpServlet {
    +
    +    public void doGet(HttpServletRequest request, HttpServletResponse response)
    +    throws IOException, ServletException
    +    {
    +        response.setContentType("text/html");
    +        PrintWriter out = response.getWriter();
    +
    +        // print out cookies
    +
    +        Cookie[] cookies = request.getCookies();
    +        for (int i = 0; i < cookies.length; i++) {
    +            Cookie c = cookies[i];
    +            String name = c.getName();
    +            String value = c.getValue();
    +            out.println(name + " = " + value);
    +        }
    +
    +        // set a cookie
    +
    +        String name = request.getParameter("cookieName");
    +        if (name != null && name.length() > 0) {
    +            String value = request.getParameter("cookieValue");
    +            Cookie c = new Cookie(name, value);
    +            response.addCookie(c);
    +        }
    +    }
    +}
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/helloworld.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/helloworld.html new file mode 100644 index 0000000..c223446 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/helloworld.html @@ -0,0 +1,50 @@ + + + +Untitled Document + + + + +

    +

    Source Code for HelloWorld Example
    +

    + +
    import java.io.*;
    +import javax.servlet.*;
    +import javax.servlet.http.*;
    +
    +public class HelloWorld extends HttpServlet {
    +
    +    public void doGet(HttpServletRequest request, HttpServletResponse response)
    +    throws IOException, ServletException
    +    {
    +        response.setContentType("text/html");
    +        PrintWriter out = response.getWriter();
    +        out.println("<html>");
    +        out.println("<head>");
    +        out.println("<title>Hello World!</title>");
    +        out.println("</head>");
    +        out.println("<body>");
    +        out.println("<h1>Hello World!</h1>");
    +        out.println("</body>");
    +        out.println("</html>");
    +    }
    +}
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/code.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/code.gif new file mode 100644 index 0000000..93af2cd Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/code.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/execute.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/execute.gif new file mode 100644 index 0000000..f64d70f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/execute.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/return.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/return.gif new file mode 100644 index 0000000..af4f68f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/images/return.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/index.html new file mode 100644 index 0000000..3e97b0f --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/index.html @@ -0,0 +1,180 @@ + + + + + + + + Servlet Examples + + +Servlet +Examples with Code +

    This is a collection of examples which demonstrate some of the more +frequently used parts of the Servlet API. Familiarity with the Java(tm) +Programming Language is assumed. +

    These examples will only work when viewed via an http URL. They will +not work if you are viewing these pages via a "file://..." URL. Please +refer to the README file provide with this Tomcat release regarding +how to configure and start the provided web server. +

    Wherever you see a form, enter some data and see how the servlet reacts. +When playing with the Cookie and Session Examples, jump back to the Headers +Example to see exactly what your browser is sending the server. +

    To navigate your way through the examples, the following icons will +help: +
      + + + + + + + + + + + + + + + + + + +
    Execute the example
    Look at the source code for the example
    Return to this screen
    + +

    Tip: To see the cookie interactions with your browser, try turning on +the "notify when setting a cookie" option in your browser preferences. +This will let you see when a session is created and give some feedback +when looking at the cookie demo. +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Hello WorldExecuteSource
    Request InfoExecuteSource
    Request HeadersExecuteSource
    Request ParametersExecuteSource
    CookiesExecuteSource
    SessionsExecuteSource
    + +

    Note: The source code for these examples does not contain all of the +source code that is actually in the example, only the important sections +of code. Code not important to understand the example has been removed +for clarity.

    + +Other Examples
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Servlet 3.0 Asynchronous processing examples:
    async0  + Execute +
    async1  + Execute +
    async2  + Execute +
    async3  + Execute +
    stockticker  + Execute +
    Comet processing example:
    + See the "Advanced IO" chapter in the User Guide for + details. This example only works with the HTTP NIO or HTTP APR/native + connectors as these are the only connectors that support Comet.
    Comet Chat  + Execute +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqheaders.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqheaders.html new file mode 100644 index 0000000..adda30c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqheaders.html @@ -0,0 +1,49 @@ + + + +Untitled Document + + + + +

    +

    Source Code for RequestHeader Example
    +

    + +
    import java.io.*;
    +import java.util.*;
    +import javax.servlet.*;
    +import javax.servlet.http.*;
    +
    +public class RequestHeaderExample extends HttpServlet {
    +
    +    public void doGet(HttpServletRequest request, HttpServletResponse response)
    +    throws IOException, ServletException
    +    {
    +        response.setContentType("text/html");
    +        PrintWriter out = response.getWriter();
    +        Enumeration e = request.getHeaderNames();
    +        while (e.hasMoreElements()) {
    +            String name = (String)e.nextElement();
    +            String value = request.getHeader(name);
    +            out.println(name + " = " + value);
    +        }
    +    }
    +}
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqinfo.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqinfo.html new file mode 100644 index 0000000..daf239c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqinfo.html @@ -0,0 +1,68 @@ + + + +Untitled Document + + + + +

    +

    Source Code for Request Info Example
    +

    + +
    import java.io.*;
    +import javax.servlet.*;
    +import javax.servlet.http.*;
    +
    +public class RequestInfo extends HttpServlet {
    +
    +    public void doGet(HttpServletRequest request, HttpServletResponse response)
    +    throws IOException, ServletException
    +    {
    +        response.setContentType("text/html");
    +        PrintWriter out = response.getWriter();
    +        out.println("<html>");
    +        out.println("<body>");
    +        out.println("<head>");
    +        out.println("<title>Request Information Example</title>");
    +        out.println("</head>");
    +        out.println("<body>");
    +        out.println("<h3>Request Information Example</h3>");
    +        out.println("Method: " + request.getMethod());
    +        out.println("Request URI: " + request.getRequestURI());
    +        out.println("Protocol: " + request.getProtocol());
    +        out.println("PathInfo: " + request.getPathInfo());
    +        out.println("Remote Address: " + request.getRemoteAddr());
    +        out.println("</body>");
    +        out.println("</html>");
    +    }
    +
    +    /**
    +     * We are going to perform the same operations for POST requests
    +     * as for GET methods, so this method just sends the request to
    +     * the doGet method.
    +     */
    +
    +    public void doPost(HttpServletRequest request, HttpServletResponse response)
    +    throws IOException, ServletException
    +    {
    +        doGet(request, response);
    +    }
    +}
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqparams.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqparams.html new file mode 100644 index 0000000..4bbb6b3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/reqparams.html @@ -0,0 +1,82 @@ + + + +Untitled Document + + + + +

    +

    Source Code for Request Parameter Example
    +

    + +
    import java.io.*;
    +import java.util.*;
    +import javax.servlet.*;
    +import javax.servlet.http.*;
    +
    +public class RequestParamExample extends HttpServlet {
    +
    +    public void doGet(HttpServletRequest request, HttpServletResponse response)
    +    throws IOException, ServletException
    +    {
    +        response.setContentType("text/html");
    +        PrintWriter out = response.getWriter();
    +        out.println("<html>");
    +        out.println("<head>");
    +        out.println("<title>Request Parameters Example</title>");
    +        out.println("</head>");
    +        out.println("<body>");
    +        out.println("<h3>Request Parameters Example</h3>");
    +        out.println("Parameters in this request:<br>");
    +
    +        String firstName = request.getParameter("firstname");
    +        String lastName = request.getParameter("lastname");
    +
    +        if (firstName != null || lastName != null) {
    +            out.println("First Name:");
    +            out.println(" = " + HTMLFilter.filter(firstName) + "<br>");
    +            out.println("Last Name:");
    +            out.println(" = " + HTMLFilter.filter(lastName));
    +        } else {
    +            out.println("No Parameters, Please enter some");
    +        }
    +        out.println("<P>");
    +        out.print("<form action=\"");
    +        out.print("RequestParamExample\" ");
    +        out.println("method=POST>");
    +        out.println("First Name:");
    +        out.println("<input type=text size=20 name=firstname>");
    +        out.println("<br>");
    +        out.println("Last Name:");
    +        out.println("<input type=text size=20 name=lastname>");
    +        out.println("<br>");
    +        out.println("<input type=submit>");
    +        out.println("</form>");
    +        out.println("</body>");
    +        out.println("</html>");
    +    }
    +
    +    public void doPost(HttpServletRequest request, HttpServletResponse res)
    +    throws IOException, ServletException
    +    {
    +        doGet(request, response);
    +    }
    +}
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/sessions.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/sessions.html new file mode 100644 index 0000000..99816c2 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/servlets/sessions.html @@ -0,0 +1,70 @@ + + + +Untitled Document + + + + +

    +

    Source Code for Session Example
    +

    + +
    import java.io.*;
    +import java.util.*;
    +import javax.servlet.*;
    +import javax.servlet.http.*;
    +
    +public class SessionExample extends HttpServlet {
    +
    +    public void doGet(HttpServletRequest request, HttpServletResponse response)
    +    throws IOException, ServletException
    +    {
    +        response.setContentType("text/html");
    +        PrintWriter out = response.getWriter();
    +
    +        HttpSession session = request.getSession(true);
    +
    +        // print session info
    +
    +        Date created = new Date(session.getCreationTime());
    +        Date accessed = new Date(session.getLastAccessedTime());
    +        out.println("ID " + session.getId());
    +        out.println("Created: " + created);
    +        out.println("Last Accessed: " + accessed);
    +
    +        // set session info if needed
    +
    +        String dataName = request.getParameter("dataName");
    +        if (dataName != null && dataName.length() > 0) {
    +            String dataValue = request.getParameter("dataValue");
    +            session.setAttribute(dataName, dataValue);
    +        }
    +
    +        // print session contents
    +
    +        Enumeration e = session.getAttributeNames();
    +        while (e.hasMoreElements()) {
    +            String name = (String)e.nextElement();
    +            String value = session.getAttribute(name).toString();
    +            out.println(name + " = " + value);
    +        }
    +    }
    +}
    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/chat.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/chat.html new file mode 100644 index 0000000..3ab0b91 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/chat.html @@ -0,0 +1,125 @@ + + + + + Apache Tomcat WebSocket Examples: Chat + + + + + +
    +

    + +

    +
    +
    +
    +
    + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/echo.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/echo.html new file mode 100644 index 0000000..a5258c1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/echo.html @@ -0,0 +1,160 @@ + + + + + Apache Tomcat WebSocket Examples: Echo + + + + + +
    +
    +
    + Connect using: + + + + +
    +
    + +
    +
    + + +
    +
    + +
    +
    + +
    +
    +
    +
    +
    +
    + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/index.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/index.html new file mode 100644 index 0000000..6133442 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/index.html @@ -0,0 +1,33 @@ + + + + + + Apache Tomcat Deprecated WebSocket Examples + + +

    Apache Tomcat Deprecated WebSocket Examples

    + +

    This API has been deprecated. The examples are also available using the JSR + 356 Java WebSocket 1.1 API.

    + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/snake.html b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/snake.html new file mode 100644 index 0000000..7704b61 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket-deprecated/snake.html @@ -0,0 +1,258 @@ + + + + + + Apache Tomcat WebSocket Examples: Multiplayer Snake + + + + +
    + +
    +
    +
    +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/chat.xhtml b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/chat.xhtml new file mode 100644 index 0000000..b74cff3 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/chat.xhtml @@ -0,0 +1,134 @@ + + + + + Apache Tomcat WebSocket Examples: Chat + + + + +

    Seems your browser doesn't support Javascript! Websockets rely on Javascript being enabled. Please enable + Javascript and reload this page!

    +
    +

    + +

    +
    +
    +
    +
    + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/drawboard.xhtml b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/drawboard.xhtml new file mode 100644 index 0000000..8c4ef73 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/drawboard.xhtml @@ -0,0 +1,897 @@ + + + + + Apache Tomcat WebSocket Examples: Drawboard + + + + +
    Seems your browser doesn't support Javascript! Websockets rely on Javascript being enabled. Please enable + Javascript and reload this page!
    +
    +
    +
    +
    + +

    About Drawboard WebSocket Example

    +
    +

    + This drawboard is a page where you can draw with your mouse or touch input + (using different colors) and everybody else which has the page open will + immediately see what you are drawing.
    + If someone opens the page later, they will get the current room image (so they + can see what was already drawn by other people). +

    +

    + It uses asynchronous sending of messages so that it doesn't need separate threads + for each client to send messages (this needs NIO or APR connector to be used).
    + Each "Room" (where the drawing happens) uses a ReentrantLock to synchronize access + (currently, only a single Room is implemented). +

    +

    + When you open the page, first you will receive a binary websocket message containing + the current room image as PNG image. After that, you will receive string messages + that contain the drawing actions (line from x1,y1 to x2,y2).
    + Note that it currently only uses simple string messages instead of JSON because + I did not want to introduce a dependency on a JSON lib. +

    +

    + It uses synchronization mechanisms to ensure that the final image will look the same + for every user, regardless of what their network latency/speed is – e.g. if two user + draw at the same time on the same place, the server will decide which line was the + first one, and that will be reflected on every client. +

    +
    + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/echo.xhtml b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/echo.xhtml new file mode 100644 index 0000000..d573d95 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/echo.xhtml @@ -0,0 +1,169 @@ + + + + + Apache Tomcat WebSocket Examples: Echo + + + + +

    Seems your browser doesn't support Javascript! Websockets rely on Javascript being enabled. Please enable + Javascript and reload this page!

    +
    +
    +
    + Connect to service implemented using: + + + + +
    +
    + +
    +
    + + +
    +
    + +
    +
    + +
    +
    +
    +
    +
    +
    + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/index.xhtml b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/index.xhtml new file mode 100644 index 0000000..97ee945 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/index.xhtml @@ -0,0 +1,32 @@ + + + + + Apache Tomcat WebSocket Examples + + +

    Apache Tomcat WebSocket Examples

    + + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/snake.xhtml b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/snake.xhtml new file mode 100644 index 0000000..fdc3e97 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/examples/websocket/snake.xhtml @@ -0,0 +1,266 @@ + + + + + Apache Tomcat WebSocket Examples: Multiplayer Snake + + + +

    Seems your browser doesn't support Javascript! Websockets rely on Javascript being enabled. Please enable + Javascript and reload this page!

    +
    + +
    +
    +
    +
    + + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/META-INF/context.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/META-INF/context.xml new file mode 100644 index 0000000..1f32048 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/META-INF/context.xml @@ -0,0 +1,28 @@ + + + + + + + \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/401.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/401.jsp new file mode 100644 index 0000000..047766b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/401.jsp @@ -0,0 +1,71 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page session="false" trimDirectiveWhitespaces="true" %> + + + + 401 Unauthorized + + + +

    401 Unauthorized

    +

    + You are not authorized to view this page. If you have not changed + any configuration files, please examine the file + conf/tomcat-users.xml in your installation. That + file must contain the credentials to let you use this webapp. +

    +

    + For example, to add the admin-gui role to a user named + tomcat with a password of s3cret, add the following to the + config file listed above. +

    +
    +<role rolename="admin-gui"/>
    +<user username="tomcat" password="s3cret" roles="admin-gui"/>
    +
    +

    + Note that for Tomcat 7 onwards, the roles required to use the host manager + application were changed from the single admin role to the + following two roles. You will need to assign the role(s) required for + the functionality you wish to access. +

    +
      +
    • admin-gui - allows access to the HTML GUI
    • +
    • admin-script - allows access to the text interface
    • +
    +

    + The HTML interface is protected against CSRF but the text interface is not. + To maintain the CSRF protection: +

    +
      +
    • Users with the admin-gui role should not be granted the + admin-script role.
    • +
    • If the text interface is accessed through a browser (e.g. for testing + since this interface is intended for tools not humans) then the browser + must be closed afterwards to terminate the session.
    • +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/403.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/403.jsp new file mode 100644 index 0000000..2c9f797 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/403.jsp @@ -0,0 +1,85 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page session="false" trimDirectiveWhitespaces="true" %> + + + + 403 Access Denied + + + +

    403 Access Denied

    +

    + You are not authorized to view this page. +

    +

    + If you have already configured the Host Manager application to allow access + and you have used your browsers back button, used a saved book-mark or + similar then you may have triggered the cross-site request forgery (CSRF) + protection that has been enabled for the HTML interface of the Host Manager + application. You will need to reset this protection by returning to the + main Host Manager page. + Once you return to this page, you will be able to continue using the Host + Manager application's HTML interface normally. If you continue to see this + access denied message, check that you have the necessary permissions to + access this application. +

    +

    If you have not changed + any configuration files, please examine the file + conf/tomcat-users.xml in your installation. That + file must contain the credentials to let you use this webapp. +

    +

    + For example, to add the admin-gui role to a user named + tomcat with a password of s3cret, add the following to the + config file listed above. +

    +
    +<role rolename="admin-gui"/>
    +<user username="tomcat" password="s3cret" roles="admin-gui"/>
    +
    +

    + Note that for Tomcat 7 onwards, the roles required to use the host manager + application were changed from the single admin role to the + following two roles. You will need to assign the role(s) required for + the functionality you wish to access. +

    +
      +
    • admin-gui - allows access to the HTML GUI
    • +
    • admin-script - allows access to the text interface
    • +
    +

    + The HTML interface is protected against CSRF but the text interface is not. + To maintain the CSRF protection: +

    +
      +
    • Users with the admin-gui role should not be granted the + admin-script role.
    • +
    • If the text interface is accessed through a browser (e.g. for testing + since this interface is intended for tools not humans) then the browser + must be closed afterwards to terminate the session.
    • +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/404.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/404.jsp new file mode 100644 index 0000000..9816df5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/jsp/404.jsp @@ -0,0 +1,62 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page import="org.apache.catalina.util.RequestUtil" session="false" + trimDirectiveWhitespaces="true" %> + + + + 404 Not found + + + +

    404 Not found

    +

    + The page you tried to access + (<%=RequestUtil.filter((String) request.getAttribute( + "javax.servlet.error.request_uri"))%>) + does not exist. +

    +

    + The Host Manager application has been re-structured for Tomcat 7 onwards and + some URLs have changed. All URLs used to access the Manager application + should now start with one of the following options: +

    +
      +
    • <%=request.getContextPath()%>/html for the HTML GUI
    • +
    • <%=request.getContextPath()%>/text for the text interface
    • +
    +

    + Note that the URL for the text interface has changed from + "<%=request.getContextPath()%>" to + "<%=request.getContextPath()%>/text". +

    +

    + You probably need to adjust the URL you are using to access the Host Manager + application. However, there is always a chance you have found a bug in the + Host Manager application. If you are sure you have found a bug, and that the + bug has not already been reported, please report it to the Apache Tomcat + team. +

    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/manager.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/manager.xml new file mode 100644 index 0000000..48ac6f8 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/manager.xml @@ -0,0 +1,28 @@ + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/web.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/web.xml new file mode 100644 index 0000000..30107ae --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/WEB-INF/web.xml @@ -0,0 +1,161 @@ + + + + + + Tomcat Host Manager Application + + A scriptable host management web application for the Tomcat Web Server; + Manager lets you view, create and remove virtual hosts. + + + + HostManager + org.apache.catalina.manager.host.HostManagerServlet + + debug + 2 + + + + HTMLHostManager + org.apache.catalina.manager.host.HTMLHostManagerServlet + + debug + 2 + + + + + SetCharacterEncoding + org.apache.catalina.filters.SetCharacterEncodingFilter + + encoding + UTF-8 + + + + + SetCharacterEncoding + /* + + + + CSRF + org.apache.catalina.filters.CsrfPreventionFilter + + entryPoints + /html,/html/,/html/list,/index.jsp + + + + + + + + HTTP header security filter + org.apache.catalina.filters.HttpHeaderSecurityFilter + + hstsEnabled + false + + + + + CSRF + HTMLHostManager + + + + HTTP header security filter + /* + + + + + HostManager + /text/* + + + HTMLHostManager + /html/* + + + + + + HostManager commands + /text/* + + + + admin-script + + + + + HTMLHostManager commands + /html/* + + + + admin-gui + + + + + + BASIC + Tomcat Host Manager Application + + + + + + The role that is required to log in to the Host Manager Application HTML + interface + + admin-gui + + + + The role that is required to log in to the Host Manager Application text + interface + + admin-script + + + + 401 + /WEB-INF/jsp/401.jsp + + + 403 + /WEB-INF/jsp/403.jsp + + + 404 + /WEB-INF/jsp/404.jsp + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/add.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/add.gif new file mode 100644 index 0000000..0774d07 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/add.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/asf-logo.svg b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/asf-logo.svg new file mode 100644 index 0000000..e24cbe5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/asf-logo.svg @@ -0,0 +1,226 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/code.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/code.gif new file mode 100644 index 0000000..d27307b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/code.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/design.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/design.gif new file mode 100644 index 0000000..f5db0a9 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/design.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/docs.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/docs.gif new file mode 100644 index 0000000..d64a4a1 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/docs.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/fix.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/fix.gif new file mode 100644 index 0000000..d59ad64 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/fix.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/tomcat.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/tomcat.gif new file mode 100644 index 0000000..f2aa6f8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/tomcat.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/update.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/update.gif new file mode 100644 index 0000000..31e22ab Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/update.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/void.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/void.gif new file mode 100644 index 0000000..e565824 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/images/void.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/index.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/index.jsp new file mode 100644 index 0000000..2806b76 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/host-manager/index.jsp @@ -0,0 +1,18 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page session="false" trimDirectiveWhitespaces="true" %> +<% response.sendRedirect(request.getContextPath() + "/html"); %> \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/META-INF/context.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/META-INF/context.xml new file mode 100644 index 0000000..0217745 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/META-INF/context.xml @@ -0,0 +1,22 @@ + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/401.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/401.jsp new file mode 100644 index 0000000..84c9a97 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/401.jsp @@ -0,0 +1,80 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page session="false" trimDirectiveWhitespaces="true" %> + + + + 401 Unauthorized + + + +

    401 Unauthorized

    +

    + You are not authorized to view this page. If you have not changed + any configuration files, please examine the file + conf/tomcat-users.xml in your installation. That + file must contain the credentials to let you use this webapp. +

    +

    + For example, to add the manager-gui role to a user named + tomcat with a password of s3cret, add the following to the + config file listed above. +

    +
    +<role rolename="manager-gui"/>
    +<user username="tomcat" password="s3cret" roles="manager-gui"/>
    +
    +

    + Note that for Tomcat 7 onwards, the roles required to use the manager + application were changed from the single manager role to the + following four roles. You will need to assign the role(s) required for + the functionality you wish to access. +

    +
      +
    • manager-gui - allows access to the HTML GUI and the status + pages
    • +
    • manager-script - allows access to the text interface and the + status pages
    • +
    • manager-jmx - allows access to the JMX proxy and the status + pages
    • +
    • manager-status - allows access to the status pages only
    • +
    +

    + The HTML interface is protected against CSRF but the text and JMX interfaces + are not. To maintain the CSRF protection: +

    +
      +
    • Users with the manager-gui role should not be granted either + the manager-script or manager-jmx roles.
    • +
    • If the text or jmx interfaces are accessed through a browser (e.g. for + testing since these interfaces are intended for tools not humans) then + the browser must be closed afterwards to terminate the session.
    • +
    +

    + For more information - please see the + Manager App How-To. +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/403.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/403.jsp new file mode 100644 index 0000000..cb7144b --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/403.jsp @@ -0,0 +1,95 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page session="false" trimDirectiveWhitespaces="true" %> + + + + 403 Access Denied + + + +

    403 Access Denied

    +

    + You are not authorized to view this page. +

    +

    + If you have already configured the Manager application to allow access and + you have used your browsers back button, used a saved book-mark or similar + then you may have triggered the cross-site request forgery (CSRF) protection + that has been enabled for the HTML interface of the Manager application. You + will need to reset this protection by returning to the + main Manager page. Once you + return to this page, you will be able to continue using the Manager + application's HTML interface normally. If you continue to see this access + denied message, check that you have the necessary permissions to access this + application. +

    +

    + If you have not changed + any configuration files, please examine the file + conf/tomcat-users.xml in your installation. That + file must contain the credentials to let you use this webapp. +

    +

    + For example, to add the manager-gui role to a user named + tomcat with a password of s3cret, add the following to the + config file listed above. +

    +
    +<role rolename="manager-gui"/>
    +<user username="tomcat" password="s3cret" roles="manager-gui"/>
    +
    +

    + Note that for Tomcat 7 onwards, the roles required to use the manager + application were changed from the single manager role to the + following four roles. You will need to assign the role(s) required for + the functionality you wish to access. +

    +
      +
    • manager-gui - allows access to the HTML GUI and the status + pages
    • +
    • manager-script - allows access to the text interface and the + status pages
    • +
    • manager-jmx - allows access to the JMX proxy and the status + pages
    • +
    • manager-status - allows access to the status pages only
    • +
    +

    + The HTML interface is protected against CSRF but the text and JMX interfaces + are not. To maintain the CSRF protection: +

    +
      +
    • Users with the manager-gui role should not be granted either + the manager-script or manager-jmx roles.
    • +
    • If the text or jmx interfaces are accessed through a browser (e.g. for + testing since these interfaces are intended for tools not humans) then + the browser must be closed afterwards to terminate the session.
    • +
    +

    + For more information - please see the + Manager App How-To. +

    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/404.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/404.jsp new file mode 100644 index 0000000..7e1ef5c --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/404.jsp @@ -0,0 +1,63 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page import="org.apache.catalina.util.RequestUtil" session="false" + trimDirectiveWhitespaces="true" %> + + + + 404 Not found + + + +

    404 Not found

    +

    + The page you tried to access + (<%=RequestUtil.filter((String) request.getAttribute( + "javax.servlet.error.request_uri"))%>) + does not exist. +

    +

    + The Manager application has been re-structured for Tomcat 7 onwards and some + of URLs have changed. All URLs used to access the Manager application should + now start with one of the following options: +

    +
      +
    • <%=request.getContextPath()%>/html for the HTML GUI
    • +
    • <%=request.getContextPath()%>/text for the text interface
    • +
    • <%=request.getContextPath()%>/jmxproxy for the JMX proxy
    • +
    • <%=request.getContextPath()%>/status for the status pages
    • +
    +

    + Note that the URL for the text interface has changed from + "<%=request.getContextPath()%>" to + "<%=request.getContextPath()%>/text". +

    +

    + You probably need to adjust the URL you are using to access the Manager + application. However, there is always a chance you have found a bug in the + Manager application. If you are sure you have found a bug, and that the bug + has not already been reported, please report it to the Apache Tomcat team. +

    + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/sessionDetail.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/sessionDetail.jsp new file mode 100644 index 0000000..159650d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/sessionDetail.jsp @@ -0,0 +1,197 @@ + +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@page session="false" contentType="text/html; charset=ISO-8859-1" %> +<%@page import="java.util.Enumeration" %> +<%@page import="javax.servlet.http.HttpSession" %> +<%@page import="org.apache.catalina.Session" %> +<%@page import="org.apache.catalina.manager.JspHelper" %> +<%@page import="org.apache.catalina.util.ContextName" %> + +<%--!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" + "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"--%> + + +<% String path = (String) request.getAttribute("path"); + String version = (String) request.getAttribute("version"); + ContextName cn = new ContextName(path, version); + Session currentSession = (Session)request.getAttribute("currentSession"); + String currentSessionId = null; + HttpSession currentHttpSession = null; + if (currentSession != null) { + currentHttpSession = currentSession.getSession(); + currentSessionId = JspHelper.escapeXml(currentSession.getId()); + } else { + currentSessionId = "Session invalidated"; + } + String submitUrl = JspHelper.escapeXml(response.encodeURL( + ((HttpServletRequest) pageContext.getRequest()).getRequestURI() + + "?path=" + path + "&version=" + version)); +%> + + + + + + + + + + Sessions Administration: details for <%= currentSessionId %> + + +<% if (currentHttpSession == null) { %> +

    <%=currentSessionId%>

    +<% } else { %> +

    Details for Session <%= currentSessionId %>

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Session Id<%= currentSessionId %>
    Guessed Locale<%= JspHelper.guessDisplayLocaleFromSession(currentSession) %>
    Guessed User<%= JspHelper.guessDisplayUserFromSession(currentSession) %>
    Creation Time<%= JspHelper.getDisplayCreationTimeForSession(currentSession) %>
    Last Accessed Time<%= JspHelper.getDisplayLastAccessedTimeForSession(currentSession) %>
    Session Max Inactive Interval<%= JspHelper.secondsToTimeString(currentSession.getMaxInactiveInterval()) %>
    Used Time<%= JspHelper.getDisplayUsedTimeForSession(currentSession) %>
    Inactive Time<%= JspHelper.getDisplayInactiveTimeForSession(currentSession) %>
    TTL<%= JspHelper.getDisplayTTLForSession(currentSession) %>
    + +
    +
    + + + <% + if ("Primary".equals(request.getParameter("sessionType"))) { + %> + + <% + } + %> +
    +
    + +
    <%= JspHelper.escapeXml(request.getAttribute("error")) %>
    +
    <%= JspHelper.escapeXml(request.getAttribute("message")) %>
    + + + <% int nAttributes = 0; + Enumeration attributeNamesEnumeration = currentHttpSession.getAttributeNames(); + while (attributeNamesEnumeration.hasMoreElements()) { + attributeNamesEnumeration.nextElement(); + ++nAttributes; + } + %> + + + + + + + + + <%--tfoot> + + + + + + <% attributeNamesEnumeration = currentHttpSession.getAttributeNames(); + while (attributeNamesEnumeration.hasMoreElements()) { + String attributeName = attributeNamesEnumeration.nextElement(); + %> + + + + + + <% } // end while %> + +
    <%= JspHelper.formatNumber(nAttributes) %> attributes
    Remove AttributeAttribute nameAttribute value
    + TODO: set Max Inactive Interval on sessions +
    +
    +
    + + + + <% + if ("Primary".equals(request.getParameter("sessionType"))) { + %> + + + <% + } else { + out.print("Primary sessions only"); + } + %> +
    +
    +
    <%= JspHelper.escapeXml(attributeName) %><% Object attributeValue = currentHttpSession.getAttribute(attributeName); %>"><%= JspHelper.escapeXml(attributeValue) %>
    +<% } // endif%> + +
    +

    + +

    +
    + +<%--div style="display: none;"> +

    + Valid HTML 4.01! + Valid XHTML 1.0! + Valid XHTML 1.1! +

    + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/sessionsList.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/sessionsList.jsp new file mode 100644 index 0000000..03a1675 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/jsp/sessionsList.jsp @@ -0,0 +1,172 @@ + +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@page session="false" contentType="text/html; charset=ISO-8859-1" %> +<%@page import="java.util.Collection" %> +<%@page import="java.util.Iterator" %> +<%@page import="org.apache.catalina.manager.JspHelper" %> +<%@page import="org.apache.catalina.Session" %> +<%@page import="org.apache.catalina.ha.session.DeltaSession" %> +<%@page import="org.apache.catalina.util.ContextName" %> + + + +<%@page import="org.apache.catalina.manager.DummyProxySession"%> +<% String path = (String) request.getAttribute("path"); + String version = (String) request.getAttribute("version"); + ContextName cn = new ContextName(path, version); + String submitUrl = JspHelper.escapeXml(response.encodeURL( + ((HttpServletRequest) pageContext.getRequest()).getRequestURI() + + "?path=" + path + "&version=" + version)); + Collection activeSessions = (Collection) request.getAttribute("activeSessions"); +%> + + + + + + + + + + Sessions Administration for <%= JspHelper.escapeXml(cn.getDisplayName()) %> + + +

    Sessions Administration for <%= JspHelper.escapeXml(cn.getDisplayName()) %>

    + +

    Tips:

    +
      +
    • Click on a column to sort.
    • +
    • To view a session details and/or remove a session attributes, click on its id.
    • +
    + +
    <%= JspHelper.escapeXml(request.getAttribute("error")) %>
    +
    <%= JspHelper.escapeXml(request.getAttribute("message")) %>
    + +
    +
    Active HttpSessions informations + + "/> + <% String order = (String) request.getAttribute("order"); + if (order == null || "".equals(order)) { + order = "ASC"; + } + %> + + + <%= JspHelper.formatNumber(activeSessions.size()) %> active Sessions
    + + + + + + + + + + + + + + + <% if (activeSessions.size() > 10) { %> + <%-- is the same as --%> + + + + + + + + + + + + + <% } // end if %> + +<% Iterator iter = activeSessions.iterator(); + while (iter.hasNext()) { + Session currentSession = (Session) iter.next(); + String currentSessionId = JspHelper.escapeXml(currentSession.getId()); + String type; + if (currentSession instanceof DeltaSession) { + if (((DeltaSession) currentSession).isPrimarySession()) { + type = "Primary"; + } else { + type = "Backup"; + } + } else if (currentSession instanceof DummyProxySession) { + type = "Proxy"; + } else { + type = "Primary"; + } +%> + + + + + + + + + + + +<% } // end while %> + +
    Session IdTypeGuessed LocaleGuessed User nameCreation TimeLast Accessed TimeUsed TimeInactive TimeTTL
    Session IdTypeGuessed LocaleGuessed User nameCreation TimeLast Accessed TimeUsed TimeInactive TimeTTL
    + <% + if ("Proxy".equals(type)) { + out.print(currentSessionId); + } else { + %> + <%= currentSessionId %> + <% + } + %> + <%= type %><%= JspHelper.guessDisplayLocaleFromSession(currentSession) %><%= JspHelper.guessDisplayUserFromSession(currentSession) %><%= JspHelper.getDisplayCreationTimeForSession(currentSession) %><%= JspHelper.getDisplayLastAccessedTimeForSession(currentSession) %><%= JspHelper.getDisplayUsedTimeForSession(currentSession) %><%= JspHelper.getDisplayInactiveTimeForSession(currentSession) %><%= JspHelper.getDisplayTTLForSession(currentSession) %>
    +

    + +

    +
    +
    + +
    +

    + +

    +
    + +<%--div style="display: none;"> +

    + Valid HTML 4.01! + Valid XHTML 1.0! + Valid XHTML 1.1! +

    + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/web.xml b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/web.xml new file mode 100644 index 0000000..f500899 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/WEB-INF/web.xml @@ -0,0 +1,225 @@ + + + + + + Tomcat Manager Application + + A scriptable management web application for the Tomcat Web Server; + Manager lets you view, load/unload/etc particular web applications. + + + + Manager + org.apache.catalina.manager.ManagerServlet + + debug + 2 + + + + HTMLManager + org.apache.catalina.manager.HTMLManagerServlet + + debug + 2 + + + + + 52428800 + 52428800 + 0 + + + + Status + org.apache.catalina.manager.StatusManagerServlet + + debug + 0 + + + + + JMXProxy + org.apache.catalina.manager.JMXProxyServlet + + + + + Manager + /text/* + + + Status + /status/* + + + JMXProxy + /jmxproxy/* + + + HTMLManager + /html/* + + + + SetCharacterEncoding + org.apache.catalina.filters.SetCharacterEncodingFilter + + encoding + UTF-8 + + + + + SetCharacterEncoding + /* + + + + CSRF + org.apache.catalina.filters.CsrfPreventionFilter + + entryPoints + /html,/html/,/html/list,/index.jsp + + + + + + + + HTTP header security filter + org.apache.catalina.filters.HttpHeaderSecurityFilter + + hstsEnabled + false + + + + + CSRF + HTMLManager + + + + HTTP header security filter + /* + + + + + + + HTML Manager interface (for humans) + /html/* + + + manager-gui + + + + + Text Manager interface (for scripts) + /text/* + + + manager-script + + + + + JMX Proxy interface + /jmxproxy/* + + + manager-jmx + + + + + Status interface + /status/* + + + manager-gui + manager-script + manager-jmx + manager-status + + + + + + BASIC + Tomcat Manager Application + + + + + + The role that is required to access the HTML Manager pages + + manager-gui + + + + The role that is required to access the text Manager pages + + manager-script + + + + The role that is required to access the HTML JMX Proxy + + manager-jmx + + + + The role that is required to access to the Manager Status pages + + manager-status + + + + 401 + /WEB-INF/jsp/401.jsp + + + 403 + /WEB-INF/jsp/403.jsp + + + 404 + /WEB-INF/jsp/404.jsp + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/add.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/add.gif new file mode 100644 index 0000000..0774d07 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/add.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/asf-logo.svg b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/asf-logo.svg new file mode 100644 index 0000000..e24cbe5 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/asf-logo.svg @@ -0,0 +1,226 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/code.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/code.gif new file mode 100644 index 0000000..d27307b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/code.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/design.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/design.gif new file mode 100644 index 0000000..f5db0a9 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/design.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/docs.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/docs.gif new file mode 100644 index 0000000..d64a4a1 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/docs.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/fix.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/fix.gif new file mode 100644 index 0000000..d59ad64 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/fix.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/tomcat.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/tomcat.gif new file mode 100644 index 0000000..f2aa6f8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/tomcat.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/update.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/update.gif new file mode 100644 index 0000000..31e22ab Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/update.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/void.gif b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/void.gif new file mode 100644 index 0000000..e565824 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/images/void.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/index.jsp b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/index.jsp new file mode 100644 index 0000000..2806b76 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/index.jsp @@ -0,0 +1,18 @@ +<%-- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--%> +<%@ page session="false" trimDirectiveWhitespaces="true" %> +<% response.sendRedirect(request.getContextPath() + "/html"); %> \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/status.xsd b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/status.xsd new file mode 100644 index 0000000..5af979d --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/status.xsd @@ -0,0 +1,84 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/xform.xsl b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/xform.xsl new file mode 100644 index 0000000..b07fcb9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/temp/manager/xform.xsl @@ -0,0 +1,125 @@ + + + + + + + + + + + + Tomcat Status + + + +
    Tomcat Status
    + + + + + +
    + + + + Memory Pools
    + +
    +
    + + + + + + + + +
    JVM:free: total: max:

    +
    + + + + + + + + + + +
    Name: Type: Initial: Committed: Maximum: Used:
    +
    + + + Connector --
    + + + + +
    + + + + + + + + +
    threadInfomaxThreads: currentThreadCount: currentThreadsBusy:

    +
    + + + + + + + + + + + +
    requestInfo maxTime: processingTime: requestCount: errorCount: bytesReceived: bytesSent:

    +
    + + + + + + +
    StageTimeB SentB RecvClientVHostRequest

    +
    + + + + + + + + + + ? + + + +
    diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/RELEASE-NOTES.txt b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/RELEASE-NOTES.txt new file mode 100644 index 0000000..c4582d1 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/RELEASE-NOTES.txt @@ -0,0 +1,237 @@ +================================================================================ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +================================================================================ + + + Apache Tomcat Version 7.0.108 + Release Notes + + +========= +CONTENTS: +========= + +* Dependency Changes +* API Stability +* JNI Based Applications +* Bundled APIs +* Web application reloading and static fields in shared libraries +* Tomcat on Linux +* Enabling SSI and CGI Support +* Security manager URLs +* Symlinking static resources +* Viewing the Tomcat Change Log +* Cryptographic software notice +* When all else fails + + +=================== +Dependency Changes: +=================== +Tomcat 7.0 is designed to run on Java 6 and later. + +In addition, Tomcat 7.0 uses the Eclipse JDT Java compiler for +compiling JSP pages. This means you no longer need to have the complete +Java Development Kit (JDK) to run Tomcat, but a Java Runtime Environment +(JRE) is sufficient. The Eclipse JDT Java compiler is bundled with the +binary Tomcat distributions. Tomcat can also be configured to use the +compiler from the JDK to compile JSPs, or any other Java compiler supported +by Apache Ant. + + +============== +API Stability: +============== +The public interfaces for the following classes are fixed and will not be +changed at all during the remaining lifetime of the 7.x series: +- javax/**/* + +The public interfaces for the following classes may be added to in order to +resolve bugs and/or add new features. No existing interface will be removed or +changed although it may be deprecated. +- org/apache/catalina/* +- org/apache/catalina/comet/* + +Note: As Tomcat 7 matures, the above list will be added to. The list is not + considered complete at this time. + +The remaining classes are considered part of the Tomcat internals and may change +without notice between point releases. + + +======================= +JNI Based Applications: +======================= +Applications that require native libraries must ensure that the libraries have +been loaded prior to use. Typically, this is done with a call like: + + static { + System.loadLibrary("path-to-library-file"); + } + +in some class. However, the application must also ensure that the library is +not loaded more than once. If the above code were placed in a class inside +the web application (i.e. under /WEB-INF/classes or /WEB-INF/lib), and the +application were reloaded, the loadLibrary() call would be attempted a second +time. + +To avoid this problem, place classes that load native libraries outside of the +web application, and ensure that the loadLibrary() call is executed only once +during the lifetime of a particular JVM. + + +============= +Bundled APIs: +============= +A standard installation of Tomcat 7.0 makes all of the following APIs available +for use by web applications (by placing them in "lib"): +* annotations-api.jar (Common Annotations 1.1 package) +* catalina.jar (Tomcat Catalina implementation) +* catalina-ant.jar (Tomcat Catalina Ant tasks) +* catalina-ha.jar (High availability package) +* catalina-tribes.jar (Group communication) +* ecj-4.4.2.jar (Eclipse JDT Java compiler) +* el-api.jar (EL 2.2 API) +* jasper.jar (Jasper 2 Compiler and Runtime) +* jasper-el.jar (Jasper 2 EL implementation) +* jsp-api.jar (JSP 2.2 API) +* servlet-api.jar (Servlet 3.0 API) +* tomcat7-websocket.jar (WebSocket 1.1 implementation) +* tomcat-api.jar (Interfaces shared by Catalina and Jasper) +* tomcat-coyote.jar (Tomcat connectors and utility classes) +* tomcat-dbcp.jar (package renamed database connection pool based on Commons DBCP 1.x) +* tomcat-jdbc.jar (Tomcat's database connection pooling solution) +* tomcat-util.jar (Various utilities) +* websocket-api.jar (WebSocket 1.1 API) + +You can make additional APIs available to all of your web applications by +putting unpacked classes into a "classes" directory (not created by default), +or by placing them in JAR files in the "lib" directory. + +To override the XML parser implementation or interfaces, use the Endorsed +Standards Override mechanism of the JVM. The default configuration defines +JARs located in "$CATALINA_HOME/endorsed" as endorsed. This mechanism is +no longer supported with Java 9. + +When running on Java 6, the Common Annotations 1.0 implementation provided +by the JRE will be used. To use the Common Annotations 1.1 provided by +Tomcat, use the Endorsed Standards Override mechanism of the JVM. The +default configuration defines JARs located in "$CATALINA_HOME/endorsed" as +endorsed. + + +================================================================ +Web application reloading and static fields in shared libraries: +================================================================ +Some shared libraries (many are part of the JDK) keep references to objects +instantiated by the web application. To avoid class loading related problems +(ClassCastExceptions, messages indicating that the classloader +is stopped, etc.), the shared libraries state should be reinitialized. + +Something which might help is to avoid putting classes which would be +referenced by a shared static field in the web application classloader, +and putting them in the shared classloader instead (JARs should be put in the +"lib" folder, and classes should be put in the "classes" folder). + + +================ +Tomcat on Linux: +================ +GLIBC 2.2 / Linux 2.4 users should define an environment variable: +export LD_ASSUME_KERNEL=2.2.5 + +Redhat Linux 9.0 users should use the following setting to avoid +stability problems: +export LD_ASSUME_KERNEL=2.4.1 + +There are some Linux bugs reported against the NIO sendfile behavior, make sure you +have a JDK that is up to date, or disable sendfile behavior in the Connector.
    +6427312: (fc) FileChannel.transferTo() throws IOException "system call interrupted"
    +5103988: (fc) FileChannel.transferTo should return -1 for EAGAIN instead throws IOException
    +6253145: (fc) FileChannel.transferTo on Linux fails when going beyond 2GB boundary
    +6470086: (fc) FileChannel.transferTo(2147483647, 1, channel) cause "Value too large" exception
    + + +============================= +Enabling SSI and CGI Support: +============================= +Because of the security risks associated with CGI and SSI available +to web applications, these features are disabled by default. + +To enable and configure CGI support, please see the cgi-howto.html page. + +To enable and configure SSI support, please see the ssi-howto.html page. + + +====================== +Security manager URLs: +====================== +In order to grant security permissions to JARs located inside the +web application repository, use URLs of the following format +in your policy file: + +file:${catalina.base}/webapps/examples/WEB-INF/lib/driver.jar + + +============================ +Symlinking static resources: +============================ +By default, Unix symlinks will not work when used in a web application to link +resources located outside the web application root directory. + +This behavior is optional, and the "allowLinking" flag may be used to disable +the check. + + +============================== +Viewing the Tomcat Change Log: +============================== +See changelog.html in this directory. + + +============================= +Cryptographic software notice +============================= +This distribution includes cryptographic software. The country in +which you currently reside may have restrictions on the import, +possession, use, and/or re-export to another country, of +encryption software. BEFORE using any encryption software, please +check your country's laws, regulations and policies concerning the +import, possession, or use, and re-export of encryption software, to +see if this is permitted. See for more +information. + +The U.S. Government Department of Commerce, Bureau of Industry and +Security (BIS), has classified this software as Export Commodity +Control Number (ECCN) 5D002.C.1, which includes information security +software using or performing cryptographic functions with asymmetric +algorithms. The form and manner of this Apache Software Foundation +distribution makes it eligible for export under the License Exception +ENC Technology Software Unrestricted (TSU) exception (see the BIS +Export Administration Regulations, Section 740.13) for both object +code and source code. + +The following provides more details on the included cryptographic +software: + - Tomcat includes code designed to work with JSSE + - Tomcat includes code designed to work with OpenSSL + + +==================== +When all else fails: +==================== +See the FAQ +https://tomcat.apache.org/faq/ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/WEB-INF/web.xml b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/WEB-INF/web.xml new file mode 100644 index 0000000..a3505e7 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/WEB-INF/web.xml @@ -0,0 +1,30 @@ + + + + + Welcome to Tomcat + + Welcome to Tomcat + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/asf-logo-wide.svg b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/asf-logo-wide.svg new file mode 100644 index 0000000..5743c42 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/asf-logo-wide.svg @@ -0,0 +1,295 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-button.png b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-button.png new file mode 100644 index 0000000..b544bbf Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-button.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-middle.png b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-middle.png new file mode 100644 index 0000000..0c95a82 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-middle.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-nav.png b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-nav.png new file mode 100644 index 0000000..d44b094 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-nav.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-upper.png b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-upper.png new file mode 100644 index 0000000..7d9ae7b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/bg-upper.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/favicon.ico b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/favicon.ico new file mode 100644 index 0000000..6c5bd2c Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/favicon.ico differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/index.jsp b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/index.jsp new file mode 100644 index 0000000..c0a56a9 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/index.jsp @@ -0,0 +1,220 @@ +<%-- +Licensed to the Apache Software Foundation (ASF) under one or more +contributor license agreements. See the NOTICE file distributed with +this work for additional information regarding copyright ownership. +The ASF licenses this file to You under the Apache License, Version 2.0 +(the "License"); you may not use this file except in compliance with +the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +--%> +<%@ page session="false" pageEncoding="UTF-8" contentType="text/html; charset=UTF-8" %> +<% +java.text.SimpleDateFormat sdf = new java.text.SimpleDateFormat("yyyy"); +request.setAttribute("year", sdf.format(new java.util.Date())); +request.setAttribute("tomcatUrl", "https://tomcat.apache.org/"); +request.setAttribute("tomcatDocUrl", "/docs/"); +request.setAttribute("tomcatExamplesUrl", "/examples/"); +%> + + + + + <%=request.getServletContext().getServerInfo() %> + + + + + + +
    + +
    +

    ${pageContext.servletContext.serverInfo}

    +
    +
    +
    +

    If you're seeing this, you've successfully installed Tomcat. Congratulations!

    +
    + +
    + + + +
    +
    +
    +
    +

    Developer Quick Start

    + + +
    +
    +

    Examples

    +
    +
    + +
    +
    +
    +
    +
    +

    Managing Tomcat

    +

    For security, access to the manager webapp is restricted. + Users are defined in:

    +
    $CATALINA_HOME/conf/tomcat-users.xml
    +

    In Tomcat 7.0 access to the manager application is split between + different users.   Read more...

    +
    +

    Release Notes

    +

    Changelog

    +

    Migration Guide

    +

    Security Notices

    +
    +
    +
    +
    +

    Documentation

    +

    Tomcat 7.0 Documentation

    +

    Tomcat 7.0 Configuration

    +

    Tomcat Wiki

    +

    Find additional important configuration information in:

    +
    $CATALINA_HOME/RUNNING.txt
    +

    Developers may be interested in:

    + +
    +
    +
    +
    +

    Getting Help

    +

    FAQ and Mailing Lists

    +

    The following mailing lists are available:

    + +
    +
    +
    +
    + + +
    + + + diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat-power.gif b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat-power.gif new file mode 100644 index 0000000..01c400b Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat-power.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.css b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.css new file mode 100644 index 0000000..6995838 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.css @@ -0,0 +1,351 @@ +/* + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ +body { + margin: 10px 20px; + text-align: center; + font-family: Arial, sans-serif; +} + +h1, h2, h3, h4, h5, h6, p, ul, ol { + margin: 0 0 0.5em; +} +h1 { + font-size: 18pt; + margin: 0.5em 0 0; +} +h2 { + font-size: 16pt; +} +h3 { + font-size: 13pt; +} +h4 { + font-size: 12pt; +} +h5 { + font-size: 11pt; +} +p { + font-size: 11pt +} + +ul { + margin: 0; + padding: 0 0 0 0.25em; + text-indent: 0; + list-style: none; +} +li { + margin: 0; + padding: 0 0 0.25em; + text-indent: 0; + font-size: 80%; +} + +pre { + text-indent: 0.25em; + width: 90%; + font-size: 90%; +} + +br.separator { + margin: 0; + padding: 0; + clear: both; +} + +a img { + border: 0 none; +} + +.container { + padding: 10px; + margin: 0 0 10px; +} + +.col20 { + float: left; + width: 20%; +} + +.col25 { + float: left; + width: 25%; +} + +#wrapper { + display: block; + margin: 0 auto; + text-align: left; + min-width: 720px; + max-width: 1000px; +} +.curved { + border-radius: 10px; + -moz-border-radius: 10px; + -webkit-border-radius: 10px; + -khtml-border-radius: 10px; +} + +#navigation { + background: #eee url(bg-nav.png) repeat-x top left; + margin: 0 0 10px; + padding: 0; +} +#navigation span { + float: left; +} +#navigation span a { + display: block; + padding: 10px; + font-weight: bold; + text-shadow: 1px 1px 1px #fff; +} +#navigation span a:link, +#navigation span a:visited, +#navigation span a:hover, +#navigation span a:active { + color: #666; + text-decoration: none; +} +#navigation span#nav-help { + float: right; + margin-right: 0; +} + +#asf-box { + height: 40px; + background: #fff url(asf-logo-wide.svg) no-repeat top right;} +#asf-box h1 { + padding: 0; + margin: 0; +} + +#upper { + background: #fff url(bg-upper.png) repeat-x top left; +} + +#congrats { + text-align: center; + padding: 10px; + margin: 0 40px 20px; + background-color: #9c9; +} +#congrats h2 { + font-size: 14pt; + padding: 0; + margin: 0; + color: #fff; +} + +#notice { + float: left; + width: 560px; + color: #696; +} +#notice a:link, +#notice a:visited, +#notice a:hover, +#notice a:active { + color: #090; + text-decoration: none; +} +#notice img, +#notice #tasks { + float: left; +} +#tasks a:link, +#tasks a:visited, +#tasks a:hover, +#tasks a:active { + text-decoration: underline; +} +#notice img { + margin-right: 20px; +} + +#actions { + float: right; + width: 140px; +} + +#actions .button { + display: block; + padding: 0; + height: 36px; + background: url(bg-button.png) no-repeat top left; +} + +#actions .button a { + display: block; + padding: 0; +} + +#actions .button a:link, +#actions .button a:visited, +#actions .button a:hover, +#actions .button a:active { + color: #696; + text-decoration: none; +} + +#actions .button a span { + display: block; + padding: 6px 10px; + color: #666; + text-shadow: 1px 1px 1px #fff; + font-size: 10pt; + font-weight: bold; +} + +#middle { + background: #eef url(bg-middle.png) repeat-x top left; + margin: 20px 0; + padding: 1px 10px; +} +#middle h3 { + margin: 0 0 10px; + color: #033; +} +#middle p { + font-size: 10pt; +} +#middle a:link, +#middle a:visited, +#middle a:hover, +#middle a:active { + color: #366; + font-weight: bold; +} +#middle .col25 .container { + padding: 0 0 1px; +} + +#developers { + float: left; + width: 40%; +} +#security { + float: right; + width: 50%; +} + +#lower { + padding: 0; +} + +#lower a:link, +#lower a:visited, +#lower a:hover, +#lower a:active { + color: #600; +} + +#lower strong a:link, +#lower strong a:visited, +#lower strong a:hover, +#lower strong a:active { + color: #c00; +} + +#lower h3 { + color: #963; + font-size: 14pt; +} +#lower h4 { + font-size: 12pt; +} +#lower ul { + padding: 0; + margin: 0.5em 0; +} +#lower p, +#lower li { + font-size: 9pt; + color: #753; + margin: 0 0 0.1em; +} +#lower li { + padding: 3px 5px; +} +#lower li strong { + color: #a53; +} +#lower li#list-announce { + border: 1px solid #f90; + background-color: #ffe8c8; +} +#lower p { + font-size: 10.5pt; +} + +#low-manage, +#low-docs, +#low-help { + float: left; + width: 32%; +} +#low-docs { + margin: 0 0 0 2.2%; +} +#low-help { + float: right; +} + +#low-manage div, +#low-docs div, +#low-help div { + min-height: 280px; + border: 3px solid #ffdc75; + background-color: #fff1c8; + padding: 10px; +} + +#footer { + padding: 0; + margin: 20px 0; + color: #999; + background-color: #eee; +} +#footer h4 { + margin: 0 0 10px; + font-size: 10pt; +} +#footer p { + margin: 0 0 10px; + font-size: 10pt; +} +#footer ul { + margin: 6px 0 1px; + padding: 0; +} +#footer li { + margin: 0; + font-size: 9pt; +} + +#footer a:link, +#footer a:visited, +#footer a:hover, +#footer a:active { + color: #666; +} + +.copyright { + font-size: 10pt; + color: #666; +} \ No newline at end of file diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.gif b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.gif new file mode 100644 index 0000000..f2aa6f8 Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.gif differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.png b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.png new file mode 100644 index 0000000..209b07f Binary files /dev/null and b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.png differ diff --git a/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.svg b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.svg new file mode 100644 index 0000000..8823f79 --- /dev/null +++ b/centos8_tomcat/apache-tomcat-7.0.108/webapps/ROOT/tomcat.svg @@ -0,0 +1,967 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + 2006-05-09T08:17:21Z + 2006-05-09T08:37:38Z + Illustrator + + + + JPEG + 256 + 184 + /9j/4AAQSkZJRgABAgEASABIAAD/7QAsUGhvdG9zaG9wIDMuMAA4QklNA+0AAAAAABAASAAAAAEA +AQBIAAAAAQAB/+4ADkFkb2JlAGTAAAAAAf/bAIQABgQEBAUEBgUFBgkGBQYJCwgGBggLDAoKCwoK +DBAMDAwMDAwQDA4PEA8ODBMTFBQTExwbGxscHx8fHx8fHx8fHwEHBwcNDA0YEBAYGhURFRofHx8f +Hx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8f/8AAEQgAuAEAAwER +AAIRAQMRAf/EAaIAAAAHAQEBAQEAAAAAAAAAAAQFAwIGAQAHCAkKCwEAAgIDAQEBAQEAAAAAAAAA +AQACAwQFBgcICQoLEAACAQMDAgQCBgcDBAIGAnMBAgMRBAAFIRIxQVEGE2EicYEUMpGhBxWxQiPB +UtHhMxZi8CRygvElQzRTkqKyY3PCNUQnk6OzNhdUZHTD0uIIJoMJChgZhJRFRqS0VtNVKBry4/PE +1OT0ZXWFlaW1xdXl9WZ2hpamtsbW5vY3R1dnd4eXp7fH1+f3OEhYaHiImKi4yNjo+Ck5SVlpeYmZ +qbnJ2en5KjpKWmp6ipqqusra6voRAAICAQIDBQUEBQYECAMDbQEAAhEDBCESMUEFURNhIgZxgZEy +obHwFMHR4SNCFVJicvEzJDRDghaSUyWiY7LCB3PSNeJEgxdUkwgJChgZJjZFGidkdFU38qOzwygp +0+PzhJSktMTU5PRldYWVpbXF1eX1RlZmdoaWprbG1ub2R1dnd4eXp7fH1+f3OEhYaHiImKi4yNjo ++DlJWWl5iZmpucnZ6fkqOkpaanqKmqq6ytrq+v/aAAwDAQACEQMRAD8A9U4q7FXYq7FXYq7FXYq7 +FXYq7FXYq7FXYq7FXYq7FXhH/OYHnWfQ/wAurfRLSUxXXmK49GQqaN9VtwJJqH3cxqfYnFXhP5Y/ +85O+f/JU0enaw769okbBJLS8ZvrUKg0IhnarDj/I9R2HHFX2F+Xn5neT/P8ApP6R8u3glKAfW7KS +iXNuzdFljqaezCqnsTirK8VdirsVdirsVdirsVdirC/zM/Nvyd+XemC71255Xcqk2WmQUa5nI2+F +CRxUd3ag+nbFXx1+Zf8Azkn+YvneaW1tLh9C0NgwXTrB2V3Sm/rzji8m3UDitP2cVfV//OOfmabz +D+T3l+6uHMl1aRPYTsxqSbVzEhJ7kxKhxV6VirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVd +irsVfHn/ADlxdSa7+bvlvyvGx4RW0EVARtNfXJVqf7BY+uRlKgT3JAt5r/zkD5ZGgfmfqSRR+nZ6 +gsd9agdOMq0f/ksj5h9nZvEwgnmNi2Z4cMiw/wAqebPMHlTXLfW9BvHstQtjVZEPwstQWjkXo6NT +4lOxzOan3v8Akl+cel/mX5a+tAJa69ZcU1fTlJojGvGWLluYpKbV6GqmtKlV6NirsVdirsVdirsV +eWfnr+eGl/lroywwBLzzPfox02wJqqL0+sT03EanoOrnYdyFXwh5i8x655j1i41jW7yS+1K6blNc +SmpPgABQKo6BVFB2xVnf5Q+SjrWh+d9Yli5w6XolylsadbqSNnTj8kiYf7IZg6zUeHKERzlIfL8U +3YoWCe4Pff8AnCfVTN5D1zTCamz1P11HcLcQIAPlWE5nNL6KxV2KuxV2KuxV2KuxV2KuxV2KuxV2 +KuxV2KuxV2KuxV2KvjD8wm/Sv/OX8UTGsdrqGnCMNUU+rW0Mp6f5ammY2sNYZ/1T9zZi+oe9m/8A +zkx+Xc/mPytFrunRepqehc3ljUVeS0cAyAU6mMqHA8OXfNB2PqhCfAeUvv8A2uZqcdix0fIedQ69 +m35OefrryN+YOla2kpjsjKttqqDo9nMwEoI78ftr/lKMVfaeqf8AOSH5KaaSs3meCZx0W1inuanf +YNDG69vHFWM3v/OYn5QW5YQ/pK8ArQwWqitPD1pIuvviqVT/APObH5cKR6GjaxIP2i8dqhB9qTvi +qmP+c2fIFd9C1Wnfa2/6q4qmFv8A85n/AJUSvxksdZtx/NJb25H/ACTuHOKp3bf85XfkpPBI7avN +BIisywS2lwGcqCeIZUdKmm1WGKvijzz5x1bzl5q1HzFqjlrm+lLrHWqxRDaOFP8AJjSij7+uKpNb +W1xdXMVtbRtNcTuscMKAszu54qqgbkkmgwE1uVfbHkL8uk8o/lTPoMiK+o3drPNqZHRrieIhlr4I +tEB9q5yWo1fi6gS/hBFfN2UMfDAjqwT/AJwdvyt/5usC20sVlOq77em0yMR2/wB2Cudc619ZYq7F +XYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXxZKTJ/zmFc+oedNTmA5b/ZtG49fCgpmH2h/ +cS9zbh+sPqDrsc4t2r57/Nf/AJxkGo3c+teSTFb3ExMlxo0hEcTMdybd/spU/sN8PgQNs3+i7Xoc +OX5/rcLLpusWIaF/zif56vFWTVr6y0pG6xgtczL81QLH90mZWTtnFH6bk1x0sjz2Z1pf/OIvlOIL ++lNbvrthSv1dYrZSe+zC4ND88wp9uTP0xA9+/wCptGkHUsms/wDnGf8AKS3AEunT3dOpmupxXam/ +pNFmPPtjOeRA+H67bBpoPDv+ch/yt03yXrdjeaFbG30HUouCQ8pJBFcQ0DqXkZ2+NSrCrfzeGbns +vWHNAiX1BxdRi4TtySH8jfJdn5u/MOy07UIfrGl28ct3fw1IDRxrxUEqQaGV0By7X6g4sRkOfRhh +hxSp9N3X/OO/5P3FSdBETGnxRXN0nT/JEvH8M50dq6gfxfYHOOnh3JDqP/OKn5a3NTazajYt+yIp +0dfpEsbn/hsvj21lHMRP497A6SPmwzW/+cQr9A76H5himO/CG9haL5AyxGT/AIhmXj7cifqiR7t/ +1NUtIehZh+S3/OP8Xk+5GveYXivNfTkLSKIloLYGqlwzBecjL3p8P45i9odqeIOCH09fNtw6fh3P +N7DfIz2VwijkzRuFA6klTmpxmpD3uRLk+bf+cJrrj+Yet2tT+90hpeP7J9O5hWp9/wB5tneunfZm +KuxV2KuxV2KuxV2KuxVZLNFDG0srrHGu7O5CqB7k4qks3nzyNC5jm8xaZHIOqPeW6nf2L4qmFhrW +j6iK6ff294KVrbypLt1r8BPjirAvzb/Pnyf+WrW9rqKS6hq90vqRaba8eaxVp6krMQEUkEL1JPbq +cVYFof8Azmp5BupVj1fR9Q0wNsZo/SuY1/1qGN6fJDir2Xyf+Yfkrzjam48taxb6iqgGSKNisyA9 +PUhcLKn+yXFWRYq7FXYq7FXxRrBNj/zl/NVwC+rL8XtcWw+Hf/jJTMXXC8M/6pbMP1h9SZxLtnYq +7FWG+afzg/LnyvdNZ6vrUSXqGj2sKvcSofB1hV+B/wBamZmHs/NkFxjt8mqWaMeZRPk78zvI/nF5 +ItA1RLm5hHKS1dXhmC1pyEcoRmXputRkdRosuLeQ2TDLGXJCfm/5JXzj5D1HSo05X8a/WtNPcXMI +JUD/AFxVP9lk+z9R4WUE8jsWOaHFGnl3/OI/lpodN1zzFMlGuJUsLcsKELCPUlpXsWkQfNc2Xbmb +eMPj+r9LRpI8y+hc0DmuxV2KuxV2Kvl//nClHP5oas4B4Lok6luwLXdqQPpoc9AdK+08VdirsVdi +rsVdiqXeYPMOi+XtIudY1q7jsdNtF5z3EpooHQAd2ZjsqjcnYYq+VfPf/OV3nXzNqp0D8stPlto5 +mMcF0IfrGoT+8UIDrGD8mbvVcVSqz/5xn/Pjzs66h5t1RbUueX+5W7kurgA/yxx+sq/6pZaeGKsj +h/5wanMYM3nNUk7qmml1/wCCN0n6sVQt7/zhDr8B56Z5stppEIMZntZLfcb1qkk9KHFXzr5mtdUs +tfv9O1S5a7vtOuJbKaZndwWt3MZ4mSjcartUDFUsxVFabqeo6XfQ3+m3UtlfW7c4Lq3dopUbxV1I +IxV9Sfkr/wA5aNcT2+gfmG6K8hWO18wqAi1OwF2q0Vf+Mi0H8w6tir6lVlZQykMrCqsNwQe4xVvF +XYq+Kfzzro3/ADlLa6oxKJLdaReFiaApGsMLeG1ISMqzw4sco94LKBogvqPOEdw7FXkf55/mBrlj +Jp3kbykX/wAVeYSFE0Zo8FuzFOSt+wzlW+P9lQx2NDm27N0sZXlyfRFxs+Qj0jmUd5B/IHyP5bsI +31Oyh1zWnAa6vb1BMnqHciKKSqKAehI5e+Q1XamTIfSeGPlzTj08YjfcsJ/PDy5pXkHX/LH5geW7 +WPTGhvlt9Rt7RBFHKpBk+wgCjnGkiPQbg5m9m5jnhLFM3s1Z4iBEg+hOu4zn3NQOkaLpuj20ltp8 +IghlnnunRe8tzK0sh/4JzQdhtlmXLKZuXdXyYxiByR2VsnYqxjV/zO/L3SJWh1DzDYQzoaPD66PI +p/ykQsw+kZlY9Dmnyifu+9qOWI6pvoOvaRr+kwato9yt3p1zz9C4UMob03MbbMFOzoR0ynLiljkY +yFEM4yBFhV1WVYdLvJWJCxwSOxHWioTjhFzA8wsuRfPn/OEVoX83eZLzekOnxQnpSsswb/mVneOn +fYOKuxV2KuxV2KqF9e2lhZT315KsFpaxtNcTuaKkcYLMzHwAFcVfFHnPzR50/wCchPzJi8veXlaH +y7aO5sYnqsUUCkK97dU/bYdB2qFXcklV9U/lj+UnlH8u9IWz0a2WS+dQL7VpVBuLhh1q37KV+yg2 +Huakqs1xV2KuxV8v/nf/AM4patrnmG+80eSp4Xn1GR7m/wBIuW9ImdyWd4JSOH7xjUq9KGvxb0Cr +5/1j8mPzX0iRkvfKepgL9qSC3e5jG9P7yASJ1PjiqRjyb5vMvpDQ9QMtePpi1m5culKca1xVPtG/ +JT82dYdUsvKepUf7MlxA1rGe395cekn44q+zf+cffKv5m+VvJ50bzvPbzRwFf0RFHK01xbxU+KCV +6cCqmnDizU3FaUAVeo4q7FXx5/zmxpD2vnTy7rcdUN5YPbh12POzmL1qO4FyuKsl/Lz/AJyc8ra2 +sNj5mUaHqZAU3TGtnI3Qnn1ir1o/wj+bOY1XY8474/UO7r+1z8epB2Oz2iKWKaJJYnWSKQBkkQhl +ZTuCCNiDmnIINFygVGXTNOmvYb6W1hkvbbkLe6eNWljDgq3ByOS1UkGhwjJIDhs0ei0LtE5FLxD/ +AJyycP5F0ezQcp59WjaNdt+NvMp/GQZuuxI/vJH+j+lxNWfSPe9rgiEMEcQNRGoQE9+IpmmlKyS5 +QCpgSsllihieWVxHFGpeR2NFVVFSST0AGEAk0EEvn2fVfOv5269e6foN9Jof5e6fIYbm9QMst2af +ZIBUtyG4QkKqkFqmgzfiGLRQBkOLKfx+C4ZMspobRZzof/OOv5U6VCiyaUdSnUUa4vZZJGb5opSL +7kzBydrZ5HY8PuDbHTQDP9G0XStE02HTNJtks9Pt+Xo20Qoi83LtQe7MTmBkyynLikbJboxAFBJv +zO1Aaf8Al35lu60ZNNuljP8AlvEyJ/wzDL9FDizQH9IfYxymol59/wA4P6S0eg+adXI+G6ura0Vv +e2jeRgP+kkZ2zqX01irsVdirsVdir50/5zJ/MGbSfK1j5PspOFxrrGa/KmhFpAwon/PWWn0KR3xV +mf8Azjd+WEPkj8vrae5iA17XES91KQijorrWG333HpI24/mLYq9YxV2KuxV2KuxV2KuxV2KuxV2K +obUdT03TbR7zUbuGytI/7y4uJFijX5u5VRir5U/5yz/MX8tfNfl7S7DQtZh1LW9NvS5W2V3iFvJG +yyUnC+kfjVPsscVSv8i/yi/LTzn5Ij1XVLSafU4J5rW9C3EkaFlIdCFQrT926980XaOuy4cnDGqI +vk5eDDGQsvdvKXkby35StXtdBgmtrZ6Vge6uZ4wf5ljmkkRCe5UCuaPPqp5Tc9/gHLhjEeSN8x3+ +o6foGoX2m2hv9QtoJJbWyFazSKpKxjjv8R22yOCEZTAkaBZTJAsPHv8AlcP53/8Altpv+BuP+ac3 +H8n6X/VPti4vjZP5rzz8wfPP5i+bfNvluw1Dyq1rqWjzG+g0ROZmuRVZDVGHPjxgbcDpXNhpdNiw +wkYy9Mutj8dWnJOUiAQ9D/5XD+d//ltpv+BuP+ac1/8AJ+l/1T7Yt3jZP5rv+Vw/nf8A+W2m/wCB +uP8AmnH+T9L/AKp9sV8bJ/NYp+ZX5v8A5qXnli40LVfKbaCutAWkdyxlWRwWXnHGrheRdfhI8DmV +pNBgE+KMuLh9zXkzTIoirR/kbzf+bvlHy1Y+XtO/LedobYENM6zK0kjtyeRzxoOTH6BtkNTp9Plm +ZyyfaEwnOIoRej+RPO35o6xr62fmPyf+hdNMTub71C1HWnFaV/azX6rS4IQuE+KXds348kyaIZ7q +jaqthKdKSCS/pSBbp3jhr4uY1kbbwA38Rmux8PF6r4fJuldbPlv8+YvzstdPS483apafoO7nEEVh +pcjJbl6NIA0bKkjgenWsnKhpnTdnHTH+7HqHfz+f6nAz8f8AFyfQ3/OLHl06N+TWkyOnCfVpJ9Rm +Hj6r+nEfphiQ5t3GeuYq7FXYq7FXYq+MfzQhXzz/AM5YWmgz1lsLe7sbB4zvW3gRbi5TvSrNLir7 +OxV2KuxV2KuxV2KuxV2KuxV5j59/5yM/K7yb6kFxqQ1TU0qP0dpvG4cMO0kgIij36hn5e2KvAvMv +/OWP5p+arl9P8laWukxtXiYIzfXvHpUuy+mg+UdR/NkJ5IwFyIA80xiSaDF/+VT/AJo+b7sah5w1 +h1kavx3sz3k617KgYoo9uYp4ZptR7QYIbRuZ8uXzP7XMx6GcuezJYf8AnH3yrBptwjXFxd6g8LrB +NIwSNJSpCOEQA7NvRmOak+0eQzGwjCxfU11/FOT/ACfEDnZYH+S+sfmZZeajoHlC8htrq6ZnubC/ +K/VnMAPLkrAtyUdfT+Kg8BnSa7HhMOLINg6/CZA1F9k6KdbOmw/pxbZdTp/pH1IyNAW8U9UK9Pnn +I5eDi9F8PnzdlG63R2VsmndUUu5CooJZiaAAdSTiBaHhP5N8/On5r+bPzEkBbT7dv0do7EGhWgUM +tRswgjUsP+LM3vaH7nBDCOZ5/j3/AHOJh9UzJ7vmicx2KvEf+clQLS78i63cEjT9O1cC6O3H4mjl +FR/qwPm77G3GSPUj9f63E1XQvbQQQCDUHoc0jlN4pSXzN5z8q+V7ZLjX9Tg0+OSvpLK37x+PXhGv +J3pXfiMuw6bJlNQFsJ5BHmXzJ+dn5haf+Z/mby75e8qtLPbLN6EbyI0YluruRI0oh+KigChIHU50 +/ZmilhieL6i4GoyiZ2fbWh6Ra6Noun6PaClpp1tFaW4/4rgQRr+C5s3HR2KuxV2KuxV2KvjfymCP ++c0p/rdK/pTU+POlKfUp/S/4144q+yMVdirsVdirsVdirsVeQfmX/wA5Ofl55MaaxtZv0/rcdVNl +ZMDEj+E1x8SL4ELyYdxir5W/Mf8A5yD/ADJ88GSC6vjpmjyVC6VYFoYmQ1FJXr6kte/I8fADFXme +Kvpj8jdTtb3yJBFFGkdxYyyW9zwVU5MDzRzTqSjipPU1zhvaDHKOosk8Mht5d/6/i7rQSBh5h6Fm +ic12Kvnvz6l35B/Nqz8z2CEQyzLqMSqeIY143UVf8upr7Pnedl5RqdLwS5gcJ/R9n2uj1MPDyWPe ++wdL1Ky1TTbXUrGQTWd5Ek9vKOjJIoZT9xznMkDCRieYc2JsWisgyYZ+b1p5vvfIGqWPlSFZ9Tu0 +9F1LiN/q77TelXYuV+EAkddt6A5vZ8sccoMzsPv6NOYSMdnzl+Wn5m/mVoKR+RtEtNLsrmGWSsOp +q1vM87t8Su8ssS+p0UKaGgAGdDqtHhyfvJ2fd3fBwseWUfSHq36V/wCcqf8AqzaN/wAGn/ZRms4N +B/OP2/qci83c79K/85U/9WbRv+DT/sox4NB/OP2/qW83c8o/Mj8z/wAy/MAm8i6zaaZfXU0sY9HT +Ea4lSdGqqxvFLKvqbFSBXqQc2el0eHH+8jY2693xcfJllL0l9KflXb+bbXyJpVp5riWLV7aIQsqu +JGMSbRGUio9ThQNQnx70znNccZyk4+R+9zsIkIi2W5iNqB1xdH/RF2+sxQy6XFE8t4tyiyRelGpZ +i6uCpAAyzFxcQ4D6ixlVb8nzj/zjB5UtfNn5xal5tisltNE0Rpbu1tEUCOOa6ZktYgBt+7j5tt3U +Z3UIkRAJt1BO77PySHYq7FXYq7FXYq+M/wAyX/wb/wA5b2WsP+7s7q90+7Zz8NILlEt7htqV3EmK +vszFXYq7FXYq7FWGfmR+bnkn8vrD6xr16PrkilrXS4KPdTdacY6jitRTmxC++Kvjz80/+clPPvnk +TWVq50Py45KfULRj6kqntcTjiz1H7K8V8QeuKsQ/KyLyvP5wtbTzFbC4trn91bc2IjW4JBj9QAjk +G+zQ7VIrmB2mcowE4jUh93Vv0wiZgS5Po7zD5J8ta/pa6bf2UfoQrxtWiAjeDbb0io+Hp06eIzht +N2jmwz4oyu+d7373dZNPCYoh8/effyj17yuZLu3B1DRgSRdRr8cS9f3yD7P+sPh+XTOz7P7Wxajb +6Z936u90+fSyx78wnP8Azj5r4s/M11o8jUi1OHlED/v63qwA+cbP92YvtDp+PCJjnA/Ydv1NugyV +Ou99C5xDuWDeefKvnzV9WiufL+v/AKKskt1jkt+Ui8pQ7sX+AEbqyj6M3XZ2t02LGRlhxyvnQO23 +e4eow5JSuJoe8sD81/lL+ZF9pj3Go65Hq7WKPLBbMZGc7VZY+S9WC9O+bnSdsaQTEYQ4OLyAHxou +Jl0mWrJuvel/5Q/8rK80ySeXdA85S6P9Qh9W2spZ51RouXx+kEDD4CwqPfbvmz1pw4xxzhxX5Bxc +XFLYGnv35Y+RfzR0DXri881+af03p0lq8MVp6s0nGZpI2WSkiqNkRh9OaLW6rBkgBjjwm+4D7nMx +Y5g7m3p2axyGGfmF+U3k/wA82pGq23paii8bfVIAFuEpWgLU+NN/st9FDvmZpddkwnbePc1ZMMZ+ +95R/iv8AMz8lbm20/wAzMPMvk2Z/Ssr5XpcIBvxXmSwKr/ut6r2Vxm28HDrAZQ9OTr+P0uNxzxbH +cNSeb/zJ/Om9uNM8pk+XPJ0Lelf6g7D13DD7L8DyJZf91oafzNTEYMOjAlP1ZOn7P1qZyymhsHrH +5d/lN5R8i2gXS7f1tRdaXGqTgNcPXqAeiJ/kr9NTvmq1euyZjvtHucjHhEPezPMJuePedvy3/OXV +fNF/qGg+c/0ZpM7KbWx9a4X0wI1VhxRSoqwJ2zc6fWaaMAJQuXuDizxZCbB2eNfm7F+Z3lQQaDr3 +nKXV21SJmm0+GedgIQwCmVXC7OwIUd6HNtopYcvrhDhrrQcbKJR2JeieSv8AnHD8+9H0SJtG83Q+ +XlvlS5udPinuonSR0Hwy+nHxLqPhO5zYtD2r8mvJH5m+V/0x/jjzN/iL659W/R/76eb0PS9X1f75 +Vpz5p08MVel4q7FXYq7FXYq+Xv8AnNjya81joXnG3Sv1Vm0y/YCp4SEy25PgquJB82GKva/yY87J +5z/LXRNbaTneNALfUfEXVv8Au5SR25leY9mGKs2xV2KrZJI4o2kkYJGgLO7EBVUCpJJ6AYq+aPzm +/wCctrTTWn0L8vmjvL1ax3GvOA9vEehFsh2lYH9tvg8A1cVeMfl95AvPzCvLrzP5l1SW6iNwUueT +tJdTyqqsQ7tXgvFgPGmwp1zS9rdrflqjEXMj4OZpdL4m5Oz3O18seXrXSP0PDp0C6ZSjWhjVkb3c +NXk3ud842etzSyeIZHi73bDDAR4a2eaeb/yBsLlmvPK9x9QuQeX1OYs0JPX4JN3j/EfLN9ovaIj0 +5hfmP0j9XycLNoBzh8noHku+1y50OKLXrV7XWLT9xeB6FZGUCkyOvwsHG549DUds03aOLHHJxYiD +jluPLy8v1OXp5SMakPUE9IBBBFQdiDmCDTe841/8pLaHW7bzL5U42OqWkyzvYfZt5+JqyrT+6LrV +f5fl1zoNL21xQOLPvGQri6j39/3+9wMujo8UOY6PSB06U9s54uewnzt5H8z69qsV5pXme60W3jgW +F7WAyhWcO7GQ+nLGKkMB07Zt9BrsGGBjkxiZvnt5d7iZ8M5m4ypj/wDyqbz9/wBT/f8A/BXP/ZRm +d/K+k/1CPyj+pp/K5f55+15z518keZ/y91G01W01SZ2nLiPVrYyW8qTMDzQurFgXQnfl8Qrm90Pa +GLVxIrl/CXCz4JYiHv8A+Qeia/NDH5tufO155k0u+s3gGm3Tzt9XufUjZuQkmlUPHwZdh0NQaHfV +9qTgP3YgIyB57bhv04PO7eyZp3KYZ+afm/zN5Z0KGby5okmtanezC1gVAXSF3UlXkRPjYbdqDxYd +83Q6eGWR45cIG7TmmYjYMC8p/kVrGu6ovmj81b1tV1Njyi0YODBEOoWQp8FB/vuP4fEtXM7P2nGE +eDAKHf8Aj7y1QwEm5orzX+Rd9pepP5n/ACuvm0HWlq0mlhqWc46lFBqqV/kYFP8AVyODtMSHBnHF +Hv8Ax9/NM8BBuGxZB+VP5j+ZPMs9/ovmbQJ9J13R1Q3s3ErbPzNEoGPJWehIA5KQKhu2Ua7RwxgT +hK4yZYcplsRuHo2a1yHh35u+SvN1nNrXnD/lYl/omiIFli0yB7gBSEVFiiC3EacpHGwAG5zd6HPi +lw4/DEpd+3z5OJmhIXLi2eW/lJ+UXnn829Svtdl1ue0XTjGo127MtzM9ytDHHG5dXrGg5E8vh+Hx +zo4QERQFBwSSeb2z/oXX86P/AC8Gq/8AI2+/7Kskh6L+UP5dedPJv6W/xN5wu/Nf1/6v9U+tvO/1 +f0fV9Th68s3956i1pT7OKvRcVdirsVdirsVY/wCf/J9l5x8nar5bvKLFqMDRpKRX05R8UUlP8iRV +b6MVfLf/ADiz50vvJX5han+XXmGtsmoztDHE/SLU4Dw4jt++Qca9yEpir7ExVK/MnmbQvLOjXGs6 +5eR2Om2q8pZ5TT5KoG7M3RVUVJ6Yq+M/zS/PHzr+bWrnyv5Vt5rPy67fDZoaS3CqaerduDRU/wAi +vEd+RplWbNDFEymaiGUIGRoc0Nc/846uugI1vqXPX1BaRGFLVtv7tTTmtP5z18BnOw9pInLRj+77 ++vv/AB9rsD2eeHY+pV/Io6rofmDWPK2rwSWlzJEl3FBIKCsbem5UjZuYddxUHjke34xy4YZYGwDW +3n/YuhJjMxL2rOSdq7FXYq7FXYq7FXYq7FUt8w6Bp2v6Pc6VqCc7a5XiSPtIw3V0J6Mp3GZGl1M8 +GQTjzH2+TXlxicaLxryB5w1r8nPPM+i63yl8v3rKbrgCVKE0ju4V8R0ZR13HUDO3ywx67CJw59P1 +H8ebpgZYZ0X1xZXlpfWkN5ZyrPa3CLLBNGQyOjiqspHUEZzE4mJo8w54N7q2RS7FXYq73xVTuLi3 +treS4uJFht4VMk00hCoiKKszMdgAOpwxiSaHNBNPlfzv5j8wfnh+Yll5O8qBhoVtKTFKwIQqvwzX +047IgNEB33p9p6Z13Z2iGGNn6zz/AFOtz5eM+T7B8j+TdG8m+V7Hy7o8fCzso+Jc/blkO8ksh7s7 +bn7htTNi0J9irsVdirsVdirsVdirsVfLP/OXf5WXENxb/mXoKNHNCY4tbMNVdWQhbe7BG9RtGx/1 +PfFWefl3/wA5I+VdQ/KqTzN5mu0ttV0YLbavarT1Z7gqfSaCPbl9YCkgdFIb9la4q+cvNPm3z/8A +nr5uCUNnolo1YLRSxtrOIkgSSdPUmYd+p7cV6Yms1mPTw4pn3DqW3FhlkNB695O8l6J5U00Wemx/ +vHAN1duB6szDux8B2XoM4LXdoZNTK5cug7vx3u7w4I4xQT/MFvUJbGzluYbqSFGubfl6ExA5oHFG +AbrQjqMsjmkImIPplzDEwBIPUNahew2Nhc3s54wWsTzSt4JGpZj9wxw4zOYiP4iB81nLhBPc8w/J +Tzn5v8y3mqHV7oXFlaIhjHpojLJKxIAZQtQFQ9a50XbujwYYRMI8MifsH4DgaLNOZNmwHq+cy7F2 +KuxV2KuxV2KuxVjXnzyLpnm/SDZ3P7m7hq9leAVaJyO/ijftL/EDNj2d2jLTTsbxPMfjq4+o04yD +zeb/AJZ/mj5g/KrXZPKnmyKSTQS9QFq5t+Z/v7c/txP1ZR8x8VQet1Gmx6vGMmM+r8bF1UJyxS4Z +PqrTNT0/VLCDUNOuI7qyuVDwXETBkZT3BGczkxygeGQohzgQRYRWRZOxVSurq2tLaW6upUgtoVLz +TSMEREUVLMxoABhjEyNDcoJp8v8A5n/mrr/5n65D5E8hQTTadcy+kxQcZL1lNeTV+xbpTl8VNvia +nTOp7O7OGL1S+v7v2uvz5+LYcn0j+SX5N6V+Wvlv6uCl1r96FfV9RUGjMKlYoq7iKOu38x+I+A2z +jPR8VdirsVdirsVdirsVdirsVSDz3rvlfQ/KWp6h5oaMaGsDx3kUgDCZJFK+iqEjm0leIXvir81d +SfTpdTupdPhkt9MedzawyMJJI4WYmNGeihmCbV74q+q/y8tfLEHlOyPlsV06VefqGnqvJ0czH/fl +RQ+HQbUzzrtWeY5z4v1D5V5eTv8ATCAgOFkma5yHYq7FWIfm3qBsfy81mRftSxLbge08ixN/wrHN +r2Jj4tVHys/Z+txdZKsZSD/nH3TRb+S5rwj4767kYH/IjVYwP+CDZm+0mQnNGPQR+/8AAauz4+gn +zenZzrnuxV2KuxV2KuxV2KuxVjnnbyLovm3Tfqt+np3MYJtL1APUiY+Feqn9pe/zocz9B2jk00rj +vHqPx1aM+njkG/N4/ovmf8xfyX1w2rr9b0W4fkbVyxtLgDq8T0Jikp12r4gimdkPA12PiHP7R7/x +7nUETwyovpX8vvzc8m+eLZf0ZdCDUgKzaVcEJcKR1KitJF/ykr70O2aHVaDJhO4uPf8Ajk5ePNGX +vTXzl578seTtMOoa9eLboa+hAPimmYfsxRjdj+A7kZVp9LPMaiP1Mp5BEbvmXzJ54/Mb87vMcflj +y1ZyQ6SzhksENFCKf96L2YbcV60+yDQAM1Cep0eghgF85d/6nX5cxn7n1H+S35IaB+Wmkkxlb3zD +eIo1LVGHyJhgrukQbfxbqewGe0vSsVdirsVdirsVdirsVdirsVQup6np+l6fc6jqNwlrY2kbTXNx +KeKJGgqzMfYYq+HfzQ/MTzL+dvnmHSNFR4PLtm7fo+2eoUIKh7y5pX42BoB+yPhG5JajU6mGGBnM +7BnjxmZoPQ4Pyv8AK8fk1vK5i5W8g5yXVAJjcU2nr/MO3am3TOGl2xmOfxfs6V3ft73dDSQ4OH7X +kehaz5g/KfzbLpWqK0+jXLB5VQfDJGaqlxDU7MKfEv0HsR0uowYu0MAlA+ocvI9x/HmHXY5ywTo8 +n0Fp2o2OpWMN9YzLcWlwoeGZDUEH/Pcds4jNhljkYyFSDuYTEhY5KzTQoaPIqnwJAOCOOR3AKmQH +VyzQueKyKx8AQTiccgLIKiQPV5t/zkDctD5FijHS5voYm37BJJP1x5vPZwf4Qf6h+8OH2h/dj3p3 ++UNt9X/LnRkoQXjklNRQ/vJnf9TbZjdtyvVT+H3Bs0Y/dBmOalynYq7FXYq7FXYq7FXYq7FUHq+j +6ZrFhLYanbJdWkwo8Tjb2II3Vh2I3GXYNRPFLigaLCeMSFF4R50/JTXdCnOq+VpJby1ib1FjjJF5 +ARuCvGhenYr8Xt3zstB25jzenJ6Z/Yf1fF1OfRShvHcJFJ5F/M7zRY3PmTUI7m8eKMFHvZHa6mRe +0SvV2CjcdK/s1OZsu0NNimMVgHy5D39zQMGSQ4qfTP8AziV518hXnlX/AA3p1lBpPmi0XnqUIr6l +6F2+sq7lnfr8SV+A9AFIzYtD6BxV2KuxV2KuxV2KuxV2KuxV2KvjX/nI7847/wA+eYk/L/ye7XGj +QTiO4kgNRfXSnswNDBEeh6Egt0CnIZMkYRMpGgExiSaDJvy88h2PlDRRbJxl1G4o9/dAfbcDZVPX +gn7P3988/wC0+0Zamd8oDkP0+93um04xx82vOP5meVvKoMV7OZ7+lVsLejy+3PcKg/1j8q4dF2Tm +1G4HDDvP6O9c2qhj25l47r/mfzt+ak6aXovlxrmO3f1I47SF7meOuxLzAURT32UZ1/Z/ZcNNdEkn +n3fJ1OfUnJzDFvNXl7z35Lu/8P8AmCG60uQoLhbNpaxMsg+2nps0TVpQkHqKHcZseEXdbtFsbySH +Yqu9ST0/T5H068uFTx5UpWnjir2HyZ+T/wCfGr+U9O1/yreSS6VdKzWkEOo+iQI5HRlMcjxoPjjI +pXKMmmxT+qMT7wGcckhyJCOudA/5yq0IfvtM1G4VDuscNvqFadqwidj07HMXJ2Tpp84D4bfc2x1W +QdUvl/Oj8y9CmEPmHQ0iPQpc209pKT1/aNP+FzCyezunly4o/H9bbHX5Bzop1pv/ADkboslBqWkX +FsfG3dJx8/j9HNfl9mZfwTB94r9bkR7RHUMv0r82/wAvtSoserx28ndLoNb0/wBlIFT7mzWZuxdT +D+HiHlv9nP7HIhrMcutMst7i3uIlmt5Umib7MkbBlPyIqM1s8coGpAg+bkxkDuFTIJdirsVdirsV +dirH/PXm608q+XZ9Umo8391ZwH/dk7A8V+Qpyb2GZ/Z2iOoyiP8AD19zRqMwxxvq+cfL9n+Yf19/ +Omi29ytzYytfnU41CgPyLOyhqCTqeSqDt1FM7+WoxYyIGQBOwDoxjlIE0+1/yK/O7S/zJ0IpP6dp +5nsVA1LT1OzrsPrEAO5jYncdVOx/ZJyGt6jirsVdirsVdirsVdirsVfO/wDzlT+dh8vaa/kfQJ6a +7qUf+5S4jPxWtrINoxTpJMD8wm/7SnFWA/k3+W48v6eNZ1OL/c1ep8EbDe3hbfhQ9Hbq3h08a8V2 +52n4svCgfRHn5n9Q/HR3Gi03COI8yl/5qfm5LYTt5d8sP6mqM3pXd3GOZiY7elFStZa9T+z0+10v +7I7G4gMmUbdI/pP6mGr1demPzZX+UH/OJcl6I/MP5lNKZJj6sehB2EjV35XkoPKp68FNfFuq51wF +OqfT2j6Jo+i2Een6RZQafYxf3dtbRrFGPfigAqe5xVj35mflh5Y/MLy++k61CBKgLWGoIB69tKf2 +o2PY0HJejD6CFXwV+Z35WeaPy715tL1qHlbyFmsNRjB9C4jBoGU/st/Mh3X5UJVYdirsVfb3/OHX +mKPUfyrfSS9Z9EvpovTrUiK4/wBIRvYM7yD6MVe7YqsmhhniaKaNZYnFHjcBlI8CDtirDde/JX8q +Ne5HUvK1g0j15zQRC1lJPcyW/pOT9OKvMfMn/OF/5eXwZ9D1K+0aY/ZRit3AP9g/CT/krirzTVv+ +cTvzh8tSPdeVNVh1EDoLS4exuWp4rIVj/wCSpyGTHGYqQBHmmMiNwxq58/fnT5ImW382aVMYgeIO +oWzRch0pHcRhUfp1+LNVn7C02TcDhPl+rk5UNbkj1tlGgf8AOQHlS94x6rBNpUx6uR68P/BIOf8A +wmaPUezmWO+MiX2H9X2uZj7QifqFPRNK1vR9Wg9fTL2G9iHVoHV6V7NQ7H2OaTPpsmI1OJi5sMkZ +cjaNyhm7FXYqlGq+VNC1fULe91S2F69opW2hn+OFCxqzekfhLGg3avTbMzDrsuKBhA8N8yOfz/U0 +zwRlKzumyqqqFUAKBQKNgAO2YhJJttp84edta0nyl+Y0Gu+Qr/0NQtH9W4WAfuI5wfiRSDxdJBUO +lOPUd6D0PsqWc4R4w36d5Hm6HUiAn6H2P+TH5xaN+ZXlwXcIW11u0ATVdM5VMbnpJHXcxP8Asnt0 +PTNk470PFXYq7FXYq7FXYqwf84fzP078uvJtxrU/GXUJawaTZMf765YbVA34IPic+G3UjFXyR+U/ +lPUvNnmK589+ZXa65XDzRPKB/pF2Wq0h7cIz0AFK7D7NM5/tztLwo+HA+uXPyH6z+OjnaLT8R4jy +DOPzf89t5Y8v+hZScdX1HlHbEdY0A/eS/MVovufbNJ2J2f4+TikPRD7T3fr/AGubrM/BGhzKf/8A +OK/5HQWtjb/mF5ltxLqV3+90K2mBPoxHpdMD1kk6x+C/F1O3dukfTGKuxV2KpL5v8neXfN+hz6J5 +gs0vLCffi2zxuPsyROPiR17EfqxV8N/nR/zj/wCZfy5umvYeep+VpXpb6mq/FFyPwx3Kj7Ddg32W +7UO2KvKcVeu/84z/AJoQeRvPwi1KX0tC11Vs7+RjRIpA1YJ29kZipJ6KxPbFX3sCCKjcHocVbxV2 +KuxV2Kqc9vBcQvBcRrNDIOMkUihlYHsVNQcVeX+cP+cZ/wAovM3OQ6QNIvH/AOPrSmFsQf8AjDRo +D/yLrirw/wA0f84fef8AQZ21DyRrKal6dTHEWNhejwVH5GJvmXT5ZGURIURYSCRyYf8A8rL/ADW8 +jXo03zjpUslK8Y7+JreVlXasU6rxdf8AKo3zzT6rsHBk3j6D5cvl+qnLx62cee7P/LX5zeSdbKxS +XJ0y7bb0byiKT/kygmP5VIPtnO6rsLPi3iOOPlz+X6rc/HrYS57FnSsrKGUhlIqCNwRmmIINFywW +8CWLebfLnmTzCG0+PVV0jRm2n+rK0lzOpG6s7FFjXtRa17nembXRavBp/VwmeTz2A93P5uLmxTnt +dRSjR/yO8g6cVea2l1GVTUPdyEiv+pH6aEfMHL83tBqJ/TUfcP12whocY57sS80+XfMH5YeaLfz3 +5JdorSKStxbAExxBz8UUigjlbydP8n58Tm97H7WGccE/7wf7L9vf8/dhavS8BsfT9z6x/Kf81NB/ +MbyzHq2nEQXsVI9U0xmDSW03genJHpVHpuPAggb1wmbYq7FXYq7FVK6ure0tprq5lWG2gRpZ5nIV +ERByZmJ2AAFTir4W89eZtV/PD81xHas8Xlyw5RWXb0bJGHqTsDt6s7U/4Vei1zE12rjp8Rmfh5lt +w4jOVB7Zp2n2enWMFjZxiG1tkWKGMdAqig655xmyyyTM5G5F6CEREUOTxPS9Gb81/wA/YNJlLNo1 +tMUuKbUsrEky0I6es9QD25jPQ+zNL4OCMevM+8/inQ6nJxzJfdcUUUUSRRIscUahY41AVVVRQAAb +AAZntC/FXYq7FXYqo3dnaXtrLaXkKXFrOpjnglUOjowoVZWqCD74q+T/AM7f+cTri0a48wfl7E09 +pvJdeX6lpY+5NqTu6/8AFZ+Ifs16BV8xyRyRSNHIpSRCVdGBDBgaEEHoRiqLv9b1nUEjS/v7m7SF +VjhWeV5QiIOKqocmgUbADFU/8k/mp588l38N1oOrzwxREcrCR2ktJFH7MkDHgRTaoow7EYq/Qb8v +POFv5y8laR5mt4/RXUoBI8NeXpyqxjlQNtULIjCuKsixV2KuxV2KuxVB6rpGlavZSWGq2cF/ZS7S +W1zGssbfNHBGKvD/AD5/zh75B1r1Lny1PL5cvmqREtbizY/8YnYOlT/K9B/LirxDWPy7/Pr8pmea +GKW90OI8nuLOt5ZcQakvERzhHixVfnmJqdDhzj1xvz6/Ntx5pw5FNvKv/OQWi3fCDzDbNp0/Q3UI +aWAmnUqKyJv2+L55zWr9nJDfEeLyPP58vudhi7QB2kKepWGo6fqNst1YXMd1bP8AZmhcOp+lSc57 +LhnjPDMGJ83YRmJCwbROVMlk0MU8LwzIJIZVKSRsKqysKEEHqCMlCZiQRsQggEUXiepWHmf8m/OM +PnDyiS+jSH07i3erxhHYFrafuY2oOD9QadwCe77J7UGojwy2yD7fN0mq0xxmx9L7C/Lr8wvL/n3y +zBr+iyExSfBc2z/3tvOAC8Ug8RXY9CNxm5cRk+KuxV2Kvm7/AJzA/NOTTNHg8haVKRf6ugn1ZkJ5 +JacqJDt3mdTyH8op0bFUg/KjyOvlfy2n1iMDVr8LNfsaVXb4Ia/8Vg7/AOVXOB7Z1/j5aH0R5fpL +vNJg4I2eZZRr1/8Ao/Q9Rv8A/lktZp/+RUZf+Ga7SwE8sInkZAfa35ZVEnyYp/zg/o0Ump+atccV +mghtbKJu/Gd3ll/GBM9PecfWeKuxV2KuxV2KuxV2KvOfPf5Aflj521UatrGmtHqRFJ7m0kMDTdKG +Xjs7CmzUr+GKsb/6FD/Jv/lmvv8ApLb+mKu/6FD/ACb/AOWa+/6S2/pir0/yZ5Q0byf5as/LmirI +mmWPqfV1lcyOPWleZ6sevxyHFU7xV2KuxV2KuxV2KuxV2KvMfzC/5x1/LLzr6lzcaf8AovVn3/Se +ncYJGbrWSOhikr3LLy9xir5080f846/nH+XVzJqnlK6k1nT1NTLpwYXHFenrWR58/kvMZTmwQyx4 +ZgSDKEzE2DSH8r/85ABZRZea7IwSoeD3lup+FgaH1YT8Qp34/wDA5zes9nBzwn4H9B/X83Y4u0Ok +w9b0nWdK1e0W80y7iu7ZukkTBgD4Hup9jvnM59PkxS4ZgxLsYZIyFg2q31jaX9pNZ3kKz2s6lJoX +FVZT2ORxZZY5CUTUgmURIUeTxy2svzN/KLzbcaj5Eil1DS9RRkNuIZLqMqDVUnij35Rk/A+3z3YZ +3Wg7YxZYXOQhMc7NfK/wHS59JKMthYZVB/zlL+eWlMZNc8owTWiEmRzaXlsaClaS83jp/sTmxx6r +FM1GUZe4guPLHIcwQ9C8jf8AOYH5ea7NFaa9bzeW7uUhRLMwns+RNADOgVl+bxhR3OXsHulvcW9z +BHcW0qTW8yh4Zo2Do6MKqysKggjoRir849U/MZtX/M6688azZnUTNdNcxWTSekFVPhtk5cZPhhVV +FKb0yjU4pZMZjE8JPVnjkIyBItnP/Qyn/fuf9Pv/AF4zm/8AQx/tn+x/487D+Uv6P2/sQWuf85A/ +pXRNQ0z9A+j9etprb1vrfLh60ZTlx9Fa05VpXLcHs74eSM+O+Eg/T3f5zGev4okcPPz/AGPU/wDn +B7UUbTvNmmkgPFNaXCjuRIsqH7vTH350zrn1DirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsV +dirsVdirsVdirBPzB/JP8uvPivJremKmpFaJqtofQul2oKuopJTsJFYYq+afOP8AzjN+afkK7fWP +JF7LrNjGeX+iVjvVUb0ktqlZh/qcq/yjK8uKGSPDIAjzZRkYmwl/lf8AP1opf0f5vsmgnjb05LyB +CCrA0PqwH4lI78f+BzmtZ7OA74T8D+g/r+bsMPaHSfzet6TrOlavZreaZdR3ds3SSJgwB8D3B9jv +nMZ9PkxS4ZgxLsoZIyFg2jMpZsJ87flR5Z8zxSTLCthqxBKX0Kgcm/4uQUEg9/te+bjQds5cBAke +KHcf0H8BxM+kjPlsWPfkJ+aPmL8t/PS+QfNEjHQbycWyo7FktbiZh6U8LH/dMpYcxsN+WxBr3OHN +HLATibiXSzgYmjzfWP8AyrzyB/1LOlf9INt/zRlrF3/KvPIH/Us6V/0g23/NGKu/5V55A/6lnSv+ +kG2/5oxVHaV5Z8uaRJJJpOlWenySgLK9rbxQMyg1AYxqtRiqZYq7FXYq7FXYq7FXYq7FXYq7FXYq +7FXYq7FXYq7FXYq7FXYq7FXYq7FXYqwT8xvyU/L/AM/xFtbsBHqQXjFq1pSG6XsKuARIB2EisB2x +V856t/ziZ+bHl/VpT5M1qO4sZhtcpcPYT0B2SVFJBp4hj8hleTFCYqQEh5i2UZGPI0of9C+f85Nf +9XeT/uLS/wDNWUfkNP8A6nD/AEo/Uz8ef84/N3/Qvn/OTX/V3k/7i0v/ADVj+Q0/+pw/0o/Uvjz/ +AJx+aX3n/OK/576ldpcalLBdTgKguLi/MzqoNQAzVagqTTMjHijAVECI8tmEpEmybf/Z + + + + + + + image/svg+xml + + +image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + eJzdffle8sqy6H0B3gFUFGQwEyEBB2YHUEFwwJlJRJlkWGuv88d59lvVSUgICWmQ75x1716/7aed +Tnd1dXXN1fF6iuVQsjmot0J8mHG7vN70qFWbDEYxN2l1n3e70/FkhE2+G7+bZcMMdEqeS29qx7vW +aNwZ9GPkEXmYw7d951e565vTrN/t80NbpTPptqB1Mug1apPw+K+2X5sLXs7UJvAwciAfMKKbZWJ8 +1J28hOepwbTf7PTbqcF/YPyo6OYZzi3AU0GKwuOzzk1rbO4TjrK8jB3DnAy/CLwYluBNQYInDL6V +GTSmvVZ/UhwNGq3xOD3oDkbjmDv9T63vvqy14UnNXW11u4O/3alurfHtgtVG3nKdbgsW1qtN3FFc +ZfKcfyOv3o7hHXgdf8fm6Nt5D1rKrckEoIKBESXpy2reOB9Aqv7ne7pptTsEw4CIF78ycqXVG3YB +KWRRPCCFl0XtX7UHwEOehqJsmJdlGfAmhiMy9BMlPiwwjAC/RMgj5Q193a2/Oq2/Y+6rQb+lLC45 +mpQ7/9XCqRg3xzBK68202xrd9jsTWASHTbKy4stBs9VVm8i7uW6NLJT8x+o/lQ6V2qjdmsBODbrT +CaEUSZvhator1P5pjfQJroetfmVwR+ALiUJYFMWIWxQY5Rc2HHFLouyOMoA6ScEgC8tUp2TJtKwy +No6E42gTRHHvi7Az16NOu9OPsYLoDnHYint2Ouo09S2Lcm5J+UHWEZYM/5e1/ysAw9onk1Zf2eZs +v5ke9BDJY6Re2Ng+7Hp30FaezX4nT2C66VCBlfz9BvtRHHX6CIPrijyR3ordKTw6HQ2mw/P+x8Dl +U05lEScd9a/78MunOzWajj/dlcGgC6dtroP6SBkFH44mxt5L54C+9uPrA601drrW7Xbao9rws9Ow +Gt7i+Wweu3eXTgjbNGrpY5A/Z/8ufbPcIKi0gnL+0WxwizeWz/BPrz7odsY9fWBDi/67E0XARnVb +/eZ4Nozypw5YofOX1rh8sEzrA1idYWtJa7b/V6s7GBrQOGup9Zvu+9poaDcsQvfR6TcBK+VpZ9LS +N3rQGyIDd5c/a0NsXuipnBA4PcbzEQotPzgrvyArT5ARTv7ptsaug3x/8Hef/OGOuXxPgJLatDt5 +8bsPrmq9ljvoOih3gEm3tC6M+9rFqDzwG367cWn8MO/SuCLjfvgH/riAX76g6W+34L50P70w7ia0 +Pty4kIE9NF0HxRoA54673AcwLfxLAIQV6eA5rrFY6wI7axEginWXnbhBkMauhdZiY/bGt+XTYmoG +gjbTKvgtwHBGpC6skHRYZyNZRnmkHBsc5v+ozTCQqdFmcBVWTV6CclJzed8OtL9hr/GvTgOxURv9 +o/z9cFm4ArlI/vBtN9W+QC3lCQzedvv+0+v2oUMIf/SBgvxAQt436+d/1bpTtYPsPjiHOeceT/4Z +qk8PkqNRzQqCXmtSawLgvweAXQ+Av2qjTq3eRT1o/G8A4n8dhv9JLMT1Po3PTrc5avXVPiayNXQE +mTXq1KcTBDRIHgUX1xIb15Dn4ZH4H95Y6iXNQ4zvOIPp2+2P3xpg5wx6cZvOBpi5/9lt0NawuB3k +QewvuuUBHY7/rYvDNQRpyHFNKoC1A7leEYQ44areIeYk++9DlXEVi8TQHTS+W03n9fXB6vv3rU2D +/k9SwQq84N98WCiRNL/28cff/2sScNztNP6/EH9kIeXBdNRoEa/Tv3JN8yD/4wjizFN2cNOqdf81 +pP6PpcBzXM3MAfjvWs1/rFbzd6c5+XRcEScyYVbk2H/ZilTgF1f12eq0P53VbVYSwgLL/9uWpUG/ +uK76YALqYaH1MVEciM4rdB+kBoN/z9IWF/AvEbYgm/4fl7WbEzgbAt7ggMAWRsVd8pxl3TM/BnFA +uwu1fntaa7fcxcFwOjSRLnmhOGqNW6O/Wu5K6z8Td7bZmdTqnW5norJoMRLhI7MJZHdtNKkPaqOm +u4HBAjfrHmmKnWPP9qilrdexb31GGRFO4CT7rpwOgGNPAwCOfesLQnyx2zzp4vPJqNYfD2uwr41/ +YLpO0z3u/Fdrtk0a2mX3sDZsjeBhb9olfjdNWjMax8RO19PJcDpx39TGk9ao81+ko1sPtajgRebe +uWyNPx3eYOb2X6Mldwd61SYtWHmL2EhLO3/3QaUfAHBtdAOrx/3pstXsTHuGCV8MJ9+KPNX4CqCC +kOHEbbB/TEdCIxfAvIr4qIb55rATNkFb63bGpqZebfytolnUMDasNXWzJHnuTk4ngxn2tP1nDAeM +cX/MQB6RfqG/Wo0JkEy91q31G4t7PfcKYKzb6bfcEzhrdD3Hk9HgWzv7rE3nRrczBJJE581/4Dy0 +AW0Obwy1Uz/4qzUaooN0xl4ANY3BqNlqLm6D++BqMJl7vCrvcRhOp5YDne8djJqjcVhx4JgV74Vu +tX5/MJmtXdnlhU4aHsbjeQ662HHabzh0AXkHJ6ZJdQSML/9nGNYlpdXo0GEwbE4dOoydRmgM5tmY +qQOSzvIOgz6QyEShw6VzqT112iasyaonMOJ5lsQzNj1H5p7RiHXHueNnufNDZd+X7zp0AjY038/A +lc1dP2vN1qi1fLwuiyezNlnaCXA3Ia6bpX16eGzHRkZu1a/fagPj/2v5YPUOnsF5CWYGvPVXq2s/ +yEd/Eh5P6+MlC8Muze5w9DGY8RcrKlO69UDbUbUDS3S3e9/hXm30PR58fIQVdZe6+0jX+yl6TwZD +6r5d0LhnCLDpDPyh1TRDTdHdADVF7xnUFH3noF7ce+xLNJx6bbSMuLHfyBA9dOg6BGHQ6X8MnGYe +GVZi3YUsRO0T5iK2C262PlCKGsxZa2ZMOn8N6hNMZHLsqIiij0532RHDjmMMdjr0mZMfVr0ao2Z4 +Ahq5ppFZnSDsM240+ssOo9Jn2G38Y9BrFvGmdKt1W+G/KPt9LiE77DUYtbWxlvZRx7Fi8NhlOBh3 +lhMZ9oL9Hn4ORv+lcraoXb/BqIO5YA4DdkfhmYJUx3Sx5X01WTkcTJYcG+ypMztrOgNadFAPsEe9 +M+nVhmYRadebrKI2Vl6i6DpYTuGzfnXVW7qsY7M17rT7TugeDkdhYkItoxbs9AlMbNxaxhtJt7/p +uhndQksGc2Qi0Enfs2iUDwuWjAm6dTCJcE4cROSIU3eDOGClsLVsmnWeSQNWdOqqC4OozNl1NeJI +ZG27GZBkxaewS1NJC1nCFqGTs7Y/nnTVXsNh035G7KbOOOtnPyB0wZPZtfLxL/RF2m+N5lyCS6dX ++muGgiHlyGoGEL/dFjGVdJM4PnPZYAJRUuvsRpuKyryyO504WW3icNZHoA6Oxi0cbWS/YOw5/u4M +gVv2v504HCoEcNzbluu7GNQxvcywOt0TA52yxbL72mS8zvlP1D4FtKIxexGz2IiPa6kHRX3rdFRr +ooAgbyk+FTtDZPaO4jc4uFP8ASk7f4AKumrfV3RrybZP2c4HoHRLo/WfVq3/G6P1T+ORwRGWuGFY +o9eqP9D9Be5On7gcUCpbuWwWqc/3ZEg3d69B/1Z2Cq6hmMm9pYmN1TG6Lq3IU+uueT0NEKHrE8BI +14aKA7TTWmKyaOOcItbg6FQ+p716v9bpLpGD2juYtwz/5pZKV61zDojqvlXHd5yhIQncmcHffSWR +J9/pNw0kTvuamdI5zkols3mZpMcn64O/dFtu+atp3arV4V2+0/NvlaY1fc+5iOOEmFtf1r17yzZ3 +VPtndWzOv7UaMuffXQWX+ObKqDS9tAIm8U16RF4O+oPG52jQa1mh09r5s+xdM1KFpRuCI9gjVaCa +2xK1y4+i8gJIHudDXhl1epfoUXDuCvydsich9tRSA37GDQEl50sNc51vEiUGQajMwnN2Jrh5efct +BzeM9sI1UdtzgHhA39+D0XdhpqKu9l7KyU1k++bNuqBWlrphtNdS6MAoLPcdzfW9cTBR5jqvAIMR +Q8voWQG4019iAWtds716q3meThdHxILUpOjSU16e1hGNg/7kBo1EZ3hmqh+FCFW0m4ohNkelHi0Z +C54rmtKVIdNmKbLNL17W/rNED6UaodO31Ulp3lf01JTJb079OmqdqtKp6JyrD6Hqt2WH0ILD6xVj +LM1R4Us2RoN6baLUjc3MDuihrmqmdppNDtkc3hrW+pp7XJOx5btTJGGFmCcLHjv1cWHQqC3OAA/J +wVGsCJWm9GcAXqOju/4NM2b7jYEerxX0B6TUQufSM00eHpHyHKRdOBANi+daheLik2L7Y7HxoWZO +LcDpu53GDKz4ojmgF77M12Lgjik1Griz2jMX2UljC5oYyXL6/FyKZGDcJlbteAPHYmgnMfY/bGXy +F42PnL/EJRM/qVefcHL9fhy955lmvBXz9smf8fPx4CP3Xpju5TyBJ8bUFji5qx8wXHcSSd5UcpVE +bPgii49i79HlPQy95wZkMJgvPk6Wp7e+ZL/eHqvvHP/0kvn77PZodFzrn3bvvuqp98tSMhnssy/x +E/ZOymw3p9lM+uz5hQwVOD4aeoUxv1MKnHxOeAKIy0sBygqAHNWTweHVRSIvj4+ls8P7cG7wKNy5 +vNnR8yOTecxVK7mj5FHDCp7jof9wCBOchdLcztF7JjxN3Cajz29VsTpki7nd0kNXna+R3M18DP1s +snIxmeptLq/Smn/wT2Cci2kmfP15OBoJmQ7DiVvDxN1eeUfpzjLFWs4/2a1lgy9XBykxyG2p47wP +EqNRfFwBeIPnDBv6iunIiqdu0i2XdyzlJnfc6+B7Vyy19gMRT9p/LRyWYpXA0Y34OXphxodhviBz +geNTz64w5saXAM2dFD4YS6eC9BP/gj/9fqa5W83MT/o8erl8LpFJgcbmp4V3o6+R2Plr2HLS152r +gu2kYid/6rWa1OUdjQ49vtGY9Y6s1jqWiuyzsMXF9q0mHe8FL0M2k0Y+fbW9apZM6vIurFXwPwcO +uXbJctKt3KuwfTvsFqwmZXKpfMJqUpcXphW3d/oj/5E1goXqK5P7uCpbT3rqOdxlL94qlpOennEV +Mime/UUEc4/HlXcyKbufrGfnd/V+9Dw9LuCk8cU99VX5py7rh0lDQX1SmEUhpQKTUtda3NszTRqJ +9N6GdpO+jV4++xWbSRM1MZrbYV1e07QqKZ2839hNerbD++LP1pMeel7G25+tG9OkwGGUaUtp//HP +Tq9gNWkg3o0d20wa+dw/eUxcW08qVKtMTmaugMas1rqVa0d3bnrctdWkTO7lJWczqbjt/e5fpk2T +wizatDXmNPh+Zz3pKZPca/miVUv0TraDJ+qk1ZDPhN6TK+Ho2aWcVTb7/J2bW+vjIVOIhlic9HBh +0rPWQLyphTiYlAmZV1p4eqyZJiWzqGuNfjdzr3aTZpjL/RfZetLzn1jia3R1YzlpOb7Hw6m0Xqu4 +nW+VecZm0qcQU37zb1lPmj9rXT09+n36pC6vYdq7vX7bdtLyZ+m9bjfpKXOXHx5aTw== + + + WuC9Lu9tLnF4ZLnWu+HFlu2kd2+nWxO7Sa+Z+5N8Rp8U1mKY9vI4+/ZaenmxnPTl+vvcdtKvaqSZ +s5n0Gbgl8zLuhqzXevU17F3LEm856dt5qG876chbDnj0SVGKGc/qLZPt9C4sJ5WuQluexEsoC5Py +YfOhmb5F39RJ67zfdGhcXv9jobZPpuX2jn1n82stMO/7sSROemyaFIb9+tGYvnhgnnQ82D1SJ52c +BGBf5tfqea49+ZVJU1X2fJ4VBkfj22MPTppY5EnnIW2lh6xpUsBY/GxLVKY9YfMhEysMDoUrRdLw +O7F0fn7SndGoVu/jpCnzSkfJ1kCj3hTQmFmUR75iqqQ5iZXCJgRvDVrvFUWmtmpv4jxIZ7e7r4OY +1VMikSNn1RLbu7N7+5M5e/dObZ8C683s2jyFHdgNpL0qt2RaX62o6bkosW8a3ONvyfy0/7n1YPs0 +WjyPPetPF3Zf4vZv3m3flj5rr3u2T5Pc7mPD6qmqwxQC/RPO9u1C/fojbvv0eqtRP7N5Kp3tnh3e +jjWMfez9yKa3bwMdTT39YLdi5qf1i3Lf9uldJvA90p8uYOzeWz/w2L59/5yJHdk+ffe+RnesnqoY ++5oUh2e2b3/fcamS7dPed+741e4poKoUj8wwtvj8ghOOH2yfNvr1csHu6a5n9/x53x5ju9nkZb1l ++/YFd7LF2j1Nergdf8wWY5EzJnu0r6065oubznSgUhqfqE/T4UPT08r76X7S+FQI3iBDKSnGXDq0 +nwbdcjJ8fUm3Pyvo1EseHctnO0hZ9z7VWj5pxGzMvvFD4u7jtpysVLz3hEUlK5dNIVsbPXkDqcH4 +Sm8Du7I2etwjfC7GSp4rwsw8+/k46wlmbu49wbvXsif41qx4fE/+Kf5WBBL8TntC+bfIolFYbSdL +fFkCqNMBsE4H3+JOVP5AS3yf82h25YuUe5s81xLxIbuVuQhsR7Sl7faSg8wrkOm2vMXtHRWPM639 +rJecOzRnnjQsWvdzKT3R2pKX9yT9jmPpp6pjPzDD6js333o/l9e257730DNwHFHcpl0L2GLRG/8L +xYg7fT7+RtHPe925rFGsRdxGod6gGHHvvB5ua/22e7n0x4V0cHnRisKf+9vJ6GOXV2xkPwjHj0OF +Tpgx101Wkv0ccxER9hWyQfcHWMsRThe84lZVuMw+Nn4+DjpHdb/4KBbOVLs5ujuaCeB0cvBz60cO +s7glft/JU3c5eGhLv9AAt5WrhY1eBVvwmFz+sGgCz3I3hKvMuxVwhFvq4FXfqMA73RFpgDstbT8a +dH478KSzOWKxxV31ZjlwQGPK1l7l72jAy2ZvczPcZZLl4PcODFCqHnS2Y8G5CQKHZhqLGUBh9yKv +mY9KhkeQBVzaob5SNnjLhvRJR1M+zVBMCjr//LREO15z0kBsMMnipEOCFoabJj7Tn8Kbui+gah4P +M9lGsSJqbsX2NNuoth6UNo2P5zPnzSPQlHLTbjReui6ib5GbPb3B38AI/5bPAergdy59EiuTbTdY +FuPA8XF2D6At7yOMYbLq46GvOVZdNfMORmWlbW83ebt9hFoBs5Usdz2jXFa6OVAHvWr8BI6LuwOY +BYWZOPGxp+qLO82MojYDZKmDz1bGq/wAOriHwYqiam3BfLMtIcvIoJMhN7+MjMGrQJbhNfzAmWPv +P8WYQbTOgfezEnDkVC4Fr86fWYFnAdy+LXC4FhW8MQ14hEIJVaojXkh2y53q42m7b7tg+HGjLFfx +3VgsF4yrwvLlulbZjb2tNUlF5ckLu3Fa7CERt/EgbStcR7wgauyddCyf3hbBctr1kh/c3glzjoCc +z4YqaZyvKELnpwzsCxhId5T7S0F8A3Y/9ZVjWDnyleATj6jB7fpmvosK04Rd9Xq1H8K+eiCJy2Au +AhF7H43rsE3xEC0CXXSn7fT55zcI1LVxFYWoJz/++oDoCORSj/IF+i3nULgSAi042o0VR5udympw +aMYyM3xNr8fRsgjNqY4RVSJb4+Q0v4sz31jufvb5emLaq8jwQC6a9oqwd5fXlsHPjXjnoRhR/VF7 +yCCCzmx3/zXL78Tzhbm92t6z3KtWMbyr7osFxk5ipcvNYCwToNzJXZfKD615w2sWHQX3Jvm6Okgu +LwIVpgXKASSwWatWIFnISic8MU4gDQJHugpBWIFyXi6WgJcOPy3F2K6uihhPL3FeamC6vBbnt7xE +I6lzCyLf+fSSfbE8vzkrxcpi43Xd6omMqAbW5sZzeZURT3zZPBUpGYTMpWzNI2G5CmOenTqiw5jO +nU+yVv3mUG2giNrWJbcci3he5mhCXzq8PTmdLX2ojy1VdvcuTyvPX02GTT23M+Gb26Ae7iczw1C3 +I50nqbLSSiYtV2PnRnwYL5dxLu8cITrrWd/SZHW9zeVdOuJ0M5rgTIp9yx6qEY/q+/o5sKJa7HyK +3v0LM082SXYa82JuXz63N70v8s6m90Wmsm5W2RdppMhSJ5UGjVCCVFXtOrXhtM1TXWt1eZeqXTRM +St3u07uB7eYAT17nGN4tCJmlqHR5nY/hiK3t7J39BpUmHQaQSafBroLK+hilmKOWvbJhfmsSgzN7 +n2BnckxlXNKpsWe6GutAY7pqb6lscKmHT7PSaYUMl8HosN79yQmVNbn0aJowdkLFPuiM5zPdeP4t +xqpbu5vB2PGYjvXMrKlFDV3RYYAcTsv9lSxHW5BWtpGtzQYEqTpcCSQlwmsNFBVfoQDpbUR19uct +bDulun1moVQv8Y/NLOxyfD70dKMNe+hLRl89Ye5lXE+lP6Nnw0w+/5PSgjVk0q9zprlXyxJkuLz0 +RjjJFrIg55dx34EBuLwWODmzwcnX+Yp7pQHnMqd5auBNHNSSleSey8u9TLzUJGBlZpuWu2hk0/iU +bHdjEtijBc5FsxuYg3C7qgfIaN3M8eQTX2ZixSDWJ75PbhZ7XUUu2nD58+UuNKOmREvOq7vQiAZr +YyAiAokT7TcIJAxu5k9WtY97eyP8hL1YMGcoXWiWnt4LkxNtTe8LvxPz7ZC9Aj7m7ESjON0wYtgs +m/XxFnbf8XT3LlZ3odlgbN6JtjbG5B9m8bys46/qXVC40Fy0QPG/caGpUR4FKDsn2sp4iphAAilG +QfNzvpI5igezgcI561qmOqgpJ9eGIOJJrDixCyLmkc6zlB5FZ/89UOD2SttkoOR52hnmTT4um2NB +ZTKTUwkjvkxTeZqDhj+WSxX+5DbmM+0V6JbWrnT/LuECdhjzbwpjFnJ4HcI+ufXyixHedRgAgPSx +9/NgC9JcJNERKPNpowXJZO8jUAvi1tYba61Pz+2fxypiZUtZ1j5vC1MfyWc7btLQdT72ULY9uusE +3k6LPTb7Mj416fxrBHPSALdg1o+s+RitzEXCPqDWLubtdEtZiTAe0YTWHE4voo0/uatc0u2+E9r8 +PmcPPM25I7Sx4M2jXd+8hwRWuPwQ0x5h3ES/brj9msb8C4FxC4pw0UpfMiJtlM48noHGLGIfrz9L +Ylen5T6toHN5KUQd7n7lN+GmmY08B+MqLNPrwDJxPDgvjrFCpxEtnBqob/p1Xcflndd20sARYpTH +giJ95OGWGCmEJ//2bIy/HRjcjJJpIyPAAFZXeHAtNioPwugQIaTkTrd4XjZhqyBIgUX/prpIrLBb +gaVgrk1w9fXNPIomwlj0TK4lX+4GxFzZEI0FFnmN0S9AMiHnA8eOfBPR5hjlmQsbu+hNF8SibeAY +xZL9hilnf6WIRxoenI9W2jU7fzLAvWn75eFuo1kEAKHJ8WCVRUB3crLPz2YHqi3aXN5l5A7bvREj +BuULUMeiH3HN9Vkn8Gj1lSvwvjsr7+HaNLZW7p21WCYV3DiiTbThN7EGZGEBIpZdXqtMZmAuBUqc +0IhlktO7Ce8hws3ScRh6sfz8s5JYdjl4IhBG4ddiWeEw9xsSywBSyEos28Qslh++2tblatlzth4S +WN+mxPLzD3KYTfgRCbJsxbKuw6wqlq3yuezEMkpkLcePTiy/jZaI5ZiPnlvSiGUA7snJWG9Nbg8s +rSS7wOrDg0Vm/9JsRf1sl+O2PPlttHG5/7BZuf82WkHu2/mr5rdb3KgljnlDNLa9YTw7Xx9usrMj +ZEY7NA4/Jb7vfPZpMl2tvH5c6qGaJF4/l3cxMv9Q3azXD/OUdL+fDcGumEqKKoSZ9VhERqhSSY1k +kXr43lq+k2pkhNqtCIDSOpUNbkXAmE1oGGGcmAP/zoqMJYtSzn6VXiLTkG59bFKvl2baL0tRQtwd +OKrXKuXMPL3OZz/18OboZFhMTCdYnJf7qtjSdYpUrPMafEiWgw+D5E2/nk+FpMH1Ap5md2iZb8vi +xm1PqF96c3mxejrrCSX5V0/oQs6qhdMXctUT/Pyq4I8wtuWw1DpN6q3xBonDZPm795Ft3J80cC1Z +rMisZmrl40LOPzpD9+rOXi7zHdrCKmpB1ZSUAuviWaWYDYz5XV3Sikdf9fNsPZRYLLa9OrnR92pJ +v+IBM1f3at+zFCtS9BtN38Mhq34u72LPGEsz81bu1XLExX7NA7q1bOW+KGce8lRrwQuyIlQjnoZk +Qz+7StnROBYYG+4hsS/kFR4+C7P7CewKeQ+3fLaFvBizMGwJG6YAL3AY7904Aidub/+I02c98m5f +Z/xEV6PdcyggV28GY3KDSoUCvN1C67PpXATdMgEH1qtlfftV6YECd0z26umUYmNd3rnCf3vwSmsX +Ru8fHRhojLoeG6ux4ytN6vIa1o/3Da0zqeAvKpOqroXCQyKW89ZUGJRYktgflhOHnckDjn2bDew3 +w8lr9uQe2qZbJhVrSTgmNx052vu6OWCvwVsZTcXdnl0aRkbX6hwyh/cpyygX6hnnbT9DJNEYMLWv +Gl1wp9AAZ2clFXcXsOxcqGILHHKYhYKt3yTwZywMroy5sn4Fk6u4R12XQ1fDu6gTrkYq8xHe4u6A +LkccmB5dyXJghXxLGuKjrUyZVwjtq74tAtoOCCT5lsuqvqkSkp0QiLOoKFyIBv7igJgSy5ZU2C1B +oBVHqwb7dhwtq9wISmGp0nG0atCSMa/ugX/Nru6gUSq57OLtMOJGEsu03c8+Vx3sXCofZTVkmYq3 +DsZWj8lYZ9pjIIXWs+NYCQ1HeANRUQSJMvJOA5RTloS9V8geY/YRiOX2sNXpVXZfO791bmB3fnO/ +Ob0WOSR1jio9nDqMUue3qHMUKUq3csSvZ3Xq1PtgLTyFzj7mWo62It5lsXTHCh7QtxM2FTzNU72C +Z3nNCH3NqWNRhjqUGk2gKpSkUist9TbLvL5Tytt6qEs5qXXL+XNgX1tsWcA4x5NpzIu5fVmUPr/e +F+dLgFbdFzqVdaV9obsJaJVqZXPYCj0kv7mcCauVnSuZXKsdQ0rl1YzK2W3zVoeG7k4gClSqOgwi +0zH6uCoq9Zqm5TWJKxvmk+MfKzGo172aBeH6hvnk2CwG7Whsptpb00H7bCWTY3anyg== + + + wu6fUTK4oKJdvHOv77ZHU8OYhfm8tvE8OTGL+bUxRjK1N4IxOtaj62N2xDDGU7kop5dYjvYgrWwj +2wK1GBCkAsngUZwBRcVXKEDSbbblZ3/ewrYJUGKQaSFlxto/ZrKwna65GX7YX3PzMm6bkxhcXmcj +fEkRNOU2uSjLZH/MVudKwJki71/ny1NNV1U/YTxUc2jvhXOq3+JeJj77GxbsfUpLarRXYS5OudZY +tLyOB8jCulF48vlyBrH6ck1aiOXtQBZycUnJMoU8cy0e8SUIdDjitgi01GDPraozV0TgnO7h8qrV +mezF2M4Iv/i1C22+sp7NL5gf69X1Utw/ttLphhGdXWgu+urMnRhrvuJgreonwJhDSRZ9JTR93oVT +2TF1FcbyGw6xEnoThV0uLwL1+xxUFSQbF9oKt50Y9+9iungVwpJct1m2rVOe1oN9EBFLQilreaj8 +9/k1k5mNGRFaES1Lk51EfRXCyW10b+Gum5XuEzVV5tpehbBaLU9+zTxmK4x5Hd2vlJXQs6sQDBHe +Ncuzac6ai648+5cpzKq9j0DRJIFSpoDmrSNWK2bSWSYuF3u2GjreBV17o6rGpzu4WFMaNitda90S +gHCvFLYy1FjZlomWf51XvFApvJHbgBFtiSnt7juhjTZ25aIqX/5tPZGijZNiY+p7ih0rvReM7LVp +bKWbEVzOhb44In2Zr6U0V2ZZLPT9avlsv4zANHePaOr4dEE3k/u2NxB8tRwvTHYMNyla3wxGjr7e +XB/Rtn4dxjugvrfHdkSr+vWRla4zu90US1QXfFhWx4IqfQTFpCFErHGY9eqMaS9ypo6MYLVrYbqm +wmNTKbwYa1mzuJffzK1NpHh5wb9pnWlPU77sfAWU7fpUzq+XLzuWKlBXeoc3R2M2gWNT2NgQ5XHO +08eqb6c6TMtUApRijiUmoK8cH9sEjkmBqpPPwbVCxOO0Olxz18z+5PRK30Ogqv/Y++E2mUWQts3d +mcsioDo51eGiR3Gte+HSK30UwbF4+W5Aa/E5rW9Td0Mpld4L3sO1acz5ywj0lgwZj13re0mOYnkS +WHYXNGiFmxTLYCjSaxfLqeieQizPqjgpxXJt640yZ84olpdVCm9GLAPaIpu5S40ULy8Ry6abJ53K +l9cUywseElK+vCGxXNu63NDNkwRZTmIZ7f3VKj8BbSuLZWqPYnFZPhcpZF0ill1GK4pKLL+NVq/7 +tF7LfC3watmKVnWfCzwZetZpvlpEL/djPmGjch8g/N6hlfsUt35jzfcKdZ8UlvjbiD6J16buU/X1 +kfp+2spP6rrPvaM71vnsr5DpOuf1q49NXr85ywJLWTfo9eNSD82p453DK6aSYuG3zXUFhsiI/YUF +NmRRH9O6Falvn6tu+va5+pjarUhzXUE6HF3h7NOVLK9834X9Jq96XQHF2Qfq/+11BarcV8SWzhuO +xRKfvBkkaqluNN87DDCZV4tjMftQ9eInqX03O1GsmC5jxXTB5fWEpNCb5Yeq9ytJcc0PVZs+U+3y +/pEPVZs+U004/+Y/VG3q5/L+kQ9Vmz5TvXwta3+o2nYtG/1Qtekz1XgTxR/4ULXVl743/6FqE3Au +7x/5UHVg/jPVsJY/8aFqE3DEB7v5D1WbPlOt1b5t+EPVps9UY5baH/hQtWlS/Dr2H/hQNcJg+Ez1 +zKuw2Q9Vz0sfowd+kx+qXjVz2KGM0uZD1RaRRINm88sPVdsBZ7aSaD9UTVtAPqar4V3vQ9Wm8Rbv +6nQ0uWg+VL1SDS/dh6qdSUVZC/WHqqlLluc/U22fb0lLfJYfqnbOt/zth6otEGj7pe8Vk8eXIxDv +7KK6LJP2gAysvrFjVWFHjcAF14nTLQEOZu+y8uwNR3lsyrMp/HYLX5Te4P15enE27dcZnDJLlxdn +r+KDtSnPXgdjm7ky11Sc/ZuoqFqevYGsG4rybAqQyL78rjybojjbDmNrOq1sirO1L0pv8nKFxeJs +my8ZrVKeTZ2j+KvybAqPmm2Uh748m6I4Wz+Va5dnU3A527XQl2dTf7X8V+XZFptoLs6212FWGNGx +dtFKiq1Ynm2gWrvi7CX7QluevcK+/KI82xKL87GGjeyLo/a74l2dVuXZv/8CO015NoWyoX+Vae3y +bIribGM04beV7vbF2evdaj5Xnk2BSrv85BXKsymKs1eOii6WZ1OUGlvl9a1Ynk1RnO1wLxxNeTZF +cfZ81s1a5dlrY2zFCkrH4myn80JRdkwhpV2UQK1YfWkCaZZtu3559iJIFnnjvy7Ppqys/2V5tnNx +tjHXGtfaMicOUq/U6uad2bezre7oNn49m75Wfdm3s6m+J05dNm7HmEw1VrTgrfjtbKdM+818O1uX +yNZfz157N+a+nU19k96vvp1tpcEuq6OmUmkWlmv7bfRPuotcHAvRSRU1sffX8Out9u1sy7s6qRFI +p8jQ36vwuVAZR319CahDBj9//s9VjNvc1LrhinEKL9wGKsYXa0X/RMW4PcY2WTG+gRsOKSrGaW84 +/F3FuDHn6s9VjNN80eD3FeMuh4SjzVSML2YQ/YmK8VmFnWWx8aYqxvVK4SjlQVunYnzdb9itVjG+ +HGObqhjH/OT1a6doK8bNsdc/UzFuWVm/8Ypx+rsIflMxPl+V9qcqxpfljm6uYnyluwfXrhi3/VrW +RivGN1OX5FQxvkJd0i8qxhdy4P9IxfgGaIyiYtxFL31/UTE+R2N/rGJ8lW/Wr18xbvPN+g1XjJMb +QTna6Oq6FeMu7+I3zzdfMb6hGiuHinEDJdOXpq1cMa74+uxUnk1VjCvaBb8ptNmUpq1e97pOxbi1 +72LTFeObo7HFWPbi3YMrlqatWDHuWsl0Wbdi3Hxn15+pGLe/qXWTFeOz6qc96vvX1qgY/81dN/QV +4y6KD17/XtnQvlpOUdLyi4pxu+/ybLZifDmNLVaMr1rfPXc7kOVHHzZXMY7f4LbKl95sxbjyjdTf +524trxg3c5g/UzHucvZEbKBifMZh2C3ar5KuUTG+5t1QK1aML/GQbLBiHLTxWc34H6kYJ2LZ/gsg +m6wY178AssK3gleuGKeIjGygYtzCSvoDFeNk923LiTdVMW6oeqZ1WK9RMb7eDYerVoyvZImvXTFu +cUfEH6gYJxVDd5v8NtKc10+tGHd5rT9xv9mKcVjLrGb8z1WMW0ZGNl4xrkdGqN2Ka1SMk7w+20/c +b6pifHb20+Hon6sYd8i031DF+Er3j61dMW5z/9jyivFFPC2pGMfacPwG95+qDtdrw+Hs/7HqcL0f +YuxPVYfr/VzeP1cdvnwtm6oO1/u5vH+uOlwvtl380vfmqsP12nC9amDz1eE6cHNfYd5wdThdZf1v +q8NNlfV/qDrcsbJ+I9Xhepk26Px/rDpcrw3X5MufqA5XRUK3PQWM/bHqcF0xVK2kP1IdbpcDv9nq +cJMO84eqw80+pT9THb65L+Utqw5fo15sjerwpV8v3Vh1uF4bvkZOL3V1uL5cy69mbKg63CKj+w9U +h1tmdG+8OlwPYzvUWfyqOtzKStpYdbiGO6s6iz9QHa4jw+VIT+tXhy/U8P6R6nC6/LHfVocbswj+ +XHX4YtXzn6gOX5ajuLnqcKcI72aqw/XacIds219Vh9thbLPV4XptOE3m8LrV4TbZgxuuDtdlvVrN +8Ueqw3VEm+5V2Gh1uJ6M5PL+uepw27VstDpcrw0309gmq8PtdZhNVodbSbHNV4cv2ZcNVofrteGb +3Re7T3f/Yl9W+HT3Eovv19Xh+mZb6Pwbqw7XNxtj4n+qOtypinMz1eFzttgfqw6nuleB+SgIz0tR +afAbqAs3xpENCRIur5Yi0WvZf8A39fC6+gdAz23PfvtsU4W8lLdq6NLeUsOD9X1TfQH4nXtFz1Wn ++MA6kFLq4cd8K/ZKpZwLGFuxlNMOY7T3XThjbPHm3xXu7Jpbmq0JvxJIJJL4RpWO5Py9dFtmZZ/X +Z4unFYtI56xXE1Br3OJmF+giX2Cnrfek0PlxpQu5O7jSOZ3fwlK31/RPfJmRnaZ/brLTf/0V5uxC +GZoN56er9l3L6Wh7EziAt2AU/8bpCON5V/gyi6PT8dzW6bg8D9Z+N/ZWOjQOVtL5eldSLqust0gJ ++90nwGcC0eXdxM0Jnwvp7fMItPkO7xIELknctkWgrQ6DxetOyWHUCMRZsHjdyZ5QcWchIS0yRsft +JbVv/I48pKlsoPPB9i6sdn+NrMCLjX/172KzXzQALrFwsNcrfdbzvX+LMccP/tH5LbF6ekPfSL0g +Gd+/zxsnIFmkelvd1EqBJ0c/03zKnlLLY5eihcXrv/w86sw7Olfsxp9UJhkb79Iwv2aWt7UPlj+5 +DZhvgFlnm2IlLSrqlFNHK95jJftjtsaN0/nVE7xtMXbk3wjGPFq92C8TqfMUSWR0X/xEoH6T222I +8eWtfBtr4skUNVoe5XFS8rF0nSYd0LV6gcZwScIClsZaHNy1b5zGuBB1kY/L61RTTCdzl0vcue8j +n73HzO6W9S+KwNJ17fQaIrxrfWm39kZzwYOLshSbSvDakrj+FWasW9/EbRFK1fr8EV73Vg1StR7c +HI2tKn2tZK9uv5AR69Q0tkLyeLmPPNnGj4iOHqoybmdBp+9+uW97HdLqYWyEcF9nmY66pWFEuzIP +MuLSa3VcXooRLWtT95ORI7simFtLD8n6sVAQkxTizUVzNgDuHA3x2TruF+ssgAHQ3j1DVZu6nywu +3j24VvnY3WB5berc7juWYu+vaT6Z/MmEOjZTm4rl15qz9LfyBavWnWtTaWksvpAgYXYiLctAsPlm +vQXfNDtCKArlZoFxwpO1ezoAj/u2yaJs9jlNYxRa+Rws13K30lVZSyuKKb9dSx01A/N3o3fcIYyr +3fdg/33ku5Xuy1peiK1V1/76kga7FCVLi8/5S+freB+svl+JdetrXZplhSyrexStXKSUH8PEEe3C +H1Y0tsKVEbWt0xM7sXyvi2UHbkkplp9/lovlFeRLbeuBxqtpJZZt7iGB3ac9dzRimdS91jfgc0G0 +2Yrlxd13/Hg3taavHz1Lnny/MbGM5dcgljdwi6ZStb5ULK9EY5eOFzzYiOVl36zfnFhe8Chi2DVo +K5YBxlsa08wklu3X8uAslqkrV3Ur6W3kqFgtfPPcuX6d27TcfxttWO7HfLQXSnjnIolLyuv7v7xq +cd4Sf1jBEaKOaIs7kxuEourZWUxi/brz2aepYLfw+r15lnn96oaPECy3xOm8fh/psIONiH4YmysX +lpU0fzpduDCfgeuiuNOg+mu34sI9ilY5Sb9wK1Yt8y3Xvn2YlK7TS2S6z50fUKvXWi2PjdiyTC1a +48KF+bNfpfHzr2JN6kIL8y0LQthebL2M2w7Xg6nLWPZdiHnr9TZ2YDsfRcTcdr7ZjTqqxxHxWKhk +6weNXrLfCA2Ske700iQDyFSpbktkEoff18+5/d1rjbk0kruZj6GfTebvHwuzfQYrSQ== + + + r7xXT5G5+/uV3l3vrNRqqTgpXKe6kodNX92XWrnD7HMY1nfvy/lLXDLxk3r1YWWKYg7MWk8aORyx +mIhXSlOsjz6TQp7dafY+de+ZP1zFTCNWa2Yb79niaMSNk5799qh0EPLGdvn7y0gyIgbGn+cHg2nN +5d07a0ny/snTzuOW53zi9yRzNwdb1VcxtlO+3854v/vlwl7rcxgSy4Wft+h3s9BOfL9ffeZbZVm+ +ej77uSuzw/xH+bPU6d6eHlxO795O/b63t3TA/1WNfF33ioH4h8s7DDwmJiNv2bc3GvE7nq1Ba3Dg +ZXY+4/7HQuMuIAcufcc/O71CjHu/OUoyh4dbo9FJrOjZfzm99HCp624g3hASTI45OWZylfscc7o9 +uGJOr68+R6POSWg0/TwGbjneC17Vw3xBjiXL2+09UkIO63vOhqKF3S8pepLOp7rRUoAUb8NKKxWA +odUMWFy4YJHnoOyky2t55YK/05U9ga5Qwul5nXRjXG2vlDgMnQlKQfte6ufGGsddVih/3u78jBJ9 +8crl9dxf5QMOKJq+h3f2d70PxR0p3k15i+XTi7338vmRIO9eirCqlCdZOaifYIF8JXB0ELpH4KKJ ++MtrN3Ph852Qr2NXS0z2Lvo2Grcvthmu9LydjL4kWpnz3slDIjZ8OTR58oFHXv5kg9I4LBcvSp3Z +6TXQOciFYlo/FC6vdixeLnXxznDdyWH6U7yuwl6NX5OwF/dz4zx5rcY2433/JTf1BD+/HvC+i7vX +rCd4ef/g8YVqW3jLxQX+iHtCSb7oCR3svuI2HXtC/dKzJ9AIy4iOSPKm8ryXrTPxKBk7es8zTXLz +Bfkt3notfgL3vffBqrYP8Tbgs4+XTGs0CiZ7g8IYVnX/g23NXDrl2Up8bSe76U7tgGWY8ftupn79 +dpWUgsNBIHv3cAadH7ZgvsA7ov+ceztrBhn2ddub6l2/SLl0clpLDMdsXfvi57HYCGYbje39RPzi +G459Pj8hRhPDTSfbidF2c5QKSd0rht3zt5Plxt40WdqX7pKDQbiAiuqOWM3384nYdfor+x5qTxKH +J4I3kyrcNXAtUZc39/52PUxWMo8ckHvwKPPBVPFaD5kla8U/3xOHomeEx8I/a+sd+hOFcqrb3wvh +YLe4k5HU90/Mmyold8SUMAk85XyDdzbzEXq6Jpz/XQCiak5wnGrm4+U+muomujyOSOJBnvTnU2Ma +uwzwT0gHeQI8kFfoIpe9vJNynuBNLvfmf8qLk+FrEfbqJAiAeHynk7dhHVb1ICBPvpgGEvGCB+/V +3d/O5PNnUXh7Ozw3jm9P25zMCBc+zqVboaeUEOn7CQloe/rgTX+Gzptn22FvVN9nPPvv51sAfI8N +ZILeac53dn4eu0pNnzLn54ldvS3e5qrfqbPb/o8yHzethmCRzS29i/gofj0lbz7ao8zHwc5btrH9 +fUKmgrUAAP5c9uc5ltv3BwPiduyhnG0ED0Nzi7ziYNJUn7iOdBhT35c3B0AHzyO8iyBNeFvmI3Uv +5TKRRw4IqVrIZTk/6DAGdHDbb98JPnXwpfzJtqMDgDa9bVhQ/vF0YAD+KPdzRnYNtuSplBhNc3tA +DNU7hvdsSZnw9WeGbCLoYx+9+E6y5Km2YRnRi8zF+3gX5N3RC8MFW92UmLj/IfKVYQfVLrCmh0ny +mg2V1c1pDktkf9UuqXorcfdxew8Mda+QKlVPGYIMQmMfsIM3vXLu+azQSl6nU9VM/txzt/CgzVyQ +033kCwXfxWrhNpF7be1UM+fdwFXmYzA6VhgXHy/vptqPpbv4x7SYRsJ9hrOPh1PRrggLm3U68k25 +99PDoa+We/fHMhhuu1ZhfNr/zgY6jxNxO339tgCS2JzAvpzswMjnfTwvd2Qtzy9HL/nsQaYd8tWT +khgN5zLVShDQFn1iuEk8KRe97Yf4RapxnzsZnxZz73fVJChTFQGPVCpZDu1cpi+P+mmVWzQK41Sp +dH2bavSnr+q+SP32M5+tlx5QF8yHxRPx4TSdvREmKgnkq9108z54n/kojd+QCd/msuxoJxOs/eAK +HkOZg9rhbqzd37sFuCK+TGt8Iqi48wgyUYJAt+S5wiT3FryLoRpbMpoNVr4prnAPxBmXcP+KtDOD +fLGYe+WZc+nPaF710CJHAz6dq6AElMXbI7wVMHm7G38nnfAukXt85yLV9VYq6XZ77AG4LyUET8o2 +Iu/+6F23cKqfl+hd6akCP3q13OHp0ylhZqQtdtWOd2KdV+kDHrCwFvVAAgCZVmfwdOo9ff7K1ivZ +iD4YcLTUrfhQG96R7UbiLGdaD35+9ud76ps78mhC5GwPr35pprrhmwBYQS9+QmPZXaB5IZvztU5e +koPP633VAtMfNL+esrVaRD6Wz7mBgtnLs7vvxOi0B/qD/7WUCd80OPJ0XudPI59+gbW0PytvoFsn +jyx02ZjBLQ5MagtY6+1OIj7oVVPXk9o43op5+4oFdj4efOTeC9M9PUtAb5vd1nj80yNX1YDiGN2L +7Q44ARTjn7vEwWQ/E5AjwiH8dniROBgPT+DB5UVmWitew4Ojk5y8c9NMv1xsnxEFK3oX2rrMvV/u +RlWn4zAJVtL8Mb0GkLlptvF4RITjDUixwxGezw7uwTnoAjxPfBd44ivkyEXjjYeQqV82sC9+iEdf +9fNsPZQ4V7I7duIfZweV5DUzvERCO1dE+bTH12HPfyrkphhyKxdwgYc0UWjhnAs+YKg/DaJsHIbe +cwP99i5JHhx8JMuT4TSZf/RLsBYkP0PrTf/7OVvf3X87O3rm7xV1+PrH30hdT/d8yMzOMh+vW99n +2zenYeDyz/d4MdBPznfx5QO0DBh1qGmJUCAcXCZ44PKysOXHMJjMAQNsbwMf37uA/f3ZBUWm6kve +dIf72cb3jwwaUDKEU3WIiILDEHwE9p/YIlRCrhc68t8HOgQtZLnECsTPI4XVbFv29DWMBS/ZrVw2 +44+aepqdFWyl4wOQmE9QjbY+U6FYZkdhlLMfYBS2PDDAzVaydNX6grMvtKeNeRLA+wKkQeZi/2kH +hmgNDVpfIwVSG9EvC29PN4fBx8xzLhMUAwb5eXJzeJ/z7b50svVyfpoNFMJKpXDKm8mn3vncc3On +TXYf21hgAPEJKMHXHrmbazzHW7f+TqrxszVSucXO1jjnL3ZigePo3Vn6/Tu1n2m9Tx9zb5PPbiKW +89ZmD7ZcXmApL8cKD3kU28+gj+UN2gxYP2I0l+kGFUGIBzslTvKTo9xb98CTiGXjxaQcz4e03Q0O +QPdoT3PJXiyo3X7Uvp73Wq9iNhivwQvtJMb+h61M/uLxPc3e9sY5z345pD/AL0tefLRhzyPRlBhk +H3DEi9Q3W2tkcs+X7Wzg8/URT+A78TilO1/iAehM99PoiD/rpAqPgwc4i7FnEOSfO8Ajr4RE7Opb +Tl0Xhx1QaWK78tfI8+TyqqSksLAPJtXtDUPK0dUV7MdGixmNjg6wyzZoLh95llC8PphisOxGBvr1 +WFWQcjdbOX+1OAEau06HjomCiRufRMM9hBYKo8O9ON8ooHuzjnzdeAfw2fYkfpLbicRhsNkkl34R +X8H2jzi9dHkNyuTifEXDDVx2OFHuvkrvnGRtVwq7r6z1kbuwWqvFzNuOKx3sm1ZK/DBWawXb3pva +ySxdaYl2pWBX8udPPaPF0GyXTLhlcw+n7MztlIpx9YMO2mw1NCC+iDwj/EB7UM+bpB2efXgeb3u8 +X9lG9Z1LdS8OemAWHkfQ45jCjwsUcu+xgZDzyaI/GwoMhrqNddAJxvAsPsqJ+5J3y/Ld1w+s5AJG +ko/GOunMJ+G1KPJ9yDyD8Y/g6DHdvLu/VC3e42wQDTcZTIlTwGKd2cl8fJT4mR3rz4TD58E4c/Lh +gS4Hr7psdnnl67v2de71eaAIodgV030Tpzf8Pdj7500Ypxgh3hC8bxF08OHTa/K6cPaIqn0p984l +IwqNHcZ7Nwx3dj3NnE6irVQkE7rTnwLG4o3rS5BExQFIIrkGnLgxVuAhasD0nTXc9mcECeSnPUhP +I5CzM5BA5zcDlRmXbYEKxLu3V6uDhLtf3O3ZAKXcI3lli6f52wqvwIZ6207ExqEBbvxZNnA1qIBh +cwUWX7LYK7dz6cZNGv0+j3jkuHTnKBWwnPSmx71qzuLMOHMR2N9OCfdcCk1PJlke98tAVAfTufUl +eCLF/FOQKhcPZNq5Sf3PhnNnNAA7JQWpuWSmYYlyBanntQcyKdiVxmljrPVOT45/aHd6YVKuXTJE +RgxoxS8bF3S0Lq7PFqkwaeJ+v0ZAgmMWfCVP0T+mPce7Sp8VoEr78Wcr8rICCXSh70s7kF4JSGhZ +2AGFmDABpT/FOzhfaEGC86IDdVKZXC0Hak2QXN6VgNJBwrinn5YdWZz9ZQxpTXZEfH3V4UrUbzpy +6oGc5J4tJ8XjiDT2ctFWVNq5jajaHMiX2rJzDgfO4pRjnpI6LF7IKh/j7jcsJn3Qd9+O5LoWrOcE +bwS6ACm2ucNne/RA66Mlqo90OLQmm4Hd/xMCBUjqc6qTlI0UW0JUR5z1sMVne0rV1rJkWDs+XXz7 +oT0AQGP00LbGtsMyuZR4bQuryzveyrUZm2EHnvWPK8A6O654e7bNgV31uL63bY8rruX0LLVMLFf7 +NsM23myHBQR9GbgAcpiFYV/smMuLDdWW+9YnrCAc6XFkI0fgT24LBQt0vNpsXXVgqSkFC4G4znDI +rebKBAkuVWXPLSZozaLHX9n6wQfGNkqvROlW3kD/fOr7MjQBdf/5PtvYFncUV/j1q3hMwhHogVfM +WX6XuInU3y4+vtEPc8MGvqN7DJtP9k4fTo7qSeb4oqc5Z6Gtuu9ppD+fUt6Z77+L8ZwfLb7kF4l3 +BTO7NL8QrL8bRhfNceajUsJgzuN++uPos4iGu+KwP6yL8X7q23fzEW/tiUXcqyd84wIMlrO+4myC +P6VZXOgZzDrf9uyrGaL/Z2YbfQEXzDJKqIfkTighsVz1VQkVsPnvSS7BXNwCHsKP6p97mXsllKV4 +/LEtefotkKgRWuJq3OgcgxhcsnJ3GwC6ewkYbRowOQ5Pu8fVbH1wFkoWm/GmIVjF+/vbYMfd7mTO +u7e3JscnCQShlcTEo5pDNzhGk8urhE8OQ/et1Hfha6T4B+eCObXk7e7hMWz33fViQOm+q9u2JCKF +33ycj0lxZ+mhQiL5armv7fTkSwmu5E9+BD3yg9vZSXde3zit7TEOW7LvnwWw9mHNzD5Sss/vM8TF +Lr62f8haovf8Yc04PYnHPo2F1PfeaU4z631eY6ArffyilmvNXmPzVZT775feLkasRMXi67xe9IHG +RiLG6bbk72QW0ObnZzHTBw8cvvxohp2JEj0ddRp+DdZ7KfHA+MPan7tg7+d8ecaLzulLOHK1XYUY +mrvBfG6fO+a0bXyU0Oru5N738i9wAo+2SWQE3ZgZA0sBGkqA/f3QS1Yus3l9c1xezQ== + + + /+uVsVMcWj1fydIVaJkY6tHRMYsgyXgOCkrwCO24+QfFRLx3nDYEfV74bBdsZOKA04JCxEFV1UJG +4ihRTudvQA/xn5MoHjpBJQw4PGldUl9JqfH4kDl4KEWVcNosGAXblPlIxJ+TF4Qnm4GKYrToKNmv +196V84K35xzujVvtrG/rrp3JeT8u5gNKF+J9zz9IDobDekqYpkqmiJTCYT5zJ+Pnu8Dx9uE2vnMG +mA/siNssc39wWf5GHfVkB/Sj/SfVEfJ+fgyc6mRsiFx2vZWSIZQzH4QBi6/16v8A7SqHmTPbEvqg +B7MY0d3Z9s1RHInhEihmb0LcEYpD15wHqmVuzYIs1/qkuJa5aTc+Kbt3gRbfee27uBjb8l9IJVk6 +BS7YqpDAuPoOCcaNIoVUKB6PEe89MArvNF0YTK4RzKF2Srhp+nN6U8HARA45jMLCSGvvK1lJ336Q +ZcyOoV8JtxWfLp6zb8PmF9DiVkQbjASC2Ex2J/R5z3Ah3yRZDHUraswf/yxdle8wMuJvXish++/W +C4xTYGup7vd5WQvjA51PfOHLxfi++kDc/vGUT4c7hyL63bcQqYVovHF7Q4QWSfZAWQm41aJFC6I1 +1u6nSing0lupwmMpqbJWRbqeMBhFD6NQ68/kx2Gq+yzHCAx6nGYWf+metnOJduJZOQJkG9lU/dMU +0VHjNPL4hHwyQOmH9/wnfhKjQ+IdVN+VO57sXn+3BCCxTy6vOTfk+DTvI9GLROzB10lxX2E1Jq70 +C4Z7Sngk3SjHzCGTdGtag+mTLVX3eKgWsvVws4VWUqe9rTiWQDiO1SDN6O5UTZBIpTygMBwntFCP +b5cczePdcqwTOK4OFE1BCfoQl+xD7eeC8Omzo9c7hhAX0cf0AI/gzZxWE/Vk/8QzyJw/idtKyi1/ +6BOSkebpbeLno91XL/h6mISVQodOMBZAPWqQrNzv7GffxWHD0M/iTntxB4DK/aAH/gsTaUZqoHP2 +A0OQmon31MzWvc26iQQQTxktEUqVj2QtO3u5zHfw9Oj+I51guO3vj6z/tdYGPaMyzj62Jruq0Nv7 +8CYOI18dZMcvChcAZCW1lL5sH/NdSMpQEiQJxyditUI/9fl+iXZlJ/n8nq2XqjPZpgV97t+PK6nu +Vj9HojyyeOpvYDgGtbCHDHkQPbwX3zDtpYMh8lI2WPk4MMCFn6AA6v0Za7qlwj7k5Hvi8CwdxsHi +amhY3d9YshxMgLLRqUxIsgtqzJdaduT4v49dAsMKbiHKiu6Dm2m3NboeddqdvjvoirsOkucse9tv +DnKjVqvS+s8kM2hMe63+xB1zHyTL6fNzCfhrY9BsQXfvXDyn8aFnOuppV7QxX8sg/aPYe3R5SehT +zeES42PMMPWBrGuPF6LEx7X+affuq556vywlk8E++xI/Ye+kzHZzms2kz55ftCjq0FyxBKLIGZQV +AAHdPji8ukjk5fGxdHZ4H84NHgVgrNnR8yOTecxVK7mj5FHDCh6NISo6z9dKkfOZwFseORfqB6ks +d5YgQfPEx23lKnkmvl9RRc5Re1dVBEWT7/a30KR4UyLit6+5GvD8pytDogS2SZXn1H3qe1eaaCcE +j+VXp6bwx5kQ1APgbLDdPlaYkS9br3QOM/n84d68CVMAtb8XxByeoprIo6RHvEQTsWtfCznJKVE0 +NTWz9pT6zpwxKg9nMi8khIRhp/RTCxihvK9EX0h8ngTkhffQi/IlF9x4NVyvpRLqOVN6WyzPHhzo +gRwlf6ReOdxGsRp8ieTejpM1+4w5e6PncXAJyziVVaEU8vWUPKrKxVRWRYh8+ePyJkaNMFGkJ9lm +7LhnYbj00UwMn748+2LpVrl4OxtnlohmCAKWrYwjlzd2WSudKOaBvtP3l8NzAvycDXSHcfeTH2Nb +z7eX8zWeZ+zyBZTP4uOBIeqO6QioVPWOMDmvWwWB+CIbktfQqkp1Wyk20bseltQw3selrKf7YZxw +V8lHNybtFB7A0mC+CWtE5OfwEz6RgYRZmSJIxZNbEA3j4JzhkhxlznOPW9qfhwB3/uHDuKDGjxfU +ndeQJky07M3rglgiGYGouIeeMOVd+diaoOkWJGW20Mrkdv2lVOSuNNEyygw+EYwEHqN0vP/J+c4f +bmabc6mmuoYS6J5gdmD3MTdAswwq9Rk6QpqZ4XlDFfBmMauNPDg6U3TDxWS5C80weQ7PJeeh7UOU +Lu1oPj5ye8e+M2OXe/kj0w7kaxa2y2G2cfyyDasPPphAArFaehx2zGL+ZVwvgfWSDYPpIbfErdxb +CbpIrOZveX45er5KH+WSjXYDU+Su0vxR5ZjYuEoCByba6VYMWct9kFhBhgQ7dvBzBiRXJCSSydQu +Lm4T8ZPpZE4rP79Pd46OYwoTBu39OxEvT4qpkPQVSHXD7f1ksfFRQLjK5FNkzcfsY/MCY7Avx5ge +gihq+NKd8SFL6iTmy2FN18KkNPPg+9p2UnSmzE3760nF41vhKskcTscqHzt4BEpW0unZg+3xYeA2 +PlI6oXZE3lET4zBZbhZZVlMAX/NZ4xFXbKDgI1ZonKksDNtaA6EBp3LBelET8UwJduoJROvlOtXL +qZuMVsDgIvui/4kZna3UWWX7Ffc0jSkfQWK0n2DKSLo3S7W7RLfLQ7J/tv8zy+vSH1zMvvU10JBa +64FmXPlBsVVNxCs3Y+Xp3AUcqyfMcIUK+t0+QUQNt+OtyvsNCNtaz1yaUrmYTGdyXy9YUT7seDHF +xN3D0Yib7Hr8h1eCJ3Swd4cp9BnPTkY6nGXUn+CDC0/wZ3iND04wwb7pCV4+nHn2f7ZHsC+XLyYX +J70RtroJhqkzqxphq5tgcF5WNsJWN8HURJCVjLDVTTDtoodVjLDVTTDislnRCFvdBMOSjFWNsNVN +MCUpfzUjbHUTzOVdNMK0mljiifZXR6TqoZ87zDVZs0Kv2AbG4rezTMszDOIZaiTuKue1XFYqtZRy +39zsURv3PEw+5KoU3UrcbS5ZnmyVcZObWPNxrBTKGzKq2qXXWXrdrVVaHGoXmL71Vpm8ZANjfnfG +wpZngiUcM8Eau0ZbbHnWG36is7Q0E+yOIhNMS2jzTHzj5ZlgzPlzMKxFkpalCk7rxR/TSkHuO2e9 +2a50a+v45HTpSm/nPnW5NOuNyR5eZx1W2tqKHNiuVNt9ZRmpg0untMiz3TNjcdjJaSATDouPxGhQ +5JlS/aA+uCfSjhTkaPJOed7bAuMk86Vkus1y2fb53fgTO59e92Wwqy4i4bieJ2d61+VV3gbl9gvs +pdhuLlnqjWcxpQZ7+tpmQOa8jlDNO8/6b8/HimoL6ucNBu5bWAHYIlFivZgJU+7ec8kn1gPyI/WK +7lq9sH2+NsY+2sy1S7TRZhJrNiVOhUNrRZtfLpcHwNHe/2XGCgVIJPBgCMlerRnsXxLqrwZBVm48 +L6+2dXpuymExpM44pUYZP1JtMPvSy/PyDGlAq+TldW9WT3UgsnJZvgdGnH6dFApr2VwWFl6BPbYC +yeWlShb8ZQ6P8ZpCI1Cx4mTt/MVFkDBM+/vEorvBcna0/OwvMKQ12ZHp7L+8U1C/He2/2uaqkQJp +Mu062WpW59wqVw3k/m+z1Shy1VAik1yamC/4RzKyydGb7f5qRFW3T9SiSP/dlECZJ6kW8fasS1R2 +qU/vZkq1Wsvq+dPvS9M1HdOybaFtLMv/ah6YBjWnmD/ZDfvxG8wCT16WXLrmcU2Y8pXNa+ktT5dH +dvxjMWwSTbysDReoPitrsR8W7Zd31SF06x0ky4+eSYp7v/wislmpNrlKH7wSp/l83cmLfrOBegH6 +8rsNfn2zAWDM+W6DX99soAbpl99t8OubDVxeirsNAr+92YAU4TvdbfDrmw3UhLbldxv8+mYDl5fi +boNf32wANOZ8t8GvbzZweSnuNvj1zQbouXK82yDw25sNMC7meLfBr282wFJMx7sNAr+92QB23/lu +g1/fbABrcbrbAAxgh/sFHC81QHt/tQsVVptUuc9gVh6/eKPBBu8zUEvKrW402OB9Bvq1OAs3GgQ2 +d58BXryl3mhgIVoNlZsF081B0jDIjVPfmb3PmTC6RWob5fZ9/g7AkL4HWVHdJnC5lExV9Au9zF8K +EM+cN47u9J7Yj/jopGQ5+L1DHEuGywO2qsJl9rHpbRNXMuxVXxV0IPck5YqfWUq47+ygs1XcnaVN +vM2c5kRg9vQwgybU78d6W1LknzvJSJNrq36B0vM2iWjgqVRiGiUmt783muphDxQE7yAIvv2pXmC3 +qgyWPxmWofMgljn/+jnjMqGngDGW0mxfZAPj7G7685kPJpnjaZQQl8ur31iAQraRhR0ZAPqDUzWO +fFS8IUEYY1TiOBuaRSXUT3ZwwZEHyed7vp93ti/aB8qUKvGr3e/qLBSSnt3Nu6uFQuDgoslBrihY +JIHPJ4Z9ufxMRfziyJgRQfJFMOuWI/EJvK/sKdPKPuwBEvQ06fte7r0w4MFw2/pMdfKJseoO1Or9 +UUDf4+5Xoe00DIpKqJ3zfUivWP5fx5i4d7hvOGiRA7meaX1dHDKRev4ED1Ioze0cvWfC0/EDSJ/K +VHvABJOV7G5HzWzeO+NzvnxSVyH2E7HsAXDQVP1E0S0vSbRBi2Tc1xOVG6mMmaEldX+1AIia4Y4R +R/2GgMF/H7viQEbnLPuW7TeNuWQurxdayq3JdIgdIm+pVrvTL9T+aY1crFv5j4H/WDfnjspuLhLB +fxg3D/8v1F2+xqA7GI397kLf5X07SI4mmU5j0hn0a6N/3DFsergs3J5n3DH3rGvc7QNImDfoDE/8 +mLz2BtC9uRh3Ev7/8LdrfwpzZ+D3axcTZjg+4mbCLCcL8E+EkSWY+tvFqIDBC//AHxfwyxc0/e0W +3JfupxfG3cSxblwCK4R5GcAWInyYkeDtntIWjUKTFGZFRnRjQ1SGhQnRaDgiwUwCy4Yl8prEhwWZ +4dxpl8AIAI0IDyUAxM3LXDjKiCym74UlkHxuXpLDgihIbkFkw5gCBC/xUT4s8xzMIQphjmOjbj4i +hAWOg8lEeCREeTfPywCaQF7jZFguvMaL4QjHRsjgcoQX3TwnhMWIDFBH5TDLsvAaQC1HRAXGKBPF +11gmLIk8QBAVwxLDYCc2zETgF5wtKokiaYmwLC6fA0AkjrzHwioFVmljYd2kJRpRWxgYkrREohHS +wsusSN7jw1wEloC4EWVWgLXwAGaUcwOCw7LMwS+48IgIA0RkpQXekyPhKC/xSi+JgUHZCKBHgl8Y +QIYgSWRT+EhUIDsHC5ZwC8jOMazSxghKJwkXjNsr46YubHja9QETQn+YXMGxBLvWI22wgIjSJsJa +sUXgcBBsEQSlJSLwSgP8z91wKZ0krRMfdSsDCbOBRPfidA0AggGiBsTBS6zyROQEAgduiCiSpoiE +hAQtUVmQlRYetxGIjYmyCiCw3wIBZLEXjiSpI0UlZaS56RCO/Vvrw0pOoXb4wiyMzA== + + + IPBw1sNSVMLjx8Ay4fBxoFlGOaQlwDEflWRcBeCdY4AKeUEGJCBa4HiJER7pmwHqwpPCSHBSgKp5 +IBegdDwgAg/HgQFUzdoKpC0aZZR+oN5ESFtEwSTPiGExipvEc2FJ4pAykT/g8YWJGFw/0iXP424J +XAQQF4XXWJhbJCQjKQTCs3Bco4h3eJ8nYEELJ/HaYQfCBrA4EagPVyHKYZ6JwuBwklgBtrvqQtqO +EMKOIow8TAa/8BKLrUDRPJwVNxx2RAgH/Tl8EoFfkUphRs7NCZEwnGGBkIyMZMVxeKwFmCfKAb9D +YIBvhCWYi8DAsTATxwHIwK2gJRoWETwOliUzEraIsE+AKGA2wEMAoQilIMEpbbhYOHiiRHYJUCVE +ZDcL7AQISybwwiRzLSpXSLv0Njie5GQADAycDQ4OmKmN4QSln8wqsDLALqMRmBMQIUUA8xwTBUaJ +x59H/gHUzOGGMQJH4OJkgKLhQvgJqQMWYbGMRFCj8KIIo5x2DqkCuQ3wpGiEENQicRacaL6QUoQf +iEIi+kKhtYThZNBr1CZUwlDrSiUMiSB0t1eQeVGNBQq6zIuqMk/WZF5ElXkozRSZx2kyT9RlXkST +eTyReYwm83hN5kU1mcfrMo/VZJ64IPMiZpnHW8g8XpN5vCrzJE6Tebwm80RN5gGlqTJPVmUesBmT +zIOWBZkHbSaZhy3zMg9bFmQeYy/zhAWZJ1rIPEGTeZIq81hGk3lRTeYJusyLajJPUGVeVJN5gibz +zBuuyDxWE0K8LvNYTebxmsxjNZnHazKPVWUer8s8VpN5vCbzWE3m8ZrMM083k3mSrAkhXpN50KTK +PF6VedCiSjNek2aMJvP4mcxb7EVGktSRiMwzT4dwIHELMuKMCYtAKeRI8ApDR/TLEYmwYCaCHB4o +CTghS/YxCoyHsHxRIrsv4mmRCOETKQBDANkCBxeEqCInkZNGeZacLAGJFV8DkmR5RCD8AhySMEMg +OlwdSC+ZQTICBHKIUiAaEJ4CvofgImkRlVKAo4AaUwQXIIiEJHG/kGgiynuyQtx4bkVCLNBL5nBX +NNkrgFgBquHIsiMRWSRwskyUSGNAU1RAARVl8OiwbgVxiE0CCse7F1CZduKvU3K2EYG8DP/KcHh6 +5NzKHApWra1gbOPIlhQMby62zN77mDXCsQ3LUZCehglmbQVjG6yPFwTDeJZNszfxPAE9inxkBgqS +kKjqBDPoDE36svQ3rdq0Vw1TzGAxzGGAz9CmL01/16pt9u4HbgfsuETYAHBYVuIJa4jgaRH1poJC +fUwkMtfGAwELeAIt20D3kGUydQQYRASp2dgGS5WRunhU6YncRtUZGR7IA4kTUFSwirAXBGQ/ArIR +hANoH4hRAJYbxbMCSiacF2xRtSzQhsKiGNUb4DXUcfA8651gX4Fjw2t8FMSOzJOWqERAEhXJogii +qBTR2mSi2oFKysC5I2/KyIyUNo5lUO+UUF7gaHjM4QVBANYuskaw1AZlNaAyCoZOEdT0WMJBQNuV +CVok5ABkwShj8DUQpiIyOgHPLbK+CAhTCTkPoJOXREXOwmAGpKM0jhJJqTaR/cLtZ/Dko/rECgo3 +4ySJJfsQAWUayBKMYxaPu9aCImzWBlwQeQiOBaQYlWW9DWQTTITyiVdsDpwO6JHVQUgrVpQEG2Ak +D2xTCVCWOA3QOTolupxiovCgFER5lKPA2qISCKqe0oaESJoiZAxg5qh5ALeXJNRCo7AIGeUbil8B +dWHoIQqMYWbEGlgZojxP5lFgqjzqOmAnSBLuN/RiCC9EWxwsFTJ6RJYUoSICTnAs2GdgOpLephyt +KIeUgnZTBAWKonQocImipFDB3IlMW59INLhA8qmWTZTQHEgunqwZ9CeOaNDA9QRiXcvAEQhUAop5 +BVeirFC0iDJc5MnuE9JWDrLEsaoNilZVgfAK2DhJkb6oguC7qABGFH4eYSKyijGOVfuBbCNNomrb +oZohs4Sjo56IG4jTMqgN4NaDwBNV8ECdB4YqabIJNxctzDuVBiReaSPDkhY8FKQFjaYFOklrigmA +LEWJwQ1oifJEakTQRANyB8qAHZIi2sZzgtrEaaudf1W1Mm5dstvndz/cu5ZJRK0Ph4pVhKiAcGii +HApGMKlQj5VUHQtW0HVxUcQpSm+wfjng5Ni28G4XQLCfkxMRUlRv0XCLAP5gLmAOIOUVNUqG0wHD +ossCSJNsBuEqXYtXHaYCWgazQVaEG2jvOFUE7UtBUa4icNpgWCBB0CZEhf3wUVzB4qvLp0IHGyIB +2WOEiaJURnKKsGhBC7hvcIi7hAswHE6vyZfu4qsOM0mCIkN5kEwysapwBKJO88hIQVTgqBJaNsjE +gXEC5ZAm05sOExGjAfmliLiAXcc1RZQTh2IRrG6ewI/ePpRT0I8YUV2Ldx3mQncZw0pEFBDeDHNx +ILPwBHBwGkEq4LCg0ooiylt4xrEcWejCq05TgeYqEi0BmJhEDhs6TDhUldHW59RhkVsSLhuBbZTJ +qsyvLp9J0WKRXDkZLVFclMAAGxNR7YU5QQ1EaJEfS0TX4HhFu+5avOswF4NMl0eGDxKDEYkvDHkC +4V3o5kEGDOPCwY2KaIKybDjKsjJpM7+7fC5V8KG4n3Nzwepwq2zcXBxrdnNxrIWbS1LdXGC8L7q5 +ZDRaoIlRLCvQQBn0I6C1CFsDz4jbDu0oBjUAaGPRVIA2dF2xqGihBSSJskpVHDrIOFSyZYJpURkL +IOTRT4WePEmUOGKBy+iDRGUClKYosbeiRNxBi4xuCvQIRlVvInE7RfQmlFUo/1nF18QSrzlxcxG5 +xqMfh7jQ0JeG+pQiHBUnEqpmcIyEKJxiOHthiZhbyAtZ0c0BouDoKwoFx0RY8hpOi2tDJicR4cYR +7xu6xMhxBV7LEZNZVjGM/jD8BRBEOBF6z2CkCApgVlaYUxQ9hRFeUxRgEjTUOaI/otNMa2kQlspw +6GDRezEKmnliVgLj5UBTg8MkkwWjcgrT8cAtRBRnuMXoSOOQIEgngB+1EHS+SRySmIiCNYLmKScg +USP5yKjqwUpA1spIh3iMiJwiXEIhSPTTRKNq2EB1jQqKaxTQBBhTXaOi5hrlFlyj7IJrFOYBjosi +JIKyBNaLvh5CKKCHMKiHKO5GpBiM4PACKuEcg5qbdkRBhSDvCSIwaWQGQjQCK4ZHgog8F6hRBnMD +34OHircJoBPRaObQlGAjCmcGUgYwQUkDBRNb0KJnRLKfwLii2AtMBOLcIr1ERlGcJVDHoQU1LZkl +DJUokQ0iNVEnBgg4Hl7n0HkUVZkzUfU5UMBFDq0HHmMVMiHfqKS4YdHyAWQAMmFfRRZ1woga2MGR +0Y0gYDhJIjhBB5PMysQw4XmwylAYK6cPNlpGjxi2sCKgXiAqJfH3gdmGDjTSiZFYluxcFIQPaYmi +3sfxsuo0gxYRthIxGVUIDJvIatHhSxyR8DqPh59DhiKyioEDFEe8wgxhqVGVj+PSgLMD61HCeBLL +oH8ZGST6LOAXYLKc+l6EHAwZNw5sKw4dh1FB8dezHJIOMk+Dnz1NfNBmP3tkwc8uWPjZuQU/u6h5 +1XnNzy7qPvWZn33WFtV96hHNzz7Xtuhn51H9jxBWSyw2JHJRwBYOYzLYMvOzEwPY7GfnzH52IAST +n52Z+dmB04DOAfwAqJwHBgK0gfChps6rMoSLomcN0QAnV0RhAu/JnGKdzNoKxjYeScDUJoaBAGA0 +9DAyRKRhZAnIEpQTVbrA+WAjxE7mkBGAugRtOABuGViRsEkCacHzzEWRVyBeAFCGJxYBgioJguIj +YDmF4cObPEGLwn70yAKrRBbSxrBX1Bz24qSFsBenh71ELezF6WEv0SLsFV0Ie0UWwl68Oeyl2DeE +wnlZIFSIZlhPDdDwircRaE5ws6CskOOD+8FEyYFCZiMpwWMiQ4AwgbEz6GuYtRWgDf2caCkAaxcx +ukDeRCUHcSZE8HDAoMSYAP01wiiEg5FscoCA3eHZQk4gS0TWgcxB1zOHngMGhS0GDnji58eRMPSA +yFdpGTkB8E0SH4oi3zGv1zHaaRX58RZr7VZlVOt0WyNXe1z7q+Wu9fuDSW3SGsITd3vUGk8Go5Z7 +/Dn4G1vgFa2715u9zrn+L1T7Dxc= + + + TM + \ No newline at end of file