Back to skill

Security audit

Where Am I Burning Tokens?

Security checks for vulnerabilities and agentic risk

Overview

This skill is a scoped token-usage diagnostic that reads OpenClaw session totals and only writes a small local savings log when the user explicitly asks.

Installers should understand that the normal workflow reads OpenClaw session usage totals, which may reveal models, timestamps, costs, and session categories. Only ask it to log improvements if you are comfortable creating a local token-diet-log.md history file under the OpenClaw workspace memory directory.

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
  • Rogue AgentSelf-Modification, Session Persistence
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (1)

Session Persistence

Medium
Category
Rogue Agent
Confidence
90% confidence
Finding

The skill claims to be read-only, but the optional improvement log explicitly instructs the agent to create and append to a persistent file under ~/.openclaw/workspace/memory/token-diet-log.md. This introduces session persistence and local state mutation, which can violate user expectations, create privacy/retention concerns, and be abused to store unintended data over time if the user triggers the logging path.

Content

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

md
## Improvement log (optional)

Only if the user explicitly asks to log an improvement or track savings:
- Read/create `~/.openclaw/workspace/memory/token-diet-log.md`
- Append entry: date, what changed, token % before/after, cost before/after
- Show running total saved

Static analysis

No suspicious patterns detected.