Commit | Line | Data |
---|---|---|
95f51977 C |
1 | # |
2 | # Sendmail | |
3 | # Copyright (c) 1983 Eric P. Allman | |
4 | # Berkeley, California | |
5 | # | |
6 | # Copyright (c) 1983 Regents of the University of California. | |
7 | # All rights reserved. The Berkeley software License Agreement | |
8 | # specifies the terms and conditions for redistribution. | |
9 | # | |
10 | # @(#)monet.mc 5.1 (Berkeley) 6/10/85 | |
11 | # | |
e804469b C |
12 | ############################################################ |
13 | ############################################################ | |
14 | ##### | |
15 | ##### SENDMAIL CONFIGURATION FILE | |
16 | ##### | |
e804469b C |
17 | ############################################################ |
18 | ############################################################ | |
19 | ||
20 | ||
21 | ||
22 | ############################################################ | |
23 | ### local info | |
24 | ############################################################ | |
25 | ||
26 | # internet hostname | |
27 | Cwucbmonet monet | |
28 | ||
95f51977 | 29 | |
e804469b C |
30 | ################################################# |
31 | # | |
32 | # General configuration information | |
33 | # | |
e804469b C |
34 | ################################################# |
35 | ||
36 | ###################### | |
37 | # General Macros # | |
38 | ###################### | |
39 | ||
40 | # our arpanet gateway | |
95f51977 | 41 | DABerkeley.EDU |
e804469b C |
42 | CABerkeley UCB ucbc70 c70 UCB-C70 u UCB-VAX ucbvax |
43 | ||
44 | # local domain names | |
95f51977 | 45 | DDBERKELEY.EDU |
e804469b C |
46 | CDBERKELEY UCB ucbc70 c70 ucb-c70 u UCB-VAX ucbvax |
47 | ||
48 | # major relay host | |
49 | DRUCBVAX | |
50 | CRucbvax vax k | |
51 | ||
0f4556f1 | 52 | # my official hostname |
95f51977 | 53 | Dj$w |
0f4556f1 | 54 | |
e804469b | 55 | # known SMTP/ethernet hosts (this domain only) -- only $R need be complete |
95f51977 C |
56 | |
57 | CSucbarmstrong armstrong | |
e804469b | 58 | CSucbarpa arpa |
0f4556f1 | 59 | CSucbbach bach ucbstatvax statvax |
95f51977 C |
60 | CSucbbass bass |
61 | CSucbbell bell | |
62 | CSucbbizet bizet | |
63 | CSucbbob bob | |
0f4556f1 | 64 | CSucbbrahms brahms mathstat |
95f51977 C |
65 | CSucbbud bud |
66 | CSucbbuddy buddy | |
e804469b C |
67 | CSucbcad cad cad-a |
68 | CSucbcalder calder | |
0f4556f1 | 69 | CSucbcartan cartan |
95f51977 C |
70 | CSucbchip chip |
71 | CSucbcogsci cogsci | |
72 | CSucbcorona corona | |
73 | CSucbcory cory | |
74 | CSucbdab dab | |
e804469b | 75 | CSucbdali dali |
95f51977 C |
76 | CSucbdavinci davinci |
77 | CSucbdavis davis | |
78 | CSucbdean dean | |
79 | CSucbdeforest deforest | |
e804469b | 80 | CSucbdegas degas |
95f51977 C |
81 | CSucbdim dim |
82 | CSucbdorothy dorothy | |
83 | CSucbear ear | |
84 | CSucbeast east beast | |
85 | CSucbedison edison | |
e804469b | 86 | CSucbernie ernie |
0f4556f1 | 87 | CSucbesvax esvax |
95f51977 C |
88 | CSucbeuler euler |
89 | CSucbfranklin franklin | |
90 | CSucbfranny franny | |
91 | CSucbheine heine | |
92 | CSucbholden holden | |
93 | CSucbhuffman huffman | |
0f4556f1 C |
94 | CSucbic ic ucbic-ec ic-ec cad-b cad-ic |
95 | CSucbicw icw ucbicw-ec icw-ec cad-c cad-icw | |
95f51977 | 96 | CSucbimage |
0f4556f1 | 97 | CSucbingres ingres |
95f51977 C |
98 | CSucbjan jan |
99 | CSucbjason jason | |
100 | CSucbji ji | |
101 | CSucbjoule joule | |
102 | CSucbkepler kepler | |
e804469b | 103 | CSucbkim kim |
95f51977 | 104 | CSucbmarconi marconi |
e804469b | 105 | CSucbmatisse matisse |
95f51977 | 106 | CSucbmaxwell maxwell |
e804469b | 107 | CSucbmedea medea |
0f4556f1 | 108 | CSucbmerlin merlin |
95f51977 | 109 | CSucbmike mike |
e804469b | 110 | CSucbmiro miro |
95f51977 | 111 | CSucbmolson molson |
e804469b | 112 | CSucbmonet monet |
95f51977 C |
113 | CSucbmote mote |
114 | CSucbnewton newton | |
115 | CSucbnyquist nyquist | |
116 | CSucbokeeffe okeeffe | |
0f4556f1 | 117 | CSucboz oz |
95f51977 C |
118 | CSucbrenoir renoir |
119 | CSucbrob rob | |
120 | CSucbrobert robert | |
121 | CSucbseymour seymour | |
122 | CSucbshadow shadow | |
123 | CSucbshannon shannon | |
124 | CSucbsilvia silvia | |
125 | CSucbtuborg tuborg | |
126 | CSucbugs bugs ucbbugs ugs | |
127 | CSucbvangogh vangogh | |
e804469b | 128 | CSucbvax |
0f4556f1 | 129 | CSucbweyl weyl |
95f51977 C |
130 | CSucbzeus zeus |
131 | CSucbzooey zooey | |
132 | CSucbzworykin zworykin | |
0f4556f1 C |
133 | |
134 | # known top-level domains | |
95f51977 C |
135 | CTLOCAL ARPA EDU GOV COM MIL |
136 | CTUUCP BITNET CSNET DEC | |
137 | ||
e804469b C |
138 | |
139 | ############################################################ | |
140 | # | |
141 | # General configuration information | |
142 | # | |
143 | # This information is basically just "boiler-plate"; it must be | |
144 | # there, but is essentially constant. | |
145 | # | |
146 | # Information in this file should be independent of location -- | |
147 | # i.e., although there are some policy decisions made, they are | |
148 | # not specific to Berkeley per se. | |
149 | # | |
e804469b C |
150 | ############################################################ |
151 | ||
e804469b | 152 | |
95f51977 C |
153 | ###################### |
154 | # Version Number # | |
155 | ###################### | |
156 | ||
157 | DZ5.17 | |
e804469b C |
158 | |
159 | ||
160 | ########################## | |
161 | ### Special macros ### | |
162 | ########################## | |
163 | ||
164 | # my name | |
165 | DnMAILER-DAEMON | |
166 | # UNIX header format | |
167 | DlFrom $g $d | |
168 | # delimiter (operator) characters | |
169 | Do.:%@!^=/[] | |
170 | # format of a total name | |
171 | Dq$g$?x ($x)$. | |
e804469b | 172 | # SMTP login message |
95f51977 | 173 | De$j Sendmail $v/$Z ready at $b |
e804469b | 174 | |
0f4556f1 C |
175 | # forwarding host -- redefine this if you can't talk to the relay directly |
176 | DF$R | |
177 | ||
e804469b C |
178 | ################### |
179 | ### Options ### | |
180 | ################### | |
181 | ||
182 | # location of alias file | |
183 | OA/usr/lib/aliases | |
95f51977 C |
184 | # wait up to ten minutes for alias file rebuild |
185 | Oa10 | |
186 | # substitution for space (blank) characters | |
187 | OB. | |
e804469b C |
188 | # (don't) connect to "expensive" mailers |
189 | #Oc | |
95f51977 C |
190 | # default delivery mode (deliver in background) |
191 | Odbackground | |
e804469b | 192 | # temporary file mode |
95f51977 | 193 | OF0600 |
e804469b C |
194 | # default GID |
195 | Og1 | |
196 | # location of help file | |
197 | OH/usr/lib/sendmail.hf | |
198 | # log level | |
199 | OL9 | |
95f51977 C |
200 | # default network name |
201 | ONARPA | |
e804469b C |
202 | # default messages to old style |
203 | Oo | |
204 | # queue directory | |
205 | OQ/usr/spool/mqueue | |
206 | # read timeout -- violates protocols | |
207 | Or2h | |
208 | # status file | |
209 | OS/usr/lib/sendmail.st | |
210 | # queue up everything before starting transmission | |
211 | Os | |
212 | # default timeout interval | |
213 | OT3d | |
214 | # time zone names (V6 only) | |
215 | OtPST,PDT | |
216 | # default UID | |
217 | Ou1 | |
218 | # wizard's password | |
95f51977 C |
219 | OW* |
220 | # load average at which we just queue messages | |
221 | Ox8 | |
222 | # load average at which we refuse connections | |
223 | OX12 | |
e804469b C |
224 | |
225 | ############################### | |
226 | ### Message precedences ### | |
227 | ############################### | |
228 | ||
229 | Pfirst-class=0 | |
230 | Pspecial-delivery=100 | |
95f51977 | 231 | Pbulk=-60 |
e804469b C |
232 | Pjunk=-100 |
233 | ||
234 | ######################### | |
235 | ### Trusted users ### | |
236 | ######################### | |
237 | ||
238 | Troot | |
239 | Tdaemon | |
240 | Tuucp | |
241 | Teric | |
242 | Tnetwork | |
243 | ||
244 | ############################# | |
245 | ### Format of headers ### | |
246 | ############################# | |
247 | ||
0f4556f1 | 248 | H?P?Return-Path: <$g> |
95f51977 | 249 | HReceived: $?sfrom $s $.by $j ($v/$Z) |
0f4556f1 C |
250 | id $i; $b |
251 | H?D?Resent-Date: $a | |
e804469b | 252 | H?D?Date: $a |
0f4556f1 | 253 | H?F?Resent-From: $q |
e804469b C |
254 | H?F?From: $q |
255 | H?x?Full-Name: $x | |
256 | HSubject: | |
e804469b C |
257 | # HPosted-Date: $a |
258 | # H?l?Received-Date: $b | |
0f4556f1 | 259 | H?M?Resent-Message-Id: <$t.$i@$j> |
e804469b | 260 | H?M?Message-Id: <$t.$i@$j> |
e804469b C |
261 | |
262 | ########################### | |
263 | ### Rewriting rules ### | |
264 | ########################### | |
265 | ||
266 | ||
267 | ################################ | |
268 | # Sender Field Pre-rewriting # | |
269 | ################################ | |
270 | S1 | |
271 | #R$*<$*>$* $1$2$3 defocus | |
272 | ||
273 | ################################### | |
274 | # Recipient Field Pre-rewriting # | |
275 | ################################### | |
276 | S2 | |
277 | #R$*<$*>$* $1$2$3 defocus | |
278 | ||
279 | ################################# | |
280 | # Final Output Post-rewriting # | |
281 | ################################# | |
282 | S4 | |
283 | ||
284 | R@ $@ handle <> error addr | |
285 | ||
286 | # externalize local domain info | |
287 | R$*<$*LOCAL>$* $1<$2$D>$3 change local info | |
95f51977 C |
288 | R$*<$*LOCAL.ARPA>$* $1<$2$D>$3 change local info |
289 | R$*<$*.CC>$* $1$2$3 strip .CC | |
e804469b | 290 | R$*<$+>$* $1$2$3 defocus |
95f51977 | 291 | R@$+:@$+:$+ @$1,@$2:$3 <route-addr> canonical |
0f4556f1 C |
292 | |
293 | # UUCP must always be presented in old form | |
294 | R$+@$-.UUCP $2!$1 u@h.UUCP => h!u | |
295 | ||
296 | # delete duplicate local names -- mostly for arpaproto.mc | |
297 | R$+%$=w@$=w $1@$3 u%UCB@UCB => u@UCB | |
298 | R$+%$=w@$=w.ARPA $1@$3.ARPA u%UCB@UCB => u@UCB | |
e804469b C |
299 | |
300 | ########################### | |
301 | # Name Canonicalization # | |
302 | ########################### | |
303 | S3 | |
304 | ||
305 | # handle "from:<>" special case | |
306 | R<> $@@ turn into magic token | |
307 | ||
95f51977 C |
308 | # basic textual canonicalization -- note RFC733 heuristic here |
309 | R$*<$*<$*<$+>$*>$*>$* $4 3-level <> nesting | |
310 | R$*<$*<$+>$*>$* $3 2-level <> nesting | |
e804469b C |
311 | R$*<$+>$* $2 basic RFC821/822 parsing |
312 | R$+ at $+ $1@$2 "at" -> "@" for RFC 822 | |
e804469b C |
313 | |
314 | # make sure <@a,@b,@c:user@d> syntax is easy to parse -- undone later | |
315 | R@$+,$+ @$1:$2 change all "," to ":" | |
316 | ||
95f51977 | 317 | # localize and dispose of route-based addresses |
e804469b C |
318 | R@$+:$+ $@$>6<@$1>:$2 handle <route-addr> |
319 | ||
320 | # more miscellaneous cleanup | |
321 | R$+ $:$>8$1 host dependent cleanup | |
322 | R$+:$*;@$+ $@$1:$2;@$3 list syntax | |
95f51977 | 323 | R$+:$*; $@$1:$2; list syntax |
e804469b C |
324 | R$+@$+ $:$1<@$2> focus on domain |
325 | R$+<$+@$+> $1$2<@$3> move gaze right | |
326 | R$+<@$+> $@$>6$1<@$2> already canonical | |
327 | ||
328 | # convert old-style addresses to a domain-based address | |
0f4556f1 | 329 | R$-:$+ $@$>6$2<@$1> host:user |
e804469b | 330 | R$+^$+ $1!$2 convert ^ to ! |
95f51977 C |
331 | R$-.$+!$+ $@$>6$3<@$1.$2> host.domain!user |
332 | R$-!$+ $@$>6$2<@$1.UUCP> host!user (uucp) | |
333 | R$+%$+ $@$>6$1<@$2> user%host | |
334 | R$-=$+ $@$>6$2<@$1.BITNET> host=user (bitnet) | |
335 | R$-.$+ $@$>6$2<@$1> host.user | |
e804469b | 336 | |
95f51977 | 337 | # always include local and tcp mailers (tcp for [w.x.y.z]-style addrs) |
e804469b C |
338 | |
339 | ############################################################ | |
340 | ############################################################ | |
341 | ##### | |
342 | ##### Local and Program Mailer specification | |
343 | ##### | |
e804469b C |
344 | ############################################################ |
345 | ############################################################ | |
346 | ||
347 | Mlocal, P=/bin/mail, F=rlsDFMmn, S=10, R=20, A=mail -d $u | |
0f4556f1 | 348 | Mprog, P=/bin/sh, F=lsDFMe, S=10, R=20, A=sh -c $u |
e804469b C |
349 | |
350 | S10 | |
95f51977 C |
351 | R@ $n errors to mailer-daemon |
352 | ||
353 | ||
354 | ############################################################ | |
355 | ############################################################ | |
356 | ##### | |
357 | ##### Arpanet TCP Mailer specification | |
358 | ##### | |
359 | ##### Messages processed by this specification are assumed to leave | |
360 | ##### the local domain -- hence, they must be canonical according to | |
361 | ##### RFC822 etc. | |
362 | ##### | |
363 | ############################################################ | |
364 | ############################################################ | |
365 | ||
366 | Mtcp, P=[IPC], F=mDFMueXL, S=14, R=14, A=IPC $h, E=\r\n | |
367 | ||
368 | S14 | |
369 | ||
370 | # pass <route-addr>'s through | |
371 | R<@$+>$* $@<@$[$1$]>$2 resolve <route-addr> | |
372 | ||
373 | # map colons to dots everywhere..... | |
374 | R$*:$* $1.$2 map colons to dots | |
375 | ||
376 | # handle the simple case.... | |
377 | R$+<@$-.ARPA> $@$1<@$[$2.ARPA$]> user@host.ARPA | |
378 | ||
379 | # output local hosts in user@host.Berkeley.EDU syntax | |
380 | R$+<@LOCAL> $@$1<@$w.$A> local names | |
381 | R$+<@$+.LOCAL> $@$1<@$2.$A> local hosts | |
382 | R$+<@$*$=S> $@$1<@$2$3.$A> | |
383 | R$+<@$*$=Z> $@$1<@$2$3.$A> | |
384 | R$+<@$+.BITNET> $@$1%$2.BITNET<@$w.$A> user@host.BITNET | |
385 | R$+<@$+.CSNET> $@$1%$2.CSNET<@CSNET-RELAY.ARPA> user@host.CSNET | |
386 | R$+<@$+.DEC> $@$1%$2.DEC<@decwrl.ARPA> user@host.DEC | |
387 | R$+<@$+.UUCP> $@$2!$1<@$w.$A> user@host.UUCP | |
388 | ||
389 | # handle other external cases | |
390 | R$+<@$-> $@$1<@$[$2$]> no .ARPA on simple names | |
391 | #R$+<@$+.$-.ARPA> $@$1%$2<@$[$3.ARPA$]> approximate something | |
392 | R$+<@[$+]> $@$1<@[$2]> already ok | |
393 | R$+<@$+> $@$1<@$[$2$]> set for named | |
394 | ||
395 | # convert remaining addresses to old format and externalize appropriately | |
396 | R$+ $:$>5$1 => old format | |
397 | R$-:$+ $@$2<@$1.$A> convert berk hosts | |
398 | #R$+<@$+> $@$1<@$2@$A> pessmize | |
399 | R$+ $:$1<@$w.$A> tack on our hostname | |
400 | R$+%$=R<@$=A> $1<@$[$3$]> strip unneeded relay | |
401 | ||
402 | ||
403 | ||
404 | ####################### | |
405 | # Rewriting rules # | |
406 | ####################### | |
407 | ||
408 | ##### special local conversions | |
409 | S6 | |
410 | R$*<@$*$=D>$* $1<@$2LOCAL>$4 convert local domain | |
411 | R$*<@$*$=D.ARPA>$* $1<@$2LOCAL>$4 | |
412 | R$*<@$*$=D.EDU>$* $1<@$2LOCAL>$4 | |
413 | R$+%$+<@LOCAL> $>9$1%$2 Hack for % syntax. | |
414 | R$*<@$+.$=T.$=T>$* $1<@$2.$3>$5 make UUCP top level | |
415 | R$*<@$*$=C.$=T>$* $1<@$2$3>$5 adjust CC hosts (ucbvax) | |
416 | R$*<@$*$=C>$* $1<@$2$3.CC>$4 tack on .CC temporarily | |
417 | R$*<@$*$=S.UUCP>$* $1<@$2$3.LOCAL>$4 trap u@etherhost.UUCP | |
418 | R$*<@ucsfcgl.UUCP>$* $1<@ucsf-cgl.ARPA>$2 ucsfcgl now on Internet | |
419 | ||
420 | ################################ | |
421 | # Change rightmost % to @. | |
422 | S9 | |
423 | R$*%$* $1@$2 First make them all @'s | |
424 | R$*@$*@$* $1%$2@$3 Undo all but the last. | |
425 | R$*@$* $@$1<@$2> Put back the brackets. | |
426 | # | |
427 | ############################### | |
428 | ||
e804469b C |
429 | |
430 | ############################################################ | |
431 | ############################################################ | |
432 | ##### | |
433 | ##### Ethernet Mailer specification | |
434 | ##### | |
95f51977 C |
435 | ##### Messages processed by this configuration are assumed to remain |
436 | ##### in the same domain. Hence, they may not necessarily correspond | |
437 | ##### to RFC822 in all details. | |
e804469b C |
438 | ##### |
439 | ############################################################ | |
440 | ############################################################ | |
441 | ||
95f51977 | 442 | Mether, P=[IPC], F=mDFMueCX, S=11, R=21, A=IPC $h |
e804469b C |
443 | |
444 | S11 | |
445 | R$*<@$+>$* $@$1<@$2>$3 already ok | |
446 | R$+ $@$1<@$w> tack on our hostname | |
447 | ||
448 | S21 | |
449 | ||
450 | ||
95f51977 | 451 | |
e804469b C |
452 | ############################################################ |
453 | ############################################################ | |
454 | ##### | |
455 | ##### BASIC ETHERNET RULES | |
456 | ##### | |
e804469b C |
457 | ############################################################ |
458 | ############################################################ | |
459 | ||
460 | ||
461 | ||
95f51977 | 462 | |
e804469b C |
463 | ############################################################ |
464 | ############################################################ | |
465 | ##### | |
466 | ##### RULESET ZERO PREAMBLE | |
467 | ##### | |
468 | ##### The beginning of ruleset zero is constant through all | |
469 | ##### configurations. | |
470 | ##### | |
e804469b C |
471 | ############################################################ |
472 | ############################################################ | |
473 | ||
474 | S0 | |
475 | ||
476 | # first make canonical | |
477 | R$*<$*>$* $1$2$3 defocus | |
478 | R$+ $:$>3$1 make canonical | |
479 | ||
480 | # handle special cases..... | |
95f51977 | 481 | R@ $#local$:$n handle <> form |
e804469b C |
482 | R$*<@[$+]>$* $#tcp$@[$2]$:$1@[$2]$3 numeric internet spec |
483 | ||
0f4556f1 C |
484 | # arrange for local names to be fully qualified |
485 | R$*<$*$=S>$* $1<$2$3.LOCAL>$4 user@etherhost | |
486 | R$*<$*$=Z>$* $1<$2$3.LOCAL>$4 user@berkhost | |
487 | R$*<$+.ARPA.LOCAL>$* $1<$2.ARPA>$3 because ARPA is a host | |
488 | ||
e804469b | 489 | # now delete the local info |
95f51977 | 490 | R$*<$*$=w.$=T>$* $1<$2>$5 thishost.LOCAL |
e804469b C |
491 | R$*<$*$=w>$* $1<$2>$4 thishost |
492 | R$*<$*.>$* $1<$2>$3 drop trailing dot | |
493 | R<@>:$* $@$>0$1 retry after route strip | |
494 | R$*<@> $@$>0$1 strip null trash & retry | |
495 | ||
0f4556f1 C |
496 | # forward around hosts with communication problems |
497 | R$*<@$=F.LOCAL>$* $#ether$@$F$:$1<@$2.LOCAL>$3 reroute message | |
498 | ||
499 | ################################## | |
500 | # End of ruleset zero preamble # | |
501 | ################################## | |
502 | ||
e804469b C |
503 | |
504 | ################################################ | |
505 | ### Machine dependent part of ruleset zero ### | |
506 | ################################################ | |
507 | ||
508 | # resolve names that can go via the ethernet | |
95f51977 | 509 | R$*<@$*$=S.LOCAL>$* $#ether$@$3$:$1<@$2$3>$4 user@etherhost |
e804469b C |
510 | |
511 | # other non-local names will be kicked upstairs | |
0f4556f1 | 512 | R$*<@$+>$* $#ether$@$F$:$1<@$2>$3 user@some.where |
e804469b C |
513 | |
514 | # remaining names must be local | |
515 | R$+ $#local$:$1 everything else | |
516 |