TLS certificate validation depends on comparing the current date against the certificate's validity window — if a device's system clock is significantly wrong (set to a date before the certificate's start date, or after a genuinely valid certificate's expiry, from the device's incorrect perspective), it will reject a perfectly valid certificate as expired or not-yet-valid.
Checking and fixing
On the affected device, check the system date and time settings, and confirm automatic time synchronization (NTP) is enabled rather than a manually-set, potentially drifted clock. This is a client-side issue rather than anything fixable on the server serving the certificate — if you're getting reports from a specific user or device, clock skew on their end is worth checking before assuming a server-side certificate problem.
Why an incorrect system clock causes such a broad, confusing range of certificate errors
Because certificate validation fundamentally depends on comparing the current date against the certificate's stated validity window, an incorrect system clock can produce seemingly contradictory errors, a certificate reported as both expired and not-yet-valid depending on which direction the clock is wrong, all stemming from the identical underlying clock problem.
How to enable automatic time synchronization to prevent this recurring
Enabling your operating system's built-in automatic time synchronization (NTP on most systems) rather than relying on a manually set clock prevents gradual clock drift from ever accumulating into a certificate-validation-affecting discrepancy in the first place.
What the practical impact of even a small clock discrepancy can be
Even a clock off by just a few minutes can occasionally trigger certificate validation issues right around a certificate's exact issuance or expiry moment — while a few minutes rarely causes problems for most certificates' validity windows, a clock off by hours or days much more reliably triggers this class of error.
How virtual machines specifically are prone to clock drift issues
Virtual machines, particularly ones that have been paused, suspended, or migrated between physical hosts, are especially prone to clock drift compared to a continuously running physical machine — explicitly enabling time synchronization is particularly important for VM-based infrastructure specifically because of this heightened drift risk.
A final note on verifying, not just installing, time sync
For any long-running server infrastructure, confirming NTP or an equivalent time synchronization service is not just installed but actually running and successfully syncing, rather than assuming installation alone guarantees ongoing accuracy, prevents a silent, gradual clock drift from eventually causing this exact class of issue.
What the exact commands look like for checking and correcting time on a Linux server
Running timedatectl status shows your current time synchronization status directly, while timedatectl set-ntp true enables automatic synchronization going forward — two commands that together diagnose and fix the large majority of Linux server clock-related issues.
How to set up monitoring specifically for clock drift on critical infrastructure
Some infrastructure monitoring tools can specifically alert if a server's reported time drifts beyond an acceptable threshold from a trusted reference time source, catching a synchronization failure proactively before it causes a certificate-related or other time-sensitive issue.
A quick closing checklist
A quick closing checklist covers checking your system's current date and time against a reliable independent source, enabling automatic time synchronization, and paying particular attention to virtual machines, which are especially prone to clock drift.
Why embedded and IoT devices are particularly prone to this specific issue
Embedded devices and IoT hardware often lack a battery-backed real-time clock or reliable internet-based time synchronization, meaning they're especially prone to running with a significantly incorrect clock, particularly after a power loss — worth specifically checking if troubleshooting a certificate issue on this category of device.