Skip to main content
EPSS 0.3%top 75%

CVE-2026-32686: CWE-400 Uncontrolled Resource Consumption in ericmj decimal

0
Medium
Published: 05/07/2026 (05/07/2026, 14:04:47 UTC)
Source: CVE Database V5
Vendor/Project: ericmj
Product: decimal

Description

Uncontrolled Resource Consumption vulnerability in ericmj decimal allows unauthenticated remote Denial of Service. The decimal library does not bound the exponent on parsed input. Storing a decimal with a very large exponent (e.g. Decimal.new("1e1000000000")) is accepted without error. Subsequent calls to arithmetic functions (Decimal.add/2, Decimal.sub/2, Decimal.div/2M), Decimal.to_string/2M with :normalM or :xsdM format, Decimal.to_integer/1M, Decimal.round/3M, or Decimal.compare/3M with a threshold allocate memory proportional to the exponent value, which can exhaust available memory and crash the BEAM VM. Any application that accepts user-supplied decimal input and subsequently performs arithmetic, rounding, conversion to integer, or string formatting on it is exposed. A single malicious request is sufficient to cause an out-of-memory crash. This issue affects decimal: from 0.1.0 before 3.0.0.

CVSS v4.0

Score 6.9medium

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vuln. Confidentiality
None
Vuln. Integrity
None
Vuln. Availability
High
Subsq. Confidentiality
None
Subsq. Integrity
None
Subsq. Availability
None
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

Affected software

ericmj

decimal

Affected versions
>=0.1.0 <3.0.0

ericmj

decimal

decimal
pkg:hex/decimal
Affected versions
=0.1.0<3.0.0
decimal
pkg:hex/decimal
Affected versions
>=0.1.0 <3.0.0
GitHub Actionsmore threats →cve
ericmj/decimal
pkg:github/ericmj/decimal
CPE configurations
cpe:2.3:a:ericmj:decimal:*:*:*:*:*:*:*:*

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 08/05/2026, 17:30:01 UTC

Technical Analysis

CVE-2026-32686 describes an uncontrolled resource consumption vulnerability (CWE-400) in the ericmj decimal library. The library does not bound the exponent on parsed decimal inputs, enabling attackers to supply extremely large exponents that cause exponential memory growth during operations such as add, subtract, divide, to_string, to_integer, round, and compare. This is due to tail-recursive multiplication and list duplication proportional to the exponent value. The impact is an unauthenticated remote denial of service by exhausting memory and crashing the BEAM node. Mitigations were introduced in version 2.4.0 but are not enabled by default, so this version is not considered fully patched. A patch is available but the exact fixed version is not specified in the input data.

Potential Impact

An attacker can cause a denial of service by sending decimal inputs with very large exponents to any system using the ericmj decimal library that performs arithmetic or conversions on user-supplied decimals. This can lead to Out-of-Memory exceptions and crash the BEAM runtime, potentially taking down the affected node with a single request. The vulnerability affects unauthenticated remote users and can be triggered via common input vectors such as JSON, form fields, or Ecto decimal fields.

Mitigation Recommendations

A patch is available for this vulnerability. Although version 2.4.0 includes mitigations, they are not enabled by default and thus it is not considered a fully patched version. Users should upgrade to a version where the mitigations are enabled by default once such a version is released. Until then, consider implementing input validation to restrict exponent sizes on decimal inputs to prevent exploitation.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
EEF
Date Reserved
2026-03-13T09:12:14.474Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 69fca37ecbff5d8610fd578b

Added to database: 05/07/2026, 14:36:46 UTC

Last enriched: 08/05/2026, 17:30:01 UTC

Last updated: 09/11/2026, 19:42:47 UTC

Views: 94

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses