CVE-2026-40872 mailcow: dockerized vulnerable to stored XSS in autodiscover logs email address field
Attackers can inject malicious scripts into Autodiscover logs via unauthenticated requests, leading to code execution when admins view the logs.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- None listed
What is CVE-2026-40872?
CVE-2026-40872 is a critical cross-site scripting vulnerability in mailcow-dockerized, published on 21 Apr 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
mailcow: dockerized is an open source groupware/email suite based on docker. In versions prior to 2026-03b, the admin dashboard's Autodiscover logs render the EMailAddress value (logged as the "user" field) without HTML escaping. By submitting an unauthenticated Autodiscover request with a crafted EMailAddress containing HTML/JS, the payload is stored in Redis and executed when an admin views the Autodiscover logs. Version 2026-03b fixes the vulnerability.
Which versions are affected by CVE-2026-40872?
How do I fix CVE-2026-40872?
No fix has been published for CVE-2026-40872 yet. Limit exposure of the affected software until one is available.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2026-40872 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-40872 exists.
Sources
Also known as GHSA-f9xf-vc72-rcgm.