# CVE-2026-22599: Strapi Vulnerable to SQL Injection in Content Type Builder

> Authenticated administrators can execute arbitrary SQL commands via the Content-Type Builder API, potentially leading to remote code execution or data theft.

- **Severity:** Critical 9.3 (`CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N`)
- **Exploited in the wild:** Not known
- **Login needed:** An administrator
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 14 May 2026
- **Updated:** 14 May 2026
- **Also known as:** GHSA-3xcq-8mjw-h6mx

## What is CVE-2026-22599?

CVE-2026-22599 is a critical SQL injection vulnerability in @strapi/content-type-builder, published on 14 May 2026. An attacker needs administrator access to exploit it, with no action from the victim.

### Official description

Strapi is an open source headless content management system. In versions on the 4.x branch prior to 4.26.1 and on the 5.x branch prior to 5.33.2, a database-query injection vulnerability existed in the Strapi Content-Type Builder write API. An authenticated administrator could inject arbitrary database statements through the `column.defaultTo` attribute when creating or modifying a content type. Setting `defaultTo` as a tuple `[value, { isRaw: true }]` caused the value to be passed directly into Knex's `db.connection.raw()` during schema migration without sanitization, allowing arbitrary statement execution at the database layer. Depending on the database engine, this enabled arbitrary file read via database utility functions, denial of service via forced server crash on schema-migration error, and on engines that permit external program execution, remote code execution against the database server. The patch in versions 4.26.1 and 5.33.2 addresses this by restricting all Content-Type Builder write APIs to development mode only. Production deployments running v5.33.2 or later return 404 for requests against `/content-type-builder/content-types` and related endpoints, removing the network-reachable attack surface entirely.

Weakness: CWE-89 (Improper Neutralization of Special Elements used in an SQL Command)

## Which versions are affected by CVE-2026-22599?

4 open source packages ship an affected version, including @strapi/content-type-builder and @strapi/plugin-content-type-builder. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `@strapi/content-type-builder` | npm | From 5.0.0 | 5.33.2 |
| `@strapi/content-type-builder` | npm | From 5.0.0 | 5.33.2 |
| `@strapi/plugin-content-type-builder` | npm | From 4.0.0 | 4.26.1 |
| `@strapi/plugin-content-type-builder` | npm | From 4.0.0 | 4.26.1 |

Products: Strapi Strapi.

## How do I fix CVE-2026-22599?

Upgrade @strapi/content-type-builder to 5.33.2 or later.

## Is CVE-2026-22599 being exploited?

There is no known exploitation of CVE-2026-22599 in the wild and no public exploit code.

Public exploit code:

- CVE-2026-22599 - Strapi - Critical 9.3 - Authenticated POST /content-type-builder/content-types - Authenticated SQL Injection (Knex raw defaultTo) (github_poc): https://github.com/abraxas/CVE-2026-22599

## Other vulnerabilities in @strapi/content-type-builder

- [CVE-2023-22894](https://insights.sbomify.com/CVE-2023-22894/): Strapi Cleartext Storage of Sensitive Information (high 7.2, exploited in the wild)
- [CVE-2023-22621](https://insights.sbomify.com/CVE-2023-22621/): Strapi plugins vulnerable to Server-Side Template Injection and Remote Code Execution in the Users-Permissions Plugin (critical 10.0)
- [CVE-2022-27263](https://insights.sbomify.com/CVE-2022-27263/): Unrestricted Upload of File with Dangerous Type in Strapi (critical 9.8)
- [CVE-2020-27664](https://insights.sbomify.com/CVE-2020-27664/): Authorization bypass in Strapi (critical 9.8)
- [CVE-2019-18818](https://insights.sbomify.com/CVE-2019-18818/): Strapi allows unauthenticated attacker to reset admin password without valid reset token (critical 9.8)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2026-22599 and fix it if it is affected.

What it is: CVE-2026-22599 is a critical SQL injection vulnerability in @strapi/content-type-builder, published on 14 May 2026. An attacker needs administrator access to exploit it, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2026-22599 in the wild and no public exploit code.

Affected packages and fixed versions:
- @strapi/content-type-builder (npm): affected from 5.0.0; fixed in 5.33.2
- @strapi/content-type-builder (npm): affected from 5.0.0; fixed in 5.33.2
- @strapi/plugin-content-type-builder (npm): affected from 4.0.0; fixed in 4.26.1
- @strapi/plugin-content-type-builder (npm): affected from 4.0.0; fixed in 4.26.1

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2026-22599/ (Markdown: https://insights.sbomify.com/CVE-2026-22599/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2026-22599
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-22599
- OSV: https://osv.dev/vulnerability/CVE-2026-22599

---
From sbomify Insights: https://insights.sbomify.com/CVE-2026-22599/
Summaries are generated and may contain mistakes; the official description above is the record.
