CVE-2026-42151: Prometheus Azure AD remote write OAuth client secret exposed via config API
Impact Users who use Azure AD remote write with OAuth authentication are impacted. The clientsecret field in the Azure AD remote write OAuth configuration (storage/remote/azuread) was typed as string instead of Secret. Prometheus redacts fields of type Secret when serving the configuration via the /-/config HTTP API endpoint.
Published May 5, 2026 · Updated Sep 9, 2026
Affected packages
github.com/prometheus/prometheus
- Ecosystem
- Go
- Affected
- >= 0.45.2, < 0.311.3
- Fixed in
- 0.311.3
- Check
go list -m github.com/prometheus/prometheus
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Impact
Users who use Azure AD remote write with OAuth authentication are impacted.
The client_secret field in the Azure AD remote write OAuth configuration (storage/remote/azuread) was typed as string instead of Secret. Prometheus redacts fields of type Secret when serving the configuration via the /-/config HTTP API endpoint. Because the field was a plain string, the Azure OAuth client secret was exposed in plaintext to any user or process with access to that endpoint.
Patches
The problem has been patched by changing ClientSecret in OAuthConfig to Secret. Users should upgrade to 3.11.3 or 3.5.3 LTS.
Workarounds
Users who can not upgrade can switch to Managed Identity or Workload Identity authentication for Azure AD remote write, which do not involve a client secret.
Credited to brettgervasoni, noren95.
References
- https://github.com/prometheus/prometheus/security/advisories/GHSA-wg65-39gg-5wfj
- https://nvd.nist.gov/vuln/detail/CVE-2026-42151
- https://github.com/prometheus/prometheus/pull/18587
- https://github.com/prometheus/prometheus/pull/18590
- https://github.com/prometheus/prometheus/releases/tag/v3.11.3
- https://github.com/prometheus/prometheus/releases/tag/v3.5.3
- https://access.redhat.com/errata/RHSA-2026:42852
- https://access.redhat.com/errata/RHSA-2026:43052
- https://access.redhat.com/errata/RHSA-2026:44622
- https://access.redhat.com/errata/RHSA-2026:47149
- https://access.redhat.com/errata/RHSA-2026:47952
- https://access.redhat.com/errata/RHSA-2026:50843
- https://access.redhat.com/errata/RHSA-2026:50874
- https://access.redhat.com/errata/RHSA-2026:53412
- https://access.redhat.com/errata/RHSA-2026:53413
- https://access.redhat.com/errata/RHSA-2026:53415
- https://access.redhat.com/errata/RHSA-2026:53530
- https://access.redhat.com/errata/RHSA-2026:54288
- https://access.redhat.com/errata/RHSA-2026:54427
- https://access.redhat.com/errata/RHSA-2026:56340
- https://access.redhat.com/errata/RHSA-2026:57191
- https://access.redhat.com/security/cve/CVE-2026-42151
- https://bugzilla.redhat.com/show_bug.cgi?id=2466507
- https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-42151.json
- https://access.redhat.com/errata/RHSA-2026:25039
- https://access.redhat.com/errata/RHSA-2026:25245
- https://access.redhat.com/errata/RHSA-2026:25504
- https://access.redhat.com/errata/RHSA-2026:34357
- https://access.redhat.com/errata/RHSA-2026:34359
- https://access.redhat.com/errata/RHSA-2026:36651
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
More Go vulnerabilities
All Go entriesCVE-2026-42154
Prometheus: Remote read endpoint allows denial of service via crafted snappy payload
high7.5No fixMay 5, 2026CVE-2026-44903
Prometheus vulnerable to stored XSS via crafted histogram bucket label values in the old web UI heatmap display
medium6.1May 5, 2026CVE-2026-40179
Prometheus has Stored XSS via metric names and label values in Prometheus web UI tooltips and metrics explorer
medium6.1Apr 13, 2026
