Habe nun die Basisinstallation gemacht mit folgenden Einstellungen und Ergebnissen:
SSH
- Port geändert
- kein root Login mehr möglich
- neuen User erstellt mit PubKey Auth
- kein Passwortlogin mehr möglich
Teamspeak 3
- keine besonderen Massnahmen getroffen
Keyhelp Panel
- Administrationspanel mit automatischer Installation der folgenden Komponenten (Apache, PHP, MariaDB, ProFTPD, Postfix, Dovecot, phpmyAdmin, Roundcube, OpenSSL)
- keine besonderen Massnahmen getroffen
- ToDo: 2-Faktor Authentifizierung einrichten
nftables
- habe nftables als systemd Service aktiviert
Systemauswertungen
netstat -tulpen
Code: Alles auswählen
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State User Inode PID/Program name
tcp 0 0 0.0.0.0:143 0.0.0.0:* LISTEN 0 19941 1868/dovecot
tcp 0 0 127.0.0.1:783 0.0.0.0:* LISTEN 0 16033 882/perl
tcp 0 0 0.0.0.0:30033 0.0.0.0:* LISTEN 1001 26869 3225/./ts3server
tcp 0 0 0.0.0.0:721 0.0.0.0:* LISTEN 0 14827 559/sshd
tcp 0 0 45.132.246.229:53 0.0.0.0:* LISTEN 106 15478 561/named
tcp 0 0 127.0.0.1:53 0.0.0.0:* LISTEN 106 15476 561/named
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 0 18440 1805/master
tcp 0 0 127.0.0.1:12345 0.0.0.0:* LISTEN 114 15339 614/opendkim
tcp 0 0 127.0.0.1:953 0.0.0.0:* LISTEN 106 15525 561/named
tcp 0 0 0.0.0.0:10011 0.0.0.0:* LISTEN 1001 26886 3225/./ts3server
tcp 0 0 0.0.0.0:4190 0.0.0.0:* LISTEN 0 19867 1868/dovecot
tcp 0 0 0.0.0.0:993 0.0.0.0:* LISTEN 0 19943 1868/dovecot
tcp 0 0 0.0.0.0:995 0.0.0.0:* LISTEN 0 19892 1868/dovecot
tcp 0 0 0.0.0.0:10022 0.0.0.0:* LISTEN 1001 26890 3225/./ts3server
tcp 0 0 127.0.0.1:10023 0.0.0.0:* LISTEN 0 13724 485/postgrey --pidf
tcp 0 0 127.0.0.1:10024 0.0.0.0:* LISTEN 117 17051 1123/amavisd-new (m
tcp 0 0 127.0.0.1:10025 0.0.0.0:* LISTEN 0 18541 1805/master
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 107 16082 724/mysqld
tcp 0 0 0.0.0.0:587 0.0.0.0:* LISTEN 0 18443 1805/master
tcp 0 0 0.0.0.0:110 0.0.0.0:* LISTEN 0 19890 1868/dovecot
tcp6 0 0 :::143 :::* LISTEN 0 19942 1868/dovecot
tcp6 0 0 ::1:783 :::* LISTEN 0 16031 882/perl
tcp6 0 0 :::80 :::* LISTEN 0 15876 718/apache2
tcp6 0 0 :::30033 :::* LISTEN 1001 26870 3225/./ts3server
tcp6 0 0 :::721 :::* LISTEN 0 14838 559/sshd
tcp6 0 0 :::21 :::* LISTEN 108 20261 1918/proftpd: (acce
tcp6 0 0 :::53 :::* LISTEN 106 15472 561/named
tcp6 0 0 ::1:953 :::* LISTEN 106 15526 561/named
tcp6 0 0 :::10011 :::* LISTEN 1001 26887 3225/./ts3server
tcp6 0 0 :::443 :::* LISTEN 0 15880 718/apache2
tcp6 0 0 :::4190 :::* LISTEN 0 19868 1868/dovecot
tcp6 0 0 :::993 :::* LISTEN 0 19944 1868/dovecot
tcp6 0 0 :::995 :::* LISTEN 0 19893 1868/dovecot
tcp6 0 0 :::10022 :::* LISTEN 1001 26891 3225/./ts3server
tcp6 0 0 ::1:10023 :::* LISTEN 0 13723 485/postgrey --pidf
tcp6 0 0 ::1:10024 :::* LISTEN 117 17052 1123/amavisd-new (m
tcp6 0 0 :::110 :::* LISTEN 0 19891 1868/dovecot
udp 0 0 0.0.0.0:9987 0.0.0.0:* 1001 26883 3225/./ts3server
udp 0 0 45.132.246.229:53 0.0.0.0:* 106 15477 561/named
udp 0 0 127.0.0.1:53 0.0.0.0:* 106 15475 561/named
udp6 0 0 :::9987 :::* 1001 26884 3225/./ts3server
udp6 0 0 :::53 :::* 106 15470 561/named
Mittlerweile sind es also einige Dienste mehr, wobei man vermutlich min 2 Ports eliminieren kann (die beiden Mailports ohne SSL) und nicht alle lauschen müssen, oder?
lsmod | grep conntrack
meine im Eingangspost erwähnte nftables Datei habe ich jetzt noch nicht eingebaut, ebensowenig wie die "nicht SSL" Ports für den Mailserver zu schliessen. Ansonsten wäre das so in etwas meine Ausgangslage gewesen für die ich eine "nftables" Datei geschustert hätte
EDIT: Nachtrag zu deinem in der Zwischenzeit eingegangenen Post
Das mit dem SSH PubKey habe ich gemacht (siehe Kommentar oben) und auch per Password einloggen funktioniert nun nicht mehr.
Nach der Eingabe der beiden Modprobe krieg ich nun das raus:
lsmod | grep conntrack
Code: Alles auswählen
nf_conntrack_ftp 20480 0
nf_conntrack 172032 1 nf_conntrack_ftp
nf_defrag_ipv6 20480 1 nf_conntrack
nf_defrag_ipv4 16384 1 nf_conntrack
libcrc32c 16384 1 nf_conntrack
um das auch beim Neustart wieder zu haben kann ich doch einfach folgendes machen
und dann die beiden Zeilen
hinzufügen, oder? (oder kommt das modprobe weg?)