```html
Je dispose d'un serveur sur lequel je veux configurer un serveur de messagerie pour me permettre de recevoir et d'envoyer des e-mails depuis mon domaine. Actuellement, j'ai un problème où je suis autorisé à envoyer des e-mails depuis le serveur, mais selon les journaux, je ne suis pas autorisé à recevoir des e-mails de tout fournisseur autre que mon propre réseau.
Je suis en train de suivre ce tutoriel, qui montre comment configurer un serveur de messagerie en utilisant Postfix, Dovecot et MySQL en tant que backend (ici).
Journaux pertinents:
Jan 6 13:55:49 mail postfix/smtpd[26857]: permit_mynetworks: mail-la0-f50.google.com 209.85.215.50
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_hostname: mail-la0-f50.google.com ~? 127.0.0.0/8
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_hostaddr: 209.85.215.50 ~? 127.0.0.0/8
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_hostname: mail-la0-f50.google.com ~? 127.0.0.2/32
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_hostaddr: 209.85.215.50 ~? 127.0.0.2/32
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_hostname: mail-la0-f50.google.com ~? 192.99.104.50/32
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_hostaddr: 209.85.215.50 ~? 192.99.104.50/32
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_hostname: mail-la0-f50.google.com ~? [::1]/128
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_hostaddr: 209.85.215.50 ~? [::1]/128
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_list_match: mail-la0-f50.google.com: no match
Jan 6 13:55:49 mail postfix/smtpd[26857]: match_list_match: 209.85.215.50: no match
Jan 6 13:55:49 mail postfix/smtpd[26857]: generic_checks: name=permit_mynetworks status=0
Jan 6 13:55:49 mail postfix/smtpd[26857]: generic_checks: name=reject_unauth_destination
Jan 6 13:55:49 mail postfix/smtpd[26857]: reject_unauth_destination: me@duper51.com
Jan 6 13:55:49 mail postfix/smtpd[26857]: permit_auth_destination: me@duper51.com`
Jan 6 13:55:49 mail postfix/smtpd[26857]: ctable_locate: leave existing entry key me@duper51.com`
Jan 6 13:55:49 mail postfix/smtpd[26857]: NOQUEUE: reject: RCPT from mail-la0-f50.google.com[209.85.215.50]: 554 5.7.1 mail-la0-f50.google.com[209.85.215.50]: 554 5.7.1 : Relay access denied`
Jan 6 13:55:49 mail postfix/smtpd[26857]: < mail-la0-f50.google.com[209.85.215.50]: DATA`
Jan 6 13:55:49 mail postfix/smtpd[26857]: > mail-la0-f50.google.com[209.85.215.50]: 554 5.5.1 Error: no valid recipients`
Jan 6 13:55:49 mail postfix/smtpd[26857]: < mail-la0-f50.google.com[209.85.215.50]: QUIT`
Jan 6 13:55:49 mail postfix/smtpd[26857]: > mail-la0-f50.google.com[209.85.215.50]: 221 2.0.0`
Mon main.cf
:
smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no
# appending .domain is the MUA's job.
append_dot_mydomain = no
# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h
readme_directory = no
smtpd_tls_cert_file=/etc/ssl/certs/dovecot.pem
smtpd_tls_key_file=/etc/ssl/private/dovecot.pem
smtpd_use_tls=yes
smtpd_tls_auth_only = yes
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth
smtpd_sasl_auth_enable = yes
virtual_transport = lmtp:unix:private/dovecot-lmtp
virtual_mailbox_domains = mysql:/etc/postfix/mysql-virtual-mailbox-domains.cf
virtual_mailbox_maps = mysql:/etc/postfix/mysql-virtual-mailbox-maps.cf
virtual_alias_maps = mysql:/etc/postfix/mysql-virtual-alias-maps.cf
smtpd_recipient_restrictions =
permit_sasl_authenticated,
permit_mynetworks,
reject_unauth_destination
smtpd_relay_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.
myhostname = duper51.com
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
#mydestination = duper51.com, mail.duper51.com, localhost
mydestination = localhost
relayhost =
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
inet_protocols = ipv4
```