patch for NCSA httpd-1.1 to allow http-gatewaying

Markus Stumpf ([email protected])
Thu, 27 Jan 1994 02:54:54 +0100


Hello!

I have put the patch on
ftp://ftp.informatik.tu-muenchen.de/tmp/httpd-1.1gate.tar.gz
In this file is also the below appended README.gate.

I hope everything is ok so far. It's about 3:00 am local time and
I am not sure I didn't miss something. :)

I have tested it with Mosaic for X11 2.0 and daemons running on
HP 9000/715 HP/UX 9.01 but I don't think I have some machine dependend
code in it.

Good night :)

\Maex

---------8<----------8<----------8<---------8<---------8<-------------

This is the README for the gateway code to NCSA httpd-1.1

This gateway currently ONLY gates http protocol requests!!!
It cannot act as a "standard" httpd AND a gateway httpd.
I haven't found a way to distinguish between a GET from
a client in, and one from a client not in gateway
mode. If you know of one PLEEEEEAAAAASE tell me :)
(This makes it also rather impossible to decide whether the
gate request is for a gopher: http: or ... URL, as the
protocoll information is also stripped. Anyone knows
why this was done? Older versions of libwww sent a protocol:/
with the request).

However: if a gateway-server and a "standard" server are
running on the same machine the gateway-server would
connect the "standard" server. This is really overhead.
I have added code that checks whether the gateway request
is for the same machine the gateway-server runs on.
If so, I take a look at the port numbers. Maybe another
specialised httpd is running on the same machine.
Per default a server port of 80 (SameServerPort keyword,
see below) is assumed for the "standard" httpd.
If both server name and port number match, the gate-httpd
acts like a "standard" httpd and delivers the "local"
document itself.

There are two new keywords for conf/httpd.conf:
o SameServerPort (default 80)
To set the port for the "standard" httpd to something other
than 80. (see above)

o GateTransferLog (default logs/gate_access_log)
Like TransferLog. The log of the gateway-server is slightly
different. It contains one additional field after the [time] field
indicating the size (in bytes) of the data that has been
gated.

There are 2 more files in the tar-archive:
o patch
contains a context diff to the httpd-1.1 source code
o src/httpd_gate.c
an additional module containing all the code needed for
gatewaying the http protocol.

The gateway code is enabled with a -DGATE_HTML compile switch.
The code still has some unnecessary comments in it for
debugging purpose and is lacking a few need comments for
documention.

To have a client use the gateway-server do e.g.
setenv WWW_http_GATEWAY //gateway_host:gate_httpd_port

Please send bugs/comments to the address below.

P.S. I have also modified SERVER_VERSION and SERVER_SUPPORT in hope
that the ncsa folx don't get blamed for errors I possibly made.

Have fun

\Maex

---------8<----------8<----------8<---------8<---------8<-------------

-- 
______________________________________________________________________________
 Markus Stumpf                        [email protected] 
                                http://www.informatik.tu-muenchen.de/~stumpf/