Ecosyste.ms: Advisories

An open API service providing security vulnerability metadata for many open source software ecosystems.

Security Advisories: GSA_kwCzR0hTQS1nZ2dtLTY2cmgtcHA5OM4AA046

Incorrect Permission Checking for GraphQL Subscriptions

Summary

CWE-200: Exposure of Sensitive Information to an Unauthorized Actor
Access to information you should not have access to when the permissions rely on $CURRENT_USER for filtering.

Details

The permission filters (i.e. user_created IS $CURRENT_USER) are not properly checked when using GraphQL subscription resulting in unauthorized users getting event on their subscription which they should not be receiving according to the permissions.
This can be any collection but out-of-the box the directus_users collection is configured with such a permissions filter allowing you to get updates for other users when changes happen.

An example:

subscription {
  directus_users_mutated {
    event
    data {
      id
      last_access
      last_page
    }
  }
}

Patches

https://github.com/directus/directus/pull/19155

Workarounds

Disable GraphQL Subscriptions

References

Permalink: https://github.com/advisories/GHSA-gggm-66rh-pp98
JSON: https://advisories.ecosyste.ms/api/v1/advisories/GSA_kwCzR0hTQS1nZ2dtLTY2cmgtcHA5OM4AA046
Source: GitHub Advisory Database
Origin: Unspecified
Severity: Moderate
Classification: General
Published: 9 months ago
Updated: 6 months ago


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

Identifiers: GHSA-gggm-66rh-pp98, CVE-2023-38503
References: Repository: https://github.com/directus/directus
Blast Radius: 11.7

Affected Packages

npm:directus
Dependent packages: 16
Dependent repositories: 115
Downloads: 62,753 last month
Affected Version Ranges: >= 10.3, < 10.5.0
Fixed in: 10.5.0
All affected versions: 10.3.0, 10.3.1, 10.4.1, 10.4.2, 10.4.3
All unaffected versions: 9.0.0, 9.0.1, 9.1.0, 9.1.1, 9.1.2, 9.2.0, 9.2.1, 9.2.2, 9.3.0, 9.4.0, 9.4.1, 9.4.2, 9.4.3, 9.5.0, 9.5.1, 9.5.2, 9.6.0, 9.7.0, 9.7.1, 9.8.0, 9.9.0, 9.9.1, 9.10.0, 9.11.0, 9.11.1, 9.12.0, 9.12.1, 9.12.2, 9.13.0, 9.14.0, 9.14.1, 9.14.2, 9.14.3, 9.14.5, 9.15.0, 9.15.1, 9.16.0, 9.16.1, 9.17.0, 9.17.1, 9.17.2, 9.17.3, 9.17.4, 9.18.0, 9.18.1, 9.19.0, 9.19.1, 9.19.2, 9.20.0, 9.20.1, 9.20.2, 9.20.3, 9.20.4, 9.21.0, 9.21.2, 9.22.0, 9.22.1, 9.22.3, 9.22.4, 9.23.1, 9.23.3, 9.23.4, 9.24.0, 9.25.0, 9.25.1, 9.25.2, 9.26.0, 10.0.0, 10.1.0, 10.1.1, 10.2.0, 10.2.1, 10.5.0, 10.5.1, 10.5.2, 10.5.3, 10.6.0, 10.6.1, 10.6.2, 10.6.3, 10.6.4, 10.7.0, 10.7.1, 10.7.2, 10.8.0, 10.8.1, 10.8.2, 10.8.3, 10.9.0, 10.9.1, 10.9.2, 10.9.3, 10.10.0, 10.10.1, 10.10.2, 10.10.3, 10.10.4, 10.10.5, 10.10.6, 10.10.7