crgabb@sdrc.UUCP (Rob Gabbard) (12/08/87)
I was having multiple problems getting sendmail to work properly with the supplied sendmail.cf so I pulled the configuration file off of a Vaxstation II/GPX and it worked great ! Our mailers include the Apollo ring, a series of Suns, HPs, IBM PC RTs, GPXs(Ultrix) and an Vax 8600 running Wollongong TCP/IP. I'm using the GPX cf file on the Apollos and Suns with great success. With a little modification, I've got all systems sending UUCP mail over the Ethernet to my HP which is my uunet connection and the HP automatically sends back over the Ethernet any mail that it recognizes as a local TCP/IP host. With the GPX config file, you can define trouble hosts to route around too. For example, a bug in the HP's sendmail facility causes it to dump core and go "crazy" whenever it trys to talk to the RT's SMTP. So I told the HP to route any request to the RT to the Sun first and the Sun delevers it. You could easily add these capabilities to the existing cf file or write one from scratch, but the GPX configuration file has more included in it than any other that I've seen. Rob Gabbard Workstation Systems Programmer Structural Dynamics Research Corporation
crgabb@sdrc.UUCP (Rob Gabbard) (12/08/87)
Is anyone out there running DOMAIN/ACCESS 2.0 ? I've just installed it and it appears to be working perfectly. I'm planning on heavily relying on it to eliminate FTP'ing hundreds of files from the VAX. My VAX server is an 8650 running VMS4.6 and my Apollo gateway is a DN660 running SR9.6. I was just curious if anyone has run across any problems I should beware of. I'm also running NFS between the Apollo ring, a Sun network and a GPX (Ultrix) as well as using a remote Sun printer via the BSD4.2 lpr facility. Rob Gabbard Workstation Systems Programmer Structural Dynamics Research Corporation
crgabb@sdrc.UUCP (Rob Gabbard) (12/11/87)
As requested, here is our Apollo and HP sendmail.cf files. The Apollo version was taken from a Vaxstation II/GPX running Ultrix and customized for use on our Apollo ring and Suns. The HP is the standard HP file, taken from our usenet relay and customized to resolve local TCP/IP uucp addresses and to route any RT references around to a Sun. (The HP mailer dumps core when it tries to talk to the RT. Our network consists of an Apollo ring, Suns, GPXs, VAXs, and HPs. +----Apollo--------- cut here ----------------+ ############################################################ ############################################################ ##### ##### SENDMAIL CONFIGURATION FILE ##### # @(#)generic.mc 1.2 (ULTRIX) 1/29/87 # ##### generic configuration ##### ##### ############################################################ ############################################################ ############################################################ ### local info ############################################################ # This section specifies data about your environment and how to # handle mail. The configuration has provisions for several (independent) # mail relay machines for handling different kinds of mail. # Below these are all given the name "RELAY". If you need or want this # kind of relay you will need to uncomment the line and put in the name # of the appropriate host. # # The relay machines are specified separately for each kind of mail # so you can spread out the load. On the other hand they could all # point to the same machine to centralize information. The relay can # even name this machine and the "right thing" will happen. When adding # relay names, be sure to put the first name directly next to the # name of the macro or class - do not put a space between it. Also, remember # to uncomment it by removing the pound sign "#". # For example, the general purpose relay example is given as: # # start of line ->#DRRELAY # # To make "foo" your general purpose relay, change the line to: # # start of line ->DRfoo # # The $w macro is preset by sendmail to the current host's # name. Here we simply capture the value in our own $A macro. # DA$w # # The $D macro will be the domain for this machine. If your machine # is part of a registered domain, that name should be defined here. # If you don't have a domain, leave it defined as "local". Some typical # domains are DEC.COM, ARPA, MIT.EDU, CSS.GOV. # DDlocal # # These are other "domains" in which this machine may be named. They # are used to recognize all forms of name for the local machine. # CDlocal uucp dnet # # The $j macro is the name presented to remote SMTP servers when # establishing a mail connection. It should always be your fully # qualified domain name. # Dj$w.$D # # The $U macro is the name of this machine for UUCP communications. # It is usually the same as the normal host name, but may need to be # different for political reasons. # DU$w # # The $S class can be used to identify "local" machines. Mail to these # machines will include the sender's and receiver's host names but will # omit the domain in order to reduce the visual clutter. Mail delivered # by SMTP to other (non-local) hosts will use full qualification. # # If your /etc/hosts file contains only local hosts, you can read the names # directly from /etc/hosts. Otherwise you should produce a separate list # of local host names in /usr/lib/hosts.local. Both forms are shown below. # #FS/usr/lib/hosts.local FS/etc/hosts %*[0-9.]%s # # The $R macro is the name of your general purpose relay machine. Any # mail that cannot be resolved locally is forwarded to this machine # for processing. It gets anything not covered by the other relay hosts. # DRsdrc # # The $F macro and class defines a named list of hosts and a relay machine # to handle their mail. This is not normally used, but is included in the # rewrite rules in case the need should arise. # #DFRELAY #CFred blue green # # The $E macro is the relay host for dnet (DECNET) connections. # You need this only if your machine is not running DECNET but depending # on some other local machine to relay DECNET mail. # DEcae15 # # The $Z macro names the relay for UUCP mail for sites not directly # reachable by this host. The list of reachable sites is read from # the UUCP L.sys file and assigned to the $Z class once when the # config file is frozen. # # *WARNING* You must refreeze the sendmail config file every time # you add a new host to uucp, or else sendmail will not know about # it. If you use uucpsetup to add new hosts, this will be done # for you automatically - if you add hosts to L.sys by hand, you # must do it yourself. Type: "/usr/lib/sendmail -bz" as root. # DZsdrc FZ/usr/lib/uucp/L.sys %[0-9a-zA-Z_-] # # The $N macro and class allow you to establish a central site for resolving # user names which are not known locally. If you use this the relay machine # will be passed any mail which is not for someone listed in /etc/passwd. # In particular this means that all alias processing will be passed to the # relay. You can add additional names to the N class to handle specific local # aliases such as postmaster. # # WARNING: If you use this feature you must refreeze the configuration file # (via /usr/lib/sendmail -bz) every time a user is added or deleted from # /etc/passwd. Also you will not be able to establish any local aliases # other than those listed in class N below. # #DNRELAY #FN/etc/passwd %[0-9a-zA-Z_-] #CN MAILER-DAEMON postmaster admin # ############################################################ # # @(#)base.m4 1.4 (ULTRIX) 12/16/86 # # General configuration information # # This information is basically just "boiler-plate"; it must be # there, but is essentially constant. # # Information in this file should be independent of location -- # i.e., although there are some policy decisions made, they are # not specific to any specific site. # # ############################################################ # @(#)version.m4 1.4 (ULTRIX) 12/16/86 DVDOMAIN/IX9.5-V4.7 # ########################## ### Special macros ### ########################## # my name DnMAILER-DAEMON # UNIX header format DlFrom $g $d # delimiter (operator) characters Do.:%@!^=/[] # format of a total name Dq$g$?x ($x)$. # SMTP login message De$j Sendmail $v/$V ready at $b # # forwarding host -- redefine this if you can't talk to the relay directly DF$R # ################### ### Options ### ################### # location of alias file OA/usr/lib/aliases # default delivery mode (deliver in background) Odbackground # (don't) connect to "expensive" mailers #Oc # temporary file mode OF0600 # default GID Og1 # location of help file OH/usr/lib/sendmail.hf # log level OL9 # send to me to in alias expansion Om # default messages to old style Oo # queue directory OQ/usr/spool/mqueue # read timeout -- violates protocols Or2h # status file OS/usr/lib/sendmail.st # queue up everything before starting transmission Os # default timeout interval OT3d # time zone names (V6 only) OtEST,EDT # default UID Ou1 # wizard's password (disabled) OWxxx ############################### ### Message precedences ### ############################### Pfirst-class=0 Pspecial-delivery=100 Pjunk=-100 ######################### ### Trusted users ### ######################### Troot Tdaemon Tuucp Tnetwork ############################# ### Format of headers ### ############################# H?P?Return-Path: <$g> H?R?Received: $?sfrom $s $.by $j ($v/$V) id $i; $b H?D?Resent-Date: $a H?D?Date: $a H?F?Resent-From: $q H?F?From: $q H?x?Full-Name: $x HSubject: # HPosted-Date: $a # H?l?Received-Date: $b H?M?Resent-Message-Id: <$t.$i@$j> H?M?Message-Id: <$t.$i@$j> ########################### ### Rewriting rules ### ########################### ################################ # Sender Field Pre-rewriting # ################################ S1 #R$*<$*>$* $1$2$3 defocus ################################### # Recipient Field Pre-rewriting # ################################### S2 #R$*<$*>$* $1$2$3 defocus ################################# # Final Output Post-rewriting # ################################# S4 R@ $@ handle <> error addr # externalize local domain info R$*<@LOCAL>$* $:$1<@$w.$D>$2 change local info R$*<$*LOCAL>$* $:$1<$2$D>$3 change local info R$*<$+>$* $1$2$3 defocus R@$+:$+:$+ @$1,$2:$3 <route-addr> canonical R@$+:$+ $@<@$1:$2> route-addr needs <> # UUCP must always be presented in old form R$+@$-.UUCP $2!$1 u@h.UUCP => h!u # Put MAIL-11 back in :: form R$+@$-.DNET $2::$1 u@h.dnet => h::u R$+@$-.$-.DNET $2.$3::$1 numeric form # delete duplicate local names -- mostly for arpaproto.mc R$+%$=w@$=w $1@$3 u%UCB@UCB => u@UCB R$+%$=w@$=w.$D $1@$3.$D u%UCB@UCB => u@UCB ########################### # Name Canonicalization # ########################### S3 # handle "from:<>" special case R<> $@@ turn into magic token # basic textual canonicalization R$*<$*<$*<$+>$*>$*>$* $4 3-level <> nesting R$*<$*<$+>$*>$* $3 2-level <> nesting R$*<$+>$* $2 basic RFC821/822 parsing R$+ at $+ $1@$2 "at" -> "@" for RFC 822 R$*<$*>$* $1$2$3 in case recursive # make sure <@a,@b,@c:user@d> syntax is easy to parse -- undone later R@$+,$+ @$1:$2 change all "," to ":" # localize and dispose of domain-based addresses R@$+:$+ $@$>6<@$1>:$2 handle <route-addr> # more miscellaneous cleanup R$=w::$-$+ $2$3 clean off my name R$+ $:$>8$1 host dependent cleanup R$+:$*;@$+ $@$1:$2;@$3 list syntax R$+@$+ $:$1<@$2> focus on domain R$+<$+@$+> $1$2<@$3> move gaze right R$+<@$+%$+> $1%$2<@$3> move gaze right R$-!$+<@$~S> $1!$2@$3 defocus - not local host R$-::$+<@$~S> $1::$2@$3 defocus - not local host R$+<@$+> $@$>6$1<@$2> already canonical # localize mail-11 syntax R$-::$+ $@$>6$2<@$1.dnet> host::user R$-.$-::$+ $@$>6$3<@$1.$2.dnet> numeric decnet addr # convert old-style addresses to a domain-based address R$+%$+ $:$1<@$2> user%host R$+<@$+%$+> $1%$2<@$3> move "@" right R$+<@$+> $@$>6$1<@$2> now canonical R$-:$+ $@$>6$2<@$1> host:user R$-.$+!$+ $@$>6$3<@$1.$2> host.domain!user R$-!$+ $@$>6$2<@$1.UUCP> resolve uucp names ############################################################ ############################################################ ##### ##### local conventions # # @(#)localbase.m4 1.2 (ULTRIX) 12/16/86 ##### ##### ##### ############################################################ ############################################################ ##### special local conversions # Here you can any special local rewriting rules and keep them all # in one place. Ruleset 8 is invoked at the beginning of ruleset 3 # and ruleset 6 is invoked at the end. Ruleset 3 always returns # the result of a call to ruleset 6. S8 # empty S6 R$-$+<@$w> $@$>3$1$2 localhost R$-$+<@$w.$D> $@$>3$1$2 localhost R$-$+<@$w.$=D> $@$>3$1$2 other local domains R$+<@$=S>$* $@$1<@$2.LOCAL>$3 localhost R$+<@$=S.$D>$* $@$1<@$2.LOCAL>$3 localhost R$+<@$=S.$=D>$* $@$1<@$2.LOCAL>$4 other local domains R$*<@$+>$* $@$1<@$2>$3 already ok ############################################################ ############################################################ ##### ##### RULESET ZERO PREAMBLE ##### ##### The beginning of ruleset zero is constant through all ##### configurations. ##### # @(#)zerobase.m4 1.3 (ULTRIX) 10/16/86 ##### ############################################################ ############################################################ S9 # rerun ruleset 3 and then call 0 again R$+ $:$>3$1 R$+ $@$>0$1 S0 # first make canonical (necessary for recursion) #R$+ $:$>3$1 make canonical # handle special cases..... R@ $#local$:MAILER-DAEMON handle <> form R$*<@[$+]>$* $#tcp$@[$2]$:$1@[$2]$3 numeric internet spec # arrange for local names to be fully qualified R$*<$*$=S>$* $1<$2$3.LOCAL>$4 user@etherhost # now delete the local info R$*<$*$=w.$D>$* $1<$2>$4 thishost.thisdomain R$*<$*$=w.$=D>$* $1<$2>$5 thishost.localdomain R$*<$*$=w>$* $1<$2>$4 thishost R$*<$*.>$* $1<$2>$3 drop trailing dot R<@>:$* $@$>9$1 retry after route strip R$*<@> $@$>9$1 strip null trash & retry R$*<@LOCAL> $@$>9$1 strip null trash & retry ################################## # End of ruleset zero preamble # ################################## ############################################### ### Machine dependent part of rulset zero ### ############################################### # short circuit local hosts R$*<@$=S.UUCP>$* $1<@$2.LOCAL>$3 uucp => local R$*<@$=S.dnet>$* $1<@$2.LOCAL>$3 dnet => local R$*<@$=S.$D>$* $:$1<@$2.LOCAL>$4 domain => local # if we do not have dnet, send to forwarder R$+<@$+.dnet>$* $:$?E$1%$2.dnet<@$E.LOCAL>$3$|$1<@$2.dnet>$3$. # forward uucp we don't know to primary forwarder R$*<@$~Z.UUCP>$* $:$?Z$1%$2.UUCP<@$Z.LOCAL>$3$|$1<@$2.UUCP>$3$. # forward around hosts with communication problems R$*<@$=F.LOCAL>$* $1%$2.LOCAL<@$F.LOCAL>$3 reroute message # Undo forwarding if we are forwarder R$+%$+.$-<@$=w.LOCAL>$* $1<@$2.$3>$5 if we are forwarder # resolve names we can handle locally R$*<@LOCAL>$* $#local$:$1$2 local # first handle local network traffic double check that we know the host #R$*<@$~S.LOCAL>$* $#error$:Host $2 not connected to $w via tcp #R$*<@$->$* $#error$:Host $2 not connected to $w via tcp R$*<@$-.LOCAL> $#tcplocal$@$2$:$1<@$2> user@tcphost.LOCAL R$*<@$-.LOCAL>$+ $#tcplocal$@$2$:$1<@$2.LOCAL>$3 user@tcphost.LOCAL # handle dnet stuff R$+<@$+.dnet> $#Dmail$@$2$:$1 dnet user # handle uucp traffic. double check that we know the host R$*<@$~Z.UUCP>$* $#error$:Host $2 not connected to $w via uucp R<@$+.UUCP>:$+ $1!$2 to old format R$+<@$+.UUCP> $2!$1 to old format R$-!$+ $#uucp$@$1$:$2 host!... # all other domains try for forwarder, if defined R$*<@$+.$->$* $:$?R$1<@$2.$3>$4<@$R>$|$1<@$2.$3>$4$. R$*<@$+.$->$*<@$=w> $#tcp$@$2.$3$:$1<@$2.$3>$4 we are forwarder R$*<@$+.$->$*<@$+> $#tcplocal$@$5$:$1<@$2.$3>$4 pass it on # no forwarder, try for tcp connection R$*<@$+>$* $#tcp$@$2$:$1<@$2>$3 user@tcphost.domain # at this point, we are trying a local name. if we don't # recognize it, forward to name forwarder host if defined. R$~N $:$?N$1<@$N.LOCAL>$|$1$. not local, redirect R$*<@$=w.LOCAL>$* $1 but wait, there's more! # we are forwarder, hope # it's an alias! R$*<@$*$-.LOCAL>$* $#tcplocal$@$3$:$1<@$2$3.LOCAL>$4 let name forwarder do it # everything else must be a local name R$+ $#local$:$1 local names ############################################################ ############################################################ ##### ##### Local and Program Mailer specification ##### # @(#)localm.m4 1.3 (ULTRIX) 10/16/86 ##### ############################################################ ############################################################ Mlocal, P=/bin/mail, F=rlsDFmn, S=10, R=10, A=mail -d $u Mprog, P=/bin/sh, F=lsDFRe, S=10, R=10, A=sh -c $u S10 R$+<@LOCAL> $@$1 delete LOCAL R$+<@$-.LOCAL> $@$1<@$2> delete .LOCAL R@ $@MAILER-DAEMON errors to mailer-daemon ############################################################ ############################################################ ##### ##### Mail-11 Mailer ##### # @(#)xm.m4 1.2 (ULTRIX) 10/16/86 ##### ############################################################ ############################################################ MDmail, P=/usr/bin/mail11, F=mnsF, S=17, R=18, A=mail11 $f $x $h $u S17 R$+ $:$>18$1 preprocess R$U::$+ $@$U::$1 ready to go R$+ $@$U::$1 add our name S18 R$+<@$-.UUCP> $:$2!$1 back to old style R$+<@$-.DNET> $:$2::$1 convert to dnet style R$+<@$-.LOCAL> $:$2::$1 convert to dnet style R$+<@$=S> $:$2::$1 convert to dnet style R$+<@$=S.$D> $:$2::$1 convert to dnet style R$=S::$+ $2 strip local names R$$+::$+ $@$1::$2 already qualified R$+ $@$U::$1 qualify others ############################################################ ############################################################ ##### ##### Arpanet TCP Mailer specification ##### # @(#)tcpm.m4 1.2 (ULTRIX) 10/16/86 ##### ############################################################ ############################################################ Mtcp, P=[IPC], F=msDFMueCXLR, S=19, R=19, A=IPC $h, E=\r\n Mtcplocal, P=[IPC], F=msDFMueCXLR, S=19, R=19, A=IPC $h, E=\r\n S14 # pass <route-addr>'s through R<@$+>$* $@<@$1>$2 resolve <route-addr> # gatewayed to/from DNET R$+<@$-.DNET>$* $@$1%$2.dnet<@$A.$D>$3 user@host.DNET # gatewayed to/from UUCP R$+<@$-.UUCP>$* $@$2!$1<@$A.$D>$3 user@host.DNET # strip local host names if we are forwarder R$+<@$=S> $:$1<@$2>$?R<$R>$. add forwarder R$+<@$=S.$D> $:$1<@$2.$3>$?R<$R>$. R$+<@$+.LOCAL> $:$1<@$2.LOCAL>$?R<$R>$. R$+<@$=S><$=w> $:$1 strip name R$+<@$=S.$D><$=w> $:$1 R$+<@$+.LOCAL><$=w> $:$1 R$+<$R> $:$1 remove forwarder name # tack on our name and domain R$- $@$1<@$A.$D> local names R$+<@LOCAL> $@$1<@$A.$D> local names R$+<@$+.LOCAL> $@$1<@$2.$D> local hosts R$+<@$=S> $@$1<@$2.$D> local hosts S19 # delete domain on local hosts R$+<@LOCAL> $@$1 R$+<@$=S> $@$1<@$2> R$+<@$=S.$D> $@$1<@$2> R$+<@$=S.LOCAL> $@$1<@$2> R$+<@$+.$=D> $@$1<@$2.$3> leave local domains R$- $@$1<@$A> qualify simple name # do normal rewrite if all else fails R$+ $@$>14$1 ############################################################ ############################################################ ##### ##### UUCP Mailer specification ##### # @(#)uucpm.m4 1.3 (ULTRIX) 10/16/86 ##### ############################################################ ############################################################ # There are two options for the uucp mailer presented here. The only # difference is the -r option to uux. With the -r option, uucp mail # will be queued until some other process forces a call to be made. # Without the -r option, a call will be attempted immediately to # deliver this message, although the normal uucp rules about when to # call still apply. # # This one just queues the message for a later uucp call. #Muucp, P=/usr/bin/uux, F=sDFhuU, S=13, R=23, M=100000, # A=uux - -r $h!rmail ($u) # # This one attempts a call immediately. Muucp, P=/usr/bin/uux, F=sDFhuU, S=13, R=23, M=100000, A=uux - $h!rmail ($u) # # This mailer lets you pretend to speak uucp to a host with which you have # an IP/TCP connection. It uses UUCP address rewrite rules with TCP # message transport. Hosts to be given this treatment must be identified # by ruleset zero. Muucptcp, P=[IPC], F=msDFMhuX, S=13, R=23, M=100000, A=IPC $h S13 R$+ $:$>23$1 prescan R$U!$+ $@$U!$1 ready to go R$+ $@$U!$1 stick on our host name S23 R$+<@$-.UUCP> $2!$1 old form R$+<@$=S> $1 strip local names R$+<@$=S.$=D> $1 strip local names R$+<@$-.DNET> $2.dnet!$1 old form R$+<@$+> $2!$1 old form R$=S!$+ $2 strip local name R$=S.$D!$+ $2 strip local name R$=S.$=D!$+ $2 strip local name R$- $U!$1 stick on our host name +---HP------ cut here ---------------+ ############################################################ ############################################################ ##### ##### SENDMAIL CONFIGURATION FILE ##### ##### @(#)7.1 86/06/24 ##### ############################################################ ############################################################ ############################################################ ##### ##### CAVEAT EMPTOR ##### ##### This configuration file is compatible for use on ##### most HP-UX systems and can be installed, as is, as ##### sendmail's configuration file, sendmail.cf. ##### ##### HP will support problems found in this version of ##### the configuration file if: ##### ##### * it is left unmodified; or ##### ##### * only minimal changes are made. Minimal changes ##### are discussed in the ARPA Services/300 Node ##### Manager's Guide. ##### ##### If more than minimal changes are made to this file, ##### you are on your own. ##### ##### Additions that reflect the local system's mailing ##### environment may be needed if the you wish to provide ##### expanded capabilities. HP recommends that these ##### additions be limited to modifications discussed in ##### the "Customizing Sendmail's Configuration File" ##### section of the Node Manager's Guide. These ##### additions should be made by an individual who is ##### knowledgeable about the configuration file. ##### ############################################################ ############################################################ ############################################################ ##### ##### Local Information ##### ##### This information is dependent on the local ##### environment and should be set accordingly. ##### ##### ############################################################ ############################################################ ###################### ### local macros ### ###################### # your official UUCP hostname (should come from "uuname -l") DH$w # your local domain (fully qualified) DDlocal # local domain names CDlocal uucp # class U defines known direct UUCP connections FU/usr/lib/uucp/L.sys %s # class S defines presumed direct SMTP connections FS/etc/hosts %*[0-9.] %s # UUCP relay for unresolved ! addresses DUuunet # This will allow forwarding for the F class of hosts. # The Hp has problems talking to the RT, so I've forwarded # around it via SUN1 DFsun1 CFrt1 rt2 rt3 rt4 rt5 rt6 rt7 rt8 rt9 # SMTP relay for unresolved @ addresses DS # pathalias nameserver DP/usr/bin/uupath ############################################################ ############################################################ ##### ##### General Configuration Information ##### ##### This information must be here, but is essentially ##### constant. It should be independent of location. ##### ##### ############################################################ ############################################################ ########################## ### Version Number ### ########################## DV6.2 ########################## ### Special macros ### ########################## # official domain name for this site Dj$?D$w.$D$|$w$. # my name DnMAILER-DAEMON # UNIX header format DlFrom $g $d # delimiter (operator) characters Do.:%@!^=/[] # format of a total name Dq$?x$x <$g>$|$g$. # SMTP login message De$j HP Sendmail $v ready at $b ################### ### Options ### ################### ### Changeable Options ### # delivery mode Odbackground # error reporting mode Oep # log level OL9 # read timeout -- this technically violates the SMTP protocol Or5m # queue timeout interval OT3d ### Other Options ### # HP recommends that these options remain unchanged. # Save those UN*X From_ lines Of # location of alias file OA/usr/lib/aliases # temporary file mode OF0600 # default UID Ou1 # default GID Og1 # location of help file OH/usr/lib/sendmail.hf # default messages to old style Oo # queue directory OQ/usr/spool/mqueue # status file OS/usr/lib/sendmail.st # queue up everything before starting transmission Os ############################### ### Message precedences ### ############################### Pfirst-class=0 Pspecial-delivery=100 Pjunk=-100 ######################### ### Trusted users ### ######################### Troot Tdaemon Tuucp ############################# ### Format of headers ### ############################# HReceived: $?sfrom $s $.by $w; $b HResent-Date: $a HDate: $a HResent-From: $q HFrom: $q HFull-Name: $x HReturn-Path: <$g> HSubject: # HPosted-Date: $a # HReceived-Date: $b # HResent-Message-Id: <$t.$i@$j> # H?M?Message-Id: <$t.$i@$j> ############################################################ ############################################################ ##### ##### ADDRESS REWRITING RULES ##### ##### ############################################################ ############################################################ ################################################### ### Ruleset 1 - Sender Field Pre-rewriting ### ################################################### S1 ################################################### ### Ruleset 2 - Recipient Field Pre-rewriting ### ################################################### S2 ################################################### ### Ruleset 3 - Address Canonicalization ### ################################################### S3 # handle "from:<>" special case R<> $@@ turn into magic token # basic textual canonicalization R$*<$+>$* $2 basic RFC821/822 parsing R$+ at $+ $1@$2 "at" -> "@" for RFC 822 R$*<$*>$* $1$2$3 in case recursive # handle route-addr <@a,@b,@c:user@d> syntax R@$+,$+ @$1:$2 change all "," to ":" R@$+:$+ $@<@$1>:$2 handle <route-addr> R$+:$*;@$+ $@$1:$2;@$3 list syntax # The @ delimiter takes precedence. Leave this alone. R$+@$+ $:$1<@$2> focus on domain R$+<$+@$+> $1$2<@$3> move gaze right R$+<@$+> $@$1<@$2> already canonical # The ! delimeter. R$+^$+ $1!$2 convert ^ to ! R$=S!$- $:$2<@$1> R$-!$+ $@$2<@$1.UUX> resolve uucp names # R$+.!$+ $@$2<@$1> domain.!host (rfc976) # R$+!$+ $@$2<@$1> domain!host (rfc976) # % is a low precedence @. R$+%$+ $:$1<%$2> focus on domain R$+<$+%$+> $1$2<%$3> move gaze right R$+<%$+> $@$1<@$2> %->@ canonical # more miscellaneous cleanup R$-.$+ $@$2<@$1> host.user R$+@ $@$1 user@ R$+% $@$1 user% ################################################### ### Ruleset 4 - Final Output Post-rewriting ### ################################################### S4 # handle problem cases R@ $@@ handle <> error addr R$+<@> $1 handle null domain # externalize local domain info R$*<$+>$* $1$2$3 defocus R@$+:$+:$+ $@@$1,$2:$3 <route-addr> canonical # UUCP must always be presented in old form R$+@$-.UUX $2!$1 u@h.UUX => h!u ############################################################ ############################################################ ##### ##### RULESET ZERO ##### ##### This ruleset attempts to resolve a recipient address ##### into a { delivery_agent, host, user } triple. It ##### consists of the preamble and the machine dependent ##### section. The preamble is constant throughout all ##### configurations. ##### ############################################################ ############################################################ S0 ################################ ### Ruleset Zero Preamble ### ################################ # first make canonical R$*<$*>$* $1$2$3 defocus R$+ $:$>3$1 make canonical # handle special cases..... R@ $#local$:MAILER-DAEMON handle <> form R$*<@[$+]>$* $#tcp$@[$2]$:$1@[$2]$3 numeric internet spec R$*<@$-.UUCP>$* $1<@$2.UUX>$3 handle .UUCP domain # strip off domain names from local host R$*<@$w$*.$=D>$* $1<@$w$2>$4 user@my_host.xx.domain R$*<@$w.UUX>$* $1<@$w>$2 user@my_host.UUX R$*<@$w>$* $1<@>$2 user@my_host # miscellaneous cleanup R$*<$*.>$* $1<$2>$3 drop trailing dot R<@>:$+ $@$>0$1 strip null route, retry R$+<@> $@$>0$1 strip null addr, retry ################################################### ### Machine dependent part of ruleset zero ### ################################################### # forward around hosts with communications problems # added by Rob Gabbard , 11/10/87 R$*<@$=F>$* $1%$2.LOCAL<@$F>$3 # resolve direct SMTP mail R$+<@$=S> $#tcp$@$2$:$1@$2 user@host R<@$=S>:$+ $#tcp$@$1$:$2 @host: ... # resolve direct UUCP mail R$+<@$=U.UUX> $#uucp$@$2$:$1 user@host.UUX R<@$=U.UUX>:$+ $#uucp$@$1$:$2 @host.UUX: ... # try to get a path to an unresolved UUCP address # by calling the pathalias nameserver # R$+<@$-.UUX> $:$>5$2!$1 uupath pathalias routing # R$+<@$=U.UUX> $#uucp$@$2$:$1 known UUCP host # end of nameserver # by default, pass unresolved UUCP addresses to the UUCP relay R$+<@$-.UUX> $#uucp$@$U$:$2!$1 hand it to UUCP relay # by default, pass unresolved SMTP addresses to the SMTP relay # R$+<@$+> $#tcp$@$S$:$1@$2 hand it to SMTP relay # other non-local names are in error R<@$-.UUX>:$+ $#error$:UUCP host name $1 not recognized at this site R$+<@$-.UUX> $#error$:UUCP host name $2 not recognized at this site # other non-local names are in error R<@$+>:$+ $#error$:Network node $1 not recognized at this site R$+<@$+> $#error$:Network node $2 not recognized at this site # remaining names must be local R$+ $#local$:$1 everything else ############################################################ ############################################################ ##### ##### Local and Program Mailer specification ##### ############################################################ ############################################################ Mlocal, P=/bin/rmail, F=lsDFm, S=10, R=20, A=rmail -d $u Mprog, P=/bin/sh, F=lsDFMeuP, S=10, R=20, A=sh -c $u Mtty, P=/bin/false, F=rlsn, S=10, R=20, A=to $u, M=5000 S10 R@ MAILER-DAEMON errors to mailer-daemon S20 ############################################################ ############################################################ ##### ##### SMTP/IPC Mailer specification ##### ############################################################ ############################################################ Mtcp, P=[IPC], F=msDFMuCP, S=11, R=21, A=IPC $h S11 R$*<@$+>$* $@$1<@$2>$3 already ok R$+ $:$1<@$w.$D> tack on host.domain R$+<$*.> $1<$2> strip extraneous dots S21 ############################################################ ############################################################ ##### ##### UUCP Mailer specification ##### ##### ############################################################ ############################################################ Muucp, P=/usr/bin/uux, F=DFMUshux, S=13, R=23, A=uux - $h!rmail ($u) S13 R$+<@$-.UUX> $2!$1 u@host.UUX => host!u R$w!$+ $1 strip local name R$+ $:$H!$1 stick on our host name S23 R$+<@$-.UUX> $2!$1 u@host.UUX => host!u ############################################################ ############################################################ ##### ##### Customized Mailers ##### ##### ############################################################ ############################################################ ############################################################ ############################################################ ##### ##### Nameservers and Domainservers ##### ############################################################ ############################################################ ############################## ### Pathalias Nameserver ### ############################## S5 R$+ $:$<P$1 uupath pathalias routing R$-!$+ $:$2<@$1.UUX> canonicalize