# CVE-2024-52812: LF Edge eKuiper has Stored XSS in Rules Functionality

> An attacker with rule modification rights can inject XSS payloads into rule IDs, allowing them to execute scripts in the browsers of other users, including administrators.

- **Severity:** Medium 5.4 (`CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Any signed-in user
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 10 Mar 2025
- **Updated:** 11 Mar 2025
- **Also known as:** GHSA-6hrw-x7pr-4mp8, GO-2025-3508

## What is CVE-2024-52812?

CVE-2024-52812 is a medium-severity cross-site scripting vulnerability in lf-edge ekuiper, published on 10 Mar 2025. Any signed-in user can exploit it over the network, with no action from the victim.

### Official description

LF Edge eKuiper is an internet-of-things data analytics and stream processing engine. Prior to version 2.0.8, auser with rights to modify the service (e.g. kuiperUser role) can inject a cross-site scripting payload into the rule `id` parameter. Then, after any user with access to this service (e.g. admin) tries make any modifications with the rule (update, run, stop, delete), a payload acts in the victim's browser. Version 2.0.8 fixes the issue.

Weakness: CWE-79 (Improper Neutralization of Input During Web Page Generation)

## Which versions are affected by CVE-2024-52812?

6 open source packages ship an affected version, including github.com/lf-edge/ekuiper and github.com/lf-edge/ekuiper/v2.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `github.com/lf-edge/ekuiper` | Go | All versions | None |
| `github.com/lf-edge/ekuiper` | Go | All versions to 1.14.7 | None |
| `github.com/lf-edge/ekuiper` | Go | All versions to 1.14.7 | None |
| `github.com/lf-edge/ekuiper/v2` | Go | All versions | 2.0.8 |
| `github.com/lf-edge/ekuiper/v2` | Go | All versions | 2.0.8 |
| `github.com/lf-edge/ekuiper/v2` | Go | All versions | 2.0.8 |

## How do I fix CVE-2024-52812?

Upgrade to a fixed version.

## Is CVE-2024-52812 being exploited?

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

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2024-52812 and fix it if it is affected.

What it is: CVE-2024-52812 is a medium-severity cross-site scripting vulnerability in lf-edge ekuiper, published on 10 Mar 2025. Any signed-in user can exploit it over the network, with no action from the victim.
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-52812 exists.

Affected packages and fixed versions:
- github.com/lf-edge/ekuiper (Go): affected all versions; no fix listed
- github.com/lf-edge/ekuiper (Go): affected all versions up to 1.14.7; no fix listed
- github.com/lf-edge/ekuiper (Go): affected all versions up to 1.14.7; no fix listed
- github.com/lf-edge/ekuiper/v2 (Go): affected all versions; fixed in 2.0.8
- github.com/lf-edge/ekuiper/v2 (Go): affected all versions; fixed in 2.0.8
- github.com/lf-edge/ekuiper/v2 (Go): affected all versions; fixed in 2.0.8

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-2024-52812/ (Markdown: https://insights.sbomify.com/CVE-2024-52812/index.md)
```

## Sources

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

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