File: iis.html

package info (click to toggle)
libapache-mod-jk 1%3A1.2.26-2%2Blenny1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 7,768 kB
  • ctags: 4,127
  • sloc: ansic: 49,590; xml: 11,098; sh: 9,213; java: 1,920; perl: 1,004; makefile: 282; awk: 59
file content (205 lines) | stat: -rw-r--r-- 13,856 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
<html><head><META http-equiv="Content-Type" content="text/html; charset=iso-8859-1"><title>The Apache Tomcat Connector - Reference Guide - Configuring IIS</title><meta name="author" value="Mladen Turk"><meta name="email" value="mturk@apache.org"><link href="../style.css" type="text/css" rel="stylesheet"></head><body bgcolor="#ffffff" text="#000000" link="#525D76" alink="#525D76" vlink="#525D76"><table border="0" width="100%" cellspacing="4"><!--PAGE HEADER--><tr><td colspan="2"><!--TOMCAT LOGO--><a href="http://tomcat.apache.org/"><img src="../images/tomcat.gif" align="left" alt="Apache Tomcat" border="0"></a><!--APACHE LOGO--><a href="http://www.apache.org/"><img src="http://www.apache.org/images/asf-logo.gif" align="right" alt="Apache Logo" border="0"></a></td></tr><!--HEADER SEPARATOR--><tr><td colspan="2"><hr noshade="noshade" size="1"></td></tr><tr><!--LEFT SIDE NAVIGATION--><td width="20%" valign="top" nowrap="true"><p><strong>Links</strong></p><ul><li><a href="../index.html">Docs Home</a></li></ul><p><strong>Reference Guide</strong></p><ul><li><a href="../reference/workers.html">workers.properties</a></li><li><a href="../reference/uriworkermap.html">uriworkermap.properties</a></li><li><a href="../reference/status.html">Status Worker</a></li><li><a href="../reference/apache.html">Apache</a></li><li><a href="../reference/iis.html">IIS</a></li></ul><p><strong>Generic HowTo</strong></p><ul><li><a href="../generic_howto/quick.html">For the impatient</a></li><li><a href="../generic_howto/workers.html">All about workers</a></li><li><a href="../generic_howto/timeouts.html">Timeouts</a></li><li><a href="../generic_howto/loadbalancers.html">Load Balancing</a></li></ul><p><strong>Webserver HowTo</strong></p><ul><li><a href="../webserver_howto/apache.html">Apache</a></li><li><a href="../webserver_howto/iis.html">IIS</a></li><li><a href="../webserver_howto/nes.html">Netscape/SunOne/Sun</a></li></ul><p><strong>AJP Protocol Reference</strong></p><ul><li><a href="../ajp/ajpv13a.html">AJPv13</a></li><li><a href="../ajp/ajpv13ext.html">AJPv13 Extension Proposal</a></li></ul><p><strong>Miscellaneous Documentation</strong></p><ul><li><a href="../miscellaneous/faq.html">Frequently asked questions</a></li><li><a href="../miscellaneous/changelog.html">Changelog</a></li><li><a href="http://issues.apache.org/bugzilla/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=&product=Tomcat+5&component=Native%3AJK&long_desc_type=substring&long_desc=&bug_file_loc_type=allwordssubstr&bug_file_loc=&keywords_type=allwords&keywords=&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&emailassigned_to1=1&emailtype1=substring&email1=&emailassigned_to2=1&emailreporter2=1&emailcc2=1&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes=&chfieldfrom=&chfieldto=Now&chfieldvalue=&cmdtype=doit&order=Reuse+same+sort+as+last+time&field0-0-0=noop&type0-0-0=noop&value0-0-0=">Current Native:JK bugs</a></li><li><a href="../miscellaneous/doccontrib.html">Contribute documentation</a></li><li><a href="../miscellaneous/jkstatustasks.html">JK Status Ant Tasks</a></li><li><a href="../miscellaneous/reporttools.html">Reporting Tools</a></li><li><a href="http://tomcat.apache.org/connectors-doc-archive/jk2/index.html">Old JK/JK2 documentation</a></li></ul><p><strong>News</strong></p><ul><li><a href="../news/20070301.html">2007</a></li><li><a href="../news/20060101.html">2006</a></li><li><a href="../news/20050101.html">2005</a></li><li><a href="../news/20041100.html">2004</a></li></ul></td><!--RIGHT SIDE MAIN BODY--><td width="80%" valign="top" align="left"><table border="0" width="100%" cellspacing="4"><tr><td align="left" valign="top"><h1>The Apache Tomcat Connector - Reference Guide</h1><h2>Configuring IIS</h2></td><td align="right" valign="top" nowrap="true"><small><a href="printer/iis.html"><img src="../images/printer.gif" border="0" alt="Printer Friendly Version"><br>print-friendly<br>version
                    </a></small></td></tr></table><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td bgcolor="#525D76"><font color="#ffffff" face="arial,helvetica.sanserif"><a name="Requirements"><strong>Requirements</strong></a></font></td></tr><tr><td><blockquote>
