[net.sources.bugs] template.cf in smail delivery

vjk@tut.UUCP (Vesa Kein{nen) (03/09/87)

There seems to be bug in sendmail configuration file
(template.cf)  which came with smail delivery in february.

In the beginning of ruleset 0 there is code like this

 	# strip local stuff
	R$*<@$-.$w.$D>$*	$1<@$2>$3
 	R$*<@$-.$D>$*	$1<@$2>$3
 	R$*<@$-.$w.$=D>$*	$1<@$2>$4	(3)
 	R$*<@$-.$w.$A>$*	$1<@$2>$3
 	R$*<@$-.$A>$*		$1<@$2>$3
 	R$*<@$-.$w.$=T>$*	$1<@$2>$4
 	R$*<$*$w>$*	$1<$2>$3		(7)
 	R$*<$*.>$*		$1<$2>$3
 	R<@>:$+			$@$>0$1
 	R$+<@>			$@$>0$1	

Meaning of this code seems clear to me:
- catch any address which may point to this host,
  remove that address and feed rest (through ruleset 
  3) to ruleset 0
- Strip local domain and leave just hostname

Bugs:
- If you don't define that your host is gateway between
  two domains when you run make.cf.sh lines 3 and 7 get commented 
  out and addresses like a@myhost.mydomain or a@myhost
  will not be catched. 
- address a@foobar.myhost.mydomain will be turned to  
  a@foobar. Doesn't make sense.

I belive that smail catches local addresses, so with smail this
is no problem. I have to use that on workstation with just
SMTP-connection so smail is no use for me. Here is a
form I'm using now.

 	# strip local stuff
	R$*<@$*$w.$D>$*	$1<@>$3
	R$*<@$*$w.$=D>$*	$1<@>$4
	R$*<@$*$w.$A>$*	$1<@>$3
	R$*<@*$w.$=T>$*	$1<@>$4
	R$*<$*$w>$*	$1<@>$3
	R$*<$*.>$*		$1<$2>$3
	R<@>:$+			$@$>0$1
	R$+<@>			$@$>0$1



Any comments are welcome.
Vesa

----------------------------------------------------------------------
Vesa  Keinanen                  # Tampere University of Technology 
                                #     /Computer Systems Laboratory
vjk@tut.UUCP    (mcvax!tut!vjk) # PO box 527, SF-33101 Tampere, Finland
vjk@tut.fi                      # tel: (931)162708



-- 
Vesa  Keinanen                  # Tampere University of Technology 
                                #     /Computer Systems Laboratory
vjk@tut.UUCP    (mcvax!tut!vjk) # PO box 527, SF-33101 Tampere, Finland
vjk@tut.fi                      # tel: (931)162708