Skip to content

XSS Vulnerability in API\ResponseTrait in CodeIgniter4

Moderate
MGatner published GHSA-7528-7jg5-6g62 Jan 24, 2022

Package

composer codeigniter4/framework (Composer)

Affected versions

< 4.1.8

Patched versions

4.1.8

Description

Impact

Cross-Site Scripting (XSS) vulnerability was found in API\ResponseTrait in Codeigniter4.
Attackers can do XSS attacks if you are using API\ResponseTrait.

Patches

Upgrade to v4.1.8 or later.

Workarounds

Do one of the following:

  1. Do not use API\ResponseTrait nor ResourceController
  2. Disable Auto Route and Use Defined Routes Only

References

For more information

If you have any questions or comments about this advisory:

Severity

Moderate
5.4
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
Required
Scope
Unchanged
Confidentiality
Low
Integrity
Low
Availability
None
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N

CVE ID

CVE-2022-21715

Weaknesses

Credits