# CVE-2025-40057: ptp: Add a upper bound on max_vclocks

- Severity: not scored yet
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.25%, higher than 17% of CVEs (2026-12-01)
- Published: 2025-10-28T11:48:30.947Z
- Modified: 2026-10-30T13:18:12.627Z
- Assigned by: Linux

## 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

(As written by CVE List.)

## Affected

- Linux Linux: from 73f37068d540eba5f93ba3a0019bf479d35ebd76 before 5ba2f8fd3db1c695f74f7f5df72eb87d52668a66; from 73f37068d540eba5f93ba3a0019bf479d35ebd76 before da513f2ad1b1b1cf1880ccc2603ce1f1f818eb2e; from 73f37068d540eba5f93ba3a0019bf479d35ebd76 before 8dd446056336faa2283d62cefc2f576536845edc; from 73f37068d540eba5f93ba3a0019bf479d35ebd76 before 35ce5f163889dbce88eda1df661b357a09bbed87; from 73f37068d540eba5f93ba3a0019bf479d35ebd76 before e9f35294e18da82162004a2f35976e7031aaf7f9; 5.14 (not affected: before 5.14; from 6.1.191 up to 6.1.*; from 6.6.160 up to 6.6.*; from 6.12.53 up to 6.12.*; from 6.17.3 up to 6.17.*; from 6.18 up to *)

## References

- <https://git.kernel.org/stable/c/5ba2f8fd3db1c695f74f7f5df72eb87d52668a66>
- <https://git.kernel.org/stable/c/da513f2ad1b1b1cf1880ccc2603ce1f1f818eb2e>
- <https://git.kernel.org/stable/c/8dd446056336faa2283d62cefc2f576536845edc>
- <https://git.kernel.org/stable/c/35ce5f163889dbce88eda1df661b357a09bbed87>
- <https://git.kernel.org/stable/c/e9f35294e18da82162004a2f35976e7031aaf7f9>

## Sources

- CVE List: [CVE-2025-40057](https://www.cve.org/CVERecord?id=CVE-2025-40057), CVE Terms of Use, modified 2026-10-30
- NVD: [CVE-2025-40057](https://nvd.nist.gov/vuln/detail/CVE-2025-40057), Public domain, modified 2026-10-30

---

Page: https://cve.day/CVE-2025-40057 · Whole record: https://cve.day/CVE-2025-40057.json · Rebuilt by cve.day 2026-11-25T22:59:06.938Z
