Security mailing lists by PureSourceCode

CVE-2026-97853

MEDIUM 6.9CVSS 4.0

Unbounded allocation in decimal Decimal.round/3 driven by the places argument enables DoS

Memory Allocation with Excessive Size Value vulnerability in ericmj decimal allows Denial of Service.

Decimal.round/3 builds the full result for the requested number of decimal places before the context precision (34 digits by default) is applied, so its cost grows with the places argument instead of with the size of the result. For positive places it appends places zero digits to the coefficient as a charlist before converting it to an integer, and for negative places it builds a charlist of -places zero digits. A single call such as Decimal.round(Decimal.new("1.5"), -50_000_000) allocates about 5.5 GB of memory, which can exhaust available memory and get the BEAM VM killed. The oldest releases instead loop once per decimal place, consuming CPU in proportion to places.

Any application that passes a user-supplied number of decimal places or scale to Decimal.round/2 or Decimal.round/3 without bounding it is exposed. The input limits added for CVE-2026-32686 do not cover the places argument.

This issue affects decimal: from 0.1.0 before 3.1.2.

Published
10 Oct 2026
Last modified
26 Nov 2026
Assigned by
6b3ad84c-e1a6-4bf7-a703-f496b71e49db
NVD status
Deferred
Weakness
CWE-789
Also known as
EEF-CVE-2026-97853GHSA-6c27-994x-c52f
Sources
NVDJSONCVE ListJSONOSV EEF-CVE-2026-97853JSON

Scores

SourceScored byVersionScoreVector / decision
NVD 6b3ad84c-e1a6-4bf7-a703-f496b71e49db (Secondary) CVSS 4.0 MEDIUM 6.9 CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
CVE List EEF CVSS 4.0 MEDIUM 6.9 CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
CVE List CISA-ADP SSVC Exploitation: none; Automatable: no; Technical Impact: partial

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
CVE List https://repo.hex.pm decimal
cpe:2.3:a:ericmj:decimal:*:*:*:*:*:*:*:*
>= 0.1.0, < 3.1.2 3.1.2
CVE List https://github.com ericmj/decimal
cpe:2.3:a:ericmj:decimal:*:*:*:*:*:*:*:*
>= 05bb73eb40ddef24eda782d905766f56a3660522
OSV Hex decimal >= 0.1.0, < 3.1.2 3.1.2

References

History

  • 26 Nov 2026 18:37 UTC · OSV: updated (other details)
  • 25 Nov 2026 21:22 UTC · NVD: first stored (published 10 Oct 2026)
  • 25 Nov 2026 20:15 UTC · OSV: first stored (published 10 Oct 2026)
  • 25 Nov 2026 20:10 UTC · CVE List: first stored (published 10 Oct 2026)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.