From: Astrid Malo This directive is used to control how Apache finds the
- interpreter used to run CGI scripts. The default technique is to
- use the interpreter pointed to by the Registry-Strict is available in Apache 2.0 and
later
#! line in the
- script.Script. This causes Apache to use the interpreter pointed to
+ by the shebang line (first line, starting with #!) in the
+ script. On Win32 systems this line usually looks like:
+ #!C:/Perl/bin/perl.exe
+
or, if perl is in PATH, simply:
+ #!perl
+
Setting ScriptInterpreterSource Registry will
- cause the Windows Registry to be searched using the script file
- extension (e.g., .pl) as a search key.
HKEY_CLASSES_ROOT to be
+ searched using the script file extension (e.g., .pl) as a
+ search key. The command defined by the registry subkey
+ Shell\Open\Command is used to open the script file. In absence
+ of the file extension key or the Shell\Open\Command subkey
+ Apache uses the Script option.
+
+ Be careful to use ScriptInterpreterSource Registry with
+ ScriptAlias'ed directories,
+ because Apache is trying to execute every file within
+ this directory. The Registry setting may cause undesired
+ program calls on files, which are usually not executed. For example, the
+ default open command on .htm files on most Windows systems is
+ executing the Microsoft Internet Explorer, so any HTTP request for an
+ .htm file existing within the script directory would start
+ the browser in background. This is an effective method to crash your
+ system within a minute or so.
The option Registry-Strict which is new in Apache 2.0
- does the same as Registry but uses a more strict registry
- search.
Registry but uses the subkey
+ Shell\ExecCGI\Command instead. The ExecCGI key
+ is not a common one. It has to be configured manually and prevents your
+ system from accidental program calls.
diff --git a/docs/manual/mod/core.xml b/docs/manual/mod/core.xml
index 70ab95cb183..f4732469097 100644
--- a/docs/manual/mod/core.xml
+++ b/docs/manual/mod/core.xml
@@ -2429,17 +2429,47 @@ later
This directive is used to control how Apache finds the
- interpreter used to run CGI scripts. The default technique is to
- use the interpreter pointed to by the #! line in the
- script.
Script. This causes Apache to use the interpreter pointed to
+ by the shebang line (first line, starting with #!) in the
+ script. On Win32 systems this line usually looks like:
+
+ or, if perl is in PATH, simply:
Setting ScriptInterpreterSource Registry will
- cause the Windows Registry to be searched using the script file
- extension (e.g., .pl) as a search key.
HKEY_CLASSES_ROOT to be
+ searched using the script file extension (e.g., .pl) as a
+ search key. The command defined by the registry subkey
+ Shell\Open\Command is used to open the script file. In absence
+ of the file extension key or the Shell\Open\Command subkey
+ Apache uses the Script option.
+
+ Be careful to use ScriptInterpreterSource Registry with
+ Registry setting may cause undesired
+ program calls on files, which are usually not executed. For example, the
+ default open command on .htm files on most Windows systems is
+ executing the Microsoft Internet Explorer, so any HTTP request for an
+ .htm file existing within the script directory would start
+ the browser in background. This is an effective method to crash your
+ system within a minute or so.
The option Registry-Strict which is new in Apache 2.0
- does the same as Registry but uses a more strict registry
- search.
Registry but uses the subkey
+ Shell\ExecCGI\Command instead. The ExecCGI key
+ is not a common one. It has to be configured manually and prevents your
+ system from accidental program calls.