Advertisement
Guest User

Untitled

a guest
May 26th, 2017
614
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.13 KB | None | 0 0
  1. /* POSTCONF -N*/
  2. append_dot_mydomain = no
  3. biff = no
  4. broken_sasl_auth_clients = yes
  5. config_directory = /etc/postfix
  6. delay_warning_time = 4h
  7. disable_vrfy_command = yes
  8. home_mailbox = Maildir/
  9. inet_interfaces = all
  10. inet_protocols = ipv4
  11. local_recipient_maps = $virtual_mailbox_maps
  12. local_transport = virtual
  13. mailbox_command = procmail -a "$EXTENSION"
  14. mailbox_size_limit = 0
  15. maximal_backoff_time = 8000s
  16. maximal_queue_lifetime = 7d
  17. minimal_backoff_time = 1000s
  18. mydestination = #$mydomain, $myhostname, localhost
  19. myhostname = mail.my_domain.com
  20. mynetworks = 127.0.0.0/8
  21. myorigin = my_domain.com
  22. readme_directory = no
  23. recipient_delimiter = +
  24. relayhost =
  25. smtp_helo_timeout = 60s
  26. smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
  27. smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
  28. smtpd_client_restrictions = reject_rbl_client sbl.spamhaus.org, reject_rbl_client blackholes.easynet.nl, reject_rbl_client dnsbl.njabl.org
  29. smtpd_delay_reject = yes
  30. smtpd_hard_error_limit = 12
  31. smtpd_helo_required = yes
  32. smtpd_helo_restrictions = permit_mynetworks, warn_if_reject reject_non_fqdn_hostname, reject_invalid_hostname, permit
  33. smtpd_recipient_limit = 16
  34. smtpd_recipient_restrictions = permit_sasl_authenticated, reject_unauth_pipelining, permit_mynetworks, reject_non_fqdn_recipient, reject_unknown_recipient_domain, reject_unauth_destination, permit smtpd_data_restrictions = reject_unauth_pipelining
  35. smtpd_sasl_auth_enable = yes
  36. smtpd_sasl_local_domain =
  37. smtpd_sasl_security_options = noanonymous
  38. smtpd_sender_restrictions = permit_sasl_authenticated, permit_mynetworks, warn_if_reject reject_non_fqdn_sender, reject_unknown_sender_domain, reject_unauth_pipelining, permit
  39. smtpd_soft_error_limit = 3
  40. smtpd_tls_cert_file = /etc/ssl/certs/ssl-cert-snakeoil.pem
  41. smtpd_tls_key_file = /etc/ssl/private/ssl-cert-snakeoil.key
  42. smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
  43. smtpd_use_tls = yes
  44. unknown_local_recipient_reject_code = 450
  45. virtual_alias_maps = proxy:mysql:/etc/postfix/mysql/virtual_alias_maps.cf
  46. virtual_gid_maps = static:8
  47. virtual_mailbox_base = /var/mail/vmail
  48. virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql/virtual_domains_maps.cf
  49. virtual_mailbox_limit = 512000000
  50. virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql/virtual_mailbox_maps.cf
  51. virtual_minimum_uid = 8
  52. virtual_transport = virtual
  53. virtual_uid_maps = static:8
  54.  
  55. /* /etc/postfix/sasl/smtpd.conf*/
  56. pwcheck_method: saslauthd
  57. saslauthd_path: /var/run/saslauthd/mux
  58. log_level: 7
  59. mech_list: PLAIN LOGIN
  60. auxprop_plugin: mysql
  61. allow_plaintext: true
  62. sql_engine: mysql
  63. sql_hostnames: 127.0.0.1
  64. sql_user: postfix
  65. sql_passwd: password
  66. sql_database: postfixadmin
  67. sql_select: select password from mailbox where username = '%u'
  68.  
  69. /*/etc/pam.d/smtp*/
  70. #
  71. # /etc/pam.d/other - specify the PAM fallback behaviour
  72. #
  73. # Note that this file is used for any unspecified service; for example
  74. #if /etc/pam.d/cron specifies no session modules but cron calls
  75. #pam_open_session, the session module out of /etc/pam.d/other is
  76. #used. If you really want nothing to happen then use pam_permit.so or
  77. #pam_deny.so as appropriate.
  78.  
  79. # We fall back to the system default in /etc/pam.d/common-*
  80. #
  81.  
  82. auth required pam_mysql.so user=postfix passwd=password host=127.0.0.1 db=postfixadmin table=mailbox usercolumn=username passwdcolumn=password crypt=1
  83. account sufficient pam_mysql.so user=postfix passwd=password host=127.0.0.1 db=postfixadmin table=mailbox usercolumn=username passwdcolumn=password crypt=1
  84.  
  85. /////
  86.  
  87. Here the error message from syslog : "SASL PLAIN authentication failed: authentication failure"
  88.  
  89. Here the error messages from auth.log :
  90. May 17 11:51:09 host postfix/smtpd[17405]: sql auxprop plugin using mysql engine
  91. May 17 11:51:09 host saslauthd[17276]: DEBUG: auth_pam: pam_authenticate failed: Authentication failure
  92. May 17 11:51:09 host saslauthd[17276]: do_auth : auth failure: [user=user@domain.com] [service=smtp] [realm=domain.com] [mech=pam] [reason=PAM auth error]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement