TMAegisBêta
Plus de règles pour linux

Linux distributions

TMA-RHEL9-6.1.2.5

Ensure access to the /etc/rsyslog.d directory is configured

MoyenneNiveau 1Automatiséelinux

Description

The /etc/rsyslog.d/ directory holds drop-in rsyslog configuration files ending in .conf. The directory should be owned by root, group-owned by root, and not writable by any account other than root so that unauthorized users cannot add, remove, or replace rsyslog configuration fragments.

Méthode de vérification

Méthode d'audit: Commande shell

shell
alt0() { command -v find >/dev/null 2>&1 || { echo "step1: find not installed"; return 1; }; o=$(bash -c 'find /etc/rsyslog.d/ -maxdepth 0 -type d \( ! -user root -o ! -group root - o -perm /0022 \) 2>/dev/null' 2>/dev/null); [ -z "$o" ] || { echo "step1: $o" | head -c 300; return 1; }; }; if alt0; then echo compliant; fi
Sortie attendue
compliant

Méthode de correction

Méthode de correction: Recommandation ou correctif d'infrastructure

Run the following commands to set ownership to root:root and remove group and other write from the directory: # chown root:root /etc/rsyslog.d # chmod g-w,o-w /etc/rsyslog.d

Propriétés

Systèmes d'exploitation
rhel-9
Étiquettes
cis-convertedlinux
Référence
CIS Red Hat Enterprise Linux 9 Benchmark v3.0.0 - 6.1.2.5

Vérifier cet hôte

Exécutez cette commande sur une machine que vous êtes autorisé à auditer. L'analyse est en lecture seule.

shell
tmaegis scan --target linux