update...
This commit is contained in:
43
roles/common/files/o13-mail/etc/postfix/header_checks.pcre
Normal file
43
roles/common/files/o13-mail/etc/postfix/header_checks.pcre
Normal file
@ -0,0 +1,43 @@
|
||||
# *** [ Ansible managed: DO NOT EDIT DIRECTLY ] ***
|
||||
|
||||
# ---
|
||||
# - Replace headers
|
||||
|
||||
# - Replace recieved from IPv4 / IPv6 header - hide senders IP address and also 'Authenticated sender'
|
||||
#
|
||||
/^Received: from (.* \([-._[:alnum:]]+ \[[.[:digit:]]{7,15}\]\))(.*)\(Authenticated sender: ([^)]+)\)(.*)/ REPLACE Received: from anonymized.ipv4 (localhost [127.0.0.1])$2(Authenticated sender: hidden)$4
|
||||
#
|
||||
/^Received: from (.*IP[vV]6:(([0-9a-f]{0,4}:){1,7}[0-9a-f]{1,4})\]\){0,1})(.*)\(Authenticated sender: ([^)]+)\)(.*)/ REPLACE Received: from anonymized.ipv6 (localhost [::1])$4(Authenticated sender: hidden)$6
|
||||
|
||||
# - Replace recieved from IPv4 / IPv6 header - hide only sender IP address
|
||||
#
|
||||
#/^Received: from (.* \([-._[:alnum:]]+ \[[.[:digit:]]{7,15}\]\))(.*)\(Authenticated sender: (.*) / REPLACE Received: from anonymized.ipv4 (localhost [127.0.0.1])$2(Authenticated sender: $3
|
||||
|
||||
#/^Received: from (.*IP[vV]6:(([0-9a-f]{0,4}:){1,7}[0-9a-f]{1,4})\]\){0,1})(.*)\(Authenticated sender: (.*) / REPLACE Received: from anonymized.ipv6 (localhost [::1])$4(Authenticated sender: $5
|
||||
|
||||
# ---
|
||||
# - Ignore Headers
|
||||
# ---
|
||||
|
||||
#/^\s*User-Agent/ IGNORE
|
||||
#/^\s*X-Enigmail/ IGNORE
|
||||
#/^\s*X-Mailer/ IGNORE
|
||||
#/^\s*X-Originating-IP/ IGNORE
|
||||
|
||||
|
||||
# ---
|
||||
# - Reject / Discard headers
|
||||
# ---
|
||||
|
||||
/^To:.*<>/ REJECT Possible SPAM Blank email address To: header - Header-Spamschutzregel T0-1001
|
||||
|
||||
/\(envelope-from <>\)/ REJECT Possible SPAM - Header-Spamschutzregel RECIEV-1001
|
||||
|
||||
/^Reply-To: .+\@inx1and1\..+/ REJECT Possible SPAM - Header-Spamschutzregel REPLY-1001
|
||||
|
||||
/^From:.*<>/ REJECT Possible SPAM - Header-Spamschutzregel FROM-1001
|
||||
|
||||
/^Date: .* 19[0-9][0-9]/ REJECT Date from the past. Fix your system clock. - Header-Spamschutzregel DATE-1001
|
||||
/^Date: .* 200[0-9]/ REJECT Date from the past. Fix your system clock. - Header-Spamschutzregel DATE-1002
|
||||
/^Date: .* 201[0-9]/ REJECT Date from the past. Fix your system clock. - Header-Spamschutzregel DATE-1003
|
||||
/^Date: .* 2020/ REJECT Date from the past. Fix your system clock. - Header-Spamschutzregel DATE-1004
|
22
roles/common/files/o13-mail/etc/postfix/postfwd.wl-hosts
Normal file
22
roles/common/files/o13-mail/etc/postfix/postfwd.wl-hosts
Normal file
@ -0,0 +1,22 @@
|
||||
# *** [ Ansible managed: DO NOT EDIT DIRECTLY ] ***
|
||||
|
||||
# ---
|
||||
# Trusted hosts whitelisted by postfwd
|
||||
#
|
||||
# This file is called with '=~'. This means perl regexp is possible
|
||||
#
|
||||
#
|
||||
# To increase performance use ^ and/or $ in regular expressions
|
||||
#
|
||||
# Example:
|
||||
#
|
||||
# # all hosts of domain 'oopen.de'
|
||||
# \.oopen\.de$
|
||||
#
|
||||
# # host a.mx.oopen.de
|
||||
# ^a\.mx\.oopen\.de$
|
||||
#
|
||||
# ---
|
||||
|
||||
# give truested hostnames here
|
||||
|
18
roles/common/files/o13-mail/etc/postfix/postfwd.wl-nets
Normal file
18
roles/common/files/o13-mail/etc/postfix/postfwd.wl-nets
Normal file
@ -0,0 +1,18 @@
|
||||
# *** [ Ansible managed: DO NOT EDIT DIRECTLY ] ***
|
||||
|
||||
# ---
|
||||
# Trusted networks whitelisted by postfwd
|
||||
#
|
||||
# Example:
|
||||
#
|
||||
# # web0.warenform.de
|
||||
# #83.223.86.76
|
||||
# #2a01:30:0:505:286:96ff:fe4a:6ee
|
||||
# #2a01:30:0:13:286:96ff:fe4a:6eee
|
||||
#
|
||||
# ---
|
||||
|
||||
# give truested networrk adresses here
|
||||
# d.mx.oopen.de (listen server)
|
||||
95.217.204.227
|
||||
2a01:4f9:4a:47e5::227
|
23
roles/common/files/o13-mail/etc/postfix/postfwd.wl-sender
Normal file
23
roles/common/files/o13-mail/etc/postfix/postfwd.wl-sender
Normal file
@ -0,0 +1,23 @@
|
||||
# *** [ Ansible managed: DO NOT EDIT DIRECTLY ] ***
|
||||
|
||||
# ---
|
||||
# Trusted senders whitelisted by postfwd
|
||||
#
|
||||
# This file is called with '=~'. This means perl regexp is possible
|
||||
#
|
||||
#
|
||||
# To increase performance use ^ and/or $ in regular expressions
|
||||
#
|
||||
# Example:
|
||||
#
|
||||
# # all senders of maildomaindomain 'oopen.de'
|
||||
# @oopen\.de$
|
||||
#
|
||||
# # sender address ckubu@oopen.de
|
||||
# ^ckubu@oopen\.de$
|
||||
#
|
||||
# ---
|
||||
|
||||
# give trusted sender addresses here
|
||||
^noreply@login\.ubuntu\.com$
|
||||
|
14
roles/common/files/o13-mail/etc/postfix/postfwd.wl-user
Normal file
14
roles/common/files/o13-mail/etc/postfix/postfwd.wl-user
Normal file
@ -0,0 +1,14 @@
|
||||
# *** [ Ansible managed: DO NOT EDIT DIRECTLY ] ***
|
||||
|
||||
# ---
|
||||
# SASL Users whitelisted by postfwd
|
||||
#
|
||||
# example:
|
||||
#
|
||||
# # give trusted sasl usernames here
|
||||
# ckubu@oopen.de
|
||||
# vertrieb@akweb.de
|
||||
#
|
||||
# ---
|
||||
|
||||
# give trusted sasl usernames here
|
@ -0,0 +1,135 @@
|
||||
# *** [ Ansible managed: DO NOT EDIT DIRECTLY ] ***
|
||||
|
||||
#---------------------------------------
|
||||
#-----------------------------
|
||||
# Settings for script check_cert_for_dovecot.sh
|
||||
#-----------------------------
|
||||
#---------------------------------------
|
||||
|
||||
# - service_domain
|
||||
# -
|
||||
# - The main domain for which the certificate was issued
|
||||
# -
|
||||
# - Example:
|
||||
# - service_domain="a.mx.oopen.de"
|
||||
# - service_domain="mail.cadus.org"
|
||||
# - service_domain="mx.warenform.de"
|
||||
# -
|
||||
#service_domain=""
|
||||
service_domain="mail.interventionistische-linke.org"
|
||||
|
||||
|
||||
# - service_name
|
||||
# -
|
||||
# - Name of service.
|
||||
# -
|
||||
# - Note: this var will also be used to determin systemd service file
|
||||
# - or sysVinit script.
|
||||
# -
|
||||
# - Example:
|
||||
# - service_name="Mumble"
|
||||
# - service_name="Prosody"
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - service_name="Dovecot"
|
||||
# -
|
||||
#service_name=""
|
||||
|
||||
|
||||
# - check_string_ps
|
||||
# -
|
||||
# - String wich (clearly) identifies the service at the process list (ps)
|
||||
# -
|
||||
# - Example:
|
||||
# - check_string_ps="[[:digit:]]\ /usr/sbin/murmurd"
|
||||
# - check_string_ps=""
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - check_string_ps="[[:digit:]]\ /usr/local/dovecot-[[:digit:]]{1,2}\.[[:digit:]]{1,2}\.[[:digit:]]{1,2}(\.[[:digit:]]{1,2})?/sbin/dovecot"
|
||||
# -
|
||||
#check_string_ps=""
|
||||
|
||||
|
||||
# - service_user
|
||||
# -
|
||||
# - User under which the service is running.
|
||||
# -
|
||||
# - Example:
|
||||
# - service_user="mumble-server"
|
||||
# - service_user="prosody"
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - service_user="prosody"
|
||||
# -
|
||||
#service_user=""
|
||||
|
||||
|
||||
# - service_group
|
||||
# -
|
||||
# - Group under which the service is running.
|
||||
# -
|
||||
# - Example:
|
||||
# - service_group="mumble-server"
|
||||
# - service_group="prosody"
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - service_group="prosody"
|
||||
# -
|
||||
#service_group=""
|
||||
|
||||
|
||||
# - cert_installed
|
||||
# -
|
||||
# - Locataion of certificate read by service
|
||||
# -
|
||||
# - Example:
|
||||
# - cert_installed="/var/lib/mumble-server/fullchain.pem"
|
||||
# - cert_installed="/var/lib/dehydrated/certs/jabber.so36.net/fullchain.pem"
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - /etc/dovecot/ssl/mailserver.crt
|
||||
# -
|
||||
#cert_installed=""
|
||||
|
||||
|
||||
# - key_installed
|
||||
# -
|
||||
# - Location of the key read by service
|
||||
# -
|
||||
# - Example:
|
||||
# - key_installed="/var/lib/mumble-server/privkey.pem"
|
||||
# - key_installed="/etc/prosody/certs/privkey_jabber.so36.pem"
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - /etc/dovecot/ssl/mailserver.key
|
||||
# -
|
||||
#key_installed=""
|
||||
|
||||
|
||||
# - cert_newest
|
||||
# -
|
||||
# - Location of the newest certificate.
|
||||
# -
|
||||
# - Example:
|
||||
# - cert_newest="/var/lib/dehydrated/certs/il-mumble.oopen.de/fullchain.pem"
|
||||
# - cert_newest="/var/lib/dehydrated/certs/jabber.so36.net/fullchain.pem"
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - /var/lib/dehydrated/certs/${service_domain}/fullchain.pem
|
||||
# -
|
||||
#cert_newest=""
|
||||
|
||||
|
||||
# - key_newest
|
||||
# -
|
||||
# - Location of the newest Key
|
||||
# -
|
||||
# - Example:
|
||||
# - key_newest="/var/lib/dehydrated/certs/il-mumble.oopen.de/privkey.pem"
|
||||
# - key_newest="/var/lib/dehydrated/certs/jabber.so36.net/privkey.pem"
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - /var/lib/dehydrated/certs/${service_domain}/privkey.pem
|
||||
# -
|
||||
#key_newest=""
|
||||
|
@ -0,0 +1,178 @@
|
||||
# *** [ Ansible managed: DO NOT EDIT DIRECTLY ] ***
|
||||
|
||||
#---------------------------------------
|
||||
#-----------------------------
|
||||
# Settings
|
||||
#-----------------------------
|
||||
#---------------------------------------
|
||||
|
||||
|
||||
# ---
|
||||
# - LOGGING
|
||||
# -
|
||||
# - This Parameter is now obsolete. If script is running in a terminal, then output ist verbose,
|
||||
# - the output will be verbos. If running as cronjob, output will only be written, if warnings or
|
||||
# - errors occurs.
|
||||
# ---
|
||||
|
||||
|
||||
# - What to check
|
||||
# -
|
||||
check_load=true
|
||||
check_mysql=false
|
||||
|
||||
# - PostgreSQL
|
||||
# -
|
||||
# - NOT useful, if more than one PostgreSQL instances are running!
|
||||
# -
|
||||
check_postgresql=true
|
||||
|
||||
check_apache=true
|
||||
check_nginx=false
|
||||
check_php_fpm=true
|
||||
check_redis=false
|
||||
check_website=false
|
||||
|
||||
# - If service is not listen on 127.0.0.1/loclhost, curl check must
|
||||
# - be ommited
|
||||
# -
|
||||
# - Defaults to: ommit_curl_check_nginx=false
|
||||
# -
|
||||
#ommit_curl_check_nginx=false
|
||||
|
||||
# - Is this a vserver guest machine?
|
||||
# -
|
||||
# - Not VSerber guest host does not support systemd!
|
||||
# -
|
||||
# - defaults to: vserver_guest=false
|
||||
# -
|
||||
#vserver_guest=false
|
||||
|
||||
|
||||
# - Additional Settings for check_mysql
|
||||
# -
|
||||
# - MySQL / MariaDB credentials
|
||||
# -
|
||||
# - Giving password on command line is insecure an sind mysql 5.5
|
||||
# - you will get a warning doing so.
|
||||
# -
|
||||
# - Reading username/password fro file ist also possible, using MySQL/MariaDB
|
||||
# - commandline parameter '--defaults-file'.
|
||||
# -
|
||||
# - Since Mysql Version 5.6, you can read username/password from
|
||||
# - encrypted file.
|
||||
# -
|
||||
# - Create (encrypted) option file:
|
||||
# - $ mysql_config_editor set --login-path=local --socket=/tmp/mysql.sock --user=root --password
|
||||
# - $ Password:
|
||||
# -
|
||||
# - Use of option file:
|
||||
# - $ mysql --login-path=local ...
|
||||
# -
|
||||
# - Example
|
||||
# - mysql_credential_args="--login-path=local"
|
||||
# - mysql_credential_args="--defaults-file=/etc/mysql/debian.cnf" (Debian default)
|
||||
# - mysql_credential_args="--defaults-file=/usr/local/mysql/sys-maint.cnf"
|
||||
# -
|
||||
mysql_credential_args=""
|
||||
|
||||
|
||||
# - Additional Settings for check_php_fpm
|
||||
# -
|
||||
# - On Linux Vserver System set
|
||||
# - curl_check_host=localhost
|
||||
# -
|
||||
# - On LX-Container set
|
||||
# - curl_check_host=127.0.0.1
|
||||
# -
|
||||
curl_check_host=127.0.0.1
|
||||
|
||||
# - Which PHP versions should be supported by this script. If more than one,
|
||||
# - give a blank separated list
|
||||
# -
|
||||
# - Example:
|
||||
# - php_versions="5.4 5.6 7.0 7.1"
|
||||
# -
|
||||
php_versions="8.1"
|
||||
|
||||
# - If PHP-FPM's ping.path setting does not match ping-$php_major_version,
|
||||
# - set the value given in your ping.path setting here. Give ping_path also
|
||||
# - the concerning php_version in form
|
||||
# - <php-version>:<ping-path>
|
||||
# -
|
||||
# - Multiple settings are possible, give a blank separated list.
|
||||
# -
|
||||
# - Example:
|
||||
# -
|
||||
# - ping_path="5.4:ping-site36_net 5.6:ping-oopen_de"
|
||||
# -
|
||||
ping_path=""
|
||||
|
||||
|
||||
# - Additional Settings for check_website - checking (expected) website response
|
||||
# -
|
||||
# - example:
|
||||
# - is_working_url="https://www.outoflineshop.de/"
|
||||
# - check_string='ool-account-links'
|
||||
# - include_cleanup_function=true
|
||||
# - extra_alert_address="ilker@so36.net"
|
||||
# - cleanup_function='
|
||||
# - rm -rf /var/www/www.outoflineshop.de/htdocs/var/cache/*
|
||||
# - rm -rf /var/www/www.outoflineshop.de/htdocs/var/session/*
|
||||
# - /usr/local/bin/redis-cli flushall > /dev/null 2>&1
|
||||
# - if [[ "$?" = "0" ]]; then
|
||||
# - ok "I have cleaned up directory \"/var/www/www.outoflineshop.de/htdocs/var/cache/\""
|
||||
# - else
|
||||
# - error "Cleaning up directory \"/var/www/www.outoflineshop.de/htdocs/var/cache/\" failed!"
|
||||
# - fi
|
||||
# - /etc/init.d/redis_6379 restart
|
||||
# - if [[ "$?" = "0" ]]; then
|
||||
# - ok "I restarted the redis service"
|
||||
# - echo -e "\t[ Ok ]: I restarted the redis service" >> $LOCK_DIR/extra_msg.txt
|
||||
# - else
|
||||
# - error "Restarting the redis server failed!"
|
||||
# - echo -e "\t[ Error ]: Restarting the redis server failed!" >> $LOCK_DIR/extra_msg.txt
|
||||
# - fi
|
||||
# - '
|
||||
# -
|
||||
is_working_url=''
|
||||
|
||||
check_string=''
|
||||
|
||||
include_cleanup_function=true
|
||||
|
||||
# - An extra e-mail address, which will be informed, if the given check URL
|
||||
# - does not response as expected (check_string) AFTER script checking, restarting
|
||||
# - servervices (webserver, php-fpm) and cleaning up (cleanup_function) was done.
|
||||
# -
|
||||
extra_alert_address=''
|
||||
|
||||
# - php_version_of_working_url
|
||||
# -
|
||||
# - If given website (is_working_url) does not response as expected, this PHP FPM
|
||||
# - engines will be restarted.
|
||||
# -
|
||||
# - Type "None" if site does not support php
|
||||
# -
|
||||
# - If php_version_of_working_url is not set, PHP FPM processes of ALL versions (php_versions)
|
||||
# - will be restarted
|
||||
# -
|
||||
php_version_of_working_url=''
|
||||
|
||||
# - Notice:
|
||||
# - If single qoutes "'" not needed inside cleanup function, then use single quotes
|
||||
# - to enclose variable "cleanup_function". Then you don't have do masquerade any
|
||||
# - sign inside.
|
||||
# -
|
||||
# - Otherwise use double quotes and masq any sign to prevent bash from interpreting.
|
||||
# -
|
||||
cleanup_function='
|
||||
'
|
||||
|
||||
|
||||
# - E-Mail settings for sending script messages
|
||||
# -
|
||||
from_address="root@`hostname -f`"
|
||||
content_type='Content-Type: text/plain;\n charset="utf-8"'
|
||||
to_addresses="root"
|
||||
|
@ -0,0 +1,54 @@
|
||||
# *** [ Ansible managed: DO NOT EDIT DIRECTLY ] ***
|
||||
|
||||
# ---------------------------------------------------------------
|
||||
# - Parameter Settings for script 'check-postfix-fatal-error.sh'.
|
||||
# ---------------------------------------------------------------
|
||||
|
||||
# MAIL_LOG
|
||||
#
|
||||
# Full qualified path to the mail log-file
|
||||
#
|
||||
# Defaults to: MAIL_LOG=/var/log/mail.log
|
||||
#
|
||||
#MAIL_LOG="/var/log/mail.log"
|
||||
|
||||
|
||||
# ---
|
||||
# - E-Mail settings for sending script messages
|
||||
# ---
|
||||
|
||||
# - company
|
||||
# -
|
||||
# - Example: company="Cadus e.V."
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - company="O.OPEN"
|
||||
# -
|
||||
#company="O.OPEN"
|
||||
company="IL"
|
||||
|
||||
# - sender_address
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - sender_address="${script_name%%.*}@$(hostname -f)"
|
||||
# -
|
||||
#sender_address="check-postfix-fatal-error@$(hostname -f)"
|
||||
|
||||
# - content_type
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - content_type='Content-Type: text/plain;\n charset="utf-8"'
|
||||
# -
|
||||
#content_type='Content-Type: text/plain;\n charset="utf-8"'
|
||||
|
||||
# - alert_email_addresses
|
||||
# -
|
||||
# - blank separated list of e-mail addresses
|
||||
#
|
||||
# - Example: alert_email_addresses="ckubu@oopen.de axel@warenform.net"
|
||||
# -
|
||||
# - Defaults to:
|
||||
# - alert_email_addresses="ckubu@oopen.de"
|
||||
# -
|
||||
#alert_email_addresses="ckubu@oopen.de"
|
||||
|
Reference in New Issue
Block a user