Rsyslog firewall Regel

Aus Xinux Wiki
Version vom 1. März 2023, 08:21 Uhr von Thomas.will (Diskussion | Beiträge) (→Prevent rsyslog logging to /var/log/syslog)
(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Zur Navigation springen Zur Suche springen

Prevent rsyslog logging to /var/log/syslog

Arbeitsverzeichni

  • cd /etc/rsyslog.d/

iptables

  • 10-iptables.conf
if $msg contains '-iptables-' then /var/log/firewall
& ~

nftables

  • 10-nftables.conf
if $msg contains '-nftables-' then /var/log/firewall
& ~

Neustarten des rsyslog

  • systemctl restart rsyslog.service