# CVE-2026-45138: CI4MS: Stored XSS in Blog Content via Broken `html_purify` Validation Rule

- Severity: Medium 5.4 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.18%, higher than 7% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-05-18T15:39:33.000Z
- Modified: 2026-10-24T20:10:00.137Z
- Also known as: GHSA-2m69-jmvh-6chr
- Weaknesses: CWE-79
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

CI4MS is a CodeIgniter 4-based content management system skeleton. Prior to version 0.31.9.0, the custom `html_purify` validation rule used to sanitize blog post bodies relies on by-reference mutation (`?string &$str`), but CodeIgniter 4's validator passes a local copy of the value, so the sanitized text is silently discarded. The Blog controller writes `$lanData['content']` directly into `blog_langs.content`, and the public template echoes it without escaping — yielding stored XSS executable in any visitor's browser, including the superadmin when previewing or editing posts. Version 0.31.9.0 patches the issue.

(As written by CVE List.)

## Affected

- ci4-cms-erp ci4ms: < 0.31.9.0
- ci4-cms-erp/ci4ms (Packagist): before 0.31.9.0

## Every score

- GitHub_M: CVSS:3.1 5.4 Medium `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N`
- GitHub: CVSS:3.1 5.4 Medium `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N`

## References

- <https://github.com/ci4-cms-erp/ci4ms/security/advisories/GHSA-2m69-jmvh-6chr> (exploit, web)
- <https://github.com/ci4-cms-erp/ci4ms/releases/tag/0.31.9.0> (web)
- <https://github.com/ci4-cms-erp/ci4ms> (package)

## Sources

- CVE List: [CVE-2026-45138](https://www.cve.org/CVERecord?id=CVE-2026-45138), CVE Terms of Use, modified 2026-07-20
- GitHub Advisory Database: [GHSA-2m69-jmvh-6chr](https://github.com/advisories/GHSA-2m69-jmvh-6chr), CC-BY-4.0, modified 2026-05-18
- NVD: [CVE-2026-45138](https://nvd.nist.gov/vuln/detail/CVE-2026-45138), Public domain, modified 2026-10-24

---

Page: https://cve.day/CVE-2026-45138 · Whole record: https://cve.day/CVE-2026-45138.json · Rebuilt by cve.day 2026-11-25T22:59:29.188Z
