CVE-2025-40057 ptp: Add a upper bound on max_vclocks
A local attacker with high privileges can trigger a kernel warning and potential denial of service by setting an excessively large value for max_vclocks in the PTP subsystem.
- Exploited in the wild
- Not known
- Login needed
- An administrator
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2025-40057?
CVE-2025-40057 is a denial of service vulnerability in Linux, published on 28 Oct 2025. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
In the Linux kernel, the following vulnerability has been resolved:
ptp: Add a upper bound on max_vclocks
syzbot reported WARNING in max_vclocks_store.
This occurs when the argument max is too large for kcalloc to handle.
Extend the guard to guard against values that are too large for kcalloc
Which versions are affected by CVE-2025-40057?
How do I fix CVE-2025-40057?
Apply the vendor's patch.
Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.
Is CVE-2025-40057 being exploited?
There is no known exploitation of CVE-2025-40057 in the wild and no public exploit code.
Sources
Also known as AZL-68930, BELL-CVE-2025-40057, DEBIAN-CVE-2025-40057, GHSA-29fx-85hc-pfpw, ROOT-OS-DEBIAN-12-CVE-2025-40057, ROOT-OS-UBUNTU-2204-CVE-2025-40057 and 2 more.