mediumsystemunverified
Ensure chrony maxpoll is configured to 16 or less
chrony-maxpoll-configured · RHEL ≥ 10 · 1 impl
Description
Each chrony time source must set maxpoll to 16 or less so the system compares its clock against the authoritative source at least that often.
Rationale
A large maxpoll lets the local clock drift far from the authoritative time source, undermining the accuracy of security-relevant timestamps.
Check → Remediate
Checkcommand
# Every 'server'/'pool' line must carry maxpoll <=16; a missing/large maxpoll is a finding.
conf=/etc/chrony.conf
[ -f "$conf" ] || { echo "FAIL: no chrony.conf"; exit 1; }
bad=0
while read -r mp; do
[ -n "$mp" ] && [ "$mp" -gt 16 ] 2>/dev/null && bad=1
done <<EOT
$(grep -E '^\s*(server|pool)\s' "$conf" 2>/dev/null | grep -oE 'maxpoll[[:space:]]+[0-9]+' | grep -oE '[0-9]+')
EOT
# also fail if any server/pool line lacks maxpoll
srv=$(grep -cE '^\s*(server|pool)\s' "$conf" 2>/dev/null)
mpc=$(grep -E '^\s*(server|pool)\s' "$conf" 2>/dev/null | grep -c 'maxpoll')
if [ "$bad" -eq 1 ] || [ "$srv" -ne "$mpc" ]; then echo "FAIL: a chrony source has maxpoll>16 or missing"; exit 1; fi
[ "$srv" -gt 0 ] && { echo "OK: all chrony sources have maxpoll<=16"; exit 0; }
echo "FAIL: no chrony sources configured"; exit 1
- expected_exit:
- 0
Remediatemanual
- note:
- Add 'maxpoll 16' (or less) to each server/pool line in /etc/chrony.conf and restart chronyd.
Framework references
STIG
V-281336 / RHEL-10-800040
NIST 800-53
AU-8
#chrony#time#ntp#stig