Back to skill

Security audit

Telegram Toolkit Free

Security checks for vulnerabilities and agentic risk

Overview

This is a Telegram bot guidance skill with expected Telegram API examples, though its activation wording is broader than it needs to be.

Install only if you want Telegram bot design and implementation help. Treat the sample curl and Python snippets as examples, keep TG_BOT_TOKEN in environment variables, verify any webhook URL and commands before execution, and do not rely on this skill as a general AI/LLM workflow skill despite its broad wording.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • YARA SignaturesMalware Match, Webshell Match, Cryptominer Match
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (13)

YARA rule 'agent_skill_credential_exfiltration_webhook': AI agent skill credential harvesting followed by webhook or external exfiltration [agent_skills]

Critical
Category
YARA Match
Confidence
85% confidence
Finding

YARA rule matched a known malware signature (reverse shell, backdoor, ransomware, C2 framework, or info stealer).

Content

Scanner excerpt · SKILL.md (reported line 110)May include surrounding context.

en格式:123456789:ABCdefGHIjklMNOpqrSTUvwxYZ

...

通过环境变量注入(禁止硬编码)

export TG_BOT_TOKEN="123456789:ABCdefGHIjklMNOpqrSTUvwxYZ"

text

### 第二步:选择更新处理策略

```bash
# 策略一:长轮询(开发环境推荐,无需公网IP)
# 主动调用 getUpdates 拉取更新
# ...
# 策略二:Webhook(生产环境推荐,实时性好)
curl -X POST "https://api.telegram.org/bot${TG_BOT_TOKEN}/setWebhook" \
  -d "url=https://your-domain.com/webhook" \
  -d "secret_token=your_secret_token"

第三步:实现命令路由

python
import os
import requests
# ...
TOKEN = os.environ["TG_BOT_TOKEN"]
API = f"https://api.telegram.org/bot{TOKEN}"
# ...
def handle_update(update):
    message = update.get("message", {})
    text = message.get("text", "")
    chat_id = message.get("chat", {}).get("id")
# ...
    if text == "/start":
        reply = "欢迎使用!输入 /help 查看可用命令。"
    el

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The description says to use the skill whenever AI model calling, intelligent dialogue, agent orchestration, or LLM applications are needed. Those triggers are extremely broad and overlap with many generic AI tasks, making it unclear when this Telegram-specific skill should activate versus other skills.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The manifest description frames the skill as a Telegram Bot workflow design tool centered on command routing, update handling, HTTP templates, and security configuration. However, lines L046-L070 describe broad generic execution capabilities such as create/query/modify/delete, import/reset, and export/save/convert, which read as a general-purpose operation framework rather than a narrowly Telegram-focused design aid.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The skill describes write/modify/delete/export/save-style operations without clear safety boundaries, approval requirements, or impact warnings. In an agent environment with read/write/exec tools, ambiguous action language can cause the model to perform state-changing or data-moving operations without adequate user confirmation, increasing the risk of unintended destructive changes or disclosure.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The coverage statement includes generic keywords like "Agent", "Use", "when", "模型调用", "智能对话", and "LLM", which are not specific enough to Telegram bot workflows. This broad keyword list could cause unintended invocation because it lacks clear boundaries and negative examples.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · SKILL.md (reported line 110)May include surrounding context.

主动调用 getUpdates 拉取更新

...

策略二:Webhook(生产环境推荐,实时性好)

curl -X POST "https://api.telegram.org/bot${TG_BOT_TOKEN}/setWebhook"
-d "url=https://your-domain.com/webhook"
-d "secret_token=your_secret_token"

text

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · SKILL.md (reported line 110)May include surrounding context.

主动调用 getUpdates 拉取更新

...

策略二:Webhook(生产环境推荐,实时性好)

curl -X POST "https://api.telegram.org/bot${TG_BOT_TOKEN}/setWebhook"
-d "url=https://your-domain.com/webhook"
-d "secret_token=your_secret_token"

text

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · SKILL.md (reported line 122)May include surrounding context.

主动调用 getUpdates 拉取更新

...

策略二:Webhook(生产环境推荐,实时性好)

curl -X POST "https://api.telegram.org/bot${TG_BOT_TOKEN}/setWebhook"
-d "url=https://your-domain.com/webhook"
-d "secret_token=your_secret_token"

text

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · SKILL.md (reported line 153)May include surrounding context.

主动调用 getUpdates 拉取更新

...

策略二:Webhook(生产环境推荐,实时性好)

curl -X POST "https://api.telegram.org/bot${TG_BOT_TOKEN}/setWebhook"
-d "url=https://your-domain.com/webhook"
-d "secret_token=your_secret_token"

text

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · SKILL.md (reported line 166)May include surrounding context.

主动调用 getUpdates 拉取更新

...

策略二:Webhook(生产环境推荐,实时性好)

curl -X POST "https://api.telegram.org/bot${TG_BOT_TOKEN}/setWebhook"
-d "url=https://your-domain.com/webhook"
-d "secret_token=your_secret_token"

text

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · SKILL.md (reported line 138)May include surrounding context.

md
else:
        reply = "未知命令,输入 /help 查看可用命令"
# ...
    requests.post(f"{API}/sendMessage", json={
        "chat_id": chat_id,
        "text": reply
    })

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · SKILL.md (reported line 185)May include surrounding context.

md
else:
        reply = "未知命令,输入 /help 查看可用命令"
# ...
    requests.post(f"{API}/sendMessage", json={
        "chat_id": chat_id,
        "text": reply
    })

Description-Behavior Mismatch

Low
Category
Not specified by scanner
Confidence
77% confidence
Finding

The manifest and summary position this as a free edition focused on core Telegram bot workflow design. Yet the capability text says the skill supports creation, querying, modification, deletion, import, reset, export, save, and conversion, implying a wider operational surface than the narrowly scoped 'design tool free edition' description suggests.

Content

No source excerpt is available for this finding.