CVE-2024-7456 SQL Injection in lunary-ai/lunary

Critical 9.8 Published Updated

Attackers can execute arbitrary SQL commands via the external-users API route, leading to data loss or modification.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
None listed

What is CVE-2024-7456?

CVE-2024-7456 is a critical SQL injection vulnerability in Lunary Lunary, published on 1 Nov 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

A SQL injection vulnerability exists in the `/api/v1/external-users` route of lunary-ai/lunary version v1.4.2. The `order by` clause of the SQL query uses `sql.unsafe` without prior sanitization, allowing for SQL injection. The `orderByClause` variable is constructed without server-side validation or sanitization, enabling an attacker to execute arbitrary SQL commands. Successful exploitation can lead to complete data loss, modification, or corruption.

Weakness: CWE-89

Which versions are affected by CVE-2024-7456?

It affects 1 product.

Products include Lunary Lunary.

How do I fix CVE-2024-7456?

No fix has been published for CVE-2024-7456 yet. Limit exposure of the affected software until one is available.

Use parameterised queries everywhere and never build SQL by joining strings. Upgrade affected software first; a web application firewall only buys time. More about SQL injection.

Is CVE-2024-7456 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-7456 exists.

Public exploit code: 1 proofs of concept on GitHub.

All Lunary Lunary vulnerabilities

Sources

Also known as GHSA-g58p-2mpf-2cpr.

Is CVE-2024-7456 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free