# CVE-2026-59707: LocalAI - Server-Side Request Forgery via POST /models/apply

- Severity: Critical 9.2 (CVSS:4.0, scored by VulnCheck) `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:H/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.59%, higher than 76% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-07-07T20:37:53.194Z
- Modified: 2026-10-25T20:10:00.147Z
- Also known as: GHSA-8c5q-hx4g-qq23, GO-2026-6645
- Weaknesses: CWE-918
- SSVC (CISA-ADP): exploitation poc, automatable yes, technical impact partial
- Assigned by: VulnCheck

## Description

LocalAI contains an unauthenticated server-side request forgery vulnerability in the POST /models/apply endpoint that allows attackers to fetch arbitrary internal URLs. The endpoint passes unsanitized gallery URL fields directly to gallery.GetGalleryConfigFromURLWithContext without proper validation, enabling attackers to force the server to issue HTTP GET requests to private and loopback ranges with partial response content leaked through error messages.

(As written by CVE List.)

## Affected

- LocalAI LocalAI: up to v4.3.1
- github.com/mudler/LocalAI (Go): before 1.40.1-0.20260703213242-2cbb3c96b34d

## Every score

- VulnCheck: CVSS:4.0 9.2 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:H/SI:N/SA:N`
- VulnCheck: CVSS:3.1 8.6 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:N`
- GitHub: CVSS:3.1 8.6 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:N`
- GitHub: CVSS:4.0 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:H/SI:N/SA:N`

## References

- <https://github.com/mudler/LocalAI/issues/10665> (exploit, issue-tracking, report, web)
- <https://github.com/mudler/LocalAI> (package, product)
- <https://github.com/mudler/LocalAI/commit/f9b968e19d7cbc556d59dceb2e0e450b828a3fda> (fix, patch, web)
- <https://www.vulncheck.com/advisories/localai-server-side-request-forgery-via-post-models-apply> (third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-59707> (advisory)
- <https://github.com/advisories/GHSA-8c5q-hx4g-qq23> (advisory)

## Sources

- CVE List: [CVE-2026-59707](https://www.cve.org/CVERecord?id=CVE-2026-59707), CVE Terms of Use, modified 2026-09-24
- GitHub Advisory Database: [GHSA-8c5q-hx4g-qq23](https://github.com/advisories/GHSA-8c5q-hx4g-qq23), CC-BY-4.0, modified 2026-10-07
- Go Vulnerability Database: [GO-2026-6645](https://pkg.go.dev/vuln/GO-2026-6645), CC-BY-4.0, modified 2026-10-07
- NVD: [CVE-2026-59707](https://nvd.nist.gov/vuln/detail/CVE-2026-59707), Public domain, modified 2026-10-25

---

Page: https://cve.day/CVE-2026-59707 · Whole record: https://cve.day/CVE-2026-59707.json · Rebuilt by cve.day 2026-11-25T22:59:27.319Z
