X-Git-Url: https://git.deb.at/?p=debienna.git;a=blobdiff_plain;f=LittleMailserverSMTP%2Findex.mdwn;h=c78039ea8dd094b71c8b91fa95b44e8711a6aa2a;hp=f98eb3ea089b5a0e91351ee337cdeb66205f075e;hb=1987a8a6713d85e7b26df584f69a177ce546e4ff;hpb=bb58b440ee60e34e1c961060195598787087c131 diff --git a/LittleMailserverSMTP/index.mdwn b/LittleMailserverSMTP/index.mdwn index f98eb3e..c78039e 100644 --- a/LittleMailserverSMTP/index.mdwn +++ b/LittleMailserverSMTP/index.mdwn @@ -1,128 +1,127 @@ -Um noch eine SMTP Auth anzubieten um seine Clients beim Versenden zu authentifieren müssen folgende Dateien so verändert werden: - -'''main.cf''' -{{{ -myhostname = mail.hostname.com -myorigin = /etc/mailname - -alias_maps = $alias_database -virtual_mailbox_domains = hash:/etc/postfix/virtual_domains - -virtual_mailbox_base = /srv/vmail - -virtual_alias_maps = hash:/etc/postfix/virtual_maps -#virtual_minimum_uid = 101 - -virtual_uid_maps = static:5000 -virtual_gid_maps = static:5000 - -virtual_transport = dovecot - -virtual_mailbox_limit = 10240000 - -# dovecot_destination_recipient_limit = 1 - -mydestination = localhost -mynetworks = 127.0.0.0/8 - -smtpd_banner = $myhostname ESMTP Mailserver -home_mailbox = mails/ - -# Zertifikate für SMTP -smtpd_tls_cert_file = /etc/postfix/mail.cert -smtpd_tls_key_file = /etc/postfix/mail.key - -# SMTP Einstellungen -smtpd_use_tls = yes -#tpd_enforce_tls = no -smtpd_tls_auth_only = no - -# SALS Auth für Dovecot -smtpd_sasl_auth_enable = yes -smtpd_sasl_type = dovecot -smtpd_sasl_path = private/auth -smtpd_sasl_security_options = noanonymous -smtpd_sasl_local_domain = -smtp_sasl_auth_enable = no -broken_sasl_auth_clients = yes - -# Mailbox Einstellungen -mailbox_size_limit = 512000000 -message_size_limit = 104857600 - - -# Antispam Confis -smtpd_helo_required = yes -smtpd_helo_restrictions = reject_invalid_hostname - -smtpd_recipient_restrictions = permit_mynetworks, reject_unknown_recipient_domain, permit_sasl_authenticated, reject_unauth_destination - -smtpd_sender_restrictions = reject_unknown_address - -smtpd_client_restrictions = reject_invalid_hostname - -strict_rfc821_envelopes = yes -}}} - -'''Diese Zeile in der master.cf''' -{{{ -smtp inet n - n - - smtpd -}}} - -'''dovecot.conf''' -{{{ -base_dir = /var/run/dovecot/ -# log_path = /var/log/dovecot.log -protocols = imap -ssl_disable = no -verbose_proctitle = yes -#first_valid_uid = 3000 -#last_valid_uid = 3000 -#first_valid_gid = 8 -#last_valid_gid = 8 -#valid_chroot_dirs = /var/mail -mail_location = maildir:~/Maildir -maildir_copy_with_hardlinks = yes - -disable_plaintext_auth = yes - -protocol imap { -} - -# auth_verbose = yes - -auth default { - socket listen { - - client { - path = /var/spool/postfix/private/auth - mode = 0660 - user = postfix - group = postfix - } - - master { - path = /var/run/dovecot/auth-master - mode = 0600 - user = vmail - group = vmail - } - - } - mechanisms = plain - - passdb passwd-file { - args = /etc/dovecot/dovecot.passwd - } - passdb pam { - } - userdb static { - args = uid=vmail gid=vmail home=/srv/vmail/%u - } - -} - -protocol lda { - postmaster_address = postmaster@hostname.com -} -}}} \ No newline at end of file + +Um noch eine SMTP Auth anzubieten um seine Clients beim Versenden zu authentifieren müssen folgende Dateien so verändert werden: + +**main.cf** +[[!format txt """ +myhostname = mail.hostname.com +myorigin = /etc/mailname + +alias_maps = $alias_database +virtual_mailbox_domains = hash:/etc/postfix/virtual_domains + +virtual_mailbox_base = /srv/vmail + +virtual_alias_maps = hash:/etc/postfix/virtual_maps +#virtual_minimum_uid = 101 + +virtual_uid_maps = static:5000 +virtual_gid_maps = static:5000 + +virtual_transport = dovecot + +virtual_mailbox_limit = 10240000 + +# dovecot_destination_recipient_limit = 1 + +mydestination = localhost +mynetworks = 127.0.0.0/8 + +smtpd_banner = $myhostname ESMTP Mailserver +home_mailbox = mails/ + +# Zertifikate für SMTP +smtpd_tls_cert_file = /etc/postfix/mail.cert +smtpd_tls_key_file = /etc/postfix/mail.key + +# SMTP Einstellungen +smtpd_use_tls = yes +#tpd_enforce_tls = no +smtpd_tls_auth_only = no + +# SALS Auth für Dovecot +smtpd_sasl_auth_enable = yes +smtpd_sasl_type = dovecot +smtpd_sasl_path = private/auth +smtpd_sasl_security_options = noanonymous +smtpd_sasl_local_domain = +smtp_sasl_auth_enable = no +broken_sasl_auth_clients = yes + +# Mailbox Einstellungen +mailbox_size_limit = 512000000 +message_size_limit = 104857600 + + +# Antispam Confis +smtpd_helo_required = yes +smtpd_helo_restrictions = reject_invalid_hostname + +smtpd_recipient_restrictions = permit_mynetworks, reject_unknown_recipient_domain, permit_sasl_authenticated, reject_unauth_destination + +smtpd_sender_restrictions = reject_unknown_address + +smtpd_client_restrictions = reject_invalid_hostname + +strict_rfc821_envelopes = yes +"""]] +**Diese Zeile in der master.cf** +[[!format txt """ +smtp inet n - n - - smtpd +"""]] +**dovecot.conf** +[[!format txt """ +base_dir = /var/run/dovecot/ +# log_path = /var/log/dovecot.log +protocols = imap +ssl_disable = no +verbose_proctitle = yes +#first_valid_uid = 3000 +#last_valid_uid = 3000 +#first_valid_gid = 8 +#last_valid_gid = 8 +#valid_chroot_dirs = /var/mail +mail_location = maildir:~/Maildir +maildir_copy_with_hardlinks = yes + +disable_plaintext_auth = yes + +protocol imap { +} + +# auth_verbose = yes + +auth default { + socket listen { + + client { + path = /var/spool/postfix/private/auth + mode = 0660 + user = postfix + group = postfix + } + + master { + path = /var/run/dovecot/auth-master + mode = 0600 + user = vmail + group = vmail + } + + } + mechanisms = plain + + passdb passwd-file { + args = /etc/dovecot/dovecot.passwd + } + passdb pam { + } + userdb static { + args = uid=vmail gid=vmail home=/srv/vmail/%u + } + +} + +protocol lda { + postmaster_address = postmaster@hostname.com +} +"""]] \ No newline at end of file