# CVE-2024-9900: Cross-Site Scripting (XSS) in mudler/localai

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.4
- **CVSS:** 5.4 (v3.0, CNA) `CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Privileges required: None; User interaction: Required; Scope: Unchanged; Confidentiality impact: Low; Integrity impact: Low; Availability impact: None
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** Yes (see exploit references)
- **Remote exploitation:** Remote, no login needed
- **EPSS:** 0.56% (percentile 41, 2026-11-28)
- **CWE:** CWE-79
- **Aliases:** GHSA-w6hh-w36c-vxmw, GO-2025-3542
- **Published:** 2025-03-20T10:09:14.108Z
- **Modified:** 2026-06-17T08:25:28.040Z

## Who should check

- Projects that depend on Go package github.com/mudler/LocalAI (\< 2.22.0)
- Anyone running mudler/localai \>= unspecified, \< 2.22.0

## Description

mudler/localai version v2.21.1 contains a Cross-Site Scripting (XSS) vulnerability in its search functionality. The vulnerability arises due to improper sanitization of user input, allowing the injection and execution of arbitrary JavaScript code. This can lead to the execution of malicious scripts in the context of the victim's browser, potentially compromising user sessions, stealing session cookies, redirecting users to malicious websites, or manipulating the DOM.

## Affected and fixed versions

- Go `github.com/mudler/LocalAI`: affected \< 2.22.0; fixed 2.22.0 (osv)
- mudler/localai: \>= unspecified, \< 2.22.0 (cvelist)

## Mitigation

- Upgrade github.com/mudler/LocalAI to 2.22.0 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2024-9900. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2024-9900.md
Affected: github.com/mudler/LocalAI < 2.22.0
Fixed in: 2.22.0

Steps:
1. Search this machine and project for github.com/mudler/LocalAI (Go), mudler/localai: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2024-9900 being exploited?

There is no confirmed exploitation: CVE-2024-9900 is not in the CISA Known Exploited Vulnerabilities catalog. Public exploit code or a proof of concept is available. EPSS estimates a 0.56% chance of exploitation in the next 30 days (as of 2026-11-28).

### How serious is CVE-2024-9900?

Medium: CVSS 5.4 (v3.0, scored by CNA). Remote, no login needed. A user has to take an action, such as opening a link, for the attack to work.

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

github.com/mudler/LocalAI \< 2.22.0.

### Is there a fix for CVE-2024-9900?

Yes. Fixed in 2.22.0. Upgrade github.com/mudler/LocalAI to 2.22.0 or later.

### How do I check if I'm affected by CVE-2024-9900?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://nvd.nist.gov/vuln/detail/CVE-2024-9900>
- vendor: <https://github.com/advisories/GHSA-w6hh-w36c-vxmw>
- patch: <https://github.com/mudler/localai/commit/a1634b219a4e52813e70ff07e6376a01449c4515>
- exploit: <https://huntr.com/bounties/b39cd230-db66-471b-89b9-24afaa078e68>
- other: <https://github.com/mudler/LocalAI>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2024-9900>
- OSV: CC-BY 4.0 <https://osv.dev/vulnerability/GHSA-w6hh-w36c-vxmw> (license: <https://creativecommons.org/licenses/by/4.0/>)
- OSV: CC-BY 4.0 <https://osv.dev/vulnerability/GO-2025-3542> (license: <https://creativecommons.org/licenses/by/4.0/>)

HTML: <https://flawdb.com/CVE-2024-9900> · JSON: <https://flawdb.com/api/v1/entries/CVE-2024-9900>
