# CVE-2026-22813: Malicious website can execute commands on the local system through XSS in the OpenCode web UI

- Severity: Critical 9.4 (CVSS:4.0, scored by GitHub_M) `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H`
- 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): 0.91%, higher than 60% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-01-12T22:52:35.103Z
- Modified: 2026-06-17T10:20:28.463Z
- Also known as: GHSA-c83v-7274-4vgp
- Weaknesses: CWE-79
- SSVC (CISA-ADP): exploitation poc, automatable yes, technical impact total
- Assigned by: GitHub_M

## Description

OpenCode is an open source AI coding agent. The markdown renderer used for LLM responses will insert arbitrary HTML into the DOM. There is no sanitization with DOMPurify or even a CSP on the web interface to prevent JavaScript execution via HTML injection. This means controlling the LLM response for a chat session gets JavaScript execution on the http://localhost:4096 origin. This vulnerability is fixed in 1.1.10.

(As written by CVE List.)

## Affected

- anomalyco opencode: < 1.1.10
- opencode-ai (npm): before 1.1.10
- anoma opencode: before 1.1.10

## Every score

- GitHub_M: CVSS:4.0 9.4 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H`
- GitHub: CVSS:4.0 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H`
- NVD: CVSS:3.1 6.1 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`

## References

- <https://github.com/anomalyco/opencode/security/advisories/GHSA-c83v-7274-4vgp> (exploit, vendor-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-22813> (advisory)
- <https://github.com/anomalyco/opencode> (package)

## Sources

- CVE List: [CVE-2026-22813](https://www.cve.org/CVERecord?id=CVE-2026-22813), CVE Terms of Use, modified 2026-01-13
- GitHub Advisory Database: [GHSA-c83v-7274-4vgp](https://github.com/advisories/GHSA-c83v-7274-4vgp), CC-BY-4.0, modified 2026-02-03
- NVD: [CVE-2026-22813](https://nvd.nist.gov/vuln/detail/CVE-2026-22813), Public domain, modified 2026-06-17

---

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