TMA-MONGO-SYSTEM-LOG-DESTINATION
Ensure system activity is logged to a file or syslog
MittelStufe 1Automatisiertmongodb
Beschreibung
systemLog.destination file or syslog keeps server logs persistently instead of only on stdout. Checks the YAML config file /etc/mongod.conf (SKIP when it does not exist).
So wird geprüft
Prüfmethode: Dateimuster
- Datei
/etc/mongod.conf- Muster
(?m)^systemLog:[ \t]*\n(?:[ \t]*(?:#[^\n]*)?\n|[ \t]+[^\n]*\n)*?[ \t]+destination:[ \t]*['\x22]?(?:file|syslog)\b
So wird behoben
Behebungsmethode: Anleitung oder Infrastruktur-Patch
Set systemLog.destination: file and systemLog.path: /var/log/mongodb/mongod.log in /etc/mongod.conf and restart mongod
Eigenschaften
- Betriebssysteme
- Beliebig
- Tags
- mongodbdatabaselogging
- Referenz
- CIS MongoDB Benchmark - Audit Logging / System Log (verify section number for your release)
Diesen Host prüfen
Führen Sie dies auf einem Rechner aus, den Sie prüfen dürfen. Der Scan ist schreibgeschützt.
shell
tmaegis scan --target mongodb