]> granicus.if.org Git - apache/blob - docs/conf/httpd-win.conf
remove bogus content type overrides from the default config
[apache] / docs / conf / httpd-win.conf
1 #
2 # Based upon the NCSA server configuration files originally by Rob McCool.
3 #
4 # This is the main Apache server configuration file.  It contains the
5 # configuration directives that give the server its instructions.
6 # See <URL:http://httpd.apache.org/docs-2.1/> for detailed information about
7 # the directives.
8 #
9 # Do NOT simply read the instructions in here without understanding
10 # what they do.  They're here only as hints or reminders.  If you are unsure
11 # consult the online docs. You have been warned.  
12 #
13 # The configuration directives are grouped into three basic sections:
14 #  1. Directives that control the operation of the Apache server process as a
15 #     whole (the 'global environment').
16 #  2. Directives that define the parameters of the 'main' or 'default' server,
17 #     which responds to requests that aren't handled by a virtual host.
18 #     These directives also provide default values for the settings
19 #     of all virtual hosts.
20 #  3. Settings for virtual hosts, which allow Web requests to be sent to
21 #     different IP addresses or hostnames and have them handled by the
22 #     same Apache server process.
23 #
24 # Configuration and logfile names: If the filenames you specify for many
25 # of the server's control files begin with "/" (or "drive:/" for Win32), the
26 # server will use that explicit path.  If the filenames do *not* begin
27 # with "/", the value of ServerRoot is prepended -- so "logs/foo.log"
28 # with ServerRoot set to "@@ServerRoot@@" will be interpreted by the
29 # server as "@@ServerRoot@@/logs/foo.log".
30 #
31 # NOTE: Where filenames are specified, you must use forward slashes
32 # instead of backslashes (e.g., "c:/apache" instead of "c:\apache").
33 # If a drive letter is omitted, the drive on which Apache.exe is located
34 # will be used by default.  It is recommended that you always supply
35 # an explicit drive letter in absolute paths, however, to avoid
36 # confusion.
37 #
38
39 ### Section 1: Global Environment
40 #
41 # The directives in this section affect the overall operation of Apache,
42 # such as the number of concurrent requests it can handle or where it
43 # can find its configuration files.
44 #
45
46 #
47 # ServerRoot: The top of the directory tree under which the server's
48 # configuration, error, and log files are kept.
49 #
50 # NOTE!  If you intend to place this on an NFS (or otherwise network)
51 # mounted filesystem then please read the LockFile documentation (available
52 # at <URL:http://httpd.apache.org/docs-2.1/mod/mpm_common.html#lockfile>);
53 # you will save yourself a lot of trouble.
54 #
55 # Do NOT add a slash at the end of the directory path.
56 #
57 ServerRoot "@@ServerRoot@@"
58
59 #
60 # ScoreBoardFile: File used to store internal server process information.
61 # If unspecified (the default), the scoreboard will be stored in an
62 # anonymous shared memory segment, and will be unavailable to third-party
63 # applications.
64 # If specified, ensure that no two invocations of Apache share the same
65 # scoreboard file. The scoreboard file MUST BE STORED ON A LOCAL DISK.
66 #
67 #ScoreBoardFile logs/apache_runtime_status
68
69 #
70 # PidFile: The file in which the server should record its process
71 # identification number when it starts.
72 #
73 PidFile logs/httpd.pid
74
75 #
76 # Timeout: The number of seconds before receives and sends time out.
77 #
78 Timeout 300
79
80 #
81 # KeepAlive: Whether or not to allow persistent connections (more than
82 # one request per connection). Set to "Off" to deactivate.
83 #
84 KeepAlive On
85
86 #
87 # MaxKeepAliveRequests: The maximum number of requests to allow
88 # during a persistent connection. Set to 0 to allow an unlimited amount.
89 # We recommend you leave this number high, for maximum performance.
90 #
91 MaxKeepAliveRequests 100
92
93 #
94 # KeepAliveTimeout: Number of seconds to wait for the next request from the
95 # same client on the same connection.
96 #
97 KeepAliveTimeout 15
98
99 ##
100 ## Server-Pool Size Regulation (MPM specific)
101 ## 
102
103 # WinNT MPM
104 # ThreadsPerChild: constant number of worker threads in the server process
105 # MaxRequestsPerChild: maximum  number of requests a server process serves
106 <IfModule mpm_winnt.c>
107 ThreadsPerChild 250
108 MaxRequestsPerChild  0
109 </IfModule>
110
111 #
112 # Listen: Allows you to bind Apache to specific IP addresses and/or
113 # ports, instead of the default. See also the <VirtualHost>
114 # directive.
115 #
116 # Change this to Listen on specific IP addresses as shown below to 
117 # prevent Apache from glomming onto all bound IP addresses (0.0.0.0)
118 #
119 #Listen 12.34.56.78:80
120 Listen @@Port@@
121
122 #
123 # Dynamic Shared Object (DSO) Support
124 #
125 # To be able to use the functionality of a module which was built as a DSO you
126 # have to place corresponding `LoadModule' lines at this location so the
127 # directives contained in it are actually available _before_ they are used.
128 # Statically compiled modules (those listed by `httpd -l') do not need
129 # to be loaded here.
130 #
131 # Example:
132 # LoadModule foo_module modules/mod_foo.so
133 #
134 LoadModule actions_module modules/mod_actions.so
135 LoadModule alias_module modules/mod_alias.so
136 LoadModule asis_module modules/mod_asis.so
137 LoadModule auth_basic_module modules/mod_auth_basic.so
138 #LoadModule auth_digest_module modules/mod_auth_digest.so
139 #LoadModule authn_anon_module modules/mod_authn_anon.so
140 #LoadModule authn_dbm_module modules/mod_authn_dbm.so
141 LoadModule authn_default_module modules/mod_authn_default.so
142 LoadModule authn_file_module modules/mod_authn_file.so
143 #LoadModule authz_dbm_module modules/mod_authz_dbm.so
144 LoadModule authz_default_module modules/mod_authz_default.so
145 LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
146 LoadModule authz_host_module modules/mod_authz_host.so
147 LoadModule authz_user_module modules/mod_authz_user.so
148 LoadModule autoindex_module modules/mod_autoindex.so
149 #LoadModule cern_meta_module modules/mod_cern_meta.so
150 LoadModule cgi_module modules/mod_cgi.so
151 #LoadModule dav_module modules/mod_dav.so
152 #LoadModule dav_fs_module modules/mod_dav_fs.so
153 LoadModule dir_module modules/mod_dir.so
154 LoadModule env_module modules/mod_env.so
155 #LoadModule expires_module modules/mod_expires.so
156 #LoadModule file_cache_module modules/mod_file_cache.so
157 #LoadModule headers_module modules/mod_headers.so
158 LoadModule imap_module modules/mod_imap.so
159 LoadModule include_module modules/mod_include.so
160 #LoadModule info_module modules/mod_info.so
161 LoadModule isapi_module modules/mod_isapi.so
162 LoadModule log_config_module modules/mod_log_config.so
163 LoadModule mime_module modules/mod_mime.so
164 #LoadModule mime_magic_module modules/mod_mime_magic.so
165 #LoadModule proxy_module modules/mod_proxy.so
166 #LoadModule proxy_connect_module modules/mod_proxy_connect.so
167 #LoadModule proxy_http_module modules/mod_proxy_http.so
168 #LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
169 LoadModule negotiation_module modules/mod_negotiation.so
170 #LoadModule rewrite_module modules/mod_rewrite.so
171 LoadModule setenvif_module modules/mod_setenvif.so
172 #LoadModule speling_module modules/mod_speling.so
173 #LoadModule status_module modules/mod_status.so
174 #LoadModule unique_id_module modules/mod_unique_id.so
175 LoadModule userdir_module modules/mod_userdir.so
176 #LoadModule usertrack_module modules/mod_usertrack.so
177 #LoadModule vhost_alias_module modules/mod_vhost_alias.so
178 #LoadModule ssl_module modules/mod_ssl.so
179
180 #
181 # ExtendedStatus controls whether Apache will generate "full" status
182 # information (ExtendedStatus On) or just basic information (ExtendedStatus
183 # Off) when the "server-status" handler is called. The default is Off.
184 #
185 #ExtendedStatus On
186
187 ### Section 2: 'Main' server configuration
188 #
189 # The directives in this section set up the values used by the 'main'
190 # server, which responds to any requests that aren't handled by a
191 # <VirtualHost> definition.  These values also provide defaults for
192 # any <VirtualHost> containers you may define later in the file.
193 #
194 # All of these directives may appear inside <VirtualHost> containers,
195 # in which case these default settings will be overridden for the
196 # virtual host being defined.
197 #
198
199 #
200 # ServerAdmin: Your address, where problems with the server should be
201 # e-mailed.  This address appears on some server-generated pages, such
202 # as error documents.  e.g. admin@your-domain.com
203 #
204 ServerAdmin @@ServerAdmin@@
205
206 #
207 # ServerName gives the name and port that the server uses to identify itself.
208 # This can often be determined automatically, but we recommend you specify
209 # it explicitly to prevent problems during startup.
210 #
211 # If this is not set to valid DNS name for your host, server-generated
212 # redirections will not work.  See also the UseCanonicalName directive.
213 #
214 # If your host doesn't have a registered DNS name, enter its IP address here.
215 # You will have to access it by its address anyway, and this will make 
216 # redirections work in a sensible way.
217 #
218 ServerName @@ServerName@@:@@Port@@
219
220 #
221 # UseCanonicalName: Determines how Apache constructs self-referencing 
222 # URLs and the SERVER_NAME and SERVER_PORT variables.
223 # When set "Off", Apache will use the Hostname and Port supplied
224 # by the client.  When set "On", Apache will use the value of the
225 # ServerName directive.
226 #
227 UseCanonicalName Off
228
229 #
230 # DocumentRoot: The directory out of which you will serve your
231 # documents. By default, all requests are taken from this directory, but
232 # symbolic links and aliases may be used to point to other locations.
233 #
234 DocumentRoot "@@ServerRoot@@/htdocs"
235
236 #
237 # Each directory to which Apache has access can be configured with respect
238 # to which services and features are allowed and/or disabled in that
239 # directory (and its subdirectories). 
240 #
241 # First, we configure the "default" to be a very restrictive set of 
242 # features.  
243 #
244 <Directory />
245     Options FollowSymLinks
246     AllowOverride None
247 </Directory>
248
249 #
250 # Note that from this point forward you must specifically allow
251 # particular features to be enabled - so if something's not working as
252 # you might expect, make sure that you have specifically enabled it
253 # below.
254 #
255
256 #
257 # This should be changed to whatever you set DocumentRoot to.
258 #
259 <Directory "@@ServerRoot@@/htdocs">
260
261 #
262 # Possible values for the Options directive are "None", "All",
263 # or any combination of:
264 #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
265 #
266 # Note that "MultiViews" must be named *explicitly* --- "Options All"
267 # doesn't give it to you.
268 #
269 # The Options directive is both complicated and important.  Please see
270 # http://httpd.apache.org/docs-2.1/mod/core.html#options
271 # for more information.
272 #
273     Options Indexes FollowSymLinks
274
275 #
276 # AllowOverride controls what directives may be placed in .htaccess files.
277 # It can be "All", "None", or any combination of the keywords:
278 #   Options FileInfo AuthConfig Limit
279 #
280     AllowOverride None
281
282 #
283 # Controls who can get stuff from this server.
284 #
285     Order allow,deny
286     Allow from all
287
288 </Directory>
289
290 #
291 # UserDir: The name of the directory that is appended onto a user's home
292 # directory if a ~user request is received.  Be especially careful to use
293 # proper, forward slashes here.  On Windows NT, "Personal/My Website"
294 # is a more appropriate choice.
295 #
296 UserDir "My Documents/My Website"
297
298 #
299 # Control access to UserDir directories.  The following is an example
300 # for a site where these directories are restricted to read-only.
301 #
302 # You must correct the path for the root to match your system's configured
303 # user directory location, e.g. "C:/WinNT/profiles/*/My Documents/My Website"
304 # or whichever, as appropriate.
305 #
306 #<Directory "C:/Documents and Settings/*/My Documents/My Website">
307 #    AllowOverride FileInfo AuthConfig Limit
308 #    Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
309 #    <Limit GET POST OPTIONS PROPFIND>
310 #        Order allow,deny
311 #        Allow from all
312 #    </Limit>
313 #    <LimitExcept GET POST OPTIONS PROPFIND>
314 #        Order deny,allow
315 #        Deny from all
316 #    </LimitExcept>
317 #</Directory>
318
319 #
320 # DirectoryIndex: sets the file that Apache will serve if a directory
321 # is requested.
322 #
323 # The index.html.var file (a type-map) is used to deliver content-
324 # negotiated documents.  The MultiViews Option can be used for the 
325 # same purpose, but it is much slower.
326 #
327 DirectoryIndex index.html index.html.var
328
329 #
330 # AccessFileName: The name of the file to look for in each directory
331 # for additional configuration directives.  See also the AllowOverride 
332 # directive.
333 #
334 AccessFileName .htaccess
335
336 #
337 # The following lines prevent .htaccess and .htpasswd files from being 
338 # viewed by Web clients. 
339 #
340 <Files ~ "^\.ht">
341     Order allow,deny
342     Deny from all
343 </Files>
344
345 #
346 # TypesConfig describes where the mime.types file (or equivalent) is
347 # to be found.
348 #
349 TypesConfig conf/mime.types
350
351 #
352 # DefaultType is the default MIME type the server will use for a document
353 # if it cannot otherwise determine one, such as from filename extensions.
354 # If your server contains mostly text or HTML documents, "text/plain" is
355 # a good value.  If most of your content is binary, such as applications
356 # or images, you may want to use "application/octet-stream" instead to
357 # keep browsers from trying to display binary files as though they are
358 # text.
359 #
360 DefaultType text/plain
361
362 #
363 # The mod_mime_magic module allows the server to use various hints from the
364 # contents of the file itself to determine its type.  The MIMEMagicFile
365 # directive tells the module where the hint definitions are located.
366 #
367 <IfModule mod_mime_magic.c>
368     MIMEMagicFile conf/magic
369 </IfModule>
370
371 #
372 # HostnameLookups: Log the names of clients or just their IP addresses
373 # e.g., www.apache.org (on) or 204.62.129.132 (off).
374 # The default is off because it'd be overall better for the net if people
375 # had to knowingly turn this feature on, since enabling it means that
376 # each client request will result in AT LEAST one lookup request to the
377 # nameserver.
378 #
379 HostnameLookups Off
380
381 #
382 # EnableMMAP: Control whether memory-mapping is used to deliver
383 # files (assuming that the underlying OS supports it).
384 # The default is on; turn this off if you serve from NFS-mounted 
385 # filesystems.  On some systems, turning it off (regardless of
386 # filesystem) can improve performance; for details, please see
387 # http://httpd.apache.org/docs-2.1/mod/core.html#enablemmap
388 #
389 #EnableMMAP off
390
391 #
392 # EnableSendfile: Control whether the sendfile kernel support is 
393 # used  to deliver files (assuming that the OS supports it).
394 # The default is on; turn this off if you serve from NFS-mounted 
395 # filesystems.  Please see
396 # http://httpd.apache.org/docs-2.1/mod/core.html#enablesendfile
397 #
398 #EnableSendfile off
399
400 #
401 # ErrorLog: The location of the error log file.
402 # If you do not specify an ErrorLog directive within a <VirtualHost>
403 # container, error messages relating to that virtual host will be
404 # logged here.  If you *do* define an error logfile for a <VirtualHost>
405 # container, that host's errors will be logged there and not here.
406 #
407 ErrorLog logs/error.log
408
409 #
410 # LogLevel: Control the number of messages logged to the error.log.
411 # Possible values include: debug, info, notice, warn, error, crit,
412 # alert, emerg.
413 #
414 LogLevel warn
415
416 #
417 # The following directives define some format nicknames for use with
418 # a CustomLog directive (see below).
419 #
420 LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
421 LogFormat "%h %l %u %t \"%r\" %>s %b" common
422 LogFormat "%{Referer}i -> %U" referer
423 LogFormat "%{User-agent}i" agent
424
425 # You need to enable mod_logio.c to use %I and %O
426 #LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
427
428 #
429 # The location and format of the access logfile (Common Logfile Format).
430 # If you do not define any access logfiles within a <VirtualHost>
431 # container, they will be logged here.  Contrariwise, if you *do*
432 # define per-<VirtualHost> access logfiles, transactions will be
433 # logged therein and *not* in this file.
434 #
435 CustomLog logs/access.log common
436
437 #
438 # If you would like to have agent and referer logfiles, uncomment the
439 # following directives.
440 #
441 #CustomLog logs/referer.log referer
442 #CustomLog logs/agent.log agent
443
444 #
445 # If you prefer a single logfile with access, agent, and referer information
446 # (Combined Logfile Format) you can use the following directive.
447 #
448 #CustomLog logs/access.log combined
449
450 #
451 # ServerTokens
452 # This directive configures what you return as the Server HTTP response
453 # Header. The default is 'Full' which sends information about the OS-Type
454 # and compiled in modules.
455 # Set to one of:  Full | OS | Minor | Minimal | Major | Prod
456 # where Full conveys the most information, and Prod the least.
457 #
458 ServerTokens Full
459
460 #
461 # Optionally add a line containing the server version and virtual host
462 # name to server-generated pages (internal error documents, FTP directory 
463 # listings, mod_status and mod_info output etc., but not CGI generated 
464 # documents or custom error documents).
465 # Set to "EMail" to also include a mailto: link to the ServerAdmin.
466 # Set to one of:  On | Off | EMail
467 #
468 ServerSignature On
469
470 #
471 # Aliases: Add here as many aliases as you need (with no limit). The format is 
472 # Alias fakename realname
473 #
474 # Note that if you include a trailing / on fakename then the server will
475 # require it to be present in the URL.  So "/icons" isn't aliased in this
476 # example, only "/icons/".  If the fakename is slash-terminated, then the 
477 # realname must also be slash terminated, and if the fakename omits the 
478 # trailing slash, the realname must also omit it.
479 #
480 # We include the /icons/ alias for FancyIndexed directory listings.  If you
481 # do not use FancyIndexing, you may comment this out.
482 #
483 Alias /icons/ "@@ServerRoot@@/icons/"
484
485 <Directory "@@ServerRoot@@/icons">
486     Options Indexes MultiViews
487     AllowOverride None
488     Order allow,deny
489     Allow from all
490 </Directory>
491
492 #
493 # This should be changed to the ServerRoot/manual/.  The alias provides
494 # the manual, even if you choose to move your DocumentRoot.  You may comment
495 # this out if you do not care for the documentation.
496 #
497 AliasMatch ^/manual(?:/(?:de|en|fr|ja|ko|ru))?(/.*)?$ "@@ServerRoot@@/manual$1"
498
499 <Directory "@@ServerRoot@@/manual">
500     Options Indexes
501     AllowOverride None
502     Order allow,deny
503     Allow from all
504
505     <Files *.html>
506         SetHandler type-map
507     </Files>
508
509     SetEnvIf Request_URI ^/manual/(de|en|fr|ja|ko|ru)/ prefer-language=$1
510     RedirectMatch 301 ^/manual(?:/(de|en|fr|ja|ko|ru)){2,}(/.*)?$ /manual/$1$2
511 </Directory>
512
513 #
514 # ScriptAlias: This controls which directories contain server scripts.
515 # ScriptAliases are essentially the same as Aliases, except that
516 # documents in the realname directory are treated as applications and
517 # run by the server when requested rather than as documents sent to the client.
518 # The same rules about trailing "/" apply to ScriptAlias directives as to
519 # Alias.
520 #
521 ScriptAlias /cgi-bin/ "@@ServerRoot@@/cgi-bin/"
522
523 #
524 # "@@ServerRoot@@/cgi-bin" should be changed to whatever your ScriptAliased
525 # CGI directory exists, if you have that configured.
526 #
527 <Directory "@@ServerRoot@@/cgi-bin">
528     AllowOverride None
529     Options None
530     Order allow,deny
531     Allow from all
532 </Directory>
533
534 #
535 # Redirect allows you to tell clients about documents which used to exist in
536 # your server's namespace, but do not anymore. This allows you to tell the
537 # clients where to look for the relocated document.
538 # Example:
539 # Redirect permanent /foo http://www.example.com/bar
540
541 #
542 # Directives controlling the display of server-generated directory listings.
543 #
544
545 #
546 # IndexOptions: Controls the appearance of server-generated directory
547 # listings.
548 #
549 IndexOptions FancyIndexing VersionSort
550
551 #
552 # AddIcon* directives tell the server which icon to show for different
553 # files or filename extensions.  These are only displayed for
554 # FancyIndexed directories.
555 #
556 AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip
557
558 AddIconByType (TXT,/icons/text.gif) text/*
559 AddIconByType (IMG,/icons/image2.gif) image/*
560 AddIconByType (SND,/icons/sound2.gif) audio/*
561 AddIconByType (VID,/icons/movie.gif) video/*
562
563 AddIcon /icons/binary.gif .bin .exe
564 AddIcon /icons/binhex.gif .hqx
565 AddIcon /icons/tar.gif .tar
566 AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv
567 AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip
568 AddIcon /icons/a.gif .ps .ai .eps
569 AddIcon /icons/layout.gif .html .shtml .htm .pdf
570 AddIcon /icons/text.gif .txt
571 AddIcon /icons/c.gif .c
572 AddIcon /icons/p.gif .pl .py
573 AddIcon /icons/f.gif .for
574 AddIcon /icons/dvi.gif .dvi
575 AddIcon /icons/uuencoded.gif .uu
576 AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl
577 AddIcon /icons/tex.gif .tex
578 AddIcon /icons/bomb.gif core
579
580 AddIcon /icons/back.gif ..
581 AddIcon /icons/hand.right.gif README
582 AddIcon /icons/folder.gif ^^DIRECTORY^^
583 AddIcon /icons/blank.gif ^^BLANKICON^^
584
585 #
586 # DefaultIcon is which icon to show for files which do not have an icon
587 # explicitly set.
588 #
589 DefaultIcon /icons/unknown.gif
590
591 #
592 # AddDescription allows you to place a short description after a file in
593 # server-generated indexes.  These are only displayed for FancyIndexed
594 # directories.
595 # Format: AddDescription "description" filename
596 #
597 #AddDescription "GZIP compressed document" .gz
598 #AddDescription "tar archive" .tar
599 #AddDescription "GZIP compressed tar archive" .tgz
600
601 #
602 # ReadmeName is the name of the README file the server will look for by
603 # default, and append to directory listings.
604 #
605 # HeaderName is the name of a file which should be prepended to
606 # directory indexes. 
607 ReadmeName README.html
608 HeaderName HEADER.html
609
610 #
611 # IndexIgnore is a set of filenames which directory indexing should ignore
612 # and not include in the listing.  Shell-style wildcarding is permitted.
613 #
614 IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t
615
616 #
617 # AddEncoding allows you to have certain browsers (Mosaic/X 2.1+) uncompress
618 # information on the fly. Note: Not all browsers support this.
619 # Despite the name similarity, the following Add* directives have nothing
620 # to do with the FancyIndexing customization directives above.
621 #
622 #AddEncoding x-compress Z
623 #AddEncoding x-gzip gz tgz
624
625 #
626 # DefaultLanguage and AddLanguage allows you to specify the language of 
627 # a document. You can then use content negotiation to give a browser a 
628 # file in a language the user can understand.
629 #
630 # Specify a default language. This means that all data
631 # going out without a specific language tag (see below) will 
632 # be marked with this one. You probably do NOT want to set
633 # this unless you are sure it is correct for all cases.
634 #
635 # * It is generally better to not mark a page as 
636 # * being a certain language than marking it with the wrong
637 # * language!
638 #
639 # DefaultLanguage nl
640 #
641 # Note 1: The suffix does not have to be the same as the language
642 # keyword --- those with documents in Polish (whose net-standard
643 # language code is pl) may wish to use "AddLanguage pl .po" to
644 # avoid the ambiguity with the common suffix for perl scripts.
645 #
646 # Note 2: The example entries below illustrate that in some cases 
647 # the two character 'Language' abbreviation is not identical to 
648 # the two character 'Country' code for its country,
649 # E.g. 'Danmark/dk' versus 'Danish/da'.
650 #
651 # Note 3: In the case of 'ltz' we violate the RFC by using a three char
652 # specifier. There is 'work in progress' to fix this and get
653 # the reference data for rfc1766 cleaned up.
654 #
655 # Danish (da) - Dutch (nl) - English (en) - Estonian (et)
656 # French (fr) - German (de) - Greek-Modern (el)
657 # Italian (it) - Norwegian (no) - Norwegian Nynorsk (nn) - Korean (ko)
658 # Portugese (pt) - Luxembourgeois* (ltz)
659 # Spanish (es) - Swedish (sv) - Catalan (ca) - Czech(cs)
660 # Polish (pl) - Brazilian Portuguese (pt-br) - Japanese (ja)
661 # Russian (ru) - Croatian (hr)
662 #
663 AddLanguage da .dk
664 AddLanguage nl .nl
665 AddLanguage en .en
666 AddLanguage et .et
667 AddLanguage fr .fr
668 AddLanguage de .de
669 AddLanguage he .he
670 AddLanguage el .el
671 AddLanguage it .it
672 AddLanguage ja .ja
673 AddLanguage pl .po
674 AddLanguage ko .ko
675 AddLanguage pt .pt
676 AddLanguage nn .nn
677 AddLanguage no .no
678 AddLanguage pt-br .pt-br
679 AddLanguage ltz .ltz
680 AddLanguage ca .ca
681 AddLanguage es .es
682 AddLanguage sv .sv
683 AddLanguage cs .cz .cs
684 AddLanguage ru .ru
685 AddLanguage zh-CN .zh-cn
686 AddLanguage zh-TW .zh-tw
687 AddLanguage hr .hr
688
689 #
690 # LanguagePriority allows you to give precedence to some languages
691 # in case of a tie during content negotiation.
692 #
693 # Just list the languages in decreasing order of preference. We have
694 # more or less alphabetized them here. You probably want to change this.
695 #
696 LanguagePriority en da nl et fr de el it ja ko no pl pt pt-br ltz ca es sv tw
697
698 #
699 # ForceLanguagePriority allows you to serve a result page rather than
700 # MULTIPLE CHOICES (Prefer) [in case of a tie] or NOT ACCEPTABLE (Fallback)
701 # [in case no accepted languages matched the available variants]
702 #
703 ForceLanguagePriority Prefer Fallback
704
705 #
706 # Specify a default charset for all pages sent out. This is
707 # always a good idea and opens the door for future internationalisation
708 # of your web site, should you ever want it. Specifying it as
709 # a default does little harm; as the standard dictates that a page
710 # is in iso-8859-1 (latin1) unless specified otherwise i.e. you
711 # are merely stating the obvious. There are also some security
712 # reasons in browsers, related to javascript and URL parsing
713 # which encourage you to always set a default char set.
714 #
715 AddDefaultCharset ISO-8859-1
716
717 #
718 # Commonly used filename extensions to character sets. You probably
719 # want to avoid clashes with the language extensions, unless you
720 # are good at carefully testing your setup after each change.
721 # See http://www.iana.org/assignments/character-sets for the
722 # official list of charset names and their respective RFCs.
723 #
724 AddCharset ISO-8859-1  .iso8859-1 .latin1
725 AddCharset ISO-8859-2  .iso8859-2 .latin2 .cen
726 AddCharset ISO-8859-3  .iso8859-3 .latin3
727 AddCharset ISO-8859-4  .iso8859-4 .latin4
728 AddCharset ISO-8859-5  .iso8859-5 .latin5 .cyr .iso-ru
729 AddCharset ISO-8859-6  .iso8859-6 .latin6 .arb
730 AddCharset ISO-8859-7  .iso8859-7 .latin7 .grk
731 AddCharset ISO-8859-8  .iso8859-8 .latin8 .heb
732 AddCharset ISO-8859-9  .iso8859-9 .latin9 .trk
733 AddCharset ISO-2022-JP .iso2022-jp .jis
734 AddCharset ISO-2022-KR .iso2022-kr .kis
735 AddCharset ISO-2022-CN .iso2022-cn .cis
736 AddCharset Big5        .Big5       .big5
737 # For russian, more than one charset is used (depends on client, mostly):
738 AddCharset WINDOWS-1251 .cp-1251   .win-1251
739 AddCharset CP866       .cp866
740 AddCharset KOI8-r      .koi8-r .koi8-ru
741 AddCharset KOI8-ru     .koi8-uk .ua
742 AddCharset ISO-10646-UCS-2 .ucs2
743 AddCharset ISO-10646-UCS-4 .ucs4
744 AddCharset UTF-8       .utf8
745
746 # The set below does not map to a specific (iso) standard
747 # but works on a fairly wide range of browsers. Note that
748 # capitalization actually matters (it should not, but it
749 # does for some browsers).
750 #
751 # See http://www.iana.org/assignments/character-sets
752 # for a list of sorts. But browsers support few.
753 #
754 AddCharset GB2312      .gb2312 .gb 
755 AddCharset utf-7       .utf7
756 AddCharset utf-8       .utf8
757 AddCharset big5        .big5 .b5
758 AddCharset EUC-TW      .euc-tw
759 AddCharset EUC-JP      .euc-jp
760 AddCharset EUC-KR      .euc-kr
761 AddCharset shift_jis   .sjis
762
763 #
764 # AddType allows you to add to or override the MIME configuration
765 # file mime.types for specific file types.
766 #
767 #AddType application/x-gzip .tgz
768 #AddType image/x-icon .ico
769
770 #
771 # AddHandler allows you to map certain file extensions to "handlers":
772 # actions unrelated to filetype. These can be either built into the server
773 # or added with the Action directive (see below)
774 #
775 # To use CGI scripts outside of ScriptAliased directories:
776 # (You will also need to add "ExecCGI" to the "Options" directive.)
777 #
778 #AddHandler cgi-script .cgi
779
780 #
781 # For files that include their own HTTP headers:
782 #
783 #AddHandler send-as-is asis
784
785 #
786 # For server-parsed imagemap files:
787 #
788 #AddHandler imap-file map
789
790 #
791 # For type maps (negotiated resources):
792 # (This is enabled by default to allow the Apache "It Worked" page
793 #  to be distributed in multiple languages.)
794 #
795 AddHandler type-map var
796
797 #
798 # Filters allow you to process content before it is sent to the client.
799 #
800 # To parse .shtml files for server-side includes (SSI):
801 # (You will also need to add "Includes" to the "Options" directive.)
802 #
803 #AddType text/html .shtml
804 #AddOutputFilter INCLUDES .shtml
805
806 #
807 # Action lets you define media types that will execute a script whenever
808 # a matching file is called. This eliminates the need for repeated URL
809 # pathnames for oft-used CGI file processors.
810 # Format: Action media/type /cgi-script/location
811 # Format: Action handler-name /cgi-script/location
812 #
813
814 #
815 # Customizable error responses come in three flavors:
816 # 1) plain text 2) local redirects 3) external redirects
817 #
818 # Some examples:
819 #ErrorDocument 500 "The server made a boo boo."
820 #ErrorDocument 404 /missing.html
821 #ErrorDocument 404 "/cgi-bin/missing_handler.pl"
822 #ErrorDocument 402 http://www.example.com/subscription_info.html
823 #
824
825 #
826 # Putting this all together, we can internationalize error responses.
827 #
828 # We use Alias to redirect any /error/HTTP_<error>.html.var response to
829 # our collection of by-error message multi-language collections.  We use 
830 # includes to substitute the appropriate text.
831 #
832 # You can modify the messages' appearance without changing any of the
833 # default HTTP_<error>.html.var files by adding the line:
834 #
835 #   Alias /error/include/ "/your/include/path/"
836 #
837 # which allows you to create your own set of files by starting with the
838 # @exp_errordir@/include/ files and copying them to /your/include/path/, 
839 # even on a per-VirtualHost basis.  The default include files will display
840 # your Apache version number and your ServerAdmin email address regardless
841 # of the setting of ServerSignature.
842 #
843 # The internationalized error documents require mod_alias, mod_include
844 # and mod_negotiation.  To activate them, uncomment the following 30 lines.
845
846 #    Alias /error/ "@exp_errordir@/"
847 #
848 #    <Directory "@exp_errordir@">
849 #        AllowOverride None
850 #        Options IncludesNoExec
851 #        AddOutputFilter Includes html
852 #        AddHandler type-map var
853 #        Order allow,deny
854 #        Allow from all
855 #        LanguagePriority en cs de es fr it nl sv pt-br ro
856 #        ForceLanguagePriority Prefer Fallback
857 #    </Directory>
858 #
859 #    ErrorDocument 400 /error/HTTP_BAD_REQUEST.html.var
860 #    ErrorDocument 401 /error/HTTP_UNAUTHORIZED.html.var
861 #    ErrorDocument 403 /error/HTTP_FORBIDDEN.html.var
862 #    ErrorDocument 404 /error/HTTP_NOT_FOUND.html.var
863 #    ErrorDocument 405 /error/HTTP_METHOD_NOT_ALLOWED.html.var
864 #    ErrorDocument 408 /error/HTTP_REQUEST_TIME_OUT.html.var
865 #    ErrorDocument 410 /error/HTTP_GONE.html.var
866 #    ErrorDocument 411 /error/HTTP_LENGTH_REQUIRED.html.var
867 #    ErrorDocument 412 /error/HTTP_PRECONDITION_FAILED.html.var
868 #    ErrorDocument 413 /error/HTTP_REQUEST_ENTITY_TOO_LARGE.html.var
869 #    ErrorDocument 414 /error/HTTP_REQUEST_URI_TOO_LARGE.html.var
870 #    ErrorDocument 415 /error/HTTP_UNSUPPORTED_MEDIA_TYPE.html.var
871 #    ErrorDocument 500 /error/HTTP_INTERNAL_SERVER_ERROR.html.var
872 #    ErrorDocument 501 /error/HTTP_NOT_IMPLEMENTED.html.var
873 #    ErrorDocument 502 /error/HTTP_BAD_GATEWAY.html.var
874 #    ErrorDocument 503 /error/HTTP_SERVICE_UNAVAILABLE.html.var
875 #    ErrorDocument 506 /error/HTTP_VARIANT_ALSO_VARIES.html.var
876
877
878
879 #
880 # The following directives modify normal HTTP response behavior to
881 # handle known problems with browser implementations.
882 #
883 BrowserMatch "Mozilla/2" nokeepalive
884 BrowserMatch "MSIE 4\.0b2;" nokeepalive downgrade-1.0 force-response-1.0
885 BrowserMatch "RealPlayer 4\.0" force-response-1.0
886 BrowserMatch "Java/1\.0" force-response-1.0
887 BrowserMatch "JDK/1\.0" force-response-1.0
888
889 #
890 # The following directive disables redirects on non-GET requests for
891 # a directory that does not include the trailing slash.  This fixes a 
892 # problem with Microsoft WebFolders which does not appropriately handle 
893 # redirects for folders with DAV methods.
894 # Same deal with Apple's DAV filesystem and Gnome VFS support for DAV.
895 #
896 BrowserMatch "Microsoft Data Access Internet Publishing Provider" redirect-carefully
897 BrowserMatch "^WebDrive" redirect-carefully
898 BrowserMatch "^WebDAVFS/1.[012]" redirect-carefully
899 BrowserMatch "^gnome-vfs/1.0" redirect-carefully
900
901 #
902 # Allow server status reports generated by mod_status,
903 # with the URL of http://servername/server-status
904 # Change the ".@@DomainName@@" to match your domain to enable.
905 #
906 #<Location /server-status>
907 #    SetHandler server-status
908 #    Order deny,allow
909 #    Deny from all
910 #    Allow from .@@DomainName@@
911 #</Location>
912
913 #
914 # Allow remote server configuration reports, with the URL of
915 #  http://servername/server-info (requires that mod_info.c be loaded).
916 # Change the ".@@DomainName@@" to match your domain to enable.
917 #
918 #<Location /server-info>
919 #    SetHandler server-info
920 #    Order deny,allow
921 #    Deny from all
922 #    Allow from .@@DomainName@@
923 #</Location>
924
925
926 #
927 # Bring in additional module-specific configurations
928 #
929 <IfModule mod_ssl.c>
930     Include conf/ssl.conf
931 </IfModule>
932
933
934 ### Section 3: Virtual Hosts
935 #
936 # VirtualHost: If you want to maintain multiple domains/hostnames on your
937 # machine you can setup VirtualHost containers for them. Most configurations
938 # use only name-based virtual hosts so the server doesn't need to worry about
939 # IP addresses. This is indicated by the asterisks in the directives below.
940 #
941 # Please see the documentation at 
942 # <URL:http://httpd.apache.org/docs-2.1/vhosts/>
943 # for further details before you try to setup virtual hosts.
944 #
945 # You may use the command line option '-S' to verify your virtual host
946 # configuration.
947
948 #
949 # Use name-based virtual hosting.
950 #
951 #NameVirtualHost *
952
953 #
954 # VirtualHost example:
955 # Almost any Apache directive may go into a VirtualHost container.
956 # The first VirtualHost section is used for requests without a known
957 # server name.
958 #
959 #<VirtualHost *>
960 #    ServerAdmin webmaster@dummy-host.example.com
961 #    DocumentRoot /www/docs/dummy-host.example.com
962 #    ServerName dummy-host.example.com
963 #    ErrorLog logs/dummy-host.example.com-error_log
964 #    CustomLog logs/dummy-host.example.com-access_log common
965 #</VirtualHost>