CVE-2024-39701
published 2024-07-08CVE-2024-39701: Directus is a real-time API and App dashboard for managing SQL database content. Directus >=9.23.0, <=v10.5.3 improperly handles _in, _nin operators. It…
PriorityP346high7.7CVSS 3.1
AVNACLPRLUINSCCHINAN
EPSS
0.42%
33.9th percentile
Directus is a real-time API and App dashboard for managing SQL database content. Directus >=9.23.0, <=v10.5.3 improperly handles _in, _nin operators. It evaluates empty arrays as valid so expressions like {"role": {"_in": $CURRENT_USER.some_field}} would evaluate to true allowing the request to pass. This results in Broken Access Control because the rule fails to do what it was intended to do: Pass rule if **field** matches any of the **values**. This vulnerability is fixed in 10.6.0.
Affected
3 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| directus | directus | — | — |
| directus | directus | >= 9.23.0 < 10.6.0 | 10.6.0 |
| monospace | directus | >= 9.23.0 < 10.6.0 | 10.6.0 |
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
GHSA
Directus incorrectly handles `_in` filter
ghsa·2024-07-08
CVE-2024-39701 [HIGH] CWE-284 Directus incorrectly handles `_in` filter
Directus incorrectly handles `_in` filter
### Summary
Directus >=9.23.0, .role** matches any of **[]**". Which should fail. This instead passes in Directus =v9.23.0
### PoC
{"role": {"_in": $CURRENT_USER.some_field}} field validation would pass if $CURRENT_USER.some_field is null.
Real scenario: Using https://github.com/u12206050/directus-extension-role-chooser with the specified versions of Directus (I tested on 10.0.0) allows users with access to this feature set their role to whatever role if they don't have any roles assigned (user_roles.role is left with the default value, null) despite the validation rule being
```yaml
validation:
role:
_in: $CURRENT_USER.user_roles.role
```
Latest version of Directus (v10.8.3 and above) handles the above validation rule correctly.
### Impact
Per
OSV
Directus incorrectly handles `_in` filter
osv·2024-07-08
CVE-2024-39701 [HIGH] Directus incorrectly handles `_in` filter
Directus incorrectly handles `_in` filter
### Summary
Directus >=9.23.0, .role** matches any of **[]**". Which should fail. This instead passes in Directus =v9.23.0
### PoC
{"role": {"_in": $CURRENT_USER.some_field}} field validation would pass if $CURRENT_USER.some_field is null.
Real scenario: Using https://github.com/u12206050/directus-extension-role-chooser with the specified versions of Directus (I tested on 10.0.0) allows users with access to this feature set their role to whatever role if they don't have any roles assigned (user_roles.role is left with the default value, null) despite the validation rule being
```yaml
validation:
role:
_in: $CURRENT_USER.user_roles.role
```
Latest version of Directus (v10.8.3 and above) handles the above validation rule correctly.
### Impact
Per
No detection rules found.
No public exploits indexed.
No writeups or analysis indexed.
2024-07-08
Published