Medium severity · published Jan 24, 2022
CVE-2022-21715
CodeIgniter4 is the 4.x branch of CodeIgniter, a PHP full-stack web framework
6.1
CVSS
1%
EPSS
No
On KEV
Description
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.
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
Required
Confidentiality
Low
Integrity
Low
Availability
None
Scope
Changed
Exploitation
Is it being used?
Exploit prediction (EPSS)1.0% · higher than 63% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
CO
Codeigniter · Codeigniter
4.0.0 before 4.1.8 · source: NVD
References
NVD
https://nvd.nist.gov/vuln/detail/CVE-2022-21715
CVE.org
https://www.cve.org/CVERecord?id=CVE-2022-21715
Mitigation
https://codeigniter4.github.io/userguide/incoming/routing.html#use-defined-routes-only
Patch
https://github.com/codeigniter4/CodeIgniter4/commit/70d881cf5322b7c32e69516aebd2273ac6a1e8dd
Mitigation
https://github.com/codeigniter4/CodeIgniter4/security/advisories/GHSA-7528-7jg5-6g62
More from Codeigniter
9.8
CVE-2025-54418
CodeIgniter4's ImageMagick Handler has Command Injection Vulnerability
9.8
CVE-2023-32692
CodeIgniter is a PHP full-stack web framework
9.8
CVE-2022-46170
CodeIgniter is a PHP full-stack web framework
9.8
CVE-2022-40834
B.C. Institute of Technology CodeIgniter <=3.1.13 is vulnerable to SQL Injection via system\database\DB_query_builder.php or_not_like() function. Note: Multiple third parties have…
9.8
CVE-2022-40824
B.C. Institute of Technology CodeIgniter <=3.1.13 is vulnerable to SQL Injection via system\database\DB_query_builder.php or_where() function. Note: Multiple third parties have…
