phpMyFAQ: Stored XSS via Unsanitized Email Field in Admin FAQ Editor
thorsten phpMyFAQ
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| thorsten/phpmyfaq Packagist |
|
|
| phpmyfaq/phpmyfaq Packagist |
|
|
thorsten phpMyFAQ
| Product | Affected | Fixed in |
|---|---|---|
| thorsten/phpmyfaq Packagist |
|
|
| phpmyfaq/phpmyfaq Packagist |
|
|
phpMyFAQ is an open source FAQ web application. Prior to version 4.1.1, an unauthenticated attacker can submit a guest FAQ with an email address that is syntactically valid per RFC 5321 (quoted local part) yet contains raw HTML — for example "<script>alert(1)</script>"@evil.com. PHP's FILTER_VALIDATE_EMAIL accepts this email as valid. The email is stored in the database without HTML sanitization and later rendered in the admin FAQ editor template using Twig's |raw filter, which bypasses auto-escaping entirely. This issue has been patched in version 4.1.1.
From the CVE record · GitHub_M
Before version 4.1.1, phpMyFAQ accepts a guest FAQ email address containing raw HTML and stores it without sanitization. An unauthenticated attacker can submit one of these addresses; when an administrator opens the FAQ editor, the address is rendered without escaping, potentially executing script in the administrator's browser.
Anyone running thorsten/phpmyfaq or phpmyfaq/phpmyfaq versions earlier than 4.1.1 should check their installation.