Skip to content
Malware

Here is How Analysts Use Telegram API to Intercept Data Exfiltrated by Malware

Threat actors are increasingly relying on Telegram and Discord apps for data exfiltration. Analysts at ANY.RUN shared a detailed guide to intercepting data stolen by malware from infected machines via these apps. The researchers outlined each step of the process and provided actionable tips that can...

· Mar 18, 2026 · 3 min read · 👁 2 views
Here is How Analysts Use Telegram API to Intercept Data Exfiltrated by Malware

Telegram API to Intercept Data Exfiltrated by Malware

Collecting Threat Actors’ Chat ID and Bot Token

Image

The query and results in Threat Intelligence Lookup

After discovering a sample, the analysts once again detonated it in the sandbox to observe all the requests directed to api.telegram.org to examine its interaction with Telegram’s API.

Image

After analyzing the malware’s POST requests, the analysts collected case, the bot token (a key used for authentication) and the chat_id (which identifies the recipient chat).

Image

The sandbox also allowed researchers to view the server’s response, which contained useful information in JSON format, including chat_id, bot username, bot name, chat name, and chat type.

google

Extracting Data Exfiltrated by Malware

After acquiring the attacker’s chat_id and bot token , the analysts initiated the process of checking whether the bot has a webhook.

If a webhook is present, it’s crucial to save its data and then delete it using the /deleteWebhook method.

Once the webhook is handled, the analysts created a Telegram group and added a bot to it.

Image

Upon request, the message was forwarded to the group.

Using the /forwardMessage method with the extracted chat_id and message_id , the analysts were finally able to forward the desired message from the attacker’s chat to the group.

Integrate Private ANY.RUN Malware Sandbox in Your Organization

  • Private mode : Securely analyze malware in a completely isolated environment, ensuring privacy and protection.

  • Real-time interaction : Interact directly with the system to see how malware responds to your inputs.

  • Windows and Linux VM support : Investigate suspicious files on different operating systems to capture platform-specific threats.

  • Detailed reporting : Receive comprehensive reports, including all Indicators of Compromise (IOCs), network activity, and process trees for thorough analysis.

Source: CybersecurityNews.com

Follow ShomoySoft for more: Follow on Facebook

💬 Comments (0)

Login to join the discussion.

No comments yet. Be the first!

Related Articles

Recommended for you