Skip to main content
EPSS 0.3%top 77%

Prometheus has Stored XSS via metric names and label values in Prometheus web UI tooltips and metrics explorer (CVE-2026-40179)

0
Medium
Published: 04/13/2026 (04/13/2026, 16:39:16 UTC)
Source: GCVE Database
Product: github.com/prometheus/prometheus

Description

Prometheus versions prior to 3.5.2 and between 3.6.0 and 3.11.1 have stored cross-site scripting (XSS) vulnerabilities in their web UI. These arise from improper escaping of metric names and label values injected into innerHTML in UI components like chart tooltips and the Metric Explorer fuzzy search. An attacker who can inject metrics via compromised scrape targets or receivers may execute arbitrary JavaScript in users' browsers. This could lead to configuration exfiltration, data deletion, or service shutdown depending on enabled features. The vulnerabilities are fixed in versions 3.5.2 and 3.11.2. Mitigations include restricting exposure of remote write and OTLP receivers, trusting scrape targets, disabling admin or mutating API endpoints in untrusted environments, and avoiding untrusted links that generate poisoned labels.

CVSS v3.1

Score 6.1medium

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Changed
Confidentiality
Low
Integrity
Low
Availability
None
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N

Affected software

Bitnamimore threats →ghsa
prometheus
pkg:bitnami/prometheus
Affected versions
<0.305.2>=0.306.0 <0.311.2>=1.0.0 <3.5.2>=3.6.0 <3.11.2
Goghsa
github.com/prometheus/prometheus
Affected versions
<0.311.2-0.20260410083055-07c6232d159b

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: 10/06/2026, 21:59:11 UTC

Technical Analysis

CVE-2026-40179 describes stored XSS vulnerabilities in Prometheus web UI versions prior to 3.5.2 and between 3.6.0 and 3.11.1. The issue stems from metric names and label values being injected into innerHTML without proper escaping in multiple UI components such as chart tooltips and the Metric Explorer fuzzy search. Attackers able to inject malicious metrics via compromised scrape targets or receivers can execute arbitrary JavaScript in the browsers of users viewing these UI components. This can result in sensitive configuration data exfiltration, deletion of data, or service shutdown depending on the features enabled. The vulnerabilities have been fixed in versions 3.5.2 and 3.11.2. Mitigation strategies include restricting access to remote write and OTLP receivers, trusting scrape targets, disabling administrative or mutating API endpoints in untrusted environments, and avoiding untrusted links that may create poisoned labels.

Potential Impact

Successful exploitation allows an attacker to execute arbitrary JavaScript in the browsers of Prometheus users viewing affected UI components. This can lead to exfiltration of configuration data, deletion of data, or shutdown of the Prometheus service depending on enabled features. The vulnerability requires the attacker to inject malicious metrics via compromised scrape targets or receivers.

Mitigation Recommendations

A fix is available in Prometheus versions 3.5.2 and 3.11.2. Users should upgrade to these or later versions to remediate the vulnerability. Additional mitigations include restricting exposure of remote write and OTLP receivers, trusting scrape targets, disabling administrative or mutating API endpoints in untrusted environments, and avoiding untrusted links that may generate poisoned labels.

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

Technical Details

Gcve Source
db.gcve.eu
Osv Id
BIT-prometheus-2026-40179
Osv Schema Version
1.6.2
Aliases
["CVE-2026-40179"]
Ecosystems
["Bitnami"]
Database Specific Severity
Medium

Threat ID: 6a58b51a68715ace43db454b

Added to database: 07/16/2026, 10:40:26 UTC

Last enriched: 10/06/2026, 21:59:11 UTC

Last updated: 10/14/2026, 18:48:20 UTC

Views: 107

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