VDB
Sign up
MEDIUM5.4

GHSA-7528-7jg5-6g62

Cross-site Scripting Vulnerability in CodeIgniter4

Quick fix

GHSA-7528-7jg5-6g62 — codeigniter4/framework: upgrade to the fixed version with the command below.

composer require codeigniter4/framework:^4.1.8

Details

### 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](https://codeigniter4.github.io/userguide/incoming/routing.html#use-defined-routes-only)

### References - [Cross Site Scripting (XSS) Software Attack | OWASP Foundation](https://owasp.org/www-community/attacks/xss/)

### For more information If you have any questions or comments about this advisory: * Open an issue in [codeigniter4/CodeIgniter4](https://github.com/codeigniter4/CodeIgniter4/issues) * Email us at [SECURITY.md](https://github.com/codeigniter4/CodeIgniter4/blob/develop/SECURITY.md)

Are you affected?

Enter the version of the package you're using.

Affected packages

Packagist/codeigniter4/framework
Introduced in: 0Fixed in: 4.1.8
Fixcomposer require codeigniter4/framework:^4.1.8

References