# CVE-2026-115274: Unbounded integer parsing in JSON.decode/1 enables CPU and memory exhaustion denial of service in Elixir

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 6.9
- **CVSS:** 6.9 (v4.0, CNA) `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Attack requirements: None; Privileges required: None; User interaction: None; Confidentiality impact: None; Integrity impact: None; Availability impact: Low; Confidentiality impact on other systems: None; Integrity impact on other systems: None; Availability impact on other systems: None
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, no login needed
- **EPSS:** 0.75% (percentile 51, 2026-11-26)
- **CWE:** CWE-1284
- **Published:** 2026-10-30T08:57:16.847Z
- **Modified:** 2026-11-20T06:17:18.520Z

## Who should check

- Anyone running elixir-lang elixir \>= 1.18.0-rc.0, \< 1.18.6; \>= 1.19.0-rc.0, \< 1.19.7; \>= 1.20.0-rc.0, \< 1.20.5
- Anyone running elixir-lang elixir \>= 793c1147210388587defb649f25f293ffbfa6b1b, \< \*

## Description

Improper Validation of Specified Quantity in Input vulnerability in the Elixir standard library's JSON module allows an unauthenticated attacker who supplies a JSON document to cause a denial of service through CPU and memory exhaustion.

JSON.decode/1 and JSON.decode!/1 convert each integer literal with erlang:binary\_to\_integer/1 and do not bound its length. A literal of one million digits decodes successfully but costs 100 to 300 times as much CPU as a string of the same length, so one request body of a few megabytes holds a scheduler for about a second. A literal of more than about 1.29 million digits raises SystemLimitError. Applications generated by phx.new decode request bodies with JSON in Plug.Parsers, before routing and authentication.

This issue affects elixir: from 1.18.0-rc.0 before 1.18.6, from 1.19.0-rc.0 before 1.19.7, and from 1.20.0-rc.0 before 1.20.5.

## Affected and fixed versions

- elixir-lang elixir: \>= 1.18.0-rc.0, \< 1.18.6; \>= 1.19.0-rc.0, \< 1.19.7; \>= 1.20.0-rc.0, \< 1.20.5 (cvelist)
- elixir-lang elixir: \>= 793c1147210388587defb649f25f293ffbfa6b1b, \< \* (cvelist)

## Mitigation

- Upgrade elixir to 1.20.5 or later.
- Vendor workaround: Decode untrusted JSON with an integer decoder that rejects long digit runs before conversion:
- 
- defmodule SafeJSON do
-   def decode!(binary) do
-     case JSON.decode(binary, :ok, integer: &safe\_integer/1) do
-       {decoded, :ok, ""} -\> decoded
-       \_ -\> raise ArgumentError, "invalid JSON"
-     end
-   end
- 
-   defp safe\_integer(digits) when byte\_size(digits) \<= 1024, do: String.to\_integer(digits)
-   defp safe\_integer(\_digits), do: raise(ArgumentError, "integer too long")
- end
- 
- In Phoenix, pass SafeJSON to Plug.Parsers as json\_decoder instead of Phoenix.json\_library().

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-115274. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-115274.md
Affected: elixir-lang elixir >= 1.18.0-rc.0, < 1.18.6; >= 1.19.0-rc.0, < 1.19.7; >= 1.20.0-rc.0, < 1.20.5; elixir-lang elixir >= 793c1147210388587defb649f25f293ffbfa6b1b, < *
Fixed in: elixir-lang elixir 1.18.6, elixir-lang elixir 1.19.7, elixir-lang elixir 1.20.5

Steps:
1. Search this machine and project for elixir-lang elixir: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2026-115274 being exploited?

There is no confirmed exploitation: CVE-2026-115274 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.75% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2026-115274?

Medium: CVSS 6.9 (v4.0, scored by CNA). Remote, no login needed.

### Which versions are affected by CVE-2026-115274?

elixir-lang elixir \>= 1.18.0-rc.0, \< 1.18.6; \>= 1.19.0-rc.0, \< 1.19.7; \>= 1.20.0-rc.0, \< 1.20.5; elixir-lang elixir \>= 793c1147210388587defb649f25f293ffbfa6b1b, \< \*.

### Is there a fix for CVE-2026-115274?

Yes. Fixed in elixir-lang elixir 1.18.6, elixir-lang elixir 1.19.7, elixir-lang elixir 1.20.5. Upgrade elixir to 1.20.5 or later. Vendor workaround: Decode untrusted JSON with an integer decoder that rejects long digit runs before conversion:  defmodule SafeJSON do   def decode!(binary) do     case JSON.decode(binary, :ok, integer: &safe\_integer/1) do       {decoded, :ok, ""} -\> decoded       \_ -\> raise ArgumentError, "invalid JSON"     end   end    defp safe\_integer(digits) when byte\_size(digits) \<= 1024, do: String.to\_integer(digits)   defp safe\_integer(\_digits), do: raise(ArgumentError, "integer too long") end  In Phoenix, pass SafeJSON to Plug.Parsers as json\_decoder instead of Phoenix.json\_library().

### How do I check if I'm affected by CVE-2026-115274?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://github.com/elixir-lang/elixir/security/advisories/GHSA-rp5q-xqhq-926h>
- patch: <https://github.com/elixir-lang/elixir/commit/793c1147210388587defb649f25f293ffbfa6b1b>
- patch: <https://github.com/elixir-lang/elixir/commit/7154e8781da9fd016a973ea01776a011c8b5726a>
- patch: <https://github.com/elixir-lang/elixir/commit/c81f12265919c34a0d5134f1905a4eb4edaea1c2>
- patch: <https://github.com/elixir-lang/elixir/commit/cd158efacdc10b30232864251747dff9b8387dfe>
- patch: <https://github.com/elixir-lang/elixir/commit/ee5cc23f8928aa5a0f25bb7f28e42ecfc7b7d396>
- other: <https://cna.erlef.org/cves/CVE-2026-115274.html>
- other: <https://osv.dev/vulnerability/EEF-CVE-2026-115274>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-115274>

HTML: <https://flawdb.com/CVE-2026-115274> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-115274>