<p>
The Tomcat redirector requires three entities:

<ul>
<li>
<b>isapi_redirect.dll</b> - The IIS server plugin, either obtain a pre-built DLL or build it yourself (see the build section).
</li>
<li>
<b>workers.properties</b> - A file that describes the host(s) and port(s) used by the workers (Tomcat processes). 
A sample workers.properties can be found under the conf directory.
</li>
<li>
<b>uriworkermap.properties</b> - A file that maps URL-Path patterns to workers. 
A sample uriworkermap.properties can be found under the conf directory as well.
</li>
</ul>
</p>

<p>
The installation includes the following parts:

<ul>
<li>
Configuring the ISAPI redirector with a default /examples context and checking that you can serve servlets with IIS.
</li>
<li>
Adding more contexts to the configuration.
</li>
</ul>
</p>
</blockquote></td></tr></table><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td bgcolor="#525D76"><font color="#ffffff" face="arial,helvetica.sanserif"><a name="Registry settings"><strong>Registry settings</strong></a></font></td></tr><tr><td><blockquote>
<p>
ISAPI redirector reads configuration from the registry, create a new registry key named :
</p>
<p>
<b>"HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi Redirector\1.0"</b>
</p>
<table border="1" cellpadding="5"><tr><th width="20%" bgcolor="#023264"><font color="#ffffff">Key Name</font></th><th width="80%" bgcolor="#023264"><font color="#ffffff">Description</font></th></tr><tr><td align="left" valign="center"><strong><code>extension_uri</code></strong></td><td align="left" valign="center"><p>
A string value pointing to the ISAPI extension <b>/jakarta/isapi_redirect.dll</b>
</p></td></tr><tr><td align="left" valign="center"><code>log_file</code></td><td align="left" valign="center"><p>
A value pointing to location where log file will be created.
(for example <b>c:\tomcat\logs\isapi.log</b>)
</p></td></tr><tr><td align="left" valign="center"><code>log_level</code></td><td align="left" valign="center"><p>
A string value for log level 
(can be debug, info, warn, error or trace).
</p></td></tr><tr><td align="left" valign="center"><strong><code>worker_file</code></strong></td><td align="left" valign="center"><p>
A string value which is the full path to workers.properties file
(for example <b>c:\tomcat\conf\workers.properties</b>)
</p></td></tr><tr><td align="left" valign="center"><strong><code>worker_mount_file</code></strong></td><td align="left" valign="center"><p>
A string value which is the full path to uriworkermap.properties file
(for example <b>c:\tomcat\conf\uriworkermap.properties</b>)
</p></td></tr><tr><td align="left" valign="center"><code>rewrite_rule_file</code></td><td align="left" valign="center"><p>
A string value which is the full path to rewrite.properties file
(for example <b>c:\tomcat\conf\rewrite.properties</b>)
</p></td></tr><tr><td align="left" valign="center"><code>shm_size</code></td><td align="left" valign="center"><p>
A DWORD value size of the shared memory. Set this value to be
the number of all defined workers * 400.
(Set this value only if you have <b>more</b> then <b>64</b> workers)
</p>
<p>This directive has been added in version 1.2.20</p>
</td></tr><tr><td align="left" valign="center"><code>worker_mount_reload</code></td><td align="left" valign="center"><p>
A DWORD value specifying the time in seconds upon which the
<b>worker_mount_file</b> will be reloaded.
</p>
<p>This directive has been added in version 1.2.20</p>
</td></tr><tr><td align="left" valign="center"><code>strip_session</code></td><td align="left" valign="center"><p>
A string value representing a boolean. If it is set to true,
URL session suffixes of the form ";jsessionid=..." get stripped of URLs,
even if the are served locally by the web server.
</p>
<p>
A true value can be represented by the string "1" or any string starting
with the letters "T" or "t". A false value will be assumed for "0"
or any string starting with "F" or "f". The default value is false.
</p>
<p>This directive has been added in version 1.2.21</p>
</td></tr><tr><td align="left" valign="center"><code>auth_complete</code></td><td align="left" valign="center"><p>
A DWORD value representing "0" or "1". This is needed because
of minor incompatibilities with IIS 5.1.
</p>
<p>
By default its value is 1, which means we use the SF_NOTIFY_AUTH_COMPLETE
event. If you set this to 0, then we use SF_NOTIFY_PREPROC_HEADERS.
This might be needed for IIS 5.1 when handling requests using the
PUT HTTP method.
</p>
<p>This directive has been added in version 1.2.21</p>
</td></tr><tr><td align="left" valign="center"><code>uri_select</code></td><td align="left" valign="center"><p>
A string value which influences, how URIs are decoded and reencoded
between IIS and Tomcat. You should leave this at it's default value,
unless you have a very good reason to change it.
</p>
<p>
If the value is "parsed", the forwarded URI
will be decoded and explicit path components like ".." will already
be resolved. This is less spec compliant and is <b>not safe</b>
if you are using prefix forwarding rules.
</p>
<p>
If the value is "unparsed", the forwarded URI
will be the original request URI. It's spec compliant and also
the safest option. Rewriting the URI and then forwarding the rewritten
URI will not work.
</p>
<p>
If the value is "escaped", the forwarded URI
will be the reencoded form of the URI used by "parsed".
Explicit path components like ".." will already be resolved.
This will not work in combination with URL encoded session IDs.
</p>
<p>
If the value is "proxy", the forwarded URI
will be a partially reencoded form of the URI used by "parsed".
Explicit path components like ".." will already be resolved.
and problematic are reencoded.
</p>
<p>The default value since version 1.2.24 is "proxy". Before it was "parsed".</p>
</td></tr><tr><td align="left" valign="center"><code>reject_unsafe</code></td><td align="left" valign="center"><p>
A string value representing a boolean. If it is set to true,
URLs containing percent signs '%' or backslashes '\'
after decoding will be rejected.
</p>
<p>
Most web apps do not use such URLs. By enabling "reject_unsafe" you
can block several well known URL encoding attacks.
</p>
<p>
A true value can be represented by the string "1" or any string starting
with the letters "T" or "t". A false value will be assumed for "0"
or any string starting with "F" or "f". The default value is false.
</p>
<p>This directive has been added in version 1.2.24</p>
</td></tr></table>
</blockquote></td></tr></table><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td bgcolor="#525D76"><font color="#ffffff" face="arial,helvetica.sanserif"><a name="Using a properties file for configuration"><strong>Using a properties file for configuration</strong></a></font></td></tr><tr><td><blockquote>
<p>
The ISAPI redirector can read it's configuration from a properties file instead of the registry. 
This has the advantage that you can use multiple ISAPI redirectors with independant configurations on the same server.
The redirector will check for the properties file during initialisation, and use it in preference to the registry if present.
</p>
<p>
Create a properties file in the same directory as the ISAPI redirector called <b>isapi_redirect.properties</b> i.e. with the same name as the ISAPI redirector DLL but with a <em>.properties</em> extension. A sample isapi_redirect.properties can be found under the conf directory.
</p>
<p>
The property names and values in the properties file are the same as for the registry settings described above. For example:
</p>
<p>
<div class="example"><pre>
# Configuration file for the Jakarta ISAPI Redirector

# The path to the ISAPI Redirector Extension, relative to the website
# This must be in a virtual directory with execute privileges
extension_uri=/jakarta/isapi_redirect.dll

# Full path to the log file for the ISAPI Redirector
log_file=c:\tomcat\logs\isapi_redirect.log

# Log level (debug, info, warn, error or trace)
log_level=info

# Full path to the workers.properties file
worker_file=c:\tomcat\conf\workers.properties

# Full path to the uriworkermap.properties file
worker_mount_file=c:\tomcat\conf\uriworkermap.properties
</pre></div>
</p>
<p>
    Notes: 
    <ul>
        <li>
            Back-slashes - '\' - are not escape characters.
        </li>
        <li>
            Comment lines begin with '#'.
        </li>
    </ul>
</p>
</blockquote></td></tr></table><table border="0" cellspacing="0" cellpadding="2" width="100%"><tr><td bgcolor="#525D76"><font color="#ffffff" face="arial,helvetica.sanserif"><a name="Using a simple rewrite rules"><strong>Using a simple rewrite rules</strong></a></font></td></tr><tr><td><blockquote>
<p>
The ISAPI redirector with version 1.2.16 can do a simple URL rewriting. Althought not
as powerfull as Apache Httpd's mod_rewrite, it allows a simple exchange of request uris
</p>
<p>
The rule is in the form rewritten=real-url.
</p>
<p>
The rules must be simple strings. For example:
</p>
<p>
<div class="example"><pre>
# Simple rewrite rules

/jsp/=/jsp-examples/
/servlets/=/servlets-examples/

</pre></div>
</p>
<p>
Note that the uriworkermap or mount point must point to that new rule.
</p>
</blockquote></td></tr></table></td></tr><!--FOOTER SEPARATOR--><tr><td colspan="2"><hr noshade="noshade" size="1"></td></tr><!--PAGE FOOTER--><tr><td colspan="2"><div align="center"><font color="#525D76" size="-1"><em>
        Copyright &copy; 1999-2005, Apache Software Foundation
        </em></font></div></td></tr></table></body></html>