Linux distributions
TMA-RHEL10-5.3.2.3.2
Ensure password history is enforced for the root user
SedangLevel 1Otomatislinux
Deskripsi
If the pwhistory enforce_for_root option is enabled, the module will enforce password history for the root user as well
Cara pemeriksaan
Metode audit: Perintah shell
shell
alt0() { command -v grep >/dev/null 2>&1 || { echo "step1: grep not installed"; return 1; }; o=$(bash -c 'grep -Pi -- '"'"'^\h*enforce_for_root\b'"'"' /etc/security/pwhistory.conf' 2>&1); printf '%s\n' "$o" | tr -s ' \t' ' ' | sed 's/^ //;s/ $//' | grep -Fxq -- enforce_for_root || { echo step1: missing enforce_for_root; return 1; }; }; if alt0; then echo compliant; fi- Output yang diharapkan
compliant
Cara perbaikan
Metode perbaikan: Panduan atau patch infrastruktur
Edit or add the following line in /etc/security/pwhistory.conf: enforce_for_root
Properti
- Sistem operasi
- rhel-10
- Tag
- cis-convertedlinux
- Referensi
- CIS Red Hat Enterprise Linux 10 Benchmark v1.0.1 - 5.3.2.3.2
Periksa host ini
Jalankan ini pada mesin yang diizinkan untuk Anda audit. Pemindaian bersifat hanya baca.
shell
tmaegis scan --target linux