Sulu: JCR-SQL2 injection via `categories` query parameter (unauthenticated)GHSA-jg26-q8hg-3pq4
Fix: sulu/sulu@d19c014GHSA-jg26-q8hg-3pq4 is a SQL Injection vulnerability in sulu/sulu. A fix is available for sulu/sulu — see the affected versions and patch details below.
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-jg26-q8hg-3pq4.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
Real-World Exposure
sulu/sulu🐘sulu/suluReal-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
Impact
An unauthenticated JCR-SQL2 injection exists in the Smart Content category filter of the 2.x content query builder.
Category IDs supplied through the public ?categories= query parameter are only trimmed and are then concatenated directly into a JCR-SQL2 WHERE clause, without the numeric validation that the equivalent tag filter already performs. Any public page that renders a Smart Content element with category filtering enabled evaluates this parameter, so no authentication or special configuration beyond a category-filtered content block is required.
An anonymous visitor can therefore:
- inject boolean conditions to infer the existence of, and disclose, content nodes they should not see (for example unpublished pages) via blind boolean-based extraction; and
- submit malformed query fragments that cause query errors or resource-intensive queries, degrading availability.
Because the sink is a JCR-SQL2 query, the impact is limited to reading and enumerating content-repository nodes and to error/denial-of-service conditions; it cannot be used to modify data through this path.
Patches
Fixed in 2.6.25 and 3.0.8. Category, tag, and audience-target-group IDs are now cast to integers before they are used in the JCR-SQL2 query, so no attacker-controlled characters can reach the query.
Workarounds
If you cannot upgrade immediately:
- Apply the fix manually — cast each ID to an integer where it is concatenated into the category (and, defensively, tag and audience-targeting)
WHEREclause in the content Smart Content query builder. - Alternatively, disable category filtering on publicly reachable Smart Content elements until the patch is applied.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐘Packagist | sulu/sulu | all versions | 2.6.25composer require sulu/sulu:^2.6.25 |
| 🐘Packagist | sulu/sulu | ≥ 3.0.0&&< 3.0.8 | 3.0.8composer require sulu/sulu:^3.0.8 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for sulu/sulu, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update sulu/sulu to 2.6.25 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-jg26-q8hg-3pq4 is resolved across your whole dependency graph.
Workarounds
Until you can upgrade, make sure every query built from user input uses parameterised statements or a prepared-statement API rather than string concatenation, and reduce the database account's privileges so an injected query cannot read or alter data beyond what the feature needs.
Frequently Asked Questions
Is GHSA-jg26-q8hg-3pq4 in your dependencies?
Find it across Packagist, including transitive dependencies.