OpenDMARK Report (Ubuntu 18.04)

Aus Tutorials
Zur Navigation springen Zur Suche springen

Noch in Bearbeitung


Voraussetzungen

OpenDMARK muss bereits installiert sein.

Konfiguration

Datei für Roh-Daten

Die Datei

sudo vi /etc/opendmarc.conf

bearbeiten und am Ende folgenden Parameter hinzufügen:

##  HistoryFile path
##  	default (none)
##
##  If set, specifies the location of a text file to which records are written
##  that can be used to generate DMARC aggregate reports.  Records are groups
##  of rows containing information about a single received message, and
##  include all relevant information needed to generate a DMARC aggregate
##  report.  It is expected that this will not be used in its raw form, but
##  rather periodically imported into a relational database from which the
##  aggregate reports can be extracted by a tool such as opendmarc-import(8).
HistoryFile /var/spool/opendmarc/opendmarc.dat

Danach das Verzeichnis dafür erstellen:

sudo mkdir -p /var/spool/opendmarc/
sudo chown opendmarc:opendmarc /var/spool/opendmarc/
sudo chmod 770 /var/spool/opendmarc/

Zum Abschluss den Service wieder neustarten:

sudo systemctl restart opendmarc.service

Datenbank

Da bei mit die Datei /usr/share/doc/opendmarc/schema.mysql gefehlt hat, musste ich sie erst von https://sources.debian.org/src/opendmarc/1.3.2-7/db/ runterladen (mittels opendmarc -V die Versin prüfen):

cd /usr/share/doc/opendmarc/
sudo wget https://sources.debian.org/data/main/o/opendmarc/1.3.2-7/db/schema.mysql
sudo wget https://sources.debian.org/data/main/o/opendmarc/1.3.2-7/db/update-db-schema.mysql

Danach die herunter geladenen SQL-Patches anpassen:

cd ~/temp
cp /usr/share/doc/opendmarc/schema.mysql .
vi schema.mysql

Am Ende die 2 Zeilen für den Benutzer anpassen:

CREATE USER 'opendmarc'@'%' IDENTIFIED BY '<password>';
GRANT ALL ON opendmarc.* to 'opendmarc'@'%';

Die angepasste Datei mittels folgenden Befehl ausführen:

mysql -u root -p < schema.mysql

Links

https://blog.schaal-24.de/mail/dmarc-reports-erstellen/

https://dokuwiki.tachtler.net/doku.php?id=tachtler:postfix_centos_7_-_opendmarc_anbinden_opendmarc-milter#konfigurationreports_ausgehend


Zurück zu OpenDMARK