1# 2# Copyright (c) 1998-2004, 2009, 2010 Proofpoint, Inc. and its suppliers. 3# All rights reserved. 4# Copyright (c) 1983, 1995 Eric P. Allman. All rights reserved. 5# Copyright (c) 1988, 1993 6# The Regents of the University of California. All rights reserved. 7# 8# By using this file, you agree to the terms and conditions set 9# forth in the LICENSE file which can be found at the top level of 10# the sendmail distribution. 11# 12# 13 14###################################################################### 15###################################################################### 16##### 17##### SENDMAIL CONFIGURATION FILE 18##### 19##### built by ca@lab.smi.sendmail.com on Sun Aug 15 23:05:00 PDT 2021 20##### in /var/tmp/ca/sm8.head/sendmail/OpenSource/sendmail-8.17.1/cf/cf 21##### using ../ as configuration include directory 22##### 23###################################################################### 24##### 25##### DO NOT EDIT THIS FILE! Only edit the source .mc file. 26##### 27###################################################################### 28###################################################################### 29 30##### $Id: cfhead.m4,v 8.122 2013-11-22 20:51:13 ca Exp $ ##### 31##### $Id: cf.m4,v 8.33 2013-11-22 20:51:13 ca Exp $ ##### 32##### $Id: submit.mc,v 8.15 2013-11-22 20:51:08 ca Exp $ ##### 33##### $Id: msp.m4,v 1.34 2013-11-22 20:51:11 ca Exp $ ##### 34 35##### $Id: no_default_msa.m4,v 8.3 2013-11-22 20:51:11 ca Exp $ ##### 36 37 38##### $Id: proto.m4,v 8.762 2013-11-22 20:51:13 ca Exp $ ##### 39 40# level 10 config file format 41V10/Berkeley 42 43# override file safeties - setting this option compromises system security, 44# addressing the actual file configuration problem is preferred 45# need to set this before any file actions are encountered in the cf file 46#O DontBlameSendmail=safe 47 48# default LDAP map specification 49# need to set this now before any LDAP maps are defined 50#O LDAPDefaultSpec=-h localhost 51 52################## 53# local info # 54################## 55 56# my LDAP cluster 57# need to set this before any LDAP lookups are done (including classes) 58#D{sendmailMTACluster}$m 59 60Cwlocalhost 61 62# my official domain name 63# ... define this only if sendmail cannot automatically determine your domain 64#Dj$w.Foo.COM 65 66# host/domain names ending with a token in class P are canonical 67CP. 68 69# "Smart" relay host (may be null) 70DS 71 72 73# operators that cannot be in local usernames (i.e., network indicators) 74CO @ % ! 75 76# a class with just dot (for identifying canonical names) 77C.. 78 79# a class with just a left bracket (for identifying domain literals) 80C[[ 81 82 83# Resolve map (to check if a host exists in check_mail) 84Kresolve host -a<OKR> -T<TEMP> 85C{ResOk}OKR 86 87 88# Hosts for which relaying is permitted ($=R) 89FR-o /etc/mail/relay-domains 90 91 92# arithmetic map 93Karith arith 94 95 96 97 98 99# dequoting map 100Kdequote dequote 101 102# class E: names that should be exposed as from this host, even if we masquerade 103# class L: names that should be delivered locally, even if we have a relay 104# class M: domains that should be converted to $M 105# class N: domains that should not be converted to $M 106#CL root 107 108 109 110# my name for error messages 111DnMAILER-DAEMON 112 113 114D{MTAHost}[127.0.0.1] 115 116 117# Configuration version number 118DZ8.17.1/Submit 119 120 121############### 122# Options # 123############### 124 125# strip message body to 7 bits on input? 126O SevenBitInput=False 127 128# 8-bit data handling 129#O EightBitMode=pass8 130 131# wait for alias file rebuild (default units: minutes) 132O AliasWait=10 133 134# location of alias file 135#O AliasFile=/etc/mail/aliases 136 137# minimum number of free blocks on filesystem 138O MinFreeBlocks=100 139 140# maximum message size 141#O MaxMessageSize=0 142 143# substitution for space (blank) characters 144O BlankSub=. 145 146# avoid connecting to "expensive" mailers on initial submission? 147O HoldExpensive=False 148 149# checkpoint queue runs after every N successful deliveries 150#O CheckpointInterval=10 151 152# default delivery mode 153O DeliveryMode=i 154 155# error message header/file 156#O ErrorHeader=/etc/mail/error-header 157 158# error mode 159#O ErrorMode=print 160 161# save Unix-style "From_" lines at top of header? 162#O SaveFromLine=False 163 164# queue file mode (qf files) 165O QueueFileMode=0660 166 167# temporary file mode 168O TempFileMode=0600 169 170# match recipients against GECOS field? 171#O MatchGECOS=False 172 173# maximum hop count 174#O MaxHopCount=25 175 176# location of help file 177O HelpFile=/etc/mail/helpfile 178 179# ignore dots as terminators in incoming messages? 180#O IgnoreDots=False 181 182# name resolver options 183#O ResolverOptions=+AAONLY 184 185# deliver MIME-encapsulated error messages? 186O SendMimeErrors=True 187 188# Forward file search path 189O ForwardPath 190 191# open connection cache size 192O ConnectionCacheSize=2 193 194# open connection cache timeout 195O ConnectionCacheTimeout=5m 196 197# persistent host status directory 198#O HostStatusDirectory=.hoststat 199 200# single thread deliveries (requires HostStatusDirectory)? 201#O SingleThreadDelivery=False 202 203# use Errors-To: header? 204O UseErrorsTo=False 205 206# use compressed IPv6 address format? 207#O UseCompressedIPv6Addresses 208 209# log level 210O LogLevel=9 211 212# send to me too, even in an alias expansion? 213#O MeToo=True 214 215# verify RHS in newaliases? 216O CheckAliases=False 217 218# default messages to old style headers if no special punctuation? 219O OldStyleHeaders=True 220 221# SMTP daemon options 222 223O DaemonPortOptions=Name=NoMTA, Addr=127.0.0.1, M=E 224 225# SMTP client options 226#O ClientPortOptions=Family=inet, Address=0.0.0.0 227 228# Modifiers to define {daemon_flags} for direct submissions 229#O DirectSubmissionModifiers 230 231# Use as mail submission program? See sendmail/SECURITY 232O UseMSP=True 233 234# privacy flags 235O PrivacyOptions=goaway,noetrn,restrictqrun 236 237# who (if anyone) should get extra copies of error messages 238#O PostmasterCopy=Postmaster 239 240# slope of queue-only function 241#O QueueFactor=600000 242 243# limit on number of concurrent queue runners 244#O MaxQueueChildren 245 246# maximum number of queue-runners per queue-grouping with multiple queues 247#O MaxRunnersPerQueue=1 248 249# priority of queue runners (nice(3)) 250#O NiceQueueRun 251 252# shall we sort the queue by hostname first? 253#O QueueSortOrder=priority 254 255# minimum time in queue before retry 256#O MinQueueAge=30m 257 258# maximum time in queue before retry (if > 0; only for exponential delay) 259#O MaxQueueAge 260 261# how many jobs can you process in the queue? 262#O MaxQueueRunSize=0 263 264# perform initial split of envelope without checking MX records 265#O FastSplit=1 266 267# queue directory 268O QueueDirectory=/var/spool/clientmqueue 269 270# key for shared memory; 0 to turn off, -1 to auto-select 271#O SharedMemoryKey=0 272 273# file to store auto-selected key for shared memory (SharedMemoryKey = -1) 274#O SharedMemoryKeyFile 275 276# timeouts (many of these) 277#O Timeout.initial=5m 278#O Timeout.connect=5m 279#O Timeout.aconnect=0s 280#O Timeout.iconnect=5m 281#O Timeout.helo=5m 282#O Timeout.mail=10m 283#O Timeout.rcpt=1h 284#O Timeout.datainit=5m 285#O Timeout.datablock=1h 286#O Timeout.datafinal=1h 287#O Timeout.rset=5m 288#O Timeout.quit=2m 289#O Timeout.misc=2m 290#O Timeout.command=1h 291#O Timeout.ident=5s 292#O Timeout.fileopen=60s 293#O Timeout.control=2m 294O Timeout.queuereturn=5d 295#O Timeout.queuereturn.normal=5d 296#O Timeout.queuereturn.urgent=2d 297#O Timeout.queuereturn.non-urgent=7d 298#O Timeout.queuereturn.dsn=5d 299O Timeout.queuewarn=4h 300#O Timeout.queuewarn.normal=4h 301#O Timeout.queuewarn.urgent=1h 302#O Timeout.queuewarn.non-urgent=12h 303#O Timeout.queuewarn.dsn=4h 304#O Timeout.hoststatus=30m 305#O Timeout.resolver.retrans=5s 306#O Timeout.resolver.retrans.first=5s 307#O Timeout.resolver.retrans.normal=5s 308#O Timeout.resolver.retry=4 309#O Timeout.resolver.retry.first=4 310#O Timeout.resolver.retry.normal=4 311#O Timeout.lhlo=2m 312#O Timeout.auth=10m 313#O Timeout.starttls=1h 314 315# time for DeliverBy; extension disabled if less than 0 316#O DeliverByMin=0 317 318# should we not prune routes in route-addr syntax addresses? 319#O DontPruneRoutes=False 320 321# queue up everything before forking? 322O SuperSafe=True 323 324# status file 325O StatusFile=/var/spool/clientmqueue/sm-client.st 326 327# time zone handling: 328# if undefined, use system default 329# if defined but null, use TZ envariable passed in 330# if defined and non-null, use that info 331O TimeZoneSpec= 332 333# default UID (can be username or userid:groupid) 334#O DefaultUser=mailnull 335 336# list of locations of user database file (null means no lookup) 337#O UserDatabaseSpec=/etc/mail/userdb 338 339# fallback MX host 340#O FallbackMXhost=fall.back.host.net 341 342# fallback smart host 343#O FallbackSmartHost=fall.back.host.net 344 345# if we are the best MX host for a site, try it directly instead of config err 346#O TryNullMXList=False 347 348# load average at which we just queue messages 349#O QueueLA=8 350 351# load average at which we refuse connections 352#O RefuseLA=12 353 354# log interval when refusing connections for this long 355#O RejectLogInterval=3h 356 357# load average at which we delay connections; 0 means no limit 358#O DelayLA=0 359 360# maximum number of children we allow at one time 361#O MaxDaemonChildren=0 362 363# maximum number of new connections per second 364#O ConnectionRateThrottle=0 365 366# Width of the window 367#O ConnectionRateWindowSize=60s 368 369# work recipient factor 370#O RecipientFactor=30000 371 372# deliver each queued job in a separate process? 373#O ForkEachJob=False 374 375# work class factor 376#O ClassFactor=1800 377 378# work time factor 379#O RetryFactor=90000 380 381# default character set 382#O DefaultCharSet=unknown-8bit 383 384# service switch file (name hardwired on Solaris, Ultrix, OSF/1, others) 385#O ServiceSwitchFile=/etc/mail/service.switch 386 387# hosts file (normally /etc/hosts) 388#O HostsFile=/etc/hosts 389 390# dialup line delay on connection failure 391#O DialDelay=0s 392 393# action to take if there are no recipients in the message 394#O NoRecipientAction=none 395 396# chrooted environment for writing to files 397#O SafeFileEnvironment 398 399# are colons OK in addresses? 400#O ColonOkInAddr=True 401 402# shall I avoid expanding CNAMEs (violates protocols)? 403#O DontExpandCnames=False 404 405# SMTP initial login message (old $e macro) 406O SmtpGreetingMessage=$j Sendmail $v/$Z; $b 407 408# UNIX initial From header format (old $l macro) 409O UnixFromLine=From $g $d 410 411# From: lines that have embedded newlines are unwrapped onto one line 412#O SingleLineFromHeader=False 413 414# Allow HELO SMTP command that does not include a host name 415#O AllowBogusHELO=False 416 417# Characters to be quoted in a full name phrase (@,;:\()[] are automatic) 418#O MustQuoteChars=. 419 420# delimiter (operator) characters (old $o macro) 421O OperatorChars=.:%@!^/[]+ 422 423# shall I avoid calling initgroups(3) because of high NIS costs? 424O DontInitGroups=True 425 426# are group-writable :include: and .forward files (un)trustworthy? 427# True (the default) means they are not trustworthy. 428#O UnsafeGroupWrites=True 429 430 431# where do errors that occur when sending errors get sent? 432#O DoubleBounceAddress=postmaster 433 434# issue temporary errors (4xy) instead of permanent errors (5xy)? 435#O SoftBounce=False 436 437# where to save bounces if all else fails 438#O DeadLetterDrop=/var/tmp/dead.letter 439 440# what user id do we assume for the majority of the processing? 441O RunAsUser=smmsp 442 443# maximum number of recipients per SMTP envelope 444#O MaxRecipientsPerMessage=0 445 446# limit the rate recipients per SMTP envelope are accepted 447# once the threshold number of recipients have been rejected 448#O BadRcptThrottle=0 449 450 451# shall we get local names from our installed interfaces? 452O DontProbeInterfaces=True 453 454# Return-Receipt-To: header implies DSN request 455#O RrtImpliesDsn=False 456 457# override connection address (for testing) 458#O ConnectOnlyTo=0.0.0.0 459 460# Trusted user for file ownership and starting the daemon 461O TrustedUser=smmsp 462 463# Control socket for daemon management 464#O ControlSocketName=/var/spool/mqueue/.control 465 466# Maximum MIME header length to protect MUAs 467#O MaxMimeHeaderLength=0/0 468 469# Maximum length of the sum of all headers 470#O MaxHeadersLength=32768 471 472# Maximum depth of alias recursion 473#O MaxAliasRecursion=10 474 475# location of pid file 476O PidFile=/var/spool/clientmqueue/sm-client.pid 477 478# Prefix string for the process title shown on 'ps' listings 479#O ProcessTitlePrefix=prefix 480 481# Data file (df) memory-buffer file maximum size 482#O DataFileBufferSize=4096 483 484# Transcript file (xf) memory-buffer file maximum size 485#O XscriptFileBufferSize=4096 486 487# lookup type to find information about local mailboxes 488#O MailboxDatabase=pw 489 490# override compile time flag REQUIRES_DIR_FSYNC 491#O RequiresDirfsync=true 492 493# list of authentication mechanisms 494#O AuthMechanisms=EXTERNAL GSSAPI KERBEROS_V4 DIGEST-MD5 CRAM-MD5 495 496# Authentication realm 497#O AuthRealm 498 499# default authentication information for outgoing connections 500#O DefaultAuthInfo=/etc/mail/default-auth-info 501 502# SMTP AUTH flags 503#O AuthOptions 504 505# SMTP AUTH maximum encryption strength 506#O AuthMaxBits 507 508# SMTP STARTTLS server options 509#O TLSSrvOptions 510 511# SSL cipherlist 512#O CipherList 513# server side SSL options 514#O ServerSSLOptions 515# client side SSL options 516#O ClientSSLOptions 517# SSL Engine 518#O SSLEngine 519# Path to dynamic library for SSLEngine 520#O SSLEnginePath 521# TLS: fall back to clear text after handshake failure? 522#O TLSFallbacktoClear 523 524# Input mail filters 525#O InputMailFilters 526 527 528# CA directory 529#O CACertPath 530# CA file 531#O CACertFile 532# Server Cert 533#O ServerCertFile 534# Server private key 535#O ServerKeyFile 536# Client Cert 537#O ClientCertFile 538# Client private key 539#O ClientKeyFile 540# File containing certificate revocation lists 541#O CRLFile 542# Directory containing hashes pointing to certificate revocation status files 543#O CRLPath 544# DHParameters (only required if DSA/DH is used) 545#O DHParameters 546# Random data source (required for systems without /dev/urandom under OpenSSL) 547#O RandFile 548# fingerprint algorithm (digest) to use for the presented cert 549#O CertFingerprintAlgorithm 550# enable DANE? 551#O DANE=false 552 553# Maximum number of "useless" commands before slowing down 554#O MaxNOOPCommands=20 555 556# Name to use for EHLO (defaults to $j) 557#O HeloName 558 559 560 561############################ 562# QUEUE GROUP DEFINITIONS # 563############################ 564 565 566########################### 567# Message precedences # 568########################### 569 570Pfirst-class=0 571Pspecial-delivery=100 572Plist=-30 573Pbulk=-60 574Pjunk=-100 575 576##################### 577# Trusted users # 578##################### 579 580# this is equivalent to setting class "t" 581#Ft/etc/mail/trusted-users 582Troot 583Tdaemon 584Tuucp 585 586######################### 587# Format of headers # 588######################### 589 590H?P?Return-Path: <$g> 591HReceived: $?sfrom $s $.$?_($?s$|from $.$_) 592 $.$?{auth_type}(authenticated$?{auth_ssf} bits=${auth_ssf}$.) 593 $.by $j ($v/$Z)$?r with $r$. id $i$?{tls_version} 594 (version=${tls_version} cipher=${cipher} bits=${cipher_bits} verify=${verify})$.$?u 595 for $u; $|; 596 $.$b 597H?D?Resent-Date: $a 598H?D?Date: $a 599H?F?Resent-From: $?x$x <$g>$|$g$. 600H?F?From: $?x$x <$g>$|$g$. 601H?x?Full-Name: $x 602# HPosted-Date: $a 603# H?l?Received-Date: $b 604H?M?Resent-Message-Id: <$t.$i@$j> 605H?M?Message-Id: <$t.$i@$j> 606 607# 608###################################################################### 609###################################################################### 610##### 611##### REWRITING RULES 612##### 613###################################################################### 614###################################################################### 615 616############################################ 617### Ruleset 3 -- Name Canonicalization ### 618############################################ 619Scanonify=3 620 621# handle null input (translate to <@> special case) 622R$@ $@ <@> 623 624# strip group: syntax (not inside angle brackets!) and trailing semicolon 625R$* $: $1 <@> mark addresses 626R$* < $* > $* <@> $: $1 < $2 > $3 unmark <addr> 627R@ $* <@> $: @ $1 unmark @host:... 628R$* [ IPv6 : $+ ] <@> $: $1 [ IPv6 : $2 ] unmark IPv6 addr 629R$* :: $* <@> $: $1 :: $2 unmark node::addr 630R:include: $* <@> $: :include: $1 unmark :include:... 631R$* : $* [ $* ] $: $1 : $2 [ $3 ] <@> remark if leading colon 632R$* : $* <@> $: $2 strip colon if marked 633R$* <@> $: $1 unmark 634R$* ; $1 strip trailing semi 635R$* < $+ :; > $* $@ $2 :; <@> catch <list:;> 636R$* < $* ; > $1 < $2 > bogus bracketed semi 637 638# null input now results from list:; syntax 639R$@ $@ :; <@> 640 641# strip angle brackets -- note RFC733 heuristic to get innermost item 642R$* $: < $1 > housekeeping <> 643R$+ < $* > < $2 > strip excess on left 644R< $* > $+ < $1 > strip excess on right 645R<> $@ < @ > MAIL FROM:<> case 646R< $+ > $: $1 remove housekeeping <> 647 648# strip route address <@a,@b,@c:user@d> -> <user@d> 649R@ $+ , $+ $2 650R@ [ $* ] : $+ $2 651R@ $+ : $+ $2 652 653# find focus for list syntax 654R $+ : $* ; @ $+ $@ $>Canonify2 $1 : $2 ; < @ $3 > list syntax 655R $+ : $* ; $@ $1 : $2; list syntax 656 657# find focus for @ syntax addresses 658R$+ @ $+ $: $1 < @ $2 > focus on domain 659R$+ < $+ @ $+ > $1 $2 < @ $3 > move gaze right 660R$+ < @ $+ > $@ $>Canonify2 $1 < @ $2 > already canonical 661 662 663# convert old-style addresses to a domain-based address 664R$- ! $+ $@ $>Canonify2 $2 < @ $1 .UUCP > resolve uucp names 665R$+ . $- ! $+ $@ $>Canonify2 $3 < @ $1 . $2 > domain uucps 666R$+ ! $+ $@ $>Canonify2 $2 < @ $1 .UUCP > uucp subdomains 667 668# convert node::user addresses into a domain-based address 669R$- :: $+ $@ $>Canonify2 $2 < @ $1 .DECNET > resolve DECnet names 670R$- . $- :: $+ $@ $>Canonify2 $3 < @ $1.$2 .DECNET > numeric DECnet addr 671 672# if we have % signs, take the rightmost one 673R$* % $* $1 @ $2 First make them all @s. 674R$* @ $* @ $* $1 % $2 @ $3 Undo all but the last. 675 676R$* @ $* $@ $>Canonify2 $1 < @ $2 > Insert < > and finish 677 678# else we must be a local name 679R$* $@ $>Canonify2 $1 680 681 682################################################ 683### Ruleset 96 -- bottom half of ruleset 3 ### 684################################################ 685 686SCanonify2=96 687 688# handle special cases for local names 689R$* < @ localhost > $* $: $1 < @ $j . > $2 no domain at all 690R$* < @ localhost . $m > $* $: $1 < @ $j . > $2 local domain 691R$* < @ localhost . UUCP > $* $: $1 < @ $j . > $2 .UUCP domain 692 693# check for IPv4/IPv6 domain literal 694R$* < @ [ $+ ] > $* $: $1 < @@ [ $2 ] > $3 mark [addr] 695R$* < @@ $=w > $* $: $1 < @ $j . > $3 self-literal 696R$* < @@ $+ > $* $@ $1 < @ $2 > $3 canon IP addr 697 698 699 700 701 702# if really UUCP, handle it immediately 703 704# try UUCP traffic as a local address 705R$* < @ $+ . UUCP > $* $: $1 < @ $[ $2 $] . UUCP . > $3 706R$* < @ $+ . . UUCP . > $* $@ $1 < @ $2 . > $3 707 708# hostnames ending in class P are always canonical 709R$* < @ $* $=P > $* $: $1 < @ $2 $3 . > $4 710R$* < @ $* $~P > $* $: $&{daemon_flags} $| $1 < @ $2 $3 > $4 711R$* CC $* $| $* < @ $+.$+ > $* $: $3 < @ $4.$5 . > $6 712R$* CC $* $| $* $: $3 713# pass to name server to make hostname canonical 714R$* $| $* < @ $* > $* $: $2 < @ $[ $3 $] > $4 715R$* $| $* $: $2 716 717# local host aliases and pseudo-domains are always canonical 718R$* < @ $=w > $* $: $1 < @ $2 . > $3 719R$* < @ $=M > $* $: $1 < @ $2 . > $3 720R$* < @ $* . . > $* $1 < @ $2 . > $3 721 722 723################################################## 724### Ruleset 4 -- Final Output Post-rewriting ### 725################################################## 726Sfinal=4 727 728R$+ :; <@> $@ $1 : handle <list:;> 729R$* <@> $@ handle <> and list:; 730 731# strip trailing dot off possibly canonical name 732R$* < @ $+ . > $* $1 < @ $2 > $3 733 734# eliminate internal code 735R$* < @ *LOCAL* > $* $1 < @ $j > $2 736 737# externalize local domain info 738R$* < $+ > $* $1 $2 $3 defocus 739R@ $+ : @ $+ : $+ @ $1 , @ $2 : $3 <route-addr> canonical 740R@ $* $@ @ $1 ... and exit 741 742# UUCP must always be presented in old form 743R$+ @ $- . UUCP $2!$1 u@h.UUCP => h!u 744 745# put DECnet back in :: form 746R$+ @ $+ . DECNET $2 :: $1 u@h.DECNET => h::u 747# delete duplicate local names 748R$+ % $=w @ $=w $1 @ $2 u%host@host => u@host 749 750 751 752############################################################## 753### Ruleset 97 -- recanonicalize and call ruleset zero ### 754### (used for recursive calls) ### 755############################################################## 756 757SRecurse=97 758R$* $: $>canonify $1 759R$* $@ $>parse $1 760 761 762###################################### 763### Ruleset 0 -- Parse Address ### 764###################################### 765 766Sparse=0 767 768R$* $: $>Parse0 $1 initial parsing 769R<@> $#local $: <@> special case error msgs 770R$* $: $>ParseLocal $1 handle local hacks 771R$* $: $>Parse1 $1 final parsing 772 773# 774# Parse0 -- do initial syntax checking and eliminate local addresses. 775# This should either return with the (possibly modified) input 776# or return with a #error mailer. It should not return with a 777# #mailer other than the #error mailer. 778# 779 780SParse0 781R<@> $@ <@> special case error msgs 782R$* : $* ; <@> $#error $@ 5.1.3 $: "553 List:; syntax illegal for recipient addresses" 783R@ <@ $* > < @ $1 > catch "@@host" bogosity 784R<@ $+> $#error $@ 5.1.3 $: "553 User address required" 785R$+ <@> $#error $@ 5.1.3 $: "553 Hostname required" 786R$* $: <> $1 787R<> $* < @ [ $* ] : $+ > $* $1 < @ [ $2 ] : $3 > $4 788R<> $* < @ [ $* ] , $+ > $* $1 < @ [ $2 ] , $3 > $4 789R<> $* < @ [ $* ] $+ > $* $#error $@ 5.1.2 $: "553 Invalid address" 790R<> $* < @ [ $+ ] > $* $1 < @ [ $2 ] > $3 791R<> $* <$* : $* > $* $#error $@ 5.1.3 $: "553 Colon illegal in host name part" 792R<> $* $1 793R$* < @ . $* > $* $#error $@ 5.1.2 $: "553 Invalid host name" 794R$* < @ $* .. $* > $* $#error $@ 5.1.2 $: "553 Invalid host name" 795R$* < @ $* @ > $* $#error $@ 5.1.2 $: "553 Invalid route address" 796R$* @ $* < @ $* > $* $#error $@ 5.1.3 $: "553 Invalid route address" 797R$* , $~O $* $#error $@ 5.1.3 $: "553 Invalid route address" 798 799 800# now delete the local info -- note $=O to find characters that cause forwarding 801R$* < @ > $* $@ $>Parse0 $>canonify $1 user@ => user 802R< @ $=w . > : $* $@ $>Parse0 $>canonify $2 @here:... -> ... 803R$- < @ $=w . > $: $(dequote $1 $) < @ $2 . > dequote "foo"@here 804R< @ $+ > $#error $@ 5.1.3 $: "553 User address required" 805R$* $=O $* < @ $=w . > $@ $>Parse0 $>canonify $1 $2 $3 ...@here -> ... 806R$- $: $(dequote $1 $) < @ *LOCAL* > dequote "foo" 807R< @ *LOCAL* > $#error $@ 5.1.3 $: "553 User address required" 808R$* $=O $* < @ *LOCAL* > 809 $@ $>Parse0 $>canonify $1 $2 $3 ...@*LOCAL* -> ... 810R$* < @ *LOCAL* > $: $1 811 812 813# 814# Parse1 -- the bottom half of ruleset 0. 815# 816 817SParse1 818 819# handle numeric address spec 820R$* < @ [ $+ ] > $* $: $>ParseLocal $1 < @ [ $2 ] > $3 numeric internet spec 821R$* < @ [ $+ ] > $* $: $1 < @ [ $2 ] : $S > $3 Add smart host to path 822R$* < @ [ $+ ] : > $* $#esmtp $@ [$2] $: $1 < @ [$2] > $3 no smarthost: send 823R$* < @ [ $+ ] : $- : $*> $* $#$3 $@ $4 $: $1 < @ [$2] > $5 smarthost with mailer 824R$* < @ [ $+ ] : $+ > $* $#esmtp $@ $3 $: $1 < @ [$2] > $4 smarthost without mailer 825 826 827# short circuit local delivery so forwarded email works 828 829 830R$=L < @ $=w . > $#local $: @ $1 special local names 831R$+ < @ $=w . > $#local $: $1 regular local name 832 833 834# resolve remotely connected UUCP links (if any) 835 836# resolve fake top level domains by forwarding to other hosts 837 838 839 840# pass names that still have a host to a smarthost (if defined) 841R$* < @ $* > $* $: $>MailerToTriple < $S > $1 < @ $2 > $3 glue on smarthost name 842 843# deal with other remote names 844R$* < @$* > $* $#esmtp $@ $2 $: $1 < @ $2 > $3 user@host.domain 845 846# handle locally delivered names 847R$=L $#local $: @ $1 special local names 848R$+ $#local $: $1 regular local names 849 850 851 852########################################################################### 853### Ruleset 5 -- special rewriting after aliases have been expanded ### 854########################################################################### 855 856SLocal_localaddr 857Slocaladdr=5 858R$+ $: $1 $| $>"Local_localaddr" $1 859R$+ $| $#ok $@ $1 no change 860R$+ $| $#$* $#$2 861R$+ $| $* $: $1 862 863 864 865 866# deal with plussed users so aliases work nicely 867R$+ + * $#local $@ $&h $: $1 868R$+ + $* $#local $@ + $2 $: $1 + * 869 870# prepend an empty "forward host" on the front 871R$+ $: <> $1 872 873 874 875R< > $+ $: < > < $1 <> $&h > nope, restore +detail 876 877R< > < $+ <> + $* > $: < > < $1 + $2 > check whether +detail 878R< > < $+ <> $* > $: < > < $1 > else discard 879R< > < $+ + $* > $* < > < $1 > + $2 $3 find the user part 880R< > < $+ > + $* $#local $@ $2 $: @ $1 strip the extra + 881R< > < $+ > $@ $1 no +detail 882R$+ $: $1 <> $&h add +detail back in 883 884R$+ <> + $* $: $1 + $2 check whether +detail 885R$+ <> $* $: $1 else discard 886R< local : $* > $* $: $>MailerToTriple < local : $1 > $2 no host extension 887R< error : $* > $* $: $>MailerToTriple < error : $1 > $2 no host extension 888 889R< $~[ : $+ > $+ $: $>MailerToTriple < $1 : $2 > $3 < @ $2 > 890 891R< $+ > $+ $@ $>MailerToTriple < $1 > $2 < @ $1 > 892 893 894################################################################### 895### Ruleset 95 -- canonify mailer:[user@]host syntax to triple ### 896################################################################### 897 898SMailerToTriple=95 899R< > $* $@ $1 strip off null relay 900R< error : $-.$-.$- : $+ > $* $#error $@ $1.$2.$3 $: $4 901R< error : $- : $+ > $* $#error $@ $(dequote $1 $) $: $2 902R< error : $+ > $* $#error $: $1 903R< local : $* > $* $>CanonLocal < $1 > $2 904R< $~[ : $+ @ $+ > $*<$*>$* $# $1 $@ $3 $: $2<@$3> use literal user 905R< $~[ : $+ > $* $# $1 $@ $2 $: $3 try qualified mailer 906R< $=w > $* $@ $2 delete local host 907R< $+ > $* $#relay $@ $1 $: $2 use unqualified mailer 908 909################################################################### 910### Ruleset CanonLocal -- canonify local: syntax ### 911################################################################### 912 913SCanonLocal 914# strip local host from routed addresses 915R< $* > < @ $+ > : $+ $@ $>Recurse $3 916R< $* > $+ $=O $+ < @ $+ > $@ $>Recurse $2 $3 $4 917 918# strip trailing dot from any host name that may appear 919R< $* > $* < @ $* . > $: < $1 > $2 < @ $3 > 920 921# handle local: syntax -- use old user, either with or without host 922R< > $* < @ $* > $* $#local $@ $1@$2 $: $1 923R< > $+ $#local $@ $1 $: $1 924 925# handle local:user@host syntax -- ignore host part 926R< $+ @ $+ > $* < @ $* > $: < $1 > $3 < @ $4 > 927 928# handle local:user syntax 929R< $+ > $* <@ $* > $* $#local $@ $2@$3 $: $1 930R< $+ > $* $#local $@ $2 $: $1 931 932################################################################### 933### Ruleset 93 -- convert header names to masqueraded form ### 934################################################################### 935 936SMasqHdr=93 937 938 939# do not masquerade anything in class N 940R$* < @ $* $=N . > $@ $1 < @ $2 $3 . > 941 942R$* < @ *LOCAL* > $@ $1 < @ $j . > 943 944################################################################### 945### Ruleset 94 -- convert envelope names to masqueraded form ### 946################################################################### 947 948SMasqEnv=94 949R$* < @ *LOCAL* > $* $: $1 < @ $j . > $2 950 951################################################################### 952### Ruleset 98 -- local part of ruleset zero (can be null) ### 953################################################################### 954 955SParseLocal=98 956 957 958 959 960 961 962###################################################################### 963### CanonAddr -- Convert an address into a standard form for 964### relay checking. Route address syntax is 965### crudely converted into a %-hack address. 966### 967### Parameters: 968### $1 -- full recipient address 969### 970### Returns: 971### parsed address, not in source route form 972###################################################################### 973 974SCanonAddr 975R$* $: $>Parse0 $>canonify $1 make domain canonical 976 977 978###################################################################### 979### ParseRecipient -- Strip off hosts in $=R as well as possibly 980### $* $=m or the access database. 981### Check user portion for host separators. 982### 983### Parameters: 984### $1 -- full recipient address 985### 986### Returns: 987### parsed, non-local-relaying address 988###################################################################### 989 990SParseRecipient 991R$* $: <?> $>CanonAddr $1 992R<?> $* < @ $* . > <?> $1 < @ $2 > strip trailing dots 993R<?> $- < @ $* > $: <?> $(dequote $1 $) < @ $2 > dequote local part 994 995# if no $=O character, no host in the user portion, we are done 996R<?> $* $=O $* < @ $* > $: <NO> $1 $2 $3 < @ $4> 997R<?> $* $@ $1 998 999 1000R<NO> $* < @ $* $=R > $: <RELAY> $1 < @ $2 $3 > 1001 1002 1003 1004R<RELAY> $* < @ $* > $@ $>ParseRecipient $1 1005R<$+> $* $@ $2 1006 1007 1008###################################################################### 1009### check_relay -- check hostname/address on SMTP startup 1010###################################################################### 1011 1012 1013 1014SLocal_check_relay 1015Scheck_relay 1016R$* $: $1 $| $>"Local_check_relay" $1 1017R$* $| $* $| $#$* $#$3 1018R$* $| $* $| $* $@ $>"Basic_check_relay" $1 $| $2 1019 1020SBasic_check_relay 1021# check for deferred delivery mode 1022R$* $: < $&{deliveryMode} > $1 1023R< d > $* $@ deferred 1024R< $* > $* $: $2 1025 1026 1027 1028###################################################################### 1029### check_mail -- check SMTP `MAIL FROM:' command argument 1030###################################################################### 1031 1032SLocal_check_mail 1033Scheck_mail 1034R$* $: $1 $| $>"Local_check_mail" $1 1035R$* $| $#$* $#$2 1036R$* $| $* $@ $>"Basic_check_mail" $1 1037 1038SBasic_check_mail 1039# check for deferred delivery mode 1040R$* $: < $&{deliveryMode} > $1 1041R< d > $* $@ deferred 1042R< $* > $* $: $2 1043 1044# authenticated? 1045R$* $: $1 $| $>"tls_client" $&{verify} $| MAIL 1046R$* $| $#$+ $#$2 1047R$* $| $* $: $1 1048 1049R<> $@ <OK> we MUST accept <> (RFC 1123) 1050R$+ $: <?> $1 1051R<?><$+> $: <@> <$1> 1052R<?>$+ $: <@> <$1> 1053R$* $: $&{daemon_flags} $| $1 1054R$* f $* $| <@> < $* @ $- > $: < ? $&{client_name} > < $3 @ $4 > 1055R$* u $* $| <@> < $* > $: <?> < $3 > 1056R$* $| $* $: $2 1057# handle case of @localhost on address 1058R<@> < $* @ localhost > $: < ? $&{client_name} > < $1 @ localhost > 1059R<@> < $* @ [127.0.0.1] > 1060 $: < ? $&{client_name} > < $1 @ [127.0.0.1] > 1061R<@> < $* @ [IPv6:0:0:0:0:0:0:0:1] > 1062 $: < ? $&{client_name} > < $1 @ [IPv6:0:0:0:0:0:0:0:1] > 1063R<@> < $* @ [IPv6:::1] > 1064 $: < ? $&{client_name} > < $1 @ [IPv6:::1] > 1065R<@> < $* @ localhost.$m > 1066 $: < ? $&{client_name} > < $1 @ localhost.$m > 1067R<@> < $* @ localhost.UUCP > 1068 $: < ? $&{client_name} > < $1 @ localhost.UUCP > 1069R<@> $* $: $1 no localhost as domain 1070R<? $=w> $* $: $2 local client: ok 1071R<? $+> <$+> $#error $@ 5.5.4 $: "553 Real domain name required for sender address" 1072R<?> $* $: $1 1073R$* $: <?> $>CanonAddr $1 canonify sender address and mark it 1074R<?> $* < @ $+ . > <?> $1 < @ $2 > strip trailing dots 1075# handle non-DNS hostnames (*.bitnet, *.decnet, *.uucp, etc) 1076R<?> $* < @ $* $=P > $: <OKR> $1 < @ $2 $3 > 1077R<?> $* < @ $j > $: <OKR> $1 < @ $j > 1078R<?> $* < @ $+ > $: <? $(resolve $2 $: $2 <PERM> $) > $1 < @ $2 > 1079R<? $* <$->> $* < @ $+ > 1080 $: <$2> $3 < @ $4 > 1081 1082 1083# handle case of no @domain on address 1084R<?> $* $: $&{daemon_flags} $| <?> $1 1085R$* u $* $| <?> $* $: <OKR> $3 1086R$* $| $* $: $2 1087R<?> $* $: < ? $&{client_addr} > $1 1088R<?> $* $@ <OKR> ...local unqualed ok 1089R<? $+> $* $#error $@ 5.5.4 $: "553 Domain name required for sender address " $&f 1090 ...remote is not 1091# check results 1092R<?> $* $: @ $1 mark address: nothing known about it 1093R<$={ResOk}> $* $: @ $2 domain ok 1094R<TEMP> $* $#error $@ 4.1.8 $: "451 Domain of sender address " $&f " does not resolve" 1095R<PERM> $* $#error $@ 5.1.8 $: "553 Domain of sender address " $&f " does not exist" 1096 1097 1098 1099###################################################################### 1100### check_rcpt -- check SMTP `RCPT TO:' command argument 1101###################################################################### 1102 1103SLocal_check_rcpt 1104Scheck_rcpt 1105R$* $: $1 $| $>"Local_check_rcpt" $1 1106R$* $| $#$* $#$2 1107R$* $| $* $@ $>"Basic_check_rcpt" $1 1108 1109SBasic_check_rcpt 1110# empty address? 1111R<> $#error $@ nouser $: "553 User address required" 1112R$@ $#error $@ nouser $: "553 User address required" 1113# check for deferred delivery mode 1114R$* $: < $&{deliveryMode} > $1 1115R< d > $* $@ deferred 1116R< $* > $* $: $2 1117 1118 1119###################################################################### 1120R$* $: $1 $| @ $>"Rcpt_ok" $1 1121R$* $| @ $#TEMP $+ $: $1 $| T $2 1122R$* $| @ $#$* $#$2 1123R$* $| @ RELAY $@ RELAY 1124R$* $| @ $* $: O $| $>"Relay_ok" $1 1125R$* $| T $+ $: T $2 $| $>"Relay_ok" $1 1126R$* $| $#TEMP $+ $#error $2 1127R$* $| $#$* $#$2 1128R$* $| RELAY $@ RELAY 1129R T $+ $| $* $#error $1 1130# anything else is bogus 1131R$* $#error $@ 5.7.1 $: "550 Relaying denied" 1132 1133 1134###################################################################### 1135### Rcpt_ok: is the recipient ok? 1136###################################################################### 1137SRcpt_ok 1138R$* $: $>ParseRecipient $1 strip relayable hosts 1139 1140 1141 1142 1143# authenticated via TLS? 1144R$* $: $1 $| $>RelayTLS client authenticated? 1145R$* $| $# $+ $# $2 error/ok? 1146R$* $| $* $: $1 no 1147 1148R$* $: $1 $| $>"Local_Relay_Auth" $&{auth_type} 1149R$* $| $# $* $# $2 1150R$* $| NO $: $1 1151R$* $| $* $: $1 $| $&{auth_type} 1152R$* $| $: $1 1153R$* $| $={TrustAuthMech} $# RELAY 1154R$* $| $* $: $1 1155# anything terminating locally is ok 1156R$+ < @ $=w > $@ RELAY 1157R$+ < @ $* $=R > $@ RELAY 1158 1159 1160 1161 1162# check for local user (i.e. unqualified address) 1163R$* $: <?> $1 1164R<?> $* < @ $+ > $: <REMOTE> $1 < @ $2 > 1165# local user is ok 1166R<?> $+ $@ RELAY 1167R<$+> $* $: $2 1168 1169###################################################################### 1170### Relay_ok: is the relay/sender ok? 1171###################################################################### 1172SRelay_ok 1173# anything originating locally is ok 1174# check IP address 1175R$* $: $&{client_addr} 1176R$@ $@ RELAY originated locally 1177R0 $@ RELAY originated locally 1178R127.0.0.1 $@ RELAY originated locally 1179RIPv6:0:0:0:0:0:0:0:1 $@ RELAY originated locally 1180RIPv6:::1 $@ RELAY originated locally 1181R$=R $* $@ RELAY relayable IP address 1182R$* $: [ $1 ] put brackets around it... 1183R$=w $@ RELAY ... and see if it is local 1184 1185 1186# check client name: first: did it resolve? 1187R$* $: < $&{client_resolve} > 1188R<TEMP> $#TEMP $@ 4.4.0 $: "450 Relaying temporarily denied. Cannot resolve PTR record for " $&{client_addr} 1189R<FORGED> $#error $@ 5.7.1 $: "550 Relaying denied. IP name possibly forged " $&{client_name} 1190R<FAIL> $#error $@ 5.7.1 $: "550 Relaying denied. IP name lookup failed " $&{client_name} 1191R$* $: <@> $&{client_name} 1192# pass to name server to make hostname canonical 1193R<@> $* $=P $:<?> $1 $2 1194R<@> $+ $:<?> $[ $1 $] 1195R$* . $1 strip trailing dots 1196R<?> $=w $@ RELAY 1197R<?> $* $=R $@ RELAY 1198 1199 1200 1201 1202 1203###################################################################### 1204### trust_auth: is user trusted to authenticate as someone else? 1205### 1206### Parameters: 1207### $1: AUTH= parameter from MAIL command 1208###################################################################### 1209 1210SLocal_trust_auth 1211Strust_auth 1212R$* $: $&{auth_type} $| $1 1213# required by RFC 2554 section 4. 1214R$@ $| $* $#error $@ 5.7.1 $: "550 not authenticated" 1215R$* $| $&{auth_authen} $@ identical 1216R$* $| <$&{auth_authen}> $@ identical 1217R$* $| $* $: $1 $| $>"Local_trust_auth" $2 1218R$* $| $#$* $#$2 1219R$* $#error $@ 5.7.1 $: "550 " $&{auth_authen} " not allowed to act as " $&{auth_author} 1220 1221###################################################################### 1222### Relay_Auth: allow relaying based on authentication? 1223### 1224### Parameters: 1225### $1: ${auth_type} 1226###################################################################### 1227SLocal_Relay_Auth 1228 1229###################################################################### 1230### srv_features: which features to offer to a client? 1231### (done in server) 1232###################################################################### 1233Ssrv_features 1234 1235 1236###################################################################### 1237### clt_features: which features to use with a server? 1238### (done in client) 1239###################################################################### 1240Sclt_features 1241 1242 1243###################################################################### 1244### try_tls: try to use STARTTLS? 1245### (done in client) 1246###################################################################### 1247Stry_tls 1248 1249 1250 1251###################################################################### 1252### tls_rcpt: is connection with server "good" enough? 1253### (done in client, per recipient) 1254### 1255### Parameters: 1256### $1: recipient 1257###################################################################### 1258Stls_rcpt 1259 1260 1261###################################################################### 1262### tls_client: is connection with client "good" enough? 1263### (done in server) 1264### 1265### Parameters: 1266### ${verify} $| (MAIL|STARTTLS) 1267###################################################################### 1268Stls_client 1269R$* $| $* $@ $>"TLS_connection" $1 1270 1271###################################################################### 1272### tls_server: is connection with server "good" enough? 1273### (done in client) 1274### 1275### Parameter: 1276### ${verify} 1277###################################################################### 1278Stls_server 1279 1280R$* $@ $>"TLS_connection" $1 1281 1282###################################################################### 1283### TLS_connection: is TLS connection "good" enough? 1284### 1285### Parameters: 1286### ${verify} 1287### Requirement: RHS from access map, may be ? for none. 1288###################################################################### 1289STLS_connection 1290RSOFTWARE $#error $@ 4.7.0 $: "454 TLS handshake failed." 1291RDANE_FAIL $#error $@ 4.7.0 $: "454 DANE check failed." 1292RPROTOCOL $#error $@ 4.7.0 $: "454 STARTTLS failed." 1293RCONFIG $#error $@ 4.7.0 $: "454 STARTTLS temporarily not possible." 1294 1295 1296 1297 1298 1299 1300###################################################################### 1301### RelayTLS: allow relaying based on TLS authentication 1302### 1303### Parameters: 1304### none 1305###################################################################### 1306SRelayTLS 1307# authenticated? 1308 1309###################################################################### 1310### authinfo: lookup authinfo in the access map 1311### 1312### Parameters: 1313### $1: {server_name} 1314### $2: {server_addr} 1315###################################################################### 1316Sauthinfo 1317 1318 1319 1320 1321 1322 1323 1324 1325SLocal_localaddr 1326R$+ $: $>ParseRecipient $1 1327R$* < @ $+ > $* $#relay $@ ${MTAHost} $: $1 < @ $2 > $3 1328# DECnet 1329R$+ :: $+ $#relay $@ ${MTAHost} $: $1 :: $2 1330R$* $#relay $@ ${MTAHost} $: $1 < @ $j > 1331# 1332###################################################################### 1333###################################################################### 1334##### 1335##### MAIL FILTER DEFINITIONS 1336##### 1337###################################################################### 1338###################################################################### 1339 1340# 1341###################################################################### 1342###################################################################### 1343##### 1344##### MAILER DEFINITIONS 1345##### 1346###################################################################### 1347###################################################################### 1348 1349 1350################################################## 1351### Local and Program Mailer specification ### 1352################################################## 1353 1354##### $Id: local.m4,v 8.60 2013-11-22 20:51:14 ca Exp $ ##### 1355 1356# 1357# Envelope sender rewriting 1358# 1359SEnvFromL 1360R<@> $n errors to mailer-daemon 1361R@ <@ $*> $n temporarily bypass Sun bogosity 1362R$+ $: $>AddDomain $1 add local domain if needed 1363R$* $: $>MasqEnv $1 do masquerading 1364 1365# 1366# Envelope recipient rewriting 1367# 1368SEnvToL 1369R$+ < @ $* > $: $1 strip host part 1370R$+ + $* $: < $&{addr_type} > $1 + $2 mark with addr type 1371R<e s> $+ + $* $: $1 remove +detail for sender 1372R< $* > $+ $: $2 else remove mark 1373 1374# 1375# Header sender rewriting 1376# 1377SHdrFromL 1378R<@> $n errors to mailer-daemon 1379R@ <@ $*> $n temporarily bypass Sun bogosity 1380R$+ $: $>AddDomain $1 add local domain if needed 1381R$* $: $>MasqHdr $1 do masquerading 1382 1383# 1384# Header recipient rewriting 1385# 1386SHdrToL 1387R$+ $: $>AddDomain $1 add local domain if needed 1388R$* < @ *LOCAL* > $* $: $1 < @ $j . > $2 1389 1390# 1391# Common code to add local domain name (only if always-add-domain) 1392# 1393SAddDomain 1394 1395Mlocal, P=[IPC], F=lmDFMuXkw5, S=EnvFromL/HdrFromL, R=EnvToL/HdrToL, 1396 T=DNS/RFC822/SMTP, 1397 A=TCP $h 1398Mprog, P=[IPC], F=lmDFMuXk5, S=EnvFromL/HdrFromL, R=EnvToL/HdrToL, D=$z:/, 1399 T=X-Unix/X-Unix/X-Unix, 1400 A=TCP $h 1401 1402##################################### 1403### SMTP Mailer specification ### 1404##################################### 1405 1406##### $Id: smtp.m4,v 8.66 2013-11-22 20:51:14 ca Exp $ ##### 1407 1408# 1409# common sender and masquerading recipient rewriting 1410# 1411SMasqSMTP 1412R$* < @ $* > $* $@ $1 < @ $2 > $3 already fully qualified 1413R$+ $@ $1 < @ *LOCAL* > add local qualification 1414 1415# 1416# convert pseudo-domain addresses to real domain addresses 1417# 1418SPseudoToReal 1419 1420# pass <route-addr>s through 1421R< @ $+ > $* $@ < @ $1 > $2 resolve <route-addr> 1422 1423# output fake domains as user%fake@relay 1424 1425# do UUCP heuristics; note that these are shared with UUCP mailers 1426R$+ < @ $+ .UUCP. > $: < $2 ! > $1 convert to UUCP form 1427R$+ < @ $* > $* $@ $1 < @ $2 > $3 not UUCP form 1428 1429# leave these in .UUCP form to avoid further tampering 1430R< $&h ! > $- ! $+ $@ $2 < @ $1 .UUCP. > 1431R< $&h ! > $-.$+ ! $+ $@ $3 < @ $1.$2 > 1432R< $&h ! > $+ $@ $1 < @ $&h .UUCP. > 1433R< $+ ! > $+ $: $1 ! $2 < @ $Y > use UUCP_RELAY 1434R$+ < @ $~[ $* : $+ > $@ $1 < @ $4 > strip mailer: part 1435R$+ < @ > $: $1 < @ *LOCAL* > if no UUCP_RELAY 1436 1437 1438# 1439# envelope sender rewriting 1440# 1441SEnvFromSMTP 1442R$+ $: $>PseudoToReal $1 sender/recipient common 1443R$* :; <@> $@ list:; special case 1444R$* $: $>MasqSMTP $1 qualify unqual'ed names 1445R$+ $: $>MasqEnv $1 do masquerading 1446 1447 1448# 1449# envelope recipient rewriting -- 1450# also header recipient if not masquerading recipients 1451# 1452SEnvToSMTP 1453R$+ $: $>PseudoToReal $1 sender/recipient common 1454R$+ $: $>MasqSMTP $1 qualify unqual'ed names 1455R$* < @ *LOCAL* > $* $: $1 < @ $j . > $2 1456 1457# 1458# header sender and masquerading header recipient rewriting 1459# 1460SHdrFromSMTP 1461R$+ $: $>PseudoToReal $1 sender/recipient common 1462R:; <@> $@ list:; special case 1463 1464# do special header rewriting 1465R$* <@> $* $@ $1 <@> $2 pass null host through 1466R< @ $* > $* $@ < @ $1 > $2 pass route-addr through 1467R$* $: $>MasqSMTP $1 qualify unqual'ed names 1468R$+ $: $>MasqHdr $1 do masquerading 1469 1470 1471# 1472# relay mailer header masquerading recipient rewriting 1473# 1474SMasqRelay 1475R$+ $: $>MasqSMTP $1 1476R$+ $: $>MasqHdr $1 1477 1478Msmtp, P=[IPC], F=mDFMuXk5, S=EnvFromSMTP/HdrFromSMTP, R=EnvToSMTP, E=\r\n, L=990, 1479 T=DNS/RFC822/SMTP, 1480 A=TCP $h 1481Mesmtp, P=[IPC], F=mDFMuXak5, S=EnvFromSMTP/HdrFromSMTP, R=EnvToSMTP, E=\r\n, L=990, 1482 T=DNS/RFC822/SMTP, 1483 A=TCP $h 1484Msmtp8, P=[IPC], F=mDFMuX8k5, S=EnvFromSMTP/HdrFromSMTP, R=EnvToSMTP, E=\r\n, L=990, 1485 T=DNS/RFC822/SMTP, 1486 A=TCP $h 1487Mdsmtp, P=[IPC], F=mDFMuXa%k5, S=EnvFromSMTP/HdrFromSMTP, R=EnvToSMTP, E=\r\n, L=990, 1488 T=DNS/RFC822/SMTP, 1489 A=TCP $h 1490Mrelay, P=[IPC], F=mDFMuXa8k, S=EnvFromSMTP/HdrFromSMTP, R=MasqSMTP, E=\r\n, L=2040, 1491 T=DNS/RFC822/SMTP, 1492 A=TCP $h 1493 1494 1495### submit.mc ### 1496# divert(-1) 1497# # 1498# # Copyright (c) 2001-2003, 2014 Proofpoint, Inc. and its suppliers. 1499# # All rights reserved. 1500# # 1501# # By using this file, you agree to the terms and conditions set 1502# # forth in the LICENSE file which can be found at the top level of 1503# # the sendmail distribution. 1504# # 1505# # 1506# 1507# # 1508# # This is the prototype file for a set-group-ID sm-msp sendmail that 1509# # acts as a initial mail submission program. 1510# # 1511# 1512# divert(0)dnl 1513# VERSIONID(`$Id: submit.mc,v 8.15 2013-11-22 20:51:08 ca Exp $') 1514# define(`confCF_VERSION', `Submit')dnl 1515# define(`__OSTYPE__',`')dnl dirty hack to keep proto.m4 from complaining 1516# define(`_USE_DECNET_SYNTAX_', `1')dnl support DECnet 1517# define(`confTIME_ZONE', `USE_TZ')dnl 1518# define(`confDONT_INIT_GROUPS', `True')dnl 1519# dnl 1520# dnl If you use IPv6 only, change [127.0.0.1] to [IPv6:0:0:0:0:0:0:0:1] 1521# FEATURE(`msp', `[127.0.0.1]')dnl 1522# dnl enable this for SMTPUTF8 support 1523# dnl LOCAL_CONFIG 1524# dnl O SMTPUTF8=true 1525