Advisory Database
  • Advisories
  • Dependency Scanning
  1. composer
  2. ›
  3. ci4-cms-erp/ci4ms
  4. ›
  5. CVE-2026-45138

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

May 18, 2026

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.

References

  • github.com/advisories/GHSA-2m69-jmvh-6chr
  • github.com/ci4-cms-erp/ci4ms/releases/tag/0.31.9.0
  • github.com/ci4-cms-erp/ci4ms/security/advisories/GHSA-2m69-jmvh-6chr
  • nvd.nist.gov/vuln/detail/CVE-2026-45138

Code Behaviors & Features

Detect and mitigate CVE-2026-45138 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 0.31.9

Fixed versions

  • 0.31.9

Solution

Upgrade to version 0.31.9 or above.

Impact 5.4 MEDIUM

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N

Learn more about CVSS

Weakness

  • CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

Source file

packagist/ci4-cms-erp/ci4ms/CVE-2026-45138.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Tue, 23 Jun 2026 12:22:38 +0000.