Return to Threats

Telegram Desktop Flaw Lets Hidden JavaScript Exfiltrate Messages From HTML Exports

thehackernews.com 2026-09-14 data leakage Medium

What Happened

A flaw in Telegram Desktop let a bot's message plant hidden JavaScript inside chats that users exported to HTML files, security researchers at ExPatch said in a writeup published on September 12. In Telegram, the message looked ordinary, with a link button, and the script ran only when someone opened the export file in a web browser. It could then copy every message in that file to

Why It Matters

Report facts: Security researchers from ExPatch disclosed a flaw in Telegram Desktop where a bot could send a seemingly normal message containing a link button that, when chats were exported to HTML and opened in a browser, executed hidden JavaScript. That script could then exfiltrate all messages contained in the HTML export file, compromising the confidentiality of the chat history. RealGround analysis: While this issue targets Telegram’s client export mechanism rather than an AI model directly, it illustrates a broader data leakage pattern where untrusted, script-capable content embedded in exports or logs can exfiltrate sensitive data when rendered. For AI systems that generate or store HTML or rich content (e.g., agent logs, report exports), secure agent design and ongoing red teaming should ensure exports are script-sanitized, rendered in hardened contexts, and tested against similar content-based exfiltration paths.

Healthcare Fintech SaaS SMB AI startups

RealGround Analysis

This signal maps to data leakage. Organizations using AI agents, LLM APIs, SaaS integrations, or sensitive data workflows should review whether this class of issue could create unauthorized tool execution, data leakage, weak approval gates, or unmanaged supply-chain exposure.

Recommended Actions

  • Restrict AI agent tool permissions and production write paths.
  • Review sensitive data access across prompts, logs, embeddings, memory, and SaaS integrations.
  • Add human approval workflows for high-impact or state-changing actions.
  • Run prompt injection and indirect prompt injection tests against affected workflows.
  • Document the owner, control gap, and remediation deadline for this risk class.

Source

https://thehackernews.com/2026/09/telegram-desktop-flaw-lets-hidden.html

Talk to AI CISO