CVE-2025-1235
Executive Summary
CVE-2025-1235 is a vulnerability in Hirschmann industrial switches that allows a low-privileged attacker to set the device date to January 19, 2038. This action triggers a 32-bit time overflow (Year 2038 problem), causing the device clock to reset to January 1, 1970. The resulting time discontinuity can disrupt logging, certificate validation, scheduled tasks, and network protocols that rely on accurate timestamps, potentially leading to denial of service (DoS) or operational instability. The vulnerability has a CVSS score of 4.3 (Medium) and currently has no known patch or public exploit code.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
This vulnerability is not related to NPM, PyPI, Go, or Ruby packages. It affects embedded firmware on Hirschmann industrial networking hardware.
CVSS Breakdown & Threat Level
- CVSS Score: 4.3 (Medium)
- Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L
- Attack Vector: Network (AV:N) – The attacker can exploit this remotely.
- Attack Complexity: Low (AC:L) – No special conditions required.
- Privileges Required: Low (PR:L) – Attacker needs low-level access (e.g., default credentials or a compromised user account).
- User Interaction: None (UI:N) – No user action needed.
- Scope: Unchanged (S:U) – The exploit does not affect other components.
- Confidentiality Impact: None (C:N)
- Integrity Impact: None (I:N)
- Availability Impact: Low (A:L) – The time reset can cause service disruption but not full system failure.
Threat Level: Medium. The attack is easy to execute but requires low-level access. The impact is limited to availability and operational integrity.
Deep Dive & Mechanics
The vulnerability exploits the Year 2038 problem in 32-bit Unix time. The device’s real-time clock (RTC) stores time as a signed 32-bit integer, which overflows on January 19, 2038 (03:14:07 UTC). By setting the date to that exact point, the integer wraps to the minimum value, which corresponds to December 13, 1901, or in some implementations, January 1, 1970.
Attack Flow:
- The attacker gains low-privileged access to the switch (e.g., via default credentials or a compromised account).
- The attacker sends a command to set the system date to
2038-01-19 03:14:07or a value that triggers the overflow. - The device’s RTC stores this as a 32-bit integer, which overflows and resets to a past date (commonly 1970-01-01).
- This causes:
- Log timestamps to become invalid or reset.
- TLS/SSL certificate validation to fail (certificates may appear expired or not yet valid).
- Scheduled tasks (e.g., firmware updates, backups) to malfunction.
- Network protocols like NTP to behave unpredictably.
Root Cause: The firmware uses a 32-bit signed integer for time storage without proper bounds checking or handling of the overflow condition.
Vulnerable vs. Patched Code
Vulnerable Code (Conceptual C):
#include <time.h>
#include <stdio.h>
void set_device_time(long timestamp) {
// Directly assign to 32-bit signed integer
time_t device_time = (time_t)timestamp;
// No validation for overflow
struct tm *timeinfo = localtime(&device_time);
printf("Time set to: %s", asctime(timeinfo));
}
Patched Code (Conceptual C):
#include <time.h>
#include <stdio.h>
#include <limits.h>
void set_device_time(long timestamp) {
// Validate timestamp range to prevent overflow
if (timestamp < 0 || timestamp > 2147483647) { // Max 32-bit signed
printf("Error: Invalid timestamp\n");
return;
}
time_t device_time = (time_t)timestamp;
struct tm *timeinfo = localtime(&device_time);
printf("Time set to: %s", asctime(timeinfo));
}
Explanation: The patched code adds a bounds check to reject timestamps that would cause a 32-bit overflow. This prevents the date from being set to the Year 2038 threshold.
Exploitation & Lab Setup
Red Team (Attack Simulation)
Prerequisites:
- Access to a Hirschmann switch with low-privileged credentials (e.g., via SSH or web interface).
- Network connectivity to the device.
Steps:
- Identify the target switch (e.g., via Shodan or network scanning).
- Log in with low-privileged credentials (e.g.,
admin:adminor a compromised account). - Execute the date change command:
# Example via SSH ssh lowpriv@192.168.1.100 # Set date to overflow point date -s "2038-01-19 03:14:07" - Verify the time reset:
date # Output: Thu Jan 1 00:00:00 UTC 1970 - Observe disruption: Logs show incorrect timestamps, certificates fail, etc.
Alternative (via SNMP):
snmpset -v2c -c public 192.168.1.100 1.3.6.1.2.1.25.1.2.0 i 2147483647
Blue Team (Defense & Detection)
Detection:
- Monitor for commands that set the system date to values near 2038-01-19.
- Alert on sudden time jumps (e.g., from 2025 to 1970).
- Use NTP monitoring to detect time synchronization anomalies.
Mitigation:
- Restrict low-privileged accounts from changing system time.
- Implement strict access controls (e.g., RBAC).
- Use NTP with authentication to prevent unauthorized time changes.
- Apply vendor firmware updates if/when available.
Indicators of Compromise (IOCs)
- Log Entries: System logs showing date set to
2038-01-19 03:14:07or1970-01-01 00:00:00. - Network Traffic: SNMP set requests for time-related OIDs (e.g.,
1.3.6.1.2.1.25.1.2.0). - System State: Device clock showing a date prior to 1970 or exactly 1970-01-01.
- Certificate Errors: TLS handshake failures due to invalid certificate validity dates.
Detection Engineering
YARA Rule
rule CVE_2025_1235_TimeOverflow {
meta:
description = "Detects attempts to set system time to Year 2038 overflow value"
author = "Valters IT"
date = "2025-04-10"
cve = "CVE-2025-1235"
strings:
$time_set_cmd = "date -s" nocase
$overflow_date = "2038-01-19" nocase
$overflow_timestamp = "2147483647" nocase
condition:
any of ($time_set_cmd) and any of ($overflow_date, $overflow_timestamp)
}
Sigma Rule
title: CVE-2025-1235 - Hirschmann Switch Time Overflow Attempt
id: 8a9b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d
status: experimental
description: Detects attempts to set the system date to the Year 2038 overflow point on Hirschmann switches.
author: Valters IT
date: 2025-04-10
logsource:
category: process_creation
product: linux
detection:
selection:
CommandLine|contains:
- 'date -s'
- '2038-01-19'
- '2147483647'
condition: selection
falsepositives:
- Legitimate NTP synchronization (unlikely)
level: high
Suricata Rule
alert tcp $HOME_NET any -> $EXTERNAL_NET 22 (msg:"CVE-2025-1235 - SSH Date Set Attempt"; content:"date -s"; content:"2038-01-19"; sid:1000001; rev:1;)
alert udp $HOME_NET any -> $EXTERNAL_NET 161 (msg:"CVE-2025-1235 - SNMP Time Set Attempt"; content:"|06 0a 2b 06 01 02 01 19 01 02 00|"; sid:1000002; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Restrict low-privileged accounts from modifying system time.
- Implement strict access controls (e.g., RBAC) to limit who can change date/time settings.
- Use NTP with authentication to prevent unauthorized time changes.
- Monitor logs for time-related anomalies.
Long-Term Fix:
- Apply vendor firmware updates when available (currently UNKNOWN/UNPATCHED).
- Consider replacing affected devices with models that use 64-bit time storage.
- Implement network segmentation to limit exposure of industrial switches.
Workaround:
- Disable the ability to set time via low-privileged interfaces (e.g., SNMP write access).
- Use a firewall to restrict SSH/SNMP access to trusted IPs only.
Valters IT
DevSecOps & Cyber Threat Intelligence