CVE-2025-37984

Severity CVSS v4.0:
Pending analysis
Type:
Unavailable / Other
Publication date:
20/05/2025
Last modified:
21/05/2025

Description

In the Linux kernel, the following vulnerability has been resolved:<br /> <br /> crypto: ecdsa - Harden against integer overflows in DIV_ROUND_UP()<br /> <br /> Herbert notes that DIV_ROUND_UP() may overflow unnecessarily if an ecdsa<br /> implementation&amp;#39;s -&gt;key_size() callback returns an unusually large value.<br /> Herbert instead suggests (for a division by 8):<br /> <br /> X / 8 + !!(X &amp; 7)<br /> <br /> Based on this formula, introduce a generic DIV_ROUND_UP_POW2() macro and<br /> use it in lieu of DIV_ROUND_UP() for -&gt;key_size() return values.<br /> <br /> Additionally, use the macro in ecc_digits_from_bytes(), whose "nbytes"<br /> parameter is a -&gt;key_size() return value in some instances, or a<br /> user-specified ASN.1 length in the case of ecdsa_get_signature_rs().

Impact