You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by sa...@c2.org on 1996/04/23 18:07:34 UTC

implementing CONNECT

	OK, i looked over the draft about CONNECT.

	I think we should implement this, because it is easy. The
question remains -- how should this be implemented? 

	This is what I'm considering doing, let me know if it seems
like the right way of doing it:

Modify Alexei's "Script PUT" stuff to include "CONNECT"

Write a handler which does CONNECT (just a select() bit proxy)

Create "Handler PUT/POST/GET/CONNECT"
	which is just like Script PUT/POST/GET except it points to a
specific handler (Using Alexei's new way of pointing at handlers)
rather than a script...

-- 
Sameer Parekh					Voice:   510-601-9777x3
Community ConneXion, Inc.			FAX:     510-601-9734
The Internet Privacy Provider			Dialin:  510-658-6376
http://www.c2.net/ (or login as "guest")		sameer@c2.net

Re: implementing CONNECT

Posted by Alexei Kosut <ak...@nueva.pvt.k12.ca.us>.
On Tue, 23 Apr 1996 sameer@c2.org wrote:

> 	This is what I'm considering doing, let me know if it seems
> like the right way of doing it:
> 
> Modify Alexei's "Script PUT" stuff to include "CONNECT"
> 
> Write a handler which does CONNECT (just a select() bit proxy)
> 
> Create "Handler PUT/POST/GET/CONNECT"
> 	which is just like Script PUT/POST/GET except it points to a
> specific handler (Using Alexei's new way of pointing at handlers)
> rather than a script...

This seems rather a roundaout way of doing it. Simply adding CONNECT
to the list of methods (located in httpd.h) and then adding a handler
for */*, that looks something like this:

int connect_handler (request_rec *r)
{
    if (r->method_number != M_CONNECT) return DECLINED;

    /* Do connect stuff */

    return OK;
}

This should work fine. A request URI of "hostname:port" and a method
of CONNECT will be ignored by everything else, so it should arrive at
this handler without anything touching it.

-- 
________________________________________________________________________
Alexei Kosut <ak...@nueva.pvt.k12.ca.us>    
URL: http://www.nueva.pvt.k12.ca.us/~akosut/  
Lefler on IRC, DALnet <http://www.dal.net/>