CVE-2026-42154: Prometheus Denial of Service Vulnerability

HIGH
Advisory Identifier: GHSA-8rm2-7qqf-34qm
CVSS 7.5
CWE-789 CWE-400
Published
Advisory Summary

CVE-2026-42154 is a HIGH (CVSS 7.5) denial of service vulnerability (CWE-789: Memory Allocation with Excessive Size Value) affecting Prometheus libraries in the Go ecosystem. The issue involves remote read endpoint allows denial of service via crafted snappy payload. Remediation is available by upgrading affected packages to version 0.311.3, 0.305.2.

CVE-2026-42154 at a Glance

CVE Identifier CVE-2026-42154
GHSA Identifier GHSA-8rm2-7qqf-34qm
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-789: Memory Allocation with Excessive Size Value
Affected Product Prometheus
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity None (I:N)
Availability High (A:H)

How to Fix CVE-2026-42154

To remediate this vulnerability, upgrade all affected Prometheus dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/prometheus/prometheus fixed: 0.311.3
Upgrade github.com/prometheus/prometheus to 0.311.3
github.com/prometheus/prometheus fixed: 0.305.2
Upgrade github.com/prometheus/prometheus to 0.305.2
github.com/prometheus/prometheus fixed: Latest secure release
Upgrade github.com/prometheus/prometheus to Latest secure release
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/prometheus/prometheus

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-42154, inspect your project dependencies for Prometheus:

inspect dependencies for github.com/prometheus/prometheus

Analyze the terminal output to locate any version of Prometheus in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.311.3), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-789: Memory Allocation with Excessive Size Value, where the product allocates memory based on an untrusted, large size value, but it does not ensure that the size is within expected limits, allowing arbitrary amounts of memory to be allocated. In Prometheus, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact The remote read endpoint (`/api/v1/read`) does not validate the declared decoded length in a snappy-compressed request body before allocating memory. An unauthenticated attacker can send a small payload that causes a huge heap allocation per request. Under concurrent load this can exhaust available memory and crash the Prometheus process. ### Patches _Has the problem been patched? What versions should users upgrade to?_ Fixed in 3.11.3 and 3.5.3 LTS. Users should upgrade to these versions or later. ### Workarounds User who can not upgrade can place Prometheus behind a reverse proxy or firewall that requires authentication before requests reach /api/v1/read.

CVE-2026-42154 Affected Prometheus Versions

3 component(s)
Fixed Versions:
0.311.30.305.2
Product / Package Ecosystem Affected Versions Fixed Version
github.com/prometheus/prometheus
Go
≥ 0.306.0
< 0.311.3
0.311.3
github.com/prometheus/prometheus
Go
< 0.305.2
0.305.2
github.com/prometheus/prometheus
Go
≥ 1.0.0-rc.0
≤ 2.5.0

References

Frequently Asked Questions

What is CVE-2026-42154?
CVE-2026-42154 is a security vulnerability in Prometheus involving Remote read endpoint allows denial of service via crafted snappy payload under CWE-789: Memory Allocation with Excessive Size Value.
Which Prometheus versions are affected?
Affected versions include releases prior to 0.311.3, 0.305.2 across affected packages: github.com/prometheus/prometheus.
What version fixes CVE-2026-42154?
Upgrading to 0.311.3, 0.305.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/prometheus/prometheus affected?
Yes, github.com/prometheus/prometheus is affected in releases prior to 0.311.3, 0.305.2, Latest secure release. Upgrade your dependency to 0.311.3, 0.305.2, Latest secure release or later.
What is the CVSS score of CVE-2026-42154?
CVE-2026-42154 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
What CWE is associated with CVE-2026-42154?
CVE-2026-42154 is classified under CWE-789: Memory Allocation with Excessive Size Value (The product allocates memory based on an untrusted, large size value, but it does not ensure that the size is within expected limits, allowing arbitrary amounts of memory to be allocated.).
How can I check Go dependencies for CVE-2026-42154?
Run the dependency tree command: 'inspect dependencies for github.com/prometheus/prometheus'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-8rm2-7qqf-34qm",
  "modified" : "2026-06-08T16:22:14Z",
  "published" : "2026-05-05T19:34:05Z",
  "aliases" : [ "CVE-2026-42154" ],
  "summary" : "Prometheus: Remote read endpoint allows denial of service via crafted snappy payload",
  "details" : "### Impact\n\nThe remote read endpoint (`/api/v1/read`) does not validate the declared decoded length in a snappy-compressed request body before allocating memory.\nAn unauthenticated attacker can send a small payload that causes a huge heap allocation per request. Under concurrent load this can exhaust available memory and crash the Prometheus process.\n\n### Patches\n_Has the problem been patched? What versions should users upgrade to?_\n\nFixed in 3.11.3 and 3.5.3 LTS. Users should upgrade to these versions or later.\n\n### Workarounds\nUser who can not upgrade can place Prometheus behind a reverse proxy or firewall that requires authentication before requests reach /api/v1/read.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/prometheus/prometheus"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0.306.0"
      }, {
        "fixed" : "0.311.3"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/prometheus/prometheus"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.305.2"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/prometheus/prometheus"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.0.0-rc.0"
      }, {
        "last_affected" : "2.5.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/prometheus/prometheus/security/advisories/GHSA-8rm2-7qqf-34qm"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-42154"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/prometheus/prometheus/pull/18584"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/prometheus/prometheus/pull/18585"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/prometheus/prometheus"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/prometheus/prometheus/releases/tag/v3.11.3"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/prometheus/prometheus/releases/tag/v3.5.3"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-400", "CWE-789" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-05-05T19:34:05Z",
    "nvd_published_at" : "2026-05-04T19:16:04Z"
  }
}