On Sun, Dec 19, 1999 at 12:46:28PM -0600, [EMAIL PROTECTED] wrote:
> 
> On Sun, 19 Dec 1999 19:23:28 +0100 , bert hubert writes:
> > On Sun, Dec 19, 1999 at 07:04:38PM +0100, [EMAIL PROTECTED] wrote:
> > 
> > > tcpserver -x /etc/tcp.smtp.cdb -u 31 -g 30 o smtp /var/qmail/bin/tcp-domche
> ck -x /etc/dom.smtp.cdb /var/qmail/bin/qmail-smtpd
> > > 
> > > where tcp-domcheck is a small tool that does the domain checking as you
> > > describe. Perhaps a bit easier than patching it in.
> > 
> > While more modular, I think that it should be integrated in tcpserver, as
> > this already does forward and reverse name lookups. With the volumes of mail
> > we transfer, I don't want to involve yet another process.
> 
> Well, it *is* just one other process -- the extra
> fork() will be pretty cheap compared to the number
> of fsync()s that the message will incur on its way
> through your server.  If you're worried about the
> exec() cost, statically link it.

It's not even a fork(). It's just an extra exec, with a couple of lookups
in a cdb database.

> I'm not sure that checking TCPREMOTEHOST and
> TCPREMOTEIP belong in the same program -- they're
> semantically different.  For example, does an empty
> key refer to a default IP, or a default hostname?
> What if you want the two to have different default
> behaviors?

Good points.

Code is now online at http://www.dataloss.net/tcp-domcheck.tar.gz

Check it out, and report back to the qmail list please! :)

Greetz, Peter.
-- 
Peter van Dijk - student/sysadmin/ircoper/womanizer/pretending coder 
|  
| 'C makes it easy to shoot yourself in the foot;
|  C++ makes it harder, but when you do it blows your whole leg off.'
|                             Bjarne Stroustrup, Inventor of C++

Reply via email to