Kerberos
TMA-KERBEROS-KADM5-ACL-PERMS
Ensure kadm5.acl is owned by root and not writable by group or others
TinggiLevel 1Otomatiskerberos
Deskripsi
kadm5.acl decides which principals may administer the Kerberos database; whoever can edit it can grant themselves full kadmin rights. Checks /etc/krb5kdc/kadm5.acl (Debian/Ubuntu) and /var/kerberos/krb5kdc/kadm5.acl (RHEL, default 600 root): owner root, no group or other write.
Cara pemeriksaan
Metode audit: Perintah shell
shell
n=0; bad=0
for f in /etc/krb5kdc/kadm5.acl /var/kerberos/krb5kdc/kadm5.acl; do
[ -f "$f" ] || continue
n=$((n+1))
o=$(stat -Lc %U "$f") || exit 1
[ "$o" = root ] || { echo "$f owned by $o"; bad=1; }
[ -z "$(find -L "$f" -maxdepth 0 -perm /022)" ] || { echo "$f is group/other writable"; bad=1; }
done
[ "$n" -gt 0 ] && [ "$bad" -eq 0 ] && echo compliant- Output yang diharapkan
compliant
Cara perbaikan
Metode perbaikan: Perintah shell
shell
for f in /etc/krb5kdc/kadm5.acl /var/kerberos/krb5kdc/kadm5.acl; do if [ -f "$f" ]; then chown root:root "$f" && chmod 600 "$f" || exit 1; fi; doneProperti
- Sistem operasi
- Apa saja
- Tag
- kerberoskdcpermissions
- Referensi
- CIS MIT Kerberos / Linux Benchmark guidance - KDC configuration file permissions (verify section number for your release)
Periksa host ini
Jalankan ini pada mesin yang diizinkan untuk Anda audit. Pemindaian bersifat hanya baca.
shell
tmaegis scan --target kerberos