# CVE-2023-25572: React-Admin vulnerable to Cross-Site-Scripting attack on \`\<RichTextField\>\`

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.4
- **CVSS:** 5.4 (v3.1, CNA) `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Privileges required: Low; User interaction: Required; Scope: Changed (impact reaches other components); Confidentiality impact: Low; Integrity impact: Low; Availability impact: None
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, login needed
- **EPSS:** 0.67% (percentile 47, 2026-11-28)
- **CWE:** CWE-79
- **Aliases:** GHSA-5jcr-82fh-339v
- **Published:** 2023-02-13T20:49:54.340Z
- **Modified:** 2026-09-10T03:49:56.699Z

## Who should check

- Projects that depend on npm package react-admin (\< 3.19.12)
- Projects that depend on npm package ra-ui-materialui (\>= 4.0.0, \< 4.7.6)
- Anyone running marmelab react-admin \< 3.19.12; \>= 4.0.0, \< 4.7.6

## Description

react-admin is a frontend framework for building browser applications on top of REST/GraphQL APIs. react-admin prior to versions 3.19.12 and 4.7.6, along with ra-ui-materialui prior to 3.19.12 and 4.7.6, are vulnerable to cross-site scripting. All React applications built with react-admin and using the \`\<RichTextField\>\` are affected. \`\<RichTextField\>\` outputs the field value using \`dangerouslySetInnerHTML\` without client-side sanitization. If the data isn't sanitized server-side, this opens a possible cross-site scripting (XSS) attack. Versions 3.19.12 and 4.7.6 now use \`DOMPurify\` to escape the HTML before outputting it with React and \`dangerouslySetInnerHTML\`. Users who already sanitize HTML data server-side do not need to upgrade. As a workaround, users may replace the \`\<RichTextField\>\` by a custom field doing sanitization by hand.

## Affected and fixed versions

- npm `react-admin`: affected \< 3.19.12; fixed 3.19.12, 4.7.6 (osv)
- npm `ra-ui-materialui`: affected \>= 4.0.0, \< 4.7.6; fixed 4.7.6, 3.19.12 (osv)
- marmelab react-admin: \< 3.19.12; \>= 4.0.0, \< 4.7.6 (cvelist)

## Mitigation

- Upgrade react-admin to one of 3.19.12, 4.7.6 (or later in the same release line).
- Upgrade ra-ui-materialui to one of 4.7.6, 3.19.12 (or later in the same release line).

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2023-25572. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2023-25572.md
Affected: react-admin < 3.19.12; ra-ui-materialui >= 4.0.0, < 4.7.6
Fixed in: 3.19.12, 4.7.6

Steps:
1. Search this machine and project for react-admin (npm), ra-ui-materialui (npm), marmelab react-admin: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2023-25572 being exploited?

There is no confirmed exploitation: CVE-2023-25572 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.67% chance of exploitation in the next 30 days (as of 2026-11-28).

### How serious is CVE-2023-25572?

Medium: CVSS 5.4 (v3.1, scored by CNA). Remote, login needed. A user has to take an action, such as opening a link, for the attack to work.

### Which versions are affected by CVE-2023-25572?

react-admin \< 3.19.12; ra-ui-materialui \>= 4.0.0, \< 4.7.6.

### Is there a fix for CVE-2023-25572?

Yes. Fixed in 3.19.12, 4.7.6. Upgrade react-admin to one of 3.19.12, 4.7.6 (or later in the same release line). Upgrade ra-ui-materialui to one of 4.7.6, 3.19.12 (or later in the same release line).

### How do I check if I'm affected by CVE-2023-25572?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://github.com/marmelab/react-admin/security/advisories/GHSA-5jcr-82fh-339v>
- vendor: <https://nvd.nist.gov/vuln/detail/CVE-2023-25572>
- patch: <https://github.com/marmelab/react-admin/pull/8644>
- patch: <https://github.com/marmelab/react-admin/pull/8645>
- other: <https://github.com/marmelab/react-admin/releases/tag/v3.19.12>
- other: <https://github.com/marmelab/react-admin/releases/tag/v4.7.6>
- other: <https://github.com/marmelab/react-admin>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2023-25572>
- OSV: CC-BY 4.0 <https://osv.dev/vulnerability/GHSA-5jcr-82fh-339v> (license: <https://creativecommons.org/licenses/by/4.0/>)

HTML: <https://flawdb.com/CVE-2023-25572> · JSON: <https://flawdb.com/api/v1/entries/CVE-2023-25572>
