The Synopsys Software Integrity Group is now Black Duck®. Learn More

close search bar

Sorry, not available in this language yet

close language selection

CyRC Vulnerability Advisory: Sensitive data exposure in JSON enables account compromise in Strapi

David Johansson

May 19, 2022 / 2 min read

Overview

The Black Duck Cybersecurity Research Center (CyRC) research has exposed two separate vulnerabilities in Strapi, a popular open source headless CMS tool built in JavaScript that allows users to quickly design and build APIs. The Strapi admin panel is a web-based UI where users define content types for the API and manage its content.

The issues found in the Strapi admin panel are

  • CVE-2022-30617: Sensitive data disclosed for admin panel users in JSON response
  • CVE-2022-30618: Sensitive data disclosed for API users in JSON response

Affected software

CVE-2022-30617

  • Strapi v3 up to v3.6.9
  • Strapi v4 beta versions up to v4.0.0-beta.15 (Strapi v4.0.0 stable releases are not affected)

CVE-2022-30618

  • Strapi v3 up to v3.6.9
  • Strapi v4 up to v4.1.9

Impact

CVE-2022-30617
An authenticated user with access to the Strapi admin panel can view private and sensitive data, such as email and password reset tokens, for other admin panel users that have a relationship (e.g., created by, updated by) with content accessible to the authenticated user. For example, a low-privileged “author” role account can view these details in the JSON response for an “editor” or “super admin” that has updated one of the author’s blog posts. There are also many other scenarios where such details from other users can leak in the JSON response, either through a direct or indirect relationship. Access to this information enables a user to compromise other users’ accounts by successfully invoking the password reset workflow. In a worst-case scenario, a low-privileged user could get access to a “super admin” account with full control over the Strapi instance, and could read and modify any data as well as block access to both the admin panel and API by revoking privileges for all other users.

CVSS 3.1 base score: 8.8 (High)
CVSS 3.1 vector:  CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H/E:P/RL:O/RC:C

CVE-2022-30618
An authenticated user with access to the Strapi admin panel can view private and sensitive data, such as email and password reset tokens, for API users if content types accessible to the authenticated user contain relationships to API users (from:users-permissions). There are many scenarios in which such details from API users can leak in the JSON response within the admin panel, either through a direct or indirect relationship. Access to this information enables a user to compromise these users’ accounts if the password reset API endpoints have been enabled. In a worst-case scenario, a low-privileged user could get access to a high-privileged API account, and could read and modify any data as well as block access to both the admin panel and API by revoking privileges for all other users.

CVSS 3.1 base score: 7.5 (High)
CVSS 3.1 vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H/E:P/RL:O/RC:C

Remediation

CVE-2022-30617

Strapi v3: Upgrade to Strapi v3.6.10 or later
Strapi v4: Upgrade to latest stable release build (this issue only affected prerelease versions)
See release notes for latest version available: https://github.com/strapi/strapi/releases

CVE-2022-30618

Strapi v3: Upgrade to Strapi v3.6.10 or later
Strapi v4: Upgrade to Strapi v4.1.10 or later
See release notes for latest version available: https://github.com/strapi/strapi/releases 

Discovery credit

As the researcher who discovered these vulnerabilities, I would like to commend Strapi team for their responsiveness and for addressing these vulnerabilities in a timely manner.

Timeline

CVE-2022-30617

  • November 19, 2021: Initial disclosure
  • November 22, 2021: Strapi security team confirms receipt of the disclosure
  • November 25, 2021: Strapi v4.0.0-beta.16 (prerelease) is released with a fix for CVE-2022-30617
  • November 30, 2021: Strapi v4.0.0 stable is released and includes the fix above from the v4 prerelease
  • May 11, 2022: Strapi v3.6.10 is released with a fix for CVE-2022-30617 in the Strapi v3 branch
  • May 19, 2022: Advisory published by Black Duck

CVE-2022-30618

  • November 25, 2021: Initial disclosure after review of fix for CVE-2022-30617 revealed that a similar issue could in certain cases be exploited against a different set of users (API users managed by the plugin “users-permissions”)
  • December 09, 2021: Additional information is provided to Strapi to clarify conditions for how the vulnerability can be exploited
  • December 10, 2021: Strapi security team confirms receipt of the disclosure
  • May 11, 2022: Strapi v3.6.10 and v4.1.10 are released with a fix for CVE-2022-30618
  • May 19, 2022: Advisory published by Black Duck

Continue Reading

Explore Topics