Aktuelle Version |
Dein Text |
Zeile 1: |
Zeile 1: |
| {{Achtung| | | * emails |
| [[{{PAGENAME}}]] wurde 2018-02-24 durch [[Server/srs14]] ersetzt. | | {{Anpassungsmerker}} |
| }}
| | Die Inhalte [[Jail/SRS21 | dieses Artikels]] sind aktuell nicht relevant. Bitte schaut unter [[Server/Dokumentation#Email]] um Näheres zur Administration von [[Mail-Adressen]] zu erfahren. |
| | : Die nachfolgende Inhalt zielen auf die Verwendung von [http://de.wikipedia.org/wiki/GNU_Mailman mailman] ab, was aktuell wegen fehlender Kenntnisse zum Ingangsetzung nicht in Betrieb ist. |
|
| |
|
| Verwendungszweck:
| | == Ports == |
| * [[SMTP]] ([[Postfix]]) für das Versenden von Mails
| | === installierte Ports === |
| * [[aliases]] für [[Mail-Adressen]]
| | === konfigurierte Ports === |
| * despam
| | ==== cyrus-sasl 2.x ==== |
| * [[mailman]] für [http://lists.htw.stura-dresden.de lists.htw.stura-dresden.de] (mit web server)
| |
| * <s>[[IMAP]] ([[Dovecot]]) für [[Mail-Account]]s</s>
| |
| * …
| |
| | |
| == [[Server/Jails/SRS14/Ports |Ports]] == | |
| | |
| {{:Server/Jails/SRS14/Ports}}
| |
| | |
| == zusätzliche Konfigurationsdateien ==
| |
| | |
| === Jail === | |
| | |
| ==== /etc/rc.conf ==== | |
|
| |
|
| <code> | | <code> |
| apache24_enable="YES" | | [ ] BDB Use Berkeley DB |
| mailman_enable="YES" | | [X] MYSQL Use MySQL |
| sshd_enable="YES" | | [ ] PGSQL Use PostgreSQL |
| dovecot_enable="YES" | | [ ] SQLITE Use SQLite |
| postfix_enable="YES" | | [ ] SQLITE3 Use SQLite3 |
| <!-- ?!? und grüße an …
| | [ ] DEV_URANDOM Use /dev/urandom |
| newsyslog_enable="YES"
| | [ ] ALWAYSTRUE Enable the alwaystrue password verifier |
| bacula_fd_enable="YES"
| | [ ] KEEP_DB_OPEN Keep handle to Berkeley DB open |
| --> | | [X] OBSOLETE_CRAM_ATTR Enable cmusaslsecretCRAM-MD5 property |
| | [X] AUTHDAEMOND Enable use of authdaemon |
| | [X] LOGIN Enable LOGIN authentication |
| | [X] PLAIN Enable PLAIN authentication |
| | [X] CRAM Enable CRAM-MD5 authentication |
| | [X] DIGEST Enable DIGEST-MD5 authentication |
| | [X] NTLM Enable NTLM authentication |
| | [X] OTP Enable OTP authentication |
| | [X] SCRAM Enable SCRAM authentication |
| </code> | | </code> |
|
| |
|
| == Konfiguration der Programme == | | ==== dovecot2 ==== |
| | |
| === apache ===
| |
| | |
| ==== httpd.conf ====
| |
|
| |
|
| <code> | | <code> |
| … | | [X] KQUEUE kqueue(2) support |
| ServrerAdmin '''you@example.com''' | | [X] SSL SSL support |
| … | | [ ] GSSAPI GSSAPI support |
| | | [ ] VPOPMAIL vpopmail support |
| ServerName '''www.example.com''':80 | | [ ] LDAP OpenLDAP support |
| … | | [ ] PGSQL PostgreSQL support |
| # Virtual hosts | | [X] MYSQL MySQL support |
| Include etc/apache22/extra/httpd-vhosts.conf | | [ ] SQLITE SQLite support |
| … | |
| </code> | | </code> |
|
| |
|
| ==== httpd-vhost.conf ==== | | ==== mailman ==== |
|
| |
|
| <code><b> | | <code> |
| # Mailman mailing list domain. | | [ ] SENDMAIL for use with sendmail |
| # | | [ ] EXIM3 for use with exim3 |
| <Virtualhost *:80> | | [ ] EXIM4 for use with exim4 |
| ServerAdmin webmaster@stura.htw-dresden.de
| | [X] POSTFIX for use with postfix |
| DocumentRoot "/usr/local/mailman/lists"
| | [ ] COURIER for use with courier |
| ServerName lists.stura.htw-dresden.de
| | [ ] CHINESE support for Chinese mailing lists |
| ServerAlias lists.stura.htw-dresden.de
| | [ ] HTDIG htdig integration patches |
| <Directory /usr/local/mailman/archives/>
| | [ ] NAMAZU2 make private archives searchable with namazu2 |
| Options FollowSymLinks
| |
| AllowOverride None
| |
| </Directory>
| |
| Alias /pipermail/ /usr/local/mailman/archives/public/
| |
| Alias /images/mailman/ /usr/share/images/mailman/
| |
| ScriptAlias /admin /usr/local/mailman/cgi-bin/admin
| |
| ScriptAlias /admindb /usr/local/mailman/cgi-bin/admindb
| |
| ScriptAlias /confirm /usr/local/mailman/cgi-bin/confirm
| |
| ScriptAlias /create /usr/local/mailman/cgi-bin/create
| |
| ScriptAlias /edithtml /usr/local/mailman/cgi-bin/edithtml
| |
| ScriptAlias /listinfo /usr/local/mailman/cgi-bin/listinfo
| |
| ScriptAlias /options /usr/local/mailman/cgi-bin/options
| |
| ScriptAlias /private /usr/local/mailman/cgi-bin/private
| |
| ScriptAlias /rmlist /usr/local/mailman/cgi-bin/rmlist
| |
| ScriptAlias /roster /usr/local/mailman/cgi-bin/roster
| |
| ScriptAlias /subscribe /usr/local/mailman/cgi-bin/subscribe
| |
| ScriptAlias /mailman/ /usr/local/mailman/cgi-bin/
| |
| ScriptAlias / /usr/local/mailman/cgi-bin/listinfo
| |
| <Directory "/usr/local/mailman">
| |
| AllowOverride All
| |
| Options FollowSymlinks
| |
| Order allow,deny
| |
| Allow from all
| |
| </Directory>
| |
| ErrorLog /var/log/mailman-error.log
| |
| # CustomLog /var/log/mailman-access.log combined | |
| </Virtualhost> | |
| ...</b> | |
| </code> | | </code> |
|
| |
|
| NOTE:
| | ==== mysql5.5-client ==== |
| | |
| Notice the addition of the default HTTP directory. The reason for this is due to the fact that once virtual hosting is enabled, the default directory used by Apache is the first VirtualHost listed in the httpd-vhosts.conf file. So, make sure that what ever site you plan on using as the default site for that machine comes first in the list of virtual hosts in the httpd-vhosts.conf file.
| |
| | |
| After adding the above VirtualHost directive, you can delete or comment out the remaining lines in the httpd-vhosts.conf file being as they’re just the default examples and pretty much useless.
| |
| | |
| === dovecot2 === | |
| | |
| 2017-03-30 wurde der Dienst dovecot gestoppt.
| |
| Es war unbekannt, dass dovecot (für IMAP?) "tatsächlich" läuft.
| |
| Es gab (zufällig) eine Recherche zu Betrieb von Mail. (Es war unklar, ob eine Mail bei mailman durchging.)
| |
| : <code>sudo service dovecot stop</code>
| |
| | |
| default config kopieren
| |
|
| |
|
| <code> | | <code> |
| # cp /usr/local/share/doc/dovecot/example-config/dovecot.conf /usr/local/etc/dovecot/dovecot.conf | | [X] OPENSSL Enable SSL support |
| | [ ] FASTMTX Replace mutexes with spinlocks |
| </code> | | </code> |
|
| |
|
| ==== dovecot.conf ==== | | ==== mysql5.5-server ==== |
|
| |
|
| <code> | | <code> |
| protocols = imap pop3 | | [X] OPENSSL Enable SSL support |
| disable_plaintext_auth = no | | [ ] FASTMTX Replace mutexes with spinlocks |
| ssl = no | |
| mail_location = mbox:~/mail/:INBOX=/var/mail/%u
| |
| mail_privileged_group = mail
| |
| protocol imap {
| |
| imap_client_workarounds = delay-newmail outlook-idle netscape-eoh tb-extra-mailbox-sep
| |
| } | |
| </code> | | </code> |
|
| |
|
| === maildrop === | | ==== Postfix ==== |
|
| |
|
| * maildir in users homeverzeichnis anlegen
| |
| <code> | | <code> |
| maildrop-maildirmake Mail | | [X] PCRE Perl Compatible Regular Expressions |
| | [X] SASL2 Cyrus SASLv2 (Simple Auth. and Sec. Layer) |
| | [ ] DOVECOT Dovecot 1.x SASL authentication method |
| | [X] DOVECOT2 Dovecot 2.x SASL authentication method |
| | [ ] SASLKRB5 If your SASL req. Kerberos5 select this option |
| | [ ] SASLKMIT If your SASL req. MIT Kerberos5 select this optio |
| | [X] TLS Enable SSL and TLS support |
| | [ ] BDB Berkeley DB (choose version with WITH_BDB_VER) |
| | [X] MYSQL MySQL maps (choose version with WITH_MYSQL_VER) |
| | [ ] PGSQL PostgreSQL maps (pick ver. with DEFAULT_PGSQL_VER |
| | [ ] SQLITE SQLite maps |
| | [ ] OPENLDAP OpenLDAP maps (choose ver. with WITH_OPENLDAP_VER |
| | [X] LDAP_SASL Enable OpenLDAP client-to-server auth via SASL |
| | [ ] CDB CDB maps lookups |
| | [ ] NIS NIS maps lookups |
| | [ ] VDA VDA (Virtual Delivery Agent 32Bit) |
| | [ ] TEST SMTP/LMTP test server and generator |
| | [ ] SPF SPF support (via libspf2 1.2.x) |
| | [ ] INST_BASE Install into /usr and /etc/postfix |
| </code> | | </code> |
|
| |
|
| * im homeverzeichnis die Datei .mailfilter anlegen: | | * postfix added to group mail -> y |
| | | * Would you like to activate Postfix in /etc/mail/mailer.conf -> y |
| <code>
| |
| MAILBOX="$HOME/Mail"
| |
| DEFAULT="$MAILBOX"
| |
| </code>
| |
|
| |
|
| * chmod 600 .mailfilter
| | ==== python27 ==== |
| * maildrop in postfix main.cf einarbeiten
| |
|
| |
|
| <code> | | <code> |
| mailbox_command = /usr/local/bin/maildrop -d ${USER} | | [X] THREADS Enable thread support |
| | [ ] HUGE_STACK_SIZE Use a larger thread stack |
| | [ ] SEM Use POSIX semaphores (experimental) |
| | [ ] PTH Use GNU Pth for threading/multiprocessing |
| | [X] UCS4 Use UCS4 for unicode support |
| | [X] PYMALLOC Use python's internal malloc |
| | [X] IPV6 Enable IPv6 support |
| | [ ] FPECTL Enable floating point exception handling |
| </code> | | </code> |
|
| |
|
| === mailman === | | ==== ohne config ==== |
|
| |
|
| <!--<code>
| | * mail/maildrop |
| # cd /usr/local/mailman
| |
| # fetch http://www.gurulabs.com/downloads/postfix-to-mailman-2.1.py
| |
| # mv postfix-to-mailman-2.1.py postfix-to-mailman.py
| |
| # chmod 750 postfix-to-mailman.py
| |
| # chown mailman:nobody postfix-to-mailman.py
| |
| </code>
| |
|
| |
|
| ==== /usr/local/mailman/postfix-to-mailman.py ==== | | == Konfiguration der Programme == |
| | |
| <code>
| |
| '''#! /usr/local/bin/python'''
| |
| …
| |
| # Configuration variables – Change these for your site if necessary.
| |
| MailmanHome = “'''/usr/local/mailman'''“; # Mailman home directory.
| |
| MailmanOwner = “'''postmaster@domain.tld'''“; # Postmaster and abuse mail recipient.
| |
| …
| |
| </code>--->
| |
|
| |
|
| ==== Set Site Password ==== | | === Dovecot2 === |
|
| |
|
| <code> | | <code> |
| # cd /usr/local/mailman | | # cp /usr/local/share/doc/dovecot/example-config/dovecot.conf /usr/local/etc/dovecot/dovecot.conf |
| # bin/mmsitepass | | # cp /usr/local/share/doc/dovecot/example-config/dovecot-sql.conf /usr/local/etc/dovecot/dovecot-sql.conf |
| New site password: '''mailman_password'''
| |
| Again to confirm password: '''mailman_password'''
| |
| </code> | | </code> |
|
| |
|
| ==== Create Mailman list ====
| | * in /usr/local/etc/dovecot.conf: (vorerst zum testen) |
| | | <code> |
| <code> | | protocols = imap pop3 |
| # bin/newlist | | disable_plaintext_auth = no |
| Enter the name of the list: '''mailman''' | | ssl = no |
| Enter the email of the person running the list: '''you@domain.tld''' | | mail_location = mbox:~/mail/:INBOX=/var/mail/%u |
| Initial mailman password: '''list_password''' | | mail_privileged_group = mail |
| | | protocol imap { |
| You’ll then see instructions to add aliases for the mailing list. We need not worry about that because everything | | imap_client_workarounds = delay-newmail outlook-idle netscape-eoh tb-extra-mailbox-sep |
| is virtual. So, proceeding… Hit enter to notify mailman owner… ENTER
| | }</code> |
|
| |
| bin/genaliases
| |
| </code> | |
|
| |
|
| | === Postfix === |
|
| |
|
| === Listen auf andere Domain ===
| | *main.cf |
|
| |
|
| Realisiert durch den Shell Einzeiler:
| |
|
| |
| Einzelne:
| |
| <code> | | <code> |
| bin/withlist -l -r fix_url <liste> -u <domain> | | local_recipient_maps = $alias_maps |
| </code>
| | unknown_local_recipient_reject_code = 550 |
| Alle:
| | mynetworks = 127.0.0.0/8 |
| <code> | | myhostname = mail.stura.htw-dresden.de |
| bin/list_lists -b | xargs -I % bin/withlist -l -r fix_url % -u <domain>
| | mydomain = stura.htw-dresden.de |
| </code>
| | myorigin = $mydomain |
| | | mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain |
| ==== Add list to Mailman configuration file /usr/local/mailman/Mailman/mm_cfg.py ====
| |
| | |
| <code> | |
| MTA = 'Postfix'
| |
| # The default language for this server.
| |
| DEFAULT_SERVER_LANGUAGE = 'de'
| |
| # Unset send_reminders on newly created lists
| |
| DEFAULT_SEND_REMINDERS = 0
| |
| DEFAULT_SEND_WELCOME_MSG = 0
| |
| DEFAULT_SEND_GOODBYE_MSG = 0
| |
| DEFAULT_ADMIN_NOTIFY_MCHANGES = 1
| |
| DEFAULT_NEW_MEMBER_OPTIONS = 272
| |
| DEFAULT_RESPOND_TO_POST_REQUESTS = 0
| |
| DEFAULT_ADMINISTRIVIA = 0
| |
| DEFAULT_MAX_MESSAGE_SIZE = 0
| |
| DEFAULT_MAX_NUM_RECIPIENTS = 0
| |
| DEFAULT_REQUIRE_EXPLICIT_DESTINATION = 0
| |
| # SUBSCRIBE POLICY
| |
| # 0 - open list (only when ALLOW_OPEN_SUBSCRIBE is set to 1) **
| |
| # 1 - confirmation required for subscribes
| |
| # 2 - admin approval required for subscribes
| |
| # 3 - both confirmation and admin approval required
| |
| #
| |
| # ** please do not choose option 0 if you are not allowing open
| |
| # subscribes (next variable)
| |
| DEFAULT_SUBSCRIBE_POLICY = 3
| |
| # Does this site allow completely unchecked subscriptions?
| |
| ALLOW_OPEN_SUBSCRIBE = Yes
| |
|
| |
| # Private_roster == 0: anyone can see, 1: members only, 2: admin only.
| |
| DEFAULT_PRIVATE_ROSTER = 0
| |
| | |
| # Are archives public or private by default?
| |
| # 0=public, 1=private
| |
| DEFAULT_ARCHIVE_PRIVATE = 1
| |
|
| |
| # What shold happen to non-member posts which are do not match explicit
| |
| # non-member actions?
| |
| # 0 = Accept
| |
| # 1 = Hold
| |
| # 2 = Reject
| |
| # 3 = Discard
| |
| DEFAULT_GENERIC_NONMEMBER_ACTION = 0
| |
|
| |
| SMTPHOST = 'localhost'
| |
| # Put YOUR site-specific settings below this line.
| |
| add_virtualhost('lists.domain.tld','domain.tld')
| |
| add_virtualhost('domain.tld','domain.tld')
| |
| OWNERS_CAN_DELETE_THEIR_OWN_LISTS = 'YES'
| |
| </code>
| |
| | |
| ==== geänderte allgemeine Listen-Informationsseite ====
| |
| | |
| ===== geänderte allgemeine Listen-Informationsseite für [[Mail-Verteiler#Mail-Verteiler, in die sich keine Person einschreiben soll | Mail-Verteiler, in die sich keine keine Person einschreiben soll]] =====
| |
| | |
| ; Entfernung von:
| |
| <nowiki>
| |
| <p>Sie können im folgenden Abschnitt diese Liste abonnieren
| |
| oder ein bestehendes Abonnement ändern.
| |
| </td>
| |
| </tr> | |
| <TR>
| |
| <TD COLSPAN="2" WIDTH="100%" BGCOLOR="#FFF0D0">
| |
| <B><FONT COLOR="#000000">Abonnieren von <MM-List-Name></FONT></B>
| |
| </TD>
| |
| </TR>
| |
| <tr>
| |
| <td colspan="2">
| |
| <P>
| |
| Abonnieren Sie <MM-List-Name>, indem Sie das folgende Formular
| |
| ausfüllen:
| |
| <MM-List-Subscription-Msg>
| |
| <ul>
| |
| <MM-Subscribe-Form-Start>
| |
| <TABLE BORDER="0" CELLSPACING="2" CELLPADDING="2" WIDTH="70%">
| |
| <TR>
| |
| <TD BGCOLOR="#dddddd" WIDTH="55%">Ihre E-Mail-Adresse:</TD>
| |
| <TD WIDTH="33%"><MM-Subscribe-Box></TD>
| |
| <TD WIDTH="12%"> </TD>
| |
| </TR>
| |
| <tr>
| |
| <td bgcolor="#dddddd" width="55%">Ihr Name (optional):</td>
| |
| <td width="33%"><mm-fullname-box></td>
| |
| <TD WIDTH="12%"> </TD>
| |
| </TR>
| |
| <TR>
| |
| <TD COLSPAN="3"><FONT SIZE=-1>Sie können weiter unten ein Passwort
| |
| eingeben. Dieses Passwort bietet nur eine geringe Sicherheit,
| |
| sollte aber verhindern, dass andere Ihr Abonnement
| |
| manipulieren. <b>Verwenden Sie kein wertvolles Passwort</b>,
| |
| da es ab und zu im Klartext an Sie geschickt wird!
| |
| | |
| <br><br>Wenn Sie kein Passwort eingeben, wird für Sie ein
| |
| Zufallspasswort generiert und Ihnen zugeschickt, sobald Sie Ihr
| |
| Abonnement bestätigt haben. Sie können sich Ihr Passwort
| |
| jederzeit per E-Mail zuschicken lassen, wenn Sie weiter unten
| |
| die Seite zum ändern Ihrer persönlichen Einstellungen aufrufen.
| |
| <MM-Reminder> </font></TD>
| |
| </TR>
| |
| <TR>
| |
| <TD BGCOLOR="#dddddd">Wählen Sie ein Passwort:</TD>
| |
| <TD><MM-New-Password-Box></TD>
| |
| <TD> </TD>
| |
| </TR>
| |
| <TR>
| |
| <TD BGCOLOR="#dddddd">Erneute Eingabe zur Bestätigung:</TD>
| |
| <TD><MM-Confirm-Password></TD>
| |
| <TD> </TD>
| |
| </TR>
| |
| <tr>
| |
| <TD BGCOLOR="#dddddd">Welche Sprache bevorzugen Sie zur
| |
| Benutzerführung?</TD>
| |
| <TD> <MM-list-langs></TD>
| |
| <TD> </TD>
| |
| </TR>
| |
| <mm-digest-question-start>
| |
| <tr>
| |
| <td>Möchten Sie die Listenmails gebündelt in Form einer täglichen
| |
| Zusammenfassung (digest) erhalten?
| |
| </td>
| |
| <td><MM-Undigest-Radio-Button>Nein
| |
| <MM-Digest-Radio-Button>Ja
| |
| </TD>
| |
| </tr>
| |
| <mm-digest-question-end>
| |
| <tr>
| |
| <td colspan="3">
| |
| <center><MM-Subscribe-Button></center>
| |
| </td>
| |
| </tr>
| |
| </TABLE>
| |
| <MM-Form-End>
| |
| </ul>
| |
| </nowiki>
| |
| | |
| <nowiki>
| |
| <TR>
| |
| <TD COLSPAN="2" WIDTH="100%" BGCOLOR="#FFF0D0">
| |
| <B><FONT COLOR="#000000">Austragen / Ändern einer Mailadresse</FONT></B>
| |
| </TD>
| |
| </TR>
| |
| <TD COLSPAN="2" WIDTH="100%">
| |
| <MM-Options-Form-Start>
| |
| <br>
| |
| <MM-Editing-Options>
| |
| <br>
| |
| <MM-Form-End>
| |
| </td>
| |
| </tr>
| |
| </nowiki>
| |
| | |
| === postfix ===
| |
| | |
| ==== /usr/local/etc/postfix/main.cf ====
| |
| | |
| <code>
| |
| alias_database = hash:/etc/aliases, hash:/etc/aliases.stura
| |
| alias_maps = hash:/etc/aliases, hash:[[#/etc/aliases.stura |/etc/aliases.stura ]], hash:/usr/local/mailman/data/aliases
| |
| command_directory = /usr/local/sbin
| |
| config_directory = /usr/local/etc/postfix
| |
| daemon_directory = /usr/local/libexec/postfix
| |
| data_directory = /var/db/postfix
| |
| home_mailbox = Mail/
| |
| html_directory = /usr/local/share/doc/postfix
| |
| inet_interfaces = all | | inet_interfaces = all |
| inet_protocols = ipv4 | | alias_maps = hash:/etc/aliases |
| local_recipient_maps = unix:passwd.byname $alias_maps
| | alias_database = hash:/etc/aliases |
| mail_owner = postfix
| | home_mailbox = Maildir/ |
| mail_spool_directory = /var/mail
| | mail_spool_directory = /var/spool/mail |
| mailbox_command = /usr/local/bin/maildrop -d ${USER} | | relay_domains = stura.htw-dresden.de |
| mailq_path = /usr/local/bin/mailq | | smtpd_recipient_restrictions = reject_invalid_hostname, |
| manpage_directory = /usr/local/man | | reject_unknown_recipient_domain, |
| mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain | | reject_unauth_destination, |
| mydomain = stura.htw-dresden.de
| | reject_rbl_client sbl.spamhaus.org, |
| myhostname = mail.stura.htw-dresden.de | | permit |
| mynetworks = <interne IP-Adresse> 127.0.0.0/24
| | smtpd_helo_restrictions = reject_invalid_helo_hostname, |
| myorigin = $myhostname
| | reject_non_fqdn_helo_hostname, |
| newaliases_path = /usr/local/bin/newaliases
| | reject_unknown_helo_hostname |
| queue_directory = /var/spool/postfix
| | smtpd_client_restrictions = reject_rbl_client dnsbl.sorbs.net |
| readme_directory = /usr/local/share/doc/postfix
| |
| sample_directory = /usr/local/etc/postfix
| |
| sendmail_path = /usr/local/sbin/sendmail
| |
| setgid_group = maildrop
| |
|
| |
| smtpd_client_restrictions =
| |
| permit_mynetworks,
| |
| reject_rbl_client bl.spamcop.net,
| |
| reject_rbl_client dnsbl.sorbs.net
| |
|
| |
| smtpd_helo_restrictions = | |
| permit_mynetworks,
| |
| reject_invalid_helo_hostname,
| |
| reject_non_fqdn_helo_hostname,
| |
| reject_unknown_helo_hostname
| |
| | |
| smtpd_recipient_restrictions =
| |
| reject_invalid_hostname,
| |
| reject_unknown_recipient_domain,
| |
| reject_rbl_client sbl.spamhaus.org,
| |
| permit
| |
|
| |
| smtpd_relay_restrictions =
| |
| permit_mynetworks,
| |
| defer_unauth_destination
| |
|
| |
| smtpd_sender_restrictions =
| |
| permit_mynetworks,
| |
| reject_unknown_sender_domain,
| |
| reject_non_fqdn_sender
| |
|
| |
| unknown_local_recipient_reject_code = 550
| |
| </code> | | </code> |
|
| |
|
| ===== <code>rhsbl.ahbl.org</code> für <code>reject_rhsbl_sender</code> bei <code>smtpd_sender_restrictions</code> entfernt =====
| | * neue virtuelle aliase: (entsprechend Eintrag in main.cf) |
| | | ** entsprechende datein anlegen/editieren |
| In er Datei <code>/usr/local/etc/postfix/main.cf</code> gab es (auch) den Eintrag
| | *** parameter in main.cf ([http://www.postfix.org/postconf.5.html#virtual_alias_domains virtual_alias_domains] und [http://www.postfix.org/postconf.5.html#virtual_alias_maps virtual_alias_maps]) |
| <pre></pre>
| | ** datenbank aktualisieren: <code>postmap /PFAD/ZUR/ALIASDATEI</code> |
| <pre>
| | ** postfix neustarten: <code>/usr/local/etc/rc.d/postfix restart</code> |
| smtpd_sender_restrictions =
| |
| </pre>
| |
| <pre></pre>
| |
| <pre>
| |
| reject_rhsbl_sender rhsbl.ahbl.org
| |
| </pre>
| |
| <pre></pre>
| |
| .
| |
| | |
| Spätestens [https://www.ahbl.org/content/last-notice-wildcarding-services-jan-1st seit Beginn 2015] führte, das zu Problemen. (Im Übrigen war [https://www.ahbl.org/content/changes-ahbl dies seit Monaten bekannt], jedoch gab es keine ordentliche Betreuung der [[Rechentechnik]] mehr, die solche absehbaren Probleme vorbereitend beseitigte.) Konkret wurden alle [[E-Mail]]s für den [[StuRa]] nicht angenommen, da sie über [[srs14]] (gemäß [[Domains#stura.htw-dresden.de DNS|DNS für <code>stura.htw-dresden.de</code>]] <code>mail.stura.htw-dresden.de</code> und <code>lists.stura.htw-dresden.de</code>) gingen und dieser Eintrag zur Abweisung führte.
| |
| | |
| "Ehemalige" ersetzten den Eintrag "auf die Schnelle" ersatzlos.
| |
| | |
| Eigentlich wäre es wünschenswert, wenn es einen guten Ersatz geben würde. Aktuell gibt es nur noch einen derartigen (<code>[http://www.postfix.org/postconf.5.html#reject_rhsbl_sender reject_rhsbl_sender]</code>) Eintrag, sodass es keine weitere Möglichkeit zum Ausweichen gäbe.
| |
| | |
| ===== als vom Mail-Server von unserem [[RZ HTW Dresden]] als Spam markierte Mails nicht verbreiten, sondern nur an eine Mail-Adresse ableiten =====
| |
| | |
| Erstellung der Datei für den Filter
| |
| : <code>touch /usr/local/etc/postfix/header_checks</code>
| |
| | |
| Erstellung der Regel in der Datei für den Filter vom Mail-Header
| |
| : Alles was
| |
| :* im Feld ''X-HTW-Spam-Flag''
| |
| :* mit wahr (''YES'') (gekennzeichnet ist
| |
| : soll
| |
| :* an eine bestimmte angegeben Mail-Adresse gesendet werden
| |
| : .
| |
| : <code>$EDITOR /usr/local/etc/postfix/header_checks</code>
| |
| :: ''spam.admin@htw-dresden.de'' ist ein fiktive [[Mail-Adresse]], wohin die Mail, die als Spam markiert sind weitergeleitet werden.
| |
| ::: Im Übrigen macht hier selbstverständlich eine [[Mail-Adresse]] …@stura.htw-dresden.de wenig Sinn, denn dann würde die Mail nach dem "Ableiten" wieder "Eingeleitet" werden und das Spiel von Neuen beginnen.
| |
| <pre>
| |
| /^X-HTW-Spam-Flag:\s+YES/ REDIRECT spam.admin@htw-dresden.de
| |
| </pre>
| |
| | |
| Hinzufügen des Eintrages zum Verweis auf den Filter
| |
| : Es soll nach den Inhalten im Header gefiltert werden und
| |
| : die Datei für den Filter muss angegeben werden.
| |
| : <code>$EDITOR /usr/local/etc/postfix/main.cf</code>
| |
| <pre></pre>
| |
| <pre>
| |
| # JUNK MAIL CONTROLS
| |
| </pre>
| |
| <pre></pre>
| |
| <pre>
| |
| header_checks = pcre:$config_directory/header_checks
| |
| </pre>
| |
| <pre></pre>
| |
| | |
| obligatorisches Neuladen der Konfiguration für postfix
| |
| : <code>sudo service postfix reload</code>
| |
| | |
| ; Herangehensweise:
| |
| | |
| Anfang 2016 gab es "eigentlich" (schon länger) keine [[Bereichsleitung Administration Rechentechnik]]. Dennoch musste der Betrieb aufrecht erhalten werden.
| |
| | |
| Die letzte [[Bereichsleitung Administration Rechentechnik]] proklamierte immer, dass keine Filtern von Mail auf dem Server stattfinden soll. Sinngemäß war die Parole ''Der StuRa "zensiert" nicht!''. Daher wurde alles an Mails weiterverbreitet. Das galt auch für Spam.
| |
| | |
| Erwartungsgemäß wurde sich über mehrere Monate über die "die Flut" an Spam beschwert. Nach Absprache mit der [[Referatsleitung studentische Selbstverwaltung & Organisation]] wurde "die [[wikipedia:de:Policy|Policy]]" geändert und eine Änderung angegangen. Insbesondere das Bitten von neuen Aktiven - anteilig wurden sie nämlich "überflutet" und konnten und wollten das nicht mehr bewältigen - war der Hintergrund für die Initiative.
| |
| | |
| Da - wieso auch immer - offensichtlich die [[Server HTW Dresden#Erkennung von Spam | Mails schon durch den Mail-Server von unserer Hochschule als erkannt und markiert werden]], bot es sich an die Markierung gleich für das Aussortieren zu verwenden.
| |
| | |
| Es wurde direkt bei [[postfix]] [http://www.postfix.org/header_checks.5.html header_checks] entsprechend konfiguriert.
| |
| | |
| ===== whitelisting der Server für das Versenden von Mails unserer HTW Dresden =====
| |
| | |
| Der einzige Dienst der zum Erkennen von IP-Adressen oder Domains, die SPAM versenden, der verwendet wird, ist [http://sorbs.net/ SORBS]. (Das war der letzte verbliebene Eintrag nach dem [[#rhsbl.ahbl.org für reject_rhsbl_sender bei smtpd_sender_restrictions entfernt]] wurde.) Von diesem Dienst wurden beide üblichen Postausgangsserver [http://www.sorbs.net/lookup.shtml?141.56.16.131 141.56.16.131 (aka ''rmr1.rz.htw-dresden.de'')] [http://www.sorbs.net/lookup.shtml?141.56.16.132 141.56.16.132 (aka ''rmr1.rz.htw-dresden.de'')] (seit 2017-02-13) als Problem "eingestuft". Demnach wurden alle Mails, die von diesen Postausgangsserver (unserer HTW Dresden) versendet wurden, schlicht blockiert. Daraus ergab sich praktisch das Problem, dass [[Studentinnen und Studenten]] sowie [[Mitarbeiterinnen und Mitarbeiter]] auf dem üblichen Weg dem StuRa [[Mail]]s senden konnten.
| |
| | |
| In Anlehnung an [https://www.howtoforge.com/how-to-whitelist-hosts-ip-addresses-in-postfix How To Whitelist Hosts/IP Addresses In Postfix] wurde speziell für die Mail-Server unserer HTW Dresden eine Liste erstellt und eingebunden, die dafür sorgt, dass pauschal immer alle Mails von diesen Postausgangsservern angenommen werden.
| |
| | |
| Erstellung der Datei für die Einträge fürs Whitelisting
| |
| : <code>touch /usr/local/etc/postfix/rbl_override</code> | |
| | |
| Erstellung der Einträge in der Datei fürs Whitelisting
| |
| : <code>$EDITOR /usr/local/etc/postfix/rbl_override</code>
| |
| Maßgeblich wurden die Postausgangsserver HTW Dresden eingetragen. (Die Domains und IPv4-Adressen waren durch die Fehlermeldungen bekannt.) Darüber hinaus wurden "prophylaktisch" alle bekannten weiteren Server zu Mail (Posteingangserver, die als Eintrag für DNS mit MX) mit Domains und IPv4-Adressen eingetragen. Auch weitere "irgendwie" sich aus Domains oder der nummerischen Zuordnung sich ergebende Domains und IPv4-Adressen wurden eingetragen.
| |
| | |
| : <code>postmap /usr/local/etc/postfix/rbl_override</code>
| |
| | |
| : <code>$EDITOR /usr/local/etc/postfix/main.cf</code> | |
| <pre></pre>
| |
| <pre>
| |
| smtpd_recipient_restrictions =
| |
| </pre>
| |
| <pre></pre>
| |
| <pre>
| |
| reject_unauth_destination,
| |
| </pre>
| |
| <pre>
| |
| check_client_access hash:/usr/local/etc/postfix/rbl_override,
| |
| </pre>
| |
| <pre></pre>
| |
| <pre>
| |
| reject_rbl_client dnsbl.sorbs.net,
| |
| </pre> | |
| <pre></pre>
| |
| <pre>
| |
| permit
| |
| </pre>
| |
| <pre></pre>
| |
| | |
| Neuladen der Konfiguration
| |
| : <code>service postfix reload</code>
| |
| | |
| ==== /etc/aliases.stura ====
| |
| | |
| Datei um [[Mail-Adresse | Mail-Adressen]] anzulegen. Diese sind simple Weiterleitungen.
| |
| | |
| === [[Server/Dokumentation#ssh | ssh ]] ===
| |
| | |
| siehe [[Server/Dokumentation#ssh]]
| |
|
| |
|
| == Siehe auch == | | == Siehe auch == |
| * [[mailman]]
| |
| * [[Server/Dokumentation]]
| |
|
| |
| == Weblinks ==
| |
| * [http://www.freebsddiary.org/postfix.php Manual: Postfix on FreeBSD]
| |
| * [http://www.freebsddiary.org/mailman.php Manual: Mailman on FreeBSD]
| |
| * [http://www.purplehat.org/?page_id=18 Manual: Mailman on FreeBSD with Postfix]
| |
| * [https://www.gnu.org/software/mailman/index.html GNU Mailman] (offical website)
| |
|
| |
|
| [[Kategorie:Mail]]
| |
| [[Kategorie:Rechentechnik]] | | [[Kategorie:Rechentechnik]] |
| [[Kategorie:Software]] | | [[Kategorie:Software]] |
| [[Kategorie:Jail]] | | [[Kategorie:Jail]] |