httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Brown <>
Subject Re: what to do about CGI and chunked
Date Wed, 20 Nov 1996 15:02:03 GMT
At 01:57 AM 11/20/96 -0800, Roy T. Fielding wrote:
>Apache is currently schizo in terms of how it treats CGI.  On the one hand,
>it tries to treat CGI scripts as idiot children and protect them from
>HTTP/1.1 improvements, which prevents new CGI scripts from using HTTP/1.1.
>On the other hand, it does so in a way which is no longer compliant with

I don't understand the issue.  Please help me.

According to HTTP/1.1, transfer codings are applied in order to
ensure "safe transport" through the network.  Safe transport
seems like a server issue, not a script issue.  Why not simply
present the entity-body to the CGI or FastCGI script?

Surely the server can deal with Content-MD5 footers, or other
footers as they are defined.

The lack of a Content-Length presents one problem, namely
how does the script detect that it has received the entire
entity-body?  The alternatives for CGI seem to be:

  * encode stdin in a tag-length-value format, forcing the CGI script
    to parse this format.  define a tag that means "premature end
    of entity-body".

  * have the server send a signal to the CGI script if the entity-body
    is not received intact. Otherwise send no signal and mark the
    end of the entity-body by sending EOF on stdin.

For FastCGI, since the client is already doing protocol interpretation,
it would be straightforward enough to define a new record type
that means "premature end of entity-body," and modify the client
library to deal with this.


View raw message