>Number: 1814
>Category: mod_include
>Synopsis: exec cmd SSI directive fails in Win95
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: apache
>State: open
>Class: sw-bug
>Submitter-Id: apache
>Arrival-Date: Mon Feb 16 09:20:00 PST 1998
>Last-Modified:
>Originator: [EMAIL PROTECTED]
>Organization:
apache
>Release: 1.3b3 (win32)
>Environment:
Apache/1.3b3 pre-compiled W32 binary on Windows 95
>Description:
Although I have
* perl working fine
* CGI scripts (written in perl) working fine
* SSI echo var working fine
and I believe I have
* configured srm.conf and access.conf correctly
the SSI exec cmd directives
<!--#exec cmd="DIR"-->
<!--#exec cmd="perl c:\htdocs\wfp\ssitest1.cgi"-->
<!--#exec cmd="/cgi-bin/ssitest1.cgi"-->
returns an error in the logs/error_log:
encountered error in GET_CHAR macro, mod_include.
[Mon Feb 16 12:00:17 1998] [error] execution failure for parameter "cmd"
to tag exec in file c:/htdocs/wfp/ssitest.shtml
[Mon Feb 16 12:00:17 1998] [error] execution failure for parameter "cmd"
to tag exec in file c:/htdocs/wfp/ssitest.shtml
[Mon Feb 16 12:00:17 1998] [error] execution failure for parameter "cmd"
to tag exec in file c:/htdocs/wfp/ssitest.shtml
>How-To-Repeat:
srm.conf:
=========
DocumentRoot "C:/htdocs"
ScriptAlias /cgi-bin/ "C:/htdocs/cgi-bin/"
AddHandler cgi-script .cgi
AddType text/html .shtml
AddHandler server-parsed .shtml
access.conf:
============
<Directory "C:/htdocs">
Options Indexes FollowSymLinks
AllowOverride None
order allow,deny
allow from all
</Directory>
<Directory "C:/htdocs/cgi-bin">
AllowOverride None
Options None
</Directory>
<Directory "C:/htdocs/WFP">
AllowOverride All
Options All
</Directory>
c:\htdocs\wfp\ssitest.shtml:
============================
<html>
<head>
<title>Test of SSI</title>
</head>
<body>
The next line contains the SSI: echo var="SERVER_SOFTWARE"<BR>
<!--#echo var="SERVER_SOFTWARE"--><P>
The next line contains the SSI: exec cmd="DIR"<BR>
<!--#exec cmd="DIR"--><P>
The next line contains the SSI: exec cmd="perl c:\htdocs\wfp\ssitest1.cgi"<BR>
<!--#exec cmd="perl c:\htdocs\wfp\ssitest1.cgi"--><P>
The next line contains the SSI: exec cmd="/cgi-bin/ssitest1.cgi"<BR>
<!--#exec cmd="/cgi-bin/ssitest1.cgi"--><P>
The next line contains the SSI: exec cgi="/WFP/ssitest1.cgi" NOT (this hangs up
Apache)<BR>
<!--exec cgi="/WFP/ssitest1.cgi"--><P>
</body>
</html>
output from Apache:
===================
The next line contains the SSI: echo var="SERVER_SOFTWARE"
Apache/1.3b3
The next line contains the SSI: exec cmd="DIR"
[an error occurred while processing this directive]
The next line contains the SSI: exec cmd="perl c:\htdocs\wfp\ssitest1.cgi"
[an error occurred while processing this directive]
The next line contains the SSI: exec cmd="/cgi-bin/ssitest1.cgi"
[an error occurred while processing this directive]
c:\htdocs\wfp\ssitest1.cgi:
===========================
#!C:/Program Files/perl/bin/perl.exe
print "content-type: text/plain\n\n";
print "This text is being generated by a Perl script","\n";
>Fix:
>Audit-Trail:
>Unformatted:
[In order for any reply to be added to the PR database, ]
[you need to include <[EMAIL PROTECTED]> in the Cc line ]
[and leave the subject line UNCHANGED. This is not done]
[automatically because of the potential for mail loops. ]