CVE-2022-1988: Cross-site Scripting in FacturaScripts
6.5
CVSS Score
3.0
Basic Information
CVE ID
GHSA ID
EPSS Score
0.43299%
CWE
Published
6/4/2022
Updated
2/1/2023
KEV Status
No
Technology
PHP
Technical Details
CVSS Vector
CVSS:3.0/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:L
| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| facturascripts/facturascripts | composer | <= 2022.08 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from improper input sanitization order in the test() method. The patch moved the noHtml() sanitization call to execute before any validation checks, ensuring 'descripcion' is always sanitized. This indicates the original implementation allowed unsanitized input to persist when early validation checks failed, creating an XSS vector. The direct code modification in the commit and added unit test for HTML escaping confirm this as the root cause.