You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Randy Terbush <ra...@zyzzyva.com> on 1997/03/27 16:30:29 UTC

[BUG NOT]

Correct me if I am wrong, but this is expected behavior, no?

------- Forwarded Message

From: Liz Stokes <il...@panix.com>
Message-Id: <19...@panix4.panix.com>
Subject: took the plunge
To: randy@zyzzyva.com (Randy Terbush)
Date: Thu, 27 Mar 1997 09:26:50 -0500 (EST)
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit


	We have only just noticed a problem, since instlaling the new
server on the main port.  The server doesn't seem to understand that it
only should look for extensions at the end.

For instance, a file named "foo.cgi.txt" gets run as a cgi script, not
handed off as text. I've got a surprising number of complaints (who'd have
thunk it). Eeek!

-- 
Liz Stokes
ilaine@panix.com

------- End of Forwarded Message




Re: [BUG NOT]

Posted by Alexei Kosut <ak...@nueva.pvt.k12.ca.us>.
On Thu, 27 Mar 1997, Randy Terbush wrote:

> Correct me if I am wrong, but this is expected behavior, no?

[...]

> 	We have only just noticed a problem, since instlaling the new
> server on the main port.  The server doesn't seem to understand that it
> only should look for extensions at the end.
> 
> For instance, a file named "foo.cgi.txt" gets run as a cgi script, not
> handed off as text. I've got a surprising number of complaints (who'd have
> thunk it). Eeek!

Yeah, that's correct. Apache does look at extensions from left to
right, but in this case, the two extensions mean different
things. .cgi tells the server to use the CGI handler, .txt tells the
server to treat it as a text/plain document, unless the CGI overrides
it (most CGIs do).

The submitter may be used to the magic mime type method of CGI
scripts, where the .txt's text/plain would override the .cgi's
application/x-httpd-cgi, and the file would be served as plain
text. You can still do this with Apache if you use AddType instead of
AddHandler to activate CGI scripts.

It's just no longer reccomended.

-- 
________________________________________________________________________
Alexei Kosut <ak...@nueva.pvt.k12.ca.us>      The Apache HTTP Server
URL: http://www.nueva.pvt.k12.ca.us/~akosut/   http://www.apache.org/


Re: [BUG NOT]

Posted by Rob Hartill <ro...@imdb.com>.
On Thu, 27 Mar 1997, Randy Terbush wrote:

> 
> Correct me if I am wrong, but this is expected behavior, no?

You are correct.

They've defined ".cgi" to trigger mod_cgi

> ------- Forwarded Message
> 
> From: Liz Stokes <il...@panix.com>
> Message-Id: <19...@panix4.panix.com>
> Subject: took the plunge
> To: randy@zyzzyva.com (Randy Terbush)
> Date: Thu, 27 Mar 1997 09:26:50 -0500 (EST)
> MIME-Version: 1.0
> Content-Type: text/plain; charset=US-ASCII
> Content-Transfer-Encoding: 7bit
> 
> 
> 	We have only just noticed a problem, since instlaling the new
> server on the main port.  The server doesn't seem to understand that it
> only should look for extensions at the end.
> 
> For instance, a file named "foo.cgi.txt" gets run as a cgi script, not
> handed off as text. I've got a surprising number of complaints (who'd have
> thunk it). Eeek!
> 
> -- 
> Liz Stokes
> ilaine@panix.com
> 
> ------- End of Forwarded Message
> 
> 
> 
> 

--
Rob Hartill   Internet Movie Database (Ltd)
http://us.imdb.com/Oscars/oscars_1996 -  hype free Oscars (R) info.
http://us.imdb.com/usr/sweepstake     -  Win a 56k X2 modem. Free draw.