master.cf 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. # inter-mx with postscreen on 25/tcp
  2. smtp inet n - n - 1 postscreen
  3. smtpd pass - - n - - smtpd
  4. -o smtpd_helo_restrictions=permit_mynetworks,reject_non_fqdn_helo_hostname
  5. -o smtpd_sasl_auth_enable=no
  6. -o smtpd_sender_restrictions=permit_mynetworks,reject_unlisted_sender,reject_unknown_sender_domain
  7. # smtpd tls-wrapped (smtps) on 465/tcp
  8. # TLS protocol can be modified by setting smtps_smtpd_tls_mandatory_protocols in extra.cf
  9. smtps inet n - n - - smtpd
  10. -o smtpd_tls_wrappermode=yes
  11. -o smtpd_client_restrictions=permit_mynetworks,permit_sasl_authenticated,reject
  12. -o smtpd_tls_mandatory_protocols=$smtps_smtpd_tls_mandatory_protocols
  13. -o tls_preempt_cipherlist=yes
  14. -o syslog_name=postfix/smtps
  15. # smtpd with starttls on 587/tcp
  16. # TLS protocol can be modified by setting submission_smtpd_tls_mandatory_protocols in extra.cf
  17. submission inet n - n - - smtpd
  18. -o smtpd_client_restrictions=permit_mynetworks,permit_sasl_authenticated,reject
  19. -o smtpd_enforce_tls=yes
  20. -o smtpd_tls_security_level=encrypt
  21. -o smtpd_tls_mandatory_protocols=$submission_smtpd_tls_mandatory_protocols
  22. -o tls_preempt_cipherlist=yes
  23. -o syslog_name=postfix/submission
  24. # used by SOGo
  25. # smtpd_sender_restrictions should match main.cf, but with check_sasl_access prepended for login-as-mailbox-user function
  26. 588 inet n - n - - smtpd
  27. -o smtpd_client_restrictions=permit_mynetworks,permit_sasl_authenticated,reject
  28. -o smtpd_tls_auth_only=no
  29. -o smtpd_sender_restrictions=check_sasl_access,regexp:/opt/postfix/conf/allow_mailcow_local.regexp,reject_authenticated_sender_login_mismatch,permit_mynetworks,permit_sasl_authenticated,reject_unlisted_sender,reject_unknown_sender_domain
  30. -o syslog_name=postfix/sogo
  31. # used to reinject quarantine mails
  32. 590 inet n - n - - smtpd
  33. -o smtpd_helo_restrictions=
  34. -o smtpd_client_restrictions=permit_mynetworks,reject
  35. -o smtpd_tls_auth_only=no
  36. -o smtpd_milters=
  37. -o non_smtpd_milters=
  38. -o syslog_name=postfix/quarantine
  39. # enforced smtp connector
  40. smtp_enforced_tls unix - - n - - smtp
  41. -o smtp_tls_security_level=encrypt
  42. -o syslog_name=enforced-tls-smtp
  43. -o smtp_delivery_status_filter=pcre:/opt/postfix/conf/smtp_dsn_filter
  44. # smtp connector used, when a transport map matched
  45. # this helps to have different sasl maps than we have with sender dependent transport maps
  46. smtp_via_transport_maps unix - - n - - smtp
  47. -o smtp_sasl_password_maps=proxy:mysql:/opt/postfix/conf/sql/mysql_sasl_passwd_maps_transport_maps.cf
  48. tlsproxy unix - - n - 0 tlsproxy
  49. dnsblog unix - - n - 0 dnsblog
  50. pickup fifo n - n 60 1 pickup
  51. cleanup unix n - n - 0 cleanup
  52. qmgr fifo n - n 300 1 qmgr
  53. tlsmgr unix - - n 1000? 1 tlsmgr
  54. rewrite unix - - n - - trivial-rewrite
  55. bounce unix - - n - 0 bounce
  56. defer unix - - n - 0 bounce
  57. trace unix - - n - 0 bounce
  58. verify unix - - n - 1 verify
  59. flush unix n - n 1000? 0 flush
  60. proxymap unix - - n - - proxymap
  61. proxywrite unix - - n - 1 proxymap
  62. smtp unix - - n - - smtp
  63. relay unix - - n - - smtp
  64. showq unix n - n - - showq
  65. error unix - - n - - error
  66. retry unix - - n - - error
  67. discard unix - - n - - discard
  68. local unix - n n - - local
  69. virtual unix - n n - - virtual
  70. lmtp unix - - n - - lmtp
  71. anvil unix - - n - 1 anvil
  72. scache unix - - n - 1 scache
  73. maildrop unix - n n - - pipe flags=DRhu
  74. user=vmail argv=/usr/bin/maildrop -d ${recipient}
  75. # start whitelist_fwd
  76. 127.0.0.1:10027 inet n n n - 0 spawn user=nobody argv=/usr/local/bin/whitelist_forwardinghosts.sh
  77. # end whitelist_fwd
  78. # start watchdog-specific
  79. # logs to local7 (hidden)
  80. 589 inet n - n - - smtpd
  81. -o smtpd_client_restrictions=permit_mynetworks,reject
  82. -o syslog_name=watchdog
  83. -o syslog_facility=local7
  84. -o smtpd_milters=
  85. -o cleanup_service_name=watchdog_cleanup
  86. -o non_smtpd_milters=
  87. watchdog_cleanup unix n - n - 0 cleanup
  88. -o syslog_name=watchdog
  89. -o syslog_facility=local7
  90. -o queue_service_name=watchdog_qmgr
  91. watchdog_qmgr fifo n - n 300 1 qmgr
  92. -o syslog_facility=local7
  93. -o syslog_name=watchdog
  94. -o rewrite_service_name=watchdog_rewrite
  95. watchdog_rewrite unix - - n - - trivial-rewrite
  96. -o syslog_facility=local7
  97. -o syslog_name=watchdog
  98. -o local_transport=watchdog_discard
  99. watchdog_discard unix - - n - - discard
  100. -o syslog_facility=local7
  101. -o syslog_name=watchdog
  102. # end watchdog-specific