Synchronize internal information system clocks
An XCCDF Rule
Description
Synchronizing internal information system clocks provides uniformity of time stamps for information systems with multiple system clocks and systems connected over a network.
Rationale
Inaccurate time stamps make it more difficult to correlate events and can lead to an inaccurate analysis. Determining the correct time a particular event occurred on a system is critical when conducting forensic analysis and investigating system events.
- ID
- xccdf_org.ssgproject.content_rule_chronyd_sync_clock
- Severity
- Medium
- Updated
Remediation - Ansible
- name: Synchronize internal information system clocks
lineinfile:
path: /etc/chrony/chrony.conf
create: true
line: makestep 1 -1
state: present
Remediation - Shell Script
# Remediation is applicable only in certain platforms
if [ ! -f /.dockerenv ] && [ ! -f /run/.containerenv ]; then
if [ -e "/etc/chrony/chrony.conf" ] ; then
LC_ALL=C sed -i "/^\s*makestep 1 \-1/Id" "/etc/chrony/chrony.conf"