1.1 --- a/docs/CHARSET.txt Thu Sep 02 19:32:50 2004 +0000
1.2 +++ b/docs/CHARSET.txt Thu Sep 02 19:33:10 2004 +0000
1.3 @@ -1,3 +1,12 @@
1.4 +Unicode and Character Sets in WebStack
1.5 +--------------------------------------
1.6 +
1.7 +Unicode text should be converted to the chosen character set (encoding) when
1.8 +written to the response stream.
1.9 +
1.10 +Classic Python strings are written directly to the response stream without
1.11 +encoding.
1.12 +
1.13 Character Set Semantics in WebStack
1.14 -----------------------------------
1.15
1.16 @@ -16,4 +25,24 @@
1.17 originated.
1.18
1.19 It is therefore also necessary to remain consistent in the usage of character
1.20 -sets when specifying content types.
1.21 +sets when specifying content types. WebStack enforces the following rules:
1.22 +
1.23 + * Where the request content type specifies a character set, this is used to
1.24 + decode the request body parameters unless explicitly overridden.
1.25 +
1.26 + * Where the request content type does not specify a character set, a default
1.27 + character set is used to decode the request body parameters unless
1.28 + overridden.
1.29 +
1.30 + * Where the response content type specifies a character set, this is used to
1.31 + encode Unicode response data (eg. HTML pages).
1.32 +
1.33 + * Where the response content type does not specify a character set, a default
1.34 + character set is used to encode Unicode response data (eg. HTML pages).
1.35 +
1.36 +Framework Behaviour
1.37 +-------------------
1.38 +
1.39 +The Java Servlet API imposes restrictions on decoding request body parameters
1.40 +by stating that the character encoding (ServletRequest.setCharacterEncoding)
1.41 +must be set before any reading of the request body is attempted.
2.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2.2 +++ b/docs/LICENCE-PyServlet.txt Thu Sep 02 19:33:10 2004 +0000
2.3 @@ -0,0 +1,147 @@
2.4 +The modified PyServlet class included with WebStack is covered by copyrights
2.5 +and the licence of the Jython project and is reproduced below.
2.6 +
2.7 +HISTORY OF THE SOFTWARE
2.8 +=======================
2.9 +
2.10 +JPython was created in late 1997 by Jim Hugunin. Jim was also the
2.11 +primary developer while he was at CNRI. In February 1999 Barry Warsaw
2.12 +took over as primary developer and released JPython version 1.1.
2.13 +In October 2000 Barry helped move the software to SourceForge
2.14 +where it was renamed to Jython. Jython 2.0 is developed by a group
2.15 +of volunteers.
2.16 +
2.17 +
2.18 +The standard library is covered by the BeOpen / CNRI license. See the
2.19 +Lib/LICENSE file for details.
2.20 +
2.21 +The oro regular expresion matcher is covered by the apache license.
2.22 +See the org/apache/LICENSE file for details.
2.23 +
2.24 +The zxJDBC package was written by Brian Zimmer and originally licensed
2.25 +under the GNU Public License. The package is now covered by the Jython
2.26 +Software License.
2.27 +
2.28 +Jython changes Software License.
2.29 +================================
2.30 +
2.31 +Copyright (c) 2000, Jython Developers
2.32 +All rights reserved.
2.33 +
2.34 +Redistribution and use in source and binary forms, with or without
2.35 +modification, are permitted provided that the following conditions
2.36 +are met:
2.37 +
2.38 + - Redistributions of source code must retain the above copyright
2.39 + notice, this list of conditions and the following disclaimer.
2.40 +
2.41 + - Redistributions in binary form must reproduce the above copyright
2.42 + notice, this list of conditions and the following disclaimer in
2.43 + the documentation and/or other materials provided with the distribution.
2.44 +
2.45 + - Neither the name of the Jython Developers nor the names of
2.46 + its contributors may be used to endorse or promote products
2.47 + derived from this software without specific prior written permission.
2.48 +
2.49 +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
2.50 +``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
2.51 +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
2.52 +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR
2.53 +CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
2.54 +EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
2.55 +PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
2.56 +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
2.57 +OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
2.58 +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
2.59 +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2.60 +
2.61 +
2.62 +
2.63 +
2.64 +JPython Software License.
2.65 +=========================
2.66 +
2.67 +______________________________________________________________________
2.68 +
2.69 +IMPORTANT: PLEASE READ THE FOLLOWING AGREEMENT CAREFULLY.
2.70 +
2.71 +BY CLICKING ON THE "ACCEPT" BUTTON WHERE INDICATED, OR BY INSTALLING,
2.72 +COPYING OR OTHERWISE USING THE SOFTWARE, YOU ARE DEEMED TO HAVE AGREED TO
2.73 +THE TERMS AND CONDITIONS OF THIS AGREEMENT.
2.74 +
2.75 +______________________________________________________________________
2.76 +
2.77 +JPython version 1.1.x
2.78 +
2.79 + 1. This LICENSE AGREEMENT is between the Corporation for National Research
2.80 + Initiatives, having an office at 1895 Preston White Drive, Reston, VA
2.81 + 20191 ("CNRI"), and the Individual or Organization ("Licensee")
2.82 + accessing and using JPython version 1.1.x in source or binary form and
2.83 + its associated documentation as provided herein ("Software").
2.84 +
2.85 + 2. Subject to the terms and conditions of this License Agreement, CNRI
2.86 + hereby grants Licensee a non-exclusive, non-transferable, royalty-free,
2.87 + world-wide license to reproduce, analyze, test, perform and/or display
2.88 + publicly, prepare derivative works, distribute, and otherwise use the
2.89 + Software alone or in any derivative version, provided, however, that
2.90 + CNRI's License Agreement and CNRI's notice of copyright, i.e.,
2.91 + "Copyright ©1996-1999 Corporation for National Research Initiatives;
2.92 + All Rights Reserved" are both retained in the Software, alone or in any
2.93 + derivative version prepared by Licensee.
2.94 +
2.95 + Alternatively, in lieu of CNRI's License Agreement, Licensee may
2.96 + substitute the following text (omitting the quotes), provided, however,
2.97 + that such text is displayed prominently in the Software alone or in any
2.98 + derivative version prepared by Licensee: "JPython (Version 1.1.x) is
2.99 + made available subject to the terms and conditions in CNRI's License
2.100 + Agreement. This Agreement may be located on the Internet using the
2.101 + following unique, persistent identifier (known as a handle):
2.102 + 1895.22/1006. The License may also be obtained from a proxy server on
2.103 + the Web using the following URL: http://hdl.handle.net/1895.22/1006."
2.104 +
2.105 + 3. In the event Licensee prepares a derivative work that is based on or
2.106 + incorporates the Software or any part thereof, and wants to make the
2.107 + derivative work available to the public as provided herein, then
2.108 + Licensee hereby agrees to indicate in any such work, in a prominently
2.109 + visible way, the nature of the modifications made to CNRI's Software.
2.110 +
2.111 + 4. Licensee may not use CNRI trademarks or trade name, including JPython
2.112 + or CNRI, in a trademark sense to endorse or promote products or
2.113 + services of Licensee, or any third party. Licensee may use the mark
2.114 + JPython in connection with Licensee's derivative versions that are
2.115 + based on or incorporate the Software, but only in the form
2.116 + "JPython-based ___________________," or equivalent.
2.117 +
2.118 + 5. CNRI is making the Software available to Licensee on an "AS IS" basis.
2.119 + CNRI MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED. BY WAY
2.120 + OF EXAMPLE, BUT NOT LIMITATION, CNRI MAKES NO AND DISCLAIMS ANY
2.121 + REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS FOR ANY
2.122 + PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE WILL NOT INFRINGE
2.123 + ANY THIRD PARTY RIGHTS.
2.124 +
2.125 + 6. CNRI SHALL NOT BE LIABLE TO LICENSEE OR OTHER USERS OF THE SOFTWARE FOR
2.126 + ANY INCIDENTAL, SPECIAL OR CONSEQUENTIAL DAMAGES OR LOSS AS A RESULT OF
2.127 + USING, MODIFYING OR DISTRIBUTING THE SOFTWARE, OR ANY DERIVATIVE
2.128 + THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. SOME STATES DO NOT
2.129 + ALLOW THE LIMITATION OR EXCLUSION OF LIABILITY SO THE ABOVE DISCLAIMER
2.130 + MAY NOT APPLY TO LICENSEE.
2.131 +
2.132 + 7. This License Agreement may be terminated by CNRI (i) immediately upon
2.133 + written notice from CNRI of any material breach by the Licensee, if the
2.134 + nature of the breach is such that it cannot be promptly remedied; or
2.135 + (ii) sixty (60) days following notice from CNRI to Licensee of a
2.136 + material remediable breach, if Licensee has not remedied such breach
2.137 + within that sixty-day period.
2.138 +
2.139 + 8. This License Agreement shall be governed by and interpreted in all
2.140 + respects by the law of the State of Virginia, excluding conflict of law
2.141 + provisions. Nothing in this Agreement shall be deemed to create any
2.142 + relationship of agency, partnership, or joint venture between CNRI and
2.143 + Licensee.
2.144 +
2.145 + 9. By clicking on the "ACCEPT" button where indicated, or by installing,
2.146 + copying or otherwise using the Software, Licensee agrees to be bound by
2.147 + the terms and conditions of this License Agreement.
2.148 +
2.149 + [ACCEPT BUTTON]
2.150 +