Executive brief
Strapi is an open-source headless CMS that manages content types and their attributes. A flaw in how Strapi handles content-type extension allows developers or plugins to inadvertently remove access restrictions from sensitive fields, causing private attributes to become publicly accessible. This can expose sensitive data such as password hashes or enable unauthorized system access.
Technical details
The vulnerability is an information disclosure (CWE-200) in Strapi's content-type handling. When extending a content-type via strapi.container.get('content-types').extend(), copying the content-type object removes the privateAttributes getter, causing all attributes to be treated as public during sanitization. An attacker with admin-level access can extend content-types at runtime (e.g., in bootstrap functions) to expose private fields. No user interaction is required once the malicious extension is deployed. The vulnerability affects @strapi/strapi, @strapi/utils, and @strapi/database versions prior to 4.10.8, which introduced fixes to preserve attribute access controls.
Affected products
- Strapi strapi < 4.10.8
- Strapi utils < 4.10.8
- Strapi database < 4.10.8
Timeline
- 2023-07-25: disclosed
- 2023-07-25: patched: Fixed in version 4.10.8