httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <>
Subject Re: listenwrap support
Date Tue, 20 Oct 1998 08:43:47 GMT
On Sun, 18 Oct 1998, Manoj Kasichainula wrote:

> Is it worth writing a C version? My tests say a perl version of cat is
> 2.5 times slower than cat, but I don't think it would hurt enough to
> matter.

Yeah I'd write it in C.  Also, if it catches HUP, USR1, INT, TERM then it
can actually buffer its writes, the parent will send one of those signals
when its about to restart/die. 

As Marc mentions you still need a secret to protect the setuid thing from
being run as anyone... which I think is why I wanted to just handle log
rotation from a simple root program:

    open pipes for logs
      -- in child setuid to logger
      -- exec logger
    open protected ports
      -- in child setuid to httpd
      -- exec httpd
    loop... replace logger or httpd as either dies

Then log rotation is achieved by killing the logger... which is completely
independant of restarting the server (assuming the logger is written to do
its buffering/signal catching properly). 


View raw message