CVE-2022-21715Codeigniter
Medium 6.1 No auth needed
Follow: this CVE · Codeigniter · Codeigniter We alert you by email or Slack (account required).
- Priority
- 52
- CVSS 3.1
- 6.1
- EPSS
- 0.9% probability of exploitation in 30 days · percentile 59
- Auth required
- No
- Published
- Jan 24, 2022
- Updated
- Jun 17, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-79
- SSVC (CISA)
- Exploitation: none · Automatable: no · Technical impact: partial
- Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
What happens
CodeIgniter4 is the 4.x branch of CodeIgniter, a PHP full-stack web framework. A cross-site scripting (XSS) vulnerability was found in `API\ResponseTrait` in Codeigniter4 prior to version 4.1.8. Attackers can do XSS attacks if a potential victim is using `API\ResponseTrait`. Version 4.1.8 contains a patch for this vulnerability. There are two potential workarounds available. Users may avoid using `API\ResponseTrait` or `ResourceController` Users may also disable Auto Route and use defined routes only.
What to do
- Apply the vendor's security update for Codeigniter.
- It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| Packagist | codeigniter4/framework |
< 4.1.8 |
4.1.8 |
composer require "codeigniter4/framework:^4.1.8" |
Per OSV / GitHub Advisories (GHSA-7528-7jg5-6g62). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| codeigniter | codeigniter | ≥ 4.0.0 < 4.1.8 |
Official sources
References
Links published by the sources. Open them with care.
- codeigniter4.github.io Mitigation Vendor Advisory
- github.com Patch Third Party Advisory
- github.com Mitigation Third Party Advisory