Skip to content

GHSA-9x5g-62gj-wqf2 CVE-2025-64746

Directus has Improper Permission Handling on Deleted Fields

Medium npm
Severity
4.6 / 10
Medium · CVSS 3.1
Exploit chance (EPSS)
0.21%
Chance of exploitation in the next 30 days. Higher than 10.46% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-284 Improper Access Control
CWE-863 Incorrect Authorization
Fix
11.13.0
Upgrade directus to this version or later

Description

Summary

Directus does not properly clean up field-level permissions when a field is deleted. If a new field with the same name is created later, the system automatically re-applies the old permissions, which can lead to unauthorized access.

Details

When a field is removed from a collection, its reference in the permissions table remains intact. This stale reference creates a security gap: if another field is later created using the same name, it inherits the outdated permission entry.
This behavior can unintentionally grant roles access to data they should not be able to read or modify.

The issue is particularly risky in multi-tenant or production environments, where administrators may reuse field names, assuming old permissions have been fully cleared.

1.	Create a collection named test_collection.
2.	Add a field called secret_field.
3.	Assign a role with read permissions specifically tied to secret_field.
4.	Remove the secret_field from the collection.
5.	Create a new field with the exact same name secret_field.
6.	Notice that the previously assigned permissions are still active, granting access to the newly created field without reconfiguration.

Impact

When creating new fields with the same name as previously deleted fields it may inherit the permissions of that previously deleted field. This can potentially result in accidentally giving access to this new field in existing policies.

Affected versions

npm

PackageVulnerableFixed in
directus
< 11.13.0
11.13.0

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

directus npm → 11.13.0

npm
npm install directus@11.13.0
yarn
yarn add directus@11.13.0
pnpm
pnpm add directus@11.13.0

Severity breakdown

CVSS 3.1 4.6

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:N

Attack vector
Network
Attack complexity
Low
Privileges required
Low
User interaction
Required
Scope
Unchanged
Confidentiality
Low
Integrity
Low
Availability
None

Weakness

CWE-284: Improper Access Control

The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.

How to prevent it
  • Architecture and Design, Operation: Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.
  • Architecture and Design: Compartmentalize the system to have "safe" areas where trust boundaries can be unambiguously drawn. Do not allow sensitive data to go outside of the trust boundary and always be careful when interfacing with a compartment outside of the safe area. Ensure that appropriate compartmentalization is built into the system design, and the compartmentalization allows for and reinforces privilege separation functionality. Architects and designers should rely on the principle of least privilege to decide the appropriate time to use privileges and the time to drop privileges.

CWE-863: Incorrect Authorization

The product performs an authorization check when an actor attempts to access a resource or perform an action, but it does not correctly perform the check.

How to prevent it
  • Architecture and Design: Divide the product into anonymous, normal, privileged, and administrative areas. Reduce the attack surface by carefully mapping roles with data and functionality. Use role-based access control (RBAC) [REF-229] to enforce the roles at the appropriate boundaries. Note that this approach may not protect against horizontal authorization, i.e., it will not protect a user from attacking others with the same role.
  • Architecture and Design: Ensure that access control checks are performed related to the business logic. These checks may be different than the access control checks that are applied to more generic resources such as files, connections, processes, memory, and database records. For example, a database may restrict access for medical records to a specific database user, but each record might only be intended to be accessible to the patient and the patient's doctor [REF-7].
  • Architecture and Design: Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid. For example, consider using authorization frameworks such as the JAAS Authorization Framework [REF-233] and the OWASP ESAPI Access Control feature [REF-45].
  • Architecture and Design: For web applications, make sure that the access control mechanism is enforced correctly at the server side on every page. Users should not be able to access any unauthorized functionality or information by simply requesting direct access to that page. One way to do this is to ensure that all pages containing sensitive information are not cached, and that all such pages restrict access to requests that are accompanied by an active and authenticated session token associated with a user who has the required permissions to access that page.
  • System Configuration, Installation: Use the access control capabilities of your operating system and server environment and define your access control lists accordingly. Use a "default deny" policy when defining these ACLs.

References

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
GHSA-c6w9-5g5j-jh2p
Directus: Authorization-dependent response served from unsegmented cache key
High Also affects directus
GHSA-j5h6-vqc3-phqh
Directus: SSRF Protection Bypass via 0.0.0.0 in File Import
High Also affects directus
GHSA-38hg-ww64-rrwc
Directus: Authenticated Users Can Extract Concealed Fields via Aggregate Queries
High Also affects directus
GHSA-6q22-g298-grjh
Directus: Unauthenticated Denial of Service via GraphQL Alias Amplification of Expensive Health Check Resolver
High Also affects directus
GHSA-ph52-67fq-75wj
Directus: GraphQL Alias Amplification Denial of Service Due to Missing Query Cost/Complexity Limits
Medium Also affects directus
GHSA-mvv8-v4jj-g47j
Directus: Sensitive fields exposed in revision history
Medium Also affects directus
GHSA-qqmv-5p3g-px89
Directus: TUS Upload Authorization Bypass Allows Arbitrary File Overwrite
High Also affects directus
GHSA-wv3h-5fx7-966h
Directus: SSRF Protection Bypass via IPv4-Mapped IPv6 Addresses in File Import
High Also affects directus
Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor