Advertisement
Guest User

/etc/postfix/main.cf

a guest
Oct 16th, 2019
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.30 KB | None | 0 0
  1. # See /usr/share/postfix/main.cf.dist for a commented, more complete version
  2. # Debian specific: Specifying a file name will cause the first
  3. # line of that file to be used as the name. The Debian default
  4. # is /etc/mailname.
  5. #myorigin = /etc/mailname
  6.  
  7. smtpd_banner = $myhostname ESMTP
  8. biff = no
  9.  
  10. # appending .domain is the MUA's job.
  11. append_dot_mydomain = no
  12.  
  13. # Uncomment the next line to generate "delayed mail" warnings
  14. #delay_warning_time = 4h
  15.  
  16. readme_directory = no
  17.  
  18. # TLS parameters
  19. smtpd_tls_cert_file = /etc/ssl/certs/mail-selfsigned.crt
  20. smtpd_tls_key_file = /etc/ssl/private/mail-selfsigned.key
  21. smtpd_tls_security_level = may
  22. smtpd_tls_auth_only = yes
  23. smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
  24.  
  25. smtp_tls_security_level = may
  26. smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
  27. smtp_tls_CApath = /etc/ssl/certs
  28.  
  29. # See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
  30. # information on enabling SSL in the smtp client.
  31.  
  32. myhostname = mail.4skill.ru
  33. alias_maps = hash:/etc/aliases
  34. alias_database = hash:/etc/aliases
  35. myorigin = /etc/mailname
  36. mydestination =
  37. relayhost =
  38. mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
  39. mailbox_size_limit = 0
  40. recipient_delimiter = +
  41. inet_interfaces = all
  42. inet_protocols = all
  43. compatibility_level = 2
  44. message_size_limit = 15630000
  45.  
  46. # Virtual Domain parameters
  47. virtual_mailbox_domains = 4skill.ru
  48. smtpd_sender_login_maps = proxy:ldap:/etc/postfix/ad_sender_login_maps.cf
  49. virtual_mailbox_maps = proxy:ldap:/etc/postfix/ad_virtual_mailbox_maps.cf
  50. virtual_alias_maps = proxy:ldap:/etc/postfix/ad_virtual_group_maps.cf
  51. virtual_uid_maps = static:1001
  52. virtual_gid_maps = static:1001
  53. virtual_mailbox_base = /var/vmail
  54.  
  55. # Virtual Transport
  56. dovecot_destination_recipient_limit = 1
  57. virtual_transport = dovecot
  58.  
  59. # SASL
  60. smtpd_sasl_auth_enable = yes
  61. smtpd_sasl_type = dovecot
  62. smtpd_sasl_path = private/auth
  63.  
  64. # Restrictions
  65. smtpd_client_restrictions =
  66. permit_mynetworks
  67. check_client_access hash:/etc/postfix/client_access
  68. reject_unknown_client_hostname
  69.  
  70. mua_client_restrictions =
  71. check_client_access hash:/etc/postfix/client_access
  72.  
  73. smtpd_helo_required = yes
  74.  
  75. smtpd_helo_restrictions =
  76. permit_mynetworks
  77. check_helo_access hash:/etc/postfix/helo_access
  78. reject_invalid_helo_hostname
  79. reject_non_fqdn_helo_hostname
  80. reject_unknown_helo_hostname
  81.  
  82. mua_helo_restrictions =
  83. check_helo_access hash:/etc/postfix/helo_access
  84. reject_invalid_helo_hostname
  85.  
  86. smtpd_sender_restrictions =
  87. permit_mynetworks
  88. check_sender_access hash:/etc/postfix/sender_access
  89. reject_non_fqdn_sender
  90. reject_unknown_sender_domain
  91. reject_sender_login_mismatch
  92. reject_unlisted_sender
  93.  
  94. mua_sender_restrictions =
  95. check_sender_access hash:/etc/postfix/sender_access
  96. reject_sender_login_mismatch
  97.  
  98. smtpd_relay_restrictions =
  99. permit_mynetworks
  100. permit_sasl_authenticated
  101. defer_unauth_destination
  102.  
  103. smtpd_recipient_restrictions =
  104. reject_non_fqdn_recipient
  105. reject_unknown_recipient_domain
  106. check_policy_service inet:127.0.0.1:12340
  107.  
  108. smtpd_data_restrictions =
  109. reject_unauth_pipelining
  110. reject_multi_recipient_bounce
  111.  
  112. smtpd_etrn_restrictions =
  113. permit_mynetworks
  114. reject
  115.  
  116. disable_vrfy_command = yes
  117. smtpd_discard_ehlo_keywords = vrfy etrn
  118.  
  119. header_checks = regexp:/etc/postfix/header_check
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement