# CVE-2025-9823: Reflected XSS in lead:addLeadTags - Quick Add

> Reflected XSS in Mautic allows attackers to execute arbitrary JavaScript in victim sessions, enabling session hijacking and data theft.

- **Severity:** Medium 4.8 (`CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:A/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Any signed-in user
- **Attackable:** Over the internet
- **Victim action needed:** A user has to click or open something
- **Fix available:** Yes
- **Published:** 3 Sep 2025
- **Updated:** 3 Sep 2025
- **Also known as:** GHSA-9v8p-m85m-f7mm

## What is CVE-2025-9823?

CVE-2025-9823 is a medium-severity cross-site scripting vulnerability in Mautic, published on 3 Sep 2025. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.

### Official description

SummaryA Cross-Site Scripting (XSS) vulnerability allows an attacker to execute arbitrary JavaScript in the context of another user’s session. This occurs because user-supplied input is reflected back in the server’s response without proper sanitization or escaping, potentially enabling malicious actions such as session hijacking, credential theft, or unauthorized actions in the application.

DetailsThe vulnerability resides in the “Tags” input field on the /s/ajax?action=lead:addLeadTags endpoint. Although the server applies sanitization before storing the data or returning it later, the payload is executed immediately in the victim’s browser upon reflection, allowing an attacker to run arbitrary JavaScript in the user’s session.

ImpactA Reflected XSS attack can have a significant impact, allowing attackers to steal sensitive user data like cookies, redirect users to malicious websites, manipulate the web page content, and essentially take control of a user's session within an application by executing malicious JavaScript code within the victim's browser, even if the server-side code is secure; essentially enabling them to perform actions as if they were the logged-in user.

References  *   Web Security Academy: Cross-site scripting https://portswigger.net/web-security/cross-site-scripting 
  *   Web Security Academy: Reflected cross-site scripting https://portswigger.net/web-security/cross-site-scripting/reflected

Weakness: CWE-79 (Improper Neutralization of Input During Web Page Generation)

## Which versions are affected by CVE-2025-9823?

6 open source packages ship an affected version, including mautic/core.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `mautic/core` | Packagist | From 4.4.0 | 4.4.17 |
| `mautic/core` | Packagist | From 4.4.0 | 4.4.17 |
| `mautic/core` | Packagist | From 5.0.0-alpha | 5.2.8 |
| `mautic/core` | Packagist | From 5.0.0-alpha | 5.2.8 |
| `mautic/core` | Packagist | From 6.0.0-alpha | 6.0.5 |
| `mautic/core` | Packagist | From 6.0.0-alpha | 6.0.5 |

## How do I fix CVE-2025-9823?

Upgrade mautic/core to a fixed version for your release line: 4.4.17, 5.2.8 or 6.0.5.

## Is CVE-2025-9823 being exploited?

There is no known exploitation of CVE-2025-9823 in the wild and no public exploit code.

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2025-9823 and fix it if it is affected.

What it is: CVE-2025-9823 is a medium-severity cross-site scripting vulnerability in Mautic, published on 3 Sep 2025. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.
Exploitation: There is no known exploitation of CVE-2025-9823 in the wild and no public exploit code.

Affected packages and fixed versions:
- mautic/core (Packagist): affected from 4.4.0; fixed in 4.4.17
- mautic/core (Packagist): affected from 4.4.0; fixed in 4.4.17
- mautic/core (Packagist): affected from 5.0.0-alpha; fixed in 5.2.8
- mautic/core (Packagist): affected from 5.0.0-alpha; fixed in 5.2.8
- mautic/core (Packagist): affected from 6.0.0-alpha; fixed in 6.0.5
- mautic/core (Packagist): affected from 6.0.0-alpha; fixed in 6.0.5

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2025-9823/ (Markdown: https://insights.sbomify.com/CVE-2025-9823/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2025-9823
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2025-9823
- OSV: https://osv.dev/vulnerability/CVE-2025-9823

---
From sbomify Insights: https://insights.sbomify.com/CVE-2025-9823/
Summaries are generated and may contain mistakes; the official description above is the record.
