Skip to content
SQL injection Disclosed report Intermediate CVE-2023-2338

SQL Injection in AssetController

The AssetController in Pimcore concatenates unsanitised strings into a SQL WHERE clause, allowing SQL injection. An attacker could dump the database, alter data, or cause a denial of service on the backend database.

pimcore/pimcore

Originally disclosed on huntr

Impact

SQL injections in AssetController due to unsanitized concatenating strings in where clause. The attacker can dump database, alter data or perform dos on the backend database.

Patches

Update to version 10.5.21 or apply this patch manually https://github.com/pimcore/pimcore/commit/21e35af721c375ef4676ed50835e30d828e76520.patch

Workarounds

Apply patch https://github.com/pimcore/pimcore/commit/21e35af721c375ef4676ed50835e30d828e76520.patch manually.

References

https://huntr.dev/bounties/bbf59fa7-cf5b-4945-81b0-328adc710462/

From the GitHub Advisory Database (GHSA-4x35-vr82-xvj6, CC BY 4.0).

The original report as published on the GitHub Advisory Database. Images and videos are our own copies; raw HTML is shown as text. View it on GitHub Advisory Database.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the AssetController builds a SQL WHERE clause by concatenating unsanitised user input instead of using parameterised queries.

Impact

An attacker could dump the database, alter data, or perform a denial of service on the backend database.

What the attacker needed

Access to the AssetController endpoint

The fix

It was fixed in version 10.5.21, or the provided patch can be applied manually.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

SQL injection is when user input is inserted directly into a database query without being cleaned, so an attacker can change the query's meaning. Here, the AssetController builds part of a database query by joining strings together, so a crafted input can make the database return or change data it should not. The result could be reading the whole database, modifying records, or making the database unavailable.

What is SQL injection?

Input reaches a database query as code, letting an attacker read or change data the application never meant to expose.

More from pimcore/pimcore

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

SQL injection

The lesson behind this report.

Input reaches a database query as code, letting an attacker read or change data the application never meant to expose.